]> git.proxmox.com Git - mirror_ubuntu-artful-kernel.git/commitdiff
fcoe: use CHECKSUM_UNNECESSARY instead of CHECKSUM_PARTIAL on tx
authorYi Zou <yi.zou@intel.com>
Fri, 16 Mar 2012 23:08:12 +0000 (23:08 +0000)
committerDavid S. Miller <davem@davemloft.net>
Mon, 19 Mar 2012 21:37:35 +0000 (17:37 -0400)
Fix a bug when using 'ethtool -K ethx tx off' to turn off tx ip checksum,
FCoE CRC offload should not be impacte. The skb_checksum_help() is needed
only if it's not FCoE traffic for ip checksum, regardless of ethtool toggling
the tx ip checksum on or off. Instead of using CHECKSUM_PARTIAL, we will
use CHECKSUM_UNNECESSARY as a proper indication to avoid sw ip checksum
on FCoE frames.

Ref. to original discussion thread:
http://patchwork.ozlabs.org/patch/146567/

CC: "James E.J. Bottomley" <JBottomley@parallels.com>
CC: Robert Love <robert.w.love@intel.com>
Signed-off-by: Yi Zou <yi.zou@intel.com>
Tested-by: Ross Brattain <ross.b.brattain@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/scsi/fcoe/fcoe.c

index e9599600aa230b8b6315c405730352f99e6a7d9a..c164890224d221526e645e9bdcb1bcc9d8b22d0c 100644 (file)
@@ -1498,7 +1498,7 @@ static int fcoe_xmit(struct fc_lport *lport, struct fc_frame *fp)
 
        /* crc offload */
        if (likely(lport->crc_offload)) {
-               skb->ip_summed = CHECKSUM_PARTIAL;
+               skb->ip_summed = CHECKSUM_UNNECESSARY;
                skb->csum_start = skb_headroom(skb);
                skb->csum_offset = skb->len;
                crc = 0;