net: Fix possible wrong checksum generation.
Patch cef401de (net: fix possible wrong checksum generation) fixed wrong checksum calculation but it broke TSO by defining new GSO type but not a netdev feature for that type. net_gso_ok() would not allow hardware checksum/segmentation offload of such packets without the feature. Following patch fixes TSO and wrong checksum. This patch uses same logic that Eric Dumazet used. Patch introduces new flag SKBTX_SHARED_FRAG if at least one frag can be modified by the user. but SKBTX_SHARED_FRAG flag is kept in skb shared info tx_flags rather than gso_type. tx_flags is better compared to gso_type since we can have skb with shared frag without gso packet. It does not link SHARED_FRAG to GSO, So there is no need to define netdev feature for this. Signed-off-by:Pravin B Shelar <pshelar@nicira.com> Signed-off-by:
David S. Miller <davem@davemloft.net>
Showing
- drivers/net/macvtap.c 2 additions, 2 deletionsdrivers/net/macvtap.c
- drivers/net/tun.c 5 additions, 8 deletionsdrivers/net/tun.c
- drivers/net/virtio_net.c 5 additions, 8 deletionsdrivers/net/virtio_net.c
- include/linux/skbuff.h 9 additions, 8 deletionsinclude/linux/skbuff.h
- net/core/skbuff.c 2 additions, 3 deletionsnet/core/skbuff.c
- net/ipv4/af_inet.c 0 additions, 1 deletionnet/ipv4/af_inet.c
- net/ipv4/ip_output.c 1 addition, 0 deletionsnet/ipv4/ip_output.c
- net/ipv4/tcp.c 1 addition, 3 deletionsnet/ipv4/tcp.c
- net/ipv4/tcp_input.c 2 additions, 2 deletionsnet/ipv4/tcp_input.c
- net/ipv4/tcp_output.c 2 additions, 2 deletionsnet/ipv4/tcp_output.c
- net/ipv6/ip6_offload.c 0 additions, 1 deletionnet/ipv6/ip6_offload.c
Loading
Please register or sign in to comment