qlcnic: add cksum flag
authorAmit Kumar Salecha <amit.salecha@qlogic.com>
Tue, 31 Aug 2010 17:17:53 +0000 (17:17 +0000)
committerDavid S. Miller <davem@davemloft.net>
Wed, 1 Sep 2010 17:41:58 +0000 (10:41 -0700)
o New CKSUM flag added by fw to notify cksum is verified.
o Update version to 5.0.9

Signed-off-by: Amit Kumar Salecha <amit.salecha@qlogic.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/qlcnic/qlcnic.h
drivers/net/qlcnic/qlcnic_init.c

index 9d211529fa16be1cf649486e7ac73243fc28ec38..cc8385a6727ed5196326aa27a9d3f0637654615d 100644 (file)
@@ -51,8 +51,8 @@
 
 #define _QLCNIC_LINUX_MAJOR 5
 #define _QLCNIC_LINUX_MINOR 0
-#define _QLCNIC_LINUX_SUBVERSION 8
-#define QLCNIC_LINUX_VERSIONID  "5.0.8"
+#define _QLCNIC_LINUX_SUBVERSION 9
+#define QLCNIC_LINUX_VERSIONID  "5.0.9"
 #define QLCNIC_DRV_IDC_VER  0x01
 #define QLCNIC_DRIVER_VERSION  ((_QLCNIC_LINUX_MAJOR << 16) |\
                 (_QLCNIC_LINUX_MINOR << 8) | (_QLCNIC_LINUX_SUBVERSION))
@@ -224,7 +224,8 @@ struct rcv_desc {
 #define QLCNIC_LRO_DESC        0x12
 
 /* for status field in status_desc */
-#define STATUS_CKSUM_OK                (2)
+#define STATUS_CKSUM_LOOP      0
+#define STATUS_CKSUM_OK                2
 
 /* owner bits of status_desc */
 #define STATUS_OWNER_HOST      (0x1ULL << 56)
index 8e0e7a3bbf9e1cea71f136f15ed62c67fa64804c..8e47d7aea562be5ba72c67dc977db44dca032ed0 100644 (file)
@@ -1364,7 +1364,8 @@ static struct sk_buff *qlcnic_process_rxbuf(struct qlcnic_adapter *adapter,
 
        skb = buffer->skb;
 
-       if (likely(adapter->rx_csum && cksum == STATUS_CKSUM_OK)) {
+       if (likely(adapter->rx_csum && (cksum == STATUS_CKSUM_OK ||
+                                               cksum == STATUS_CKSUM_LOOP))) {
                adapter->stats.csummed++;
                skb->ip_summed = CHECKSUM_UNNECESSARY;
        } else {