aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorPekka Enberg <penberg@cs.helsinki.fi>2007-11-30 02:54:33 -0500
committerDavid S. Miller <davem@davemloft.net>2008-01-28 18:05:51 -0500
commit6d3b2cb92bee1cec43c716f4cd6554be1e6b36ea (patch)
treeff284c9bbe7a1a08c28c9b5e9d55680b5acfcb0a /drivers
parent1662e4b7af956979c6cb864bf23cf88f882cdaf8 (diff)
ipg: remove commented out code
Signed-off-by: Pekka Enberg <penberg@cs.helsinki.fi> Cc: Francois Romieu <romieu@fr.zoreil.com> Cc: Sorbica Shieh <sorbica@icplus.com.tw> Cc: Jesse Huang <jesse@icplus.com.tw>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/net/ipg.c34
-rw-r--r--drivers/net/ipg.h4
2 files changed, 7 insertions, 31 deletions
diff --git a/drivers/net/ipg.c b/drivers/net/ipg.c
index 7f85732f03e9..9e228e7d3bef 100644
--- a/drivers/net/ipg.c
+++ b/drivers/net/ipg.c
@@ -1483,35 +1483,13 @@ static int ipg_nic_rx(struct net_device *dev)
1483 /* Set the buffer's protocol field to Ethernet. */ 1483 /* Set the buffer's protocol field to Ethernet. */
1484 skb->protocol = eth_type_trans(skb, dev); 1484 skb->protocol = eth_type_trans(skb, dev);
1485 1485
1486 /* If the frame contains an IP/TCP/UDP frame, 1486 /* The IPG encountered an error with (or
1487 * determine if upper layer must check IP/TCP/UDP 1487 * there were no) IP/TCP/UDP checksums.
1488 * checksums. 1488 * This may or may not indicate an invalid
1489 * 1489 * IP/TCP/UDP frame was received. Let the
1490 * NOTE: DO NOT RELY ON THE TCP/UDP CHECKSUM 1490 * upper layer decide.
1491 * VERIFICATION FOR SILICON REVISIONS B3
1492 * AND EARLIER!
1493 *
1494 if ((le64_to_cpu(rxfd->rfs &
1495 (IPG_RFS_TCPDETECTED | IPG_RFS_UDPDETECTED |
1496 IPG_RFS_IPDETECTED))) &&
1497 !(le64_to_cpu(rxfd->rfs &
1498 (IPG_RFS_TCPERROR | IPG_RFS_UDPERROR |
1499 IPG_RFS_IPERROR)))) {
1500 * Indicate IP checksums were performed
1501 * by the IPG.
1502 *
1503 skb->ip_summed = CHECKSUM_UNNECESSARY;
1504 } else
1505 */ 1491 */
1506 { 1492 skb->ip_summed = CHECKSUM_NONE;
1507 /* The IPG encountered an error with (or
1508 * there were no) IP/TCP/UDP checksums.
1509 * This may or may not indicate an invalid
1510 * IP/TCP/UDP frame was received. Let the
1511 * upper layer decide.
1512 */
1513 skb->ip_summed = CHECKSUM_NONE;
1514 }
1515 1493
1516 /* Hand off frame for higher layer processing. 1494 /* Hand off frame for higher layer processing.
1517 * The function netif_rx() releases the sk_buff 1495 * The function netif_rx() releases the sk_buff
diff --git a/drivers/net/ipg.h b/drivers/net/ipg.h
index 4f4919282646..7e3ccd103630 100644
--- a/drivers/net/ipg.h
+++ b/drivers/net/ipg.h
@@ -23,7 +23,6 @@
23#include <linux/skbuff.h> 23#include <linux/skbuff.h>
24#include <linux/version.h> 24#include <linux/version.h>
25#include <asm/bitops.h> 25#include <asm/bitops.h>
26/*#include <asm/spinlock.h>*/
27 26
28/* 27/*
29 * Constants 28 * Constants
@@ -733,8 +732,7 @@ enum ipg_regs {
733 * Miscellaneous macros. 732 * Miscellaneous macros.
734 */ 733 */
735 734
736/* Marco for printing debug statements. 735/* Marco for printing debug statements. */
737# define IPG_DDEBUG_MSG(args...) printk(KERN_DEBUG "IPG: " ## args) */
738#ifdef IPG_DEBUG 736#ifdef IPG_DEBUG
739# define IPG_DEBUG_MSG(args...) 737# define IPG_DEBUG_MSG(args...)
740# define IPG_DDEBUG_MSG(args...) printk(KERN_DEBUG "IPG: " args) 738# define IPG_DDEBUG_MSG(args...) printk(KERN_DEBUG "IPG: " args)