aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/net/ipv4
diff options
context:
space:
mode:
authorXin Long <lucien.xin@gmail.com>2020-03-30 23:31:45 +0800
committerDavid S. Miller <davem@davemloft.net>2020-03-30 10:35:03 -0700
commitbde1b56f898ca8112912d7b36e55e1543b3be0cf (patch)
tree59ef2dbecd151c6d2dce99f79834de1315868ad6 /net/ipv4
parentnet, ip_tunnel: fix interface lookup with no key (diff)
downloadwireguard-linux-bde1b56f898ca8112912d7b36e55e1543b3be0cf.tar.xz
wireguard-linux-bde1b56f898ca8112912d7b36e55e1543b3be0cf.zip
udp: initialize is_flist with 0 in udp_gro_receive
Without NAPI_GRO_CB(skb)->is_flist initialized, when the dev doesn't support NETIF_F_GRO_FRAGLIST, is_flist can still be set and fraglist will be used in udp_gro_receive(). So fix it by initializing is_flist with 0 in udp_gro_receive. Fixes: 9fd1ff5d2ac7 ("udp: Support UDP fraglist GRO/GSO.") Signed-off-by: Xin Long <lucien.xin@gmail.com> Acked-by: Steffen Klassert <steffen.klassert@secunet.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4')
-rw-r--r--net/ipv4/udp_offload.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/net/ipv4/udp_offload.c b/net/ipv4/udp_offload.c
index 1a98583a79f4..e67a66fbf27b 100644
--- a/net/ipv4/udp_offload.c
+++ b/net/ipv4/udp_offload.c
@@ -453,6 +453,7 @@ struct sk_buff *udp_gro_receive(struct list_head *head, struct sk_buff *skb,
unsigned int off = skb_gro_offset(skb);
int flush = 1;
+ NAPI_GRO_CB(skb)->is_flist = 0;
if (skb->dev->features & NETIF_F_GRO_FRAGLIST)
NAPI_GRO_CB(skb)->is_flist = sk ? !udp_sk(sk)->gro_enabled: 1;