Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

[NET]: Don't send ICMP_FRAG_NEEDED for GSO packets

Commit 9af3912ec9e30509b76cb376abb65a4d8af27df3 ("[NET] Move DF check
to ip_forward") added a new check to send ICMP fragmentation needed
for large packets.

Unlike the check in ip_finish_output(), it doesn't check for GSO.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Signed-off-by: David S. Miller <davem@davemloft.net>

authored by

Rusty Russell and committed by
David S. Miller
32aced75 d41a95e0

+1 -1
+1 -1
net/ipv4/ip_forward.c
··· 85 85 if (opt->is_strictroute && rt->rt_dst != rt->rt_gateway) 86 86 goto sr_failed; 87 87 88 - if (unlikely(skb->len > dst_mtu(&rt->u.dst) && 88 + if (unlikely(skb->len > dst_mtu(&rt->u.dst) && !skb_is_gso(skb) && 89 89 (ip_hdr(skb)->frag_off & htons(IP_DF))) && !skb->local_df) { 90 90 IP_INC_STATS(IPSTATS_MIB_FRAGFAILS); 91 91 icmp_send(skb, ICMP_DEST_UNREACH, ICMP_FRAG_NEEDED,