aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/igb
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/igb')
-rw-r--r--drivers/net/igb/e1000_82575.h1
-rw-r--r--drivers/net/igb/e1000_defines.h3
-rw-r--r--drivers/net/igb/e1000_mbx.c8
-rw-r--r--drivers/net/igb/igb.h2
-rw-r--r--drivers/net/igb/igb_ethtool.c20
-rw-r--r--drivers/net/igb/igb_main.c101
6 files changed, 76 insertions, 59 deletions
diff --git a/drivers/net/igb/e1000_82575.h b/drivers/net/igb/e1000_82575.h
index eaf977050368..0f16abab2565 100644
--- a/drivers/net/igb/e1000_82575.h
+++ b/drivers/net/igb/e1000_82575.h
@@ -130,6 +130,7 @@ struct e1000_adv_tx_context_desc {
130#define E1000_ADVTXD_MACLEN_SHIFT 9 /* Adv ctxt desc mac len shift */ 130#define E1000_ADVTXD_MACLEN_SHIFT 9 /* Adv ctxt desc mac len shift */
131#define E1000_ADVTXD_TUCMD_IPV4 0x00000400 /* IP Packet Type: 1=IPv4 */ 131#define E1000_ADVTXD_TUCMD_IPV4 0x00000400 /* IP Packet Type: 1=IPv4 */
132#define E1000_ADVTXD_TUCMD_L4T_TCP 0x00000800 /* L4 Packet TYPE of TCP */ 132#define E1000_ADVTXD_TUCMD_L4T_TCP 0x00000800 /* L4 Packet TYPE of TCP */
133#define E1000_ADVTXD_TUCMD_L4T_SCTP 0x00001000 /* L4 packet TYPE of SCTP */
133/* IPSec Encrypt Enable for ESP */ 134/* IPSec Encrypt Enable for ESP */
134#define E1000_ADVTXD_L4LEN_SHIFT 8 /* Adv ctxt L4LEN shift */ 135#define E1000_ADVTXD_L4LEN_SHIFT 8 /* Adv ctxt L4LEN shift */
135#define E1000_ADVTXD_MSS_SHIFT 16 /* Adv ctxt MSS shift */ 136#define E1000_ADVTXD_MSS_SHIFT 16 /* Adv ctxt MSS shift */
diff --git a/drivers/net/igb/e1000_defines.h b/drivers/net/igb/e1000_defines.h
index ad2d319d0f8b..3bda3db73f1f 100644
--- a/drivers/net/igb/e1000_defines.h
+++ b/drivers/net/igb/e1000_defines.h
@@ -289,8 +289,9 @@
289#define E1000_SCTL_DISABLE_SERDES_LOOPBACK 0x0400 289#define E1000_SCTL_DISABLE_SERDES_LOOPBACK 0x0400
290 290
291/* Receive Checksum Control */ 291/* Receive Checksum Control */
292#define E1000_RXCSUM_IPOFL 0x00000100 /* IPv4 checksum offload */
292#define E1000_RXCSUM_TUOFL 0x00000200 /* TCP / UDP checksum offload */ 293#define E1000_RXCSUM_TUOFL 0x00000200 /* TCP / UDP checksum offload */
293#define E1000_RXCSUM_IPPCSE 0x00001000 /* IP payload checksum enable */ 294#define E1000_RXCSUM_CRCOFL 0x00000800 /* CRC32 offload enable */
294#define E1000_RXCSUM_PCSD 0x00002000 /* packet checksum disabled */ 295#define E1000_RXCSUM_PCSD 0x00002000 /* packet checksum disabled */
295 296
296/* Header split receive */ 297/* Header split receive */
diff --git a/drivers/net/igb/e1000_mbx.c b/drivers/net/igb/e1000_mbx.c
index 840782fb5736..ed9058eca45c 100644
--- a/drivers/net/igb/e1000_mbx.c
+++ b/drivers/net/igb/e1000_mbx.c
@@ -140,13 +140,13 @@ static s32 igb_poll_for_msg(struct e1000_hw *hw, u16 mbx_id)
140 struct e1000_mbx_info *mbx = &hw->mbx; 140 struct e1000_mbx_info *mbx = &hw->mbx;
141 int countdown = mbx->timeout; 141 int countdown = mbx->timeout;
142 142
143 if (!mbx->ops.check_for_msg) 143 if (!countdown || !mbx->ops.check_for_msg)
144 goto out; 144 goto out;
145 145
146 while (mbx->ops.check_for_msg(hw, mbx_id)) { 146 while (mbx->ops.check_for_msg(hw, mbx_id)) {
147 countdown--;
147 if (!countdown) 148 if (!countdown)
148 break; 149 break;
149 countdown--;
150 udelay(mbx->usec_delay); 150 udelay(mbx->usec_delay);
151 } 151 }
152out: 152out:
@@ -165,13 +165,13 @@ static s32 igb_poll_for_ack(struct e1000_hw *hw, u16 mbx_id)
165 struct e1000_mbx_info *mbx = &hw->mbx; 165 struct e1000_mbx_info *mbx = &hw->mbx;
166 int countdown = mbx->timeout; 166 int countdown = mbx->timeout;
167 167
168 if (!mbx->ops.check_for_ack) 168 if (!countdown || !mbx->ops.check_for_ack)
169 goto out; 169 goto out;
170 170
171 while (mbx->ops.check_for_ack(hw, mbx_id)) { 171 while (mbx->ops.check_for_ack(hw, mbx_id)) {
172 countdown--;
172 if (!countdown) 173 if (!countdown)
173 break; 174 break;
174 countdown--;
175 udelay(mbx->usec_delay); 175 udelay(mbx->usec_delay);
176 } 176 }
177out: 177out:
diff --git a/drivers/net/igb/igb.h b/drivers/net/igb/igb.h
index 4e8464b9df2e..154c5acc6fce 100644
--- a/drivers/net/igb/igb.h
+++ b/drivers/net/igb/igb.h
@@ -238,7 +238,6 @@ struct igb_adapter {
238 u64 hw_csum_err; 238 u64 hw_csum_err;
239 u64 hw_csum_good; 239 u64 hw_csum_good;
240 u32 alloc_rx_buff_failed; 240 u32 alloc_rx_buff_failed;
241 bool rx_csum;
242 u32 gorc; 241 u32 gorc;
243 u64 gorc_old; 242 u64 gorc_old;
244 u16 rx_ps_hdr_size; 243 u16 rx_ps_hdr_size;
@@ -286,6 +285,7 @@ struct igb_adapter {
286#define IGB_FLAG_DCA_ENABLED (1 << 1) 285#define IGB_FLAG_DCA_ENABLED (1 << 1)
287#define IGB_FLAG_QUAD_PORT_A (1 << 2) 286#define IGB_FLAG_QUAD_PORT_A (1 << 2)
288#define IGB_FLAG_NEED_CTX_IDX (1 << 3) 287#define IGB_FLAG_NEED_CTX_IDX (1 << 3)
288#define IGB_FLAG_RX_CSUM_DISABLED (1 << 4)
289 289
290enum e1000_state_t { 290enum e1000_state_t {
291 __IGB_TESTING, 291 __IGB_TESTING,
diff --git a/drivers/net/igb/igb_ethtool.c b/drivers/net/igb/igb_ethtool.c
index 27eae49e79c2..b8551a57dd3f 100644
--- a/drivers/net/igb/igb_ethtool.c
+++ b/drivers/net/igb/igb_ethtool.c
@@ -275,13 +275,17 @@ static int igb_set_pauseparam(struct net_device *netdev,
275static u32 igb_get_rx_csum(struct net_device *netdev) 275static u32 igb_get_rx_csum(struct net_device *netdev)
276{ 276{
277 struct igb_adapter *adapter = netdev_priv(netdev); 277 struct igb_adapter *adapter = netdev_priv(netdev);
278 return adapter->rx_csum; 278 return !(adapter->flags & IGB_FLAG_RX_CSUM_DISABLED);
279} 279}
280 280
281static int igb_set_rx_csum(struct net_device *netdev, u32 data) 281static int igb_set_rx_csum(struct net_device *netdev, u32 data)
282{ 282{
283 struct igb_adapter *adapter = netdev_priv(netdev); 283 struct igb_adapter *adapter = netdev_priv(netdev);
284 adapter->rx_csum = data; 284
285 if (data)
286 adapter->flags &= ~IGB_FLAG_RX_CSUM_DISABLED;
287 else
288 adapter->flags |= IGB_FLAG_RX_CSUM_DISABLED;
285 289
286 return 0; 290 return 0;
287} 291}
@@ -293,10 +297,16 @@ static u32 igb_get_tx_csum(struct net_device *netdev)
293 297
294static int igb_set_tx_csum(struct net_device *netdev, u32 data) 298static int igb_set_tx_csum(struct net_device *netdev, u32 data)
295{ 299{
296 if (data) 300 struct igb_adapter *adapter = netdev_priv(netdev);
301
302 if (data) {
297 netdev->features |= (NETIF_F_IP_CSUM | NETIF_F_IPV6_CSUM); 303 netdev->features |= (NETIF_F_IP_CSUM | NETIF_F_IPV6_CSUM);
298 else 304 if (adapter->hw.mac.type == e1000_82576)
299 netdev->features &= ~(NETIF_F_IP_CSUM | NETIF_F_IPV6_CSUM); 305 netdev->features |= NETIF_F_SCTP_CSUM;
306 } else {
307 netdev->features &= ~(NETIF_F_IP_CSUM | NETIF_F_IPV6_CSUM |
308 NETIF_F_SCTP_CSUM);
309 }
300 310
301 return 0; 311 return 0;
302} 312}
diff --git a/drivers/net/igb/igb_main.c b/drivers/net/igb/igb_main.c
index e25343588fc7..ffd731539997 100644
--- a/drivers/net/igb/igb_main.c
+++ b/drivers/net/igb/igb_main.c
@@ -942,6 +942,8 @@ int igb_up(struct igb_adapter *adapter)
942 rd32(E1000_ICR); 942 rd32(E1000_ICR);
943 igb_irq_enable(adapter); 943 igb_irq_enable(adapter);
944 944
945 netif_tx_start_all_queues(adapter->netdev);
946
945 /* Fire a link change interrupt to start the watchdog. */ 947 /* Fire a link change interrupt to start the watchdog. */
946 wr32(E1000_ICS, E1000_ICS_LSC); 948 wr32(E1000_ICS, E1000_ICS_LSC);
947 return 0; 949 return 0;
@@ -1343,6 +1345,9 @@ static int __devinit igb_probe(struct pci_dev *pdev,
1343 if (pci_using_dac) 1345 if (pci_using_dac)
1344 netdev->features |= NETIF_F_HIGHDMA; 1346 netdev->features |= NETIF_F_HIGHDMA;
1345 1347
1348 if (adapter->hw.mac.type == e1000_82576)
1349 netdev->features |= NETIF_F_SCTP_CSUM;
1350
1346 adapter->en_mng_pt = igb_enable_mng_pass_thru(&adapter->hw); 1351 adapter->en_mng_pt = igb_enable_mng_pass_thru(&adapter->hw);
1347 1352
1348 /* before reading the NVM, reset the controller to put the device in a 1353 /* before reading the NVM, reset the controller to put the device in a
@@ -1390,8 +1395,6 @@ static int __devinit igb_probe(struct pci_dev *pdev,
1390 1395
1391 igb_validate_mdi_setting(hw); 1396 igb_validate_mdi_setting(hw);
1392 1397
1393 adapter->rx_csum = 1;
1394
1395 /* Initial Wake on LAN setting If APM wake is enabled in the EEPROM, 1398 /* Initial Wake on LAN setting If APM wake is enabled in the EEPROM,
1396 * enable the ACPI Magic Packet filter 1399 * enable the ACPI Magic Packet filter
1397 */ 1400 */
@@ -1442,15 +1445,14 @@ static int __devinit igb_probe(struct pci_dev *pdev,
1442 * driver. */ 1445 * driver. */
1443 igb_get_hw_control(adapter); 1446 igb_get_hw_control(adapter);
1444 1447
1445 /* tell the stack to leave us alone until igb_open() is called */
1446 netif_carrier_off(netdev);
1447 netif_tx_stop_all_queues(netdev);
1448
1449 strcpy(netdev->name, "eth%d"); 1448 strcpy(netdev->name, "eth%d");
1450 err = register_netdev(netdev); 1449 err = register_netdev(netdev);
1451 if (err) 1450 if (err)
1452 goto err_register; 1451 goto err_register;
1453 1452
1453 /* carrier off reporting is important to ethtool even BEFORE open */
1454 netif_carrier_off(netdev);
1455
1454#ifdef CONFIG_IGB_DCA 1456#ifdef CONFIG_IGB_DCA
1455 if (dca_add_requester(&pdev->dev) == 0) { 1457 if (dca_add_requester(&pdev->dev) == 0) {
1456 adapter->flags |= IGB_FLAG_DCA_ENABLED; 1458 adapter->flags |= IGB_FLAG_DCA_ENABLED;
@@ -1699,6 +1701,8 @@ static int igb_open(struct net_device *netdev)
1699 if (test_bit(__IGB_TESTING, &adapter->state)) 1701 if (test_bit(__IGB_TESTING, &adapter->state))
1700 return -EBUSY; 1702 return -EBUSY;
1701 1703
1704 netif_carrier_off(netdev);
1705
1702 /* allocate transmit descriptors */ 1706 /* allocate transmit descriptors */
1703 err = igb_setup_all_tx_resources(adapter); 1707 err = igb_setup_all_tx_resources(adapter);
1704 if (err) 1708 if (err)
@@ -2231,29 +2235,24 @@ static void igb_configure_rx(struct igb_adapter *adapter)
2231 mrqc |= (E1000_MRQC_RSS_FIELD_IPV6_UDP_EX | 2235 mrqc |= (E1000_MRQC_RSS_FIELD_IPV6_UDP_EX |
2232 E1000_MRQC_RSS_FIELD_IPV6_TCP_EX); 2236 E1000_MRQC_RSS_FIELD_IPV6_TCP_EX);
2233 2237
2234
2235 wr32(E1000_MRQC, mrqc); 2238 wr32(E1000_MRQC, mrqc);
2236 2239 } else if (adapter->vfs_allocated_count) {
2237 /* Multiqueue and raw packet checksumming are mutually
2238 * exclusive. Note that this not the same as TCP/IP
2239 * checksumming, which works fine. */
2240 rxcsum = rd32(E1000_RXCSUM);
2241 rxcsum |= E1000_RXCSUM_PCSD;
2242 wr32(E1000_RXCSUM, rxcsum);
2243 } else {
2244 /* Enable multi-queue for sr-iov */ 2240 /* Enable multi-queue for sr-iov */
2245 if (adapter->vfs_allocated_count) 2241 wr32(E1000_MRQC, E1000_MRQC_ENABLE_VMDQ);
2246 wr32(E1000_MRQC, E1000_MRQC_ENABLE_VMDQ);
2247 /* Enable Receive Checksum Offload for TCP and UDP */
2248 rxcsum = rd32(E1000_RXCSUM);
2249 if (adapter->rx_csum)
2250 rxcsum |= E1000_RXCSUM_TUOFL | E1000_RXCSUM_IPPCSE;
2251 else
2252 rxcsum &= ~(E1000_RXCSUM_TUOFL | E1000_RXCSUM_IPPCSE);
2253
2254 wr32(E1000_RXCSUM, rxcsum);
2255 } 2242 }
2256 2243
2244 /* Enable Receive Checksum Offload for TCP and UDP */
2245 rxcsum = rd32(E1000_RXCSUM);
2246 /* Disable raw packet checksumming */
2247 rxcsum |= E1000_RXCSUM_PCSD;
2248
2249 if (adapter->hw.mac.type == e1000_82576)
2250 /* Enable Receive Checksum Offload for SCTP */
2251 rxcsum |= E1000_RXCSUM_CRCOFL;
2252
2253 /* Don't need to set TUOFL or IPOFL, they default to 1 */
2254 wr32(E1000_RXCSUM, rxcsum);
2255
2257 /* Set the default pool for the PF's first queue */ 2256 /* Set the default pool for the PF's first queue */
2258 igb_configure_vt_default_pool(adapter); 2257 igb_configure_vt_default_pool(adapter);
2259 2258
@@ -2661,7 +2660,6 @@ static void igb_watchdog_task(struct work_struct *work)
2661 } 2660 }
2662 2661
2663 netif_carrier_on(netdev); 2662 netif_carrier_on(netdev);
2664 netif_tx_wake_all_queues(netdev);
2665 2663
2666 igb_ping_all_vfs(adapter); 2664 igb_ping_all_vfs(adapter);
2667 2665
@@ -2678,7 +2676,6 @@ static void igb_watchdog_task(struct work_struct *work)
2678 printk(KERN_INFO "igb: %s NIC Link is Down\n", 2676 printk(KERN_INFO "igb: %s NIC Link is Down\n",
2679 netdev->name); 2677 netdev->name);
2680 netif_carrier_off(netdev); 2678 netif_carrier_off(netdev);
2681 netif_tx_stop_all_queues(netdev);
2682 2679
2683 igb_ping_all_vfs(adapter); 2680 igb_ping_all_vfs(adapter);
2684 2681
@@ -2712,6 +2709,8 @@ link_up:
2712 * (Do the reset outside of interrupt context). */ 2709 * (Do the reset outside of interrupt context). */
2713 adapter->tx_timeout_count++; 2710 adapter->tx_timeout_count++;
2714 schedule_work(&adapter->reset_task); 2711 schedule_work(&adapter->reset_task);
2712 /* return immediately since reset is imminent */
2713 return;
2715 } 2714 }
2716 } 2715 }
2717 2716
@@ -2895,13 +2894,13 @@ static void igb_set_itr(struct igb_adapter *adapter)
2895 switch (current_itr) { 2894 switch (current_itr) {
2896 /* counts and packets in update_itr are dependent on these numbers */ 2895 /* counts and packets in update_itr are dependent on these numbers */
2897 case lowest_latency: 2896 case lowest_latency:
2898 new_itr = 70000; 2897 new_itr = 56; /* aka 70,000 ints/sec */
2899 break; 2898 break;
2900 case low_latency: 2899 case low_latency:
2901 new_itr = 20000; /* aka hwitr = ~200 */ 2900 new_itr = 196; /* aka 20,000 ints/sec */
2902 break; 2901 break;
2903 case bulk_latency: 2902 case bulk_latency:
2904 new_itr = 4000; 2903 new_itr = 980; /* aka 4,000 ints/sec */
2905 break; 2904 break;
2906 default: 2905 default:
2907 break; 2906 break;
@@ -2920,7 +2919,8 @@ set_itr_now:
2920 * by adding intermediate steps when interrupt rate is 2919 * by adding intermediate steps when interrupt rate is
2921 * increasing */ 2920 * increasing */
2922 new_itr = new_itr > adapter->itr ? 2921 new_itr = new_itr > adapter->itr ?
2923 min(adapter->itr + (new_itr >> 2), new_itr) : 2922 max((new_itr * adapter->itr) /
2923 (new_itr + (adapter->itr >> 2)), new_itr) :
2924 new_itr; 2924 new_itr;
2925 /* Don't write the value here; it resets the adapter's 2925 /* Don't write the value here; it resets the adapter's
2926 * internal timer, and causes us to delay far longer than 2926 * internal timer, and causes us to delay far longer than
@@ -2929,7 +2929,7 @@ set_itr_now:
2929 * ends up being correct. 2929 * ends up being correct.
2930 */ 2930 */
2931 adapter->itr = new_itr; 2931 adapter->itr = new_itr;
2932 adapter->rx_ring->itr_val = 1000000000 / (new_itr * 256); 2932 adapter->rx_ring->itr_val = new_itr;
2933 adapter->rx_ring->set_itr = 1; 2933 adapter->rx_ring->set_itr = 1;
2934 } 2934 }
2935 2935
@@ -3068,11 +3068,15 @@ static inline bool igb_tx_csum_adv(struct igb_adapter *adapter,
3068 tu_cmd |= E1000_ADVTXD_TUCMD_IPV4; 3068 tu_cmd |= E1000_ADVTXD_TUCMD_IPV4;
3069 if (ip_hdr(skb)->protocol == IPPROTO_TCP) 3069 if (ip_hdr(skb)->protocol == IPPROTO_TCP)
3070 tu_cmd |= E1000_ADVTXD_TUCMD_L4T_TCP; 3070 tu_cmd |= E1000_ADVTXD_TUCMD_L4T_TCP;
3071 else if (ip_hdr(skb)->protocol == IPPROTO_SCTP)
3072 tu_cmd |= E1000_ADVTXD_TUCMD_L4T_SCTP;
3071 break; 3073 break;
3072 case cpu_to_be16(ETH_P_IPV6): 3074 case cpu_to_be16(ETH_P_IPV6):
3073 /* XXX what about other V6 headers?? */ 3075 /* XXX what about other V6 headers?? */
3074 if (ipv6_hdr(skb)->nexthdr == IPPROTO_TCP) 3076 if (ipv6_hdr(skb)->nexthdr == IPPROTO_TCP)
3075 tu_cmd |= E1000_ADVTXD_TUCMD_L4T_TCP; 3077 tu_cmd |= E1000_ADVTXD_TUCMD_L4T_TCP;
3078 else if (ipv6_hdr(skb)->nexthdr == IPPROTO_SCTP)
3079 tu_cmd |= E1000_ADVTXD_TUCMD_L4T_SCTP;
3076 break; 3080 break;
3077 default: 3081 default:
3078 if (unlikely(net_ratelimit())) 3082 if (unlikely(net_ratelimit()))
@@ -4434,20 +4438,12 @@ static void igb_receive_skb(struct igb_ring *ring, u8 status,
4434 bool vlan_extracted = (adapter->vlgrp && (status & E1000_RXD_STAT_VP)); 4438 bool vlan_extracted = (adapter->vlgrp && (status & E1000_RXD_STAT_VP));
4435 4439
4436 skb_record_rx_queue(skb, ring->queue_index); 4440 skb_record_rx_queue(skb, ring->queue_index);
4437 if (skb->ip_summed == CHECKSUM_UNNECESSARY) { 4441 if (vlan_extracted)
4438 if (vlan_extracted) 4442 vlan_gro_receive(&ring->napi, adapter->vlgrp,
4439 vlan_gro_receive(&ring->napi, adapter->vlgrp, 4443 le16_to_cpu(rx_desc->wb.upper.vlan),
4440 le16_to_cpu(rx_desc->wb.upper.vlan), 4444 skb);
4441 skb); 4445 else
4442 else 4446 napi_gro_receive(&ring->napi, skb);
4443 napi_gro_receive(&ring->napi, skb);
4444 } else {
4445 if (vlan_extracted)
4446 vlan_hwaccel_receive_skb(skb, adapter->vlgrp,
4447 le16_to_cpu(rx_desc->wb.upper.vlan));
4448 else
4449 netif_receive_skb(skb);
4450 }
4451} 4447}
4452 4448
4453static inline void igb_rx_checksum_adv(struct igb_adapter *adapter, 4449static inline void igb_rx_checksum_adv(struct igb_adapter *adapter,
@@ -4456,19 +4452,28 @@ static inline void igb_rx_checksum_adv(struct igb_adapter *adapter,
4456 skb->ip_summed = CHECKSUM_NONE; 4452 skb->ip_summed = CHECKSUM_NONE;
4457 4453
4458 /* Ignore Checksum bit is set or checksum is disabled through ethtool */ 4454 /* Ignore Checksum bit is set or checksum is disabled through ethtool */
4459 if ((status_err & E1000_RXD_STAT_IXSM) || !adapter->rx_csum) 4455 if ((status_err & E1000_RXD_STAT_IXSM) ||
4456 (adapter->flags & IGB_FLAG_RX_CSUM_DISABLED))
4460 return; 4457 return;
4461 /* TCP/UDP checksum error bit is set */ 4458 /* TCP/UDP checksum error bit is set */
4462 if (status_err & 4459 if (status_err &
4463 (E1000_RXDEXT_STATERR_TCPE | E1000_RXDEXT_STATERR_IPE)) { 4460 (E1000_RXDEXT_STATERR_TCPE | E1000_RXDEXT_STATERR_IPE)) {
4461 /*
4462 * work around errata with sctp packets where the TCPE aka
4463 * L4E bit is set incorrectly on 64 byte (60 byte w/o crc)
4464 * packets, (aka let the stack check the crc32c)
4465 */
4466 if (!((adapter->hw.mac.type == e1000_82576) &&
4467 (skb->len == 60)))
4468 adapter->hw_csum_err++;
4464 /* let the stack verify checksum errors */ 4469 /* let the stack verify checksum errors */
4465 adapter->hw_csum_err++;
4466 return; 4470 return;
4467 } 4471 }
4468 /* It must be a TCP or UDP packet with a valid checksum */ 4472 /* It must be a TCP or UDP packet with a valid checksum */
4469 if (status_err & (E1000_RXD_STAT_TCPCS | E1000_RXD_STAT_UDPCS)) 4473 if (status_err & (E1000_RXD_STAT_TCPCS | E1000_RXD_STAT_UDPCS))
4470 skb->ip_summed = CHECKSUM_UNNECESSARY; 4474 skb->ip_summed = CHECKSUM_UNNECESSARY;
4471 4475
4476 dev_dbg(&adapter->pdev->dev, "cksum success: bits %08X\n", status_err);
4472 adapter->hw_csum_good++; 4477 adapter->hw_csum_good++;
4473} 4478}
4474 4479