Fix IPv6 GSO type checks in Intel ethernet drivers
Subsystems (2)
PATCH 1/1 Fix IPv6 GSO type checks in Intel ethernet drivers
From: Sridhar Samudrala <[email protected]>
Found this problem when testing IPv6 from a KVM guest to a remote host via e1000e device on the host.
The following patch fixes the check for IPv6 GSO packet in Intel ethernet drivers to use skb_is_gso_v6(). SKB_GSO_DODGY is also set when packets are forwarded from a guest.
---
drivers/net/e1000e/netdev.c | 2 +- drivers/net/igb/igb_main.c | 2 +- drivers/net/igbvf/netdev.c | 2 +- drivers/net/ixgbe/ixgbe_main.c | 2 +- drivers/net/ixgbevf/ixgbevf_main.c | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-)
drivers/net/e1000e/netdev.c +1 -1
@@ -3771,7 +3771,7 @@ static int e1000_tso(struct e1000_adapter *adapter, 0, IPPROTO_TCP, 0); cmd_length =E1000_TXD_CMD_IP ; ipcse =skb_transport_offset (skb) -1 ; - }else if (skb_shinfo (skb)->gso_type ==SKB_GSO_TCPV6 ) { + }else if (skb_is_gso_v6 (skb)) {ipv6_hdr (skb)->payload_len =0 ; tcp_hdr(skb)->check = ~csum_ipv6_magic(&ipv6_hdr(skb)->saddr, &ipv6_hdr(skb)->daddr,
drivers/net/igb/igb_main.c +1 -1
@@ -3422,7 +3422,7 @@ static inline int igb_tso_adv(struct igb_ring *tx_ring, iph->daddr,0 ,IPPROTO_TCP , 0); - }else if (skb_shinfo (skb)->gso_type ==SKB_GSO_TCPV6 ) { + }else if (skb_is_gso_v6 (skb)) {ipv6_hdr (skb)->payload_len =0 ; tcp_hdr(skb)->check = ~csum_ipv6_magic(&ipv6_hdr(skb)->saddr, &ipv6_hdr(skb)->daddr,
drivers/net/igbvf/netdev.c +1 -1
@@ -1963,7 +1963,7 @@ static int igbvf_tso(struct igbvf_adapter *adapter, iph->daddr,0 ,IPPROTO_TCP , 0); - }else if (skb_shinfo (skb)->gso_type ==SKB_GSO_TCPV6 ) { + }else if (skb_is_gso_v6 (skb)) {ipv6_hdr (skb)->payload_len =0 ; tcp_hdr(skb)->check = ~csum_ipv6_magic(&ipv6_hdr(skb)->saddr, &ipv6_hdr(skb)->daddr,
drivers/net/ixgbe/ixgbe_main.c +1 -1
@@ -5113,7 +5113,7 @@ static int ixgbe_tso(struct ixgbe_adapter *adapter, iph->daddr,0 ,IPPROTO_TCP , 0); - }else if (skb_shinfo (skb)->gso_type ==SKB_GSO_TCPV6 ) { + }else if (skb_is_gso_v6 (skb)) {ipv6_hdr (skb)->payload_len =0 ;tcp_hdr (skb)->check = ~csum_ipv6_magic(&ipv6_hdr(skb)->saddr,
drivers/net/ixgbevf/ixgbevf_main.c +1 -1
@@ -2756,7 +2756,7 @@ static int ixgbevf_tso(struct ixgbevf_adapter *adapter,IPPROTO_TCP , 0); adapter->hw_tso_ctxt++; - }else if (skb_shinfo (skb)->gso_type ==SKB_GSO_TCPV6 ) { + }else if (skb_is_gso_v6 (skb)) {ipv6_hdr (skb)->payload_len =0 ;tcp_hdr (skb)->check = ~csum_ipv6_magic(&ipv6_hdr(skb)->saddr,
David Miller
maintainerFrom: Jeff Kirsher <[email protected]>
Date: Sat, 23 Jan 2010 01:24:45 -0800
Quoted 10 lines
From: Sridhar Samudrala <[email protected]>
Found this problem when testing IPv6 from a KVM guest to a remote host via e1000e device on the host.
The following patch fixes the check for IPv6 GSO packet in Intel ethernet drivers to useskb_is_gso_v6().SKB_GSO_DODGYis also set when packets are forwarded from a guest.Signed-off-by Sridhar Samudrala <[email protected]>Signed-off-by Jeff Kirsher <[email protected]>
This is definitely net-2.6 material, the bug definitely exists there and besides the ixgbevf bit, this patch applies cleanly to net-2.6 as well.
Please spin two patches, one which gets everything in net-2.6 and one which hits ixgbevf in net-next-2.6
Thanks.
Quoted 18 lines · David Miller
From: Jeff Kirsher <[email protected]>
Date: Sat, 23 Jan 2010 01:24:45 -0800Quoted 10 lines
From: Sridhar Samudrala <[email protected]>
Found this problem when testing IPv6 from a KVM guest to a remote host via e1000e device on the host.
The following patch fixes the check for IPv6 GSO packet in Intel ethernet drivers to useskb_is_gso_v6().SKB_GSO_DODGYis also set when packets are forwarded from a guest.Signed-off-by Sridhar Samudrala <[email protected]>Signed-off-by Jeff Kirsher <[email protected]>This is definitely net-2.6 material, the bug definitely exists there and besides the ixgbevf bit, this patch applies cleanly to net-2.6 as well.
Quoted 5 lines
Please spin two patches, one which gets everything in net-2.6 and one which hits ixgbevf in net-next-2.6
Thanks.
--
Thanks Dave, I will work up the two patches now.
Signature · 2 lines
Cheers, Jeff
Quoted 11 lines · David Miller
From: Jeff Kirsher <[email protected]>
Date: Sat, 23 Jan 2010 01:24:45 -0800Quoted 8 lines
From: Sridhar Samudrala <[email protected]>
Found this problem when testing IPv6 from a KVM guest to a remote host via e1000e device on the host.
The following patch fixes the check for IPv6 GSO packet in Intel ethernet drivers to useskb_is_gso_v6().SKB_GSO_DODGYis also set when packets are forwarded from a guest.
Quoted 6 lines
Quoted 2 lines
Signed-off-by Sridhar Samudrala <[email protected]>Signed-off-by Jeff Kirsher <[email protected]>This is definitely net-2.6 material, the bug definitely exists there and besides the ixgbevf bit, this patch applies cleanly to net-2.6 as well.
This is presumably suitable for stable as well; if so, please cc [email protected].
Ben.
Signature · 2 lines
Ben Hutchings Any smoothly functioning technology is indistinguishable from a rigged demo.