From: Alice Mikityanska skb->len may be bigger than 65535 in UDP-based tunnels that have BIG TCP enabled. If GSO aggregates packets that large, set the length in the UDP header to 0, so that tcpdump can print such packets properly (treating them as RFC 2675 jumbograms). Later in the pipeline, __udp_gso_segment will set uh->len to the size of individual packets. Signed-off-by: Alice Mikityanska --- net/ipv4/udp_tunnel_core.c | 2 +- net/ipv6/ip6_udp_tunnel.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/net/ipv4/udp_tunnel_core.c b/net/ipv4/udp_tunnel_core.c index 18f789d9383e..8c586dc08f3b 100644 --- a/net/ipv4/udp_tunnel_core.c +++ b/net/ipv4/udp_tunnel_core.c @@ -184,7 +184,7 @@ void udp_tunnel_xmit_skb(struct rtable *rt, struct sock *sk, struct sk_buff *skb uh->dest = dst_port; uh->source = src_port; - udp_set_len_short(uh, skb->len); + udp_set_len(uh, skb->len); memset(&(IPCB(skb)->opt), 0, sizeof(IPCB(skb)->opt)); diff --git a/net/ipv6/ip6_udp_tunnel.c b/net/ipv6/ip6_udp_tunnel.c index 43e94a3efb26..03c9e55f575e 100644 --- a/net/ipv6/ip6_udp_tunnel.c +++ b/net/ipv6/ip6_udp_tunnel.c @@ -93,7 +93,7 @@ void udp_tunnel6_xmit_skb(struct dst_entry *dst, struct sock *sk, uh->dest = dst_port; uh->source = src_port; - udp_set_len_short(uh, skb->len); + udp_set_len(uh, skb->len); skb_dst_set(skb, dst); -- 2.53.0