Skip to content

Commit b128ed5

Browse files
nbd168kuba-moo
authored andcommitted
udp: fix receiving fraglist GSO packets
When assembling fraglist GSO packets, udp4_gro_complete does not set skb->csum_start, which makes the extra validation in __udp_gso_segment fail. Fixes: 89add40 ("net: drop bad gso csum_start and offset in virtio_net_hdr") Signed-off-by: Felix Fietkau <[email protected]> Reviewed-by: Willem de Bruijn <[email protected]> Link: https://patch.msgid.link/[email protected] Signed-off-by: Jakub Kicinski <[email protected]>
1 parent 0d76fc7 commit b128ed5

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

net/ipv4/udp_offload.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -279,7 +279,8 @@ struct sk_buff *__udp_gso_segment(struct sk_buff *gso_skb,
279279
return ERR_PTR(-EINVAL);
280280

281281
if (unlikely(skb_checksum_start(gso_skb) !=
282-
skb_transport_header(gso_skb)))
282+
skb_transport_header(gso_skb) &&
283+
!(skb_shinfo(gso_skb)->gso_type & SKB_GSO_FRAGLIST)))
283284
return ERR_PTR(-EINVAL);
284285

285286
/* We don't know if egress device can segment and checksum the packet

0 commit comments

Comments
 (0)