]> err.no Git - linux-2.6/commitdiff
cassini: Only use chip checksum for ipv4 packets.
authorDavid S. Miller <davem@davemloft.net>
Thu, 22 May 2008 00:05:34 +0000 (17:05 -0700)
committerDavid S. Miller <davem@davemloft.net>
Thu, 22 May 2008 00:05:34 +0000 (17:05 -0700)
According to David Monro, at least with Natsemi Saturn chips the
cassini driver has some trouble with ipv6 checksums.

Until we have more information about what's going on here, only
use the chip checksums for ipv4.

This workaround was suggested and tested by David.

Update version and release date.

Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/cassini.c

index 93e13636f8dda2fef5667cc544b99fb068f2ca17..83768df27806be9394fb087acac83ee6f87f08a0 100644 (file)
 
 #define DRV_MODULE_NAME                "cassini"
 #define PFX DRV_MODULE_NAME    ": "
-#define DRV_MODULE_VERSION     "1.5"
-#define DRV_MODULE_RELDATE     "4 Jan 2008"
+#define DRV_MODULE_VERSION     "1.6"
+#define DRV_MODULE_RELDATE     "21 May 2008"
 
 #define CAS_DEF_MSG_ENABLE       \
        (NETIF_MSG_DRV          | \
@@ -2136,9 +2136,12 @@ end_copy_pkt:
                if (addr)
                        cas_page_unmap(addr);
        }
-       skb->csum = csum_unfold(~csum);
-       skb->ip_summed = CHECKSUM_COMPLETE;
        skb->protocol = eth_type_trans(skb, cp->dev);
+       if (skb->protocol == htons(ETH_P_IP)) {
+               skb->csum = csum_unfold(~csum);
+               skb->ip_summed = CHECKSUM_COMPLETE;
+       } else
+               skb->ip_summed = CHECKSUM_NONE;
        return len;
 }