diff options
author | Toshiaki Makita <makita.toshiaki@lab.ntt.co.jp> | 2015-01-29 06:37:09 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2015-01-30 21:03:47 -0500 |
commit | 0213668f060ea966ee8f4e6334f0fd27b6a1c428 (patch) | |
tree | 0aacfd4991c9232e060645397c0f90eb9f15da54 /drivers/net/ethernet/intel | |
parent | 72b1405964c19b99ad9f75340249b16305cf31ab (diff) |
ixgbe: Fix checksum error when using stacked vlan
When a skb has multiple vlans and it is CHECKSUM_PARTIAL,
ixgbe_tx_csum() fails to get the network protocol and checksum related
descriptor fields are not configured correctly because skb->protocol
doesn't show the L3 protocol in this case.
Use vlan_get_protocol() to get the proper network protocol.
Signed-off-by: Toshiaki Makita <makita.toshiaki@lab.ntt.co.jp>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/intel')
-rw-r--r-- | drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c b/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c index 2ed2c7de2304..67b02bde179e 100644 --- a/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c +++ b/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | |||
@@ -7227,11 +7227,11 @@ netdev_tx_t ixgbe_xmit_frame_ring(struct sk_buff *skb, | |||
7227 | if (!vhdr) | 7227 | if (!vhdr) |
7228 | goto out_drop; | 7228 | goto out_drop; |
7229 | 7229 | ||
7230 | protocol = vhdr->h_vlan_encapsulated_proto; | ||
7231 | tx_flags |= ntohs(vhdr->h_vlan_TCI) << | 7230 | tx_flags |= ntohs(vhdr->h_vlan_TCI) << |
7232 | IXGBE_TX_FLAGS_VLAN_SHIFT; | 7231 | IXGBE_TX_FLAGS_VLAN_SHIFT; |
7233 | tx_flags |= IXGBE_TX_FLAGS_SW_VLAN; | 7232 | tx_flags |= IXGBE_TX_FLAGS_SW_VLAN; |
7234 | } | 7233 | } |
7234 | protocol = vlan_get_protocol(skb); | ||
7235 | 7235 | ||
7236 | if (unlikely(skb_shinfo(skb)->tx_flags & SKBTX_HW_TSTAMP) && | 7236 | if (unlikely(skb_shinfo(skb)->tx_flags & SKBTX_HW_TSTAMP) && |
7237 | adapter->ptp_clock && | 7237 | adapter->ptp_clock && |