X-Git-Url: https://git.proxmox.com/?a=blobdiff_plain;f=net%2Fipv6%2Fip6_output.c;h=bc09cb97b8401011c112afe469fd231382387622;hb=01b6961410b76af228eb993220024ff6db6ba80c;hp=c21777565c58cabd7649cc48b790ff21c88498b5;hpb=3c25a75ee047c3393cc5b995c6c68c8cbdaf02fa;p=mirror_ubuntu-zesty-kernel.git diff --git a/net/ipv6/ip6_output.c b/net/ipv6/ip6_output.c index c21777565c58..bc09cb97b840 100644 --- a/net/ipv6/ip6_output.c +++ b/net/ipv6/ip6_output.c @@ -1300,8 +1300,10 @@ emsgsize: /* If this is the first and only packet and device * supports checksum offloading, let's use it. + * Use transhdrlen, same as IPv4, because partial + * sums only work when transhdrlen is set. */ - if (!skb && sk->sk_protocol == IPPROTO_UDP && + if (transhdrlen && sk->sk_protocol == IPPROTO_UDP && length + fragheaderlen < mtu && rt->dst.dev->features & NETIF_F_V6_CSUM && !exthdrlen)