]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
udp: using datalen to cap ipv6 udp max gso segments
authorCoco Li <lixiaoyan@google.com>
Thu, 23 Dec 2021 22:24:40 +0000 (22:24 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 5 Jan 2022 11:34:58 +0000 (12:34 +0100)
commitbbd9c7120c31c1aff6dcffdcce122773d163df72
tree2c2ee831fa31f6535aeafea04a44840c99d992e2
parentdc3d27538c4f45ca1bed9a0f907fd96051e26c09
udp: using datalen to cap ipv6 udp max gso segments

[ Upstream commit 736ef37fd9a44f5966e25319d08ff7ea99ac79e8 ]

The max number of UDP gso segments is intended to cap to
UDP_MAX_SEGMENTS, this is checked in udp_send_skb().

skb->len contains network and transport header len here, we should use
only data len instead.

This is the ipv6 counterpart to the below referenced commit,
which missed the ipv6 change

Fixes: 158390e45612 ("udp: using datalen to cap max gso segments")
Signed-off-by: Coco Li <lixiaoyan@google.com>
Reviewed-by: Willem de Bruijn <willemb@google.com>
Link: https://lore.kernel.org/r/20211223222441.2975883-1-lixiaoyan@google.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
net/ipv6/udp.c