linux/include
Willem de Bruijn 2460d96c19 net: skip virtio_net_hdr_set_proto if protocol already set
[ Upstream commit 1ed1d592113959f00cc552c3b9f47ca2d157768f ]

virtio_net_hdr_set_proto infers skb->protocol from the virtio_net_hdr
gso_type, to avoid packets getting dropped for lack of a proto type.

Its protocol choice is a guess, especially in the case of UFO, where
the single VIRTIO_NET_HDR_GSO_UDP label covers both UFOv4 and UFOv6.

Skip this best effort if the field is already initialized. Whether
explicitly from userspace, or implicitly based on an earlier call to
dev_parse_header_protocol (which is more robust, but was introduced
after this patch).

Fixes: 9d2f67e43b ("net/packet: fix packet drop as of virtio gso")
Signed-off-by: Willem de Bruijn <willemb@google.com>
Link: https://lore.kernel.org/r/20211220145027.2784293-1-willemdebruijn.kernel@gmail.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2021-12-29 12:23:34 +01:00
..
acpi ACPI: fix NULL pointer dereference 2021-08-08 09:04:08 +02:00
asm-generic tlb: mmu_gather: add tlb_flush_*_range APIs 2021-11-26 10:47:23 +01:00
clocksource
crypto crypto: public_key: fix overflow during implicit conversion 2021-09-22 12:26:21 +02:00
drm
dt-bindings
keys
kvm
linux net: skip virtio_net_hdr_set_proto if protocol already set 2021-12-29 12:23:34 +01:00
math-emu
media
misc
net net: sched: Fix suspicious RCU usage while accessing tcf_tunnel_info 2021-12-22 09:29:40 +01:00
pcmcia
ras
rdma RDMA/netlink: Add __maybe_unused to static inline in C file 2021-11-26 10:47:18 +01:00
scsi
soc
sound ALSA: hda: hdac_ext_stream: fix potential locking issues 2021-11-26 10:47:23 +01:00
target scsi: target: Fix ordered tag handling 2021-11-26 10:47:16 +01:00
trace f2fs: fix up f2fs_lookup tracepoints 2021-11-26 10:47:17 +01:00
uapi aio: fix use-after-free due to missing POLLFREE handling 2021-12-14 14:49:02 +01:00
vdso
video
xen xen: sync include/xen/interface/io/ring.h with Xen's newest version 2021-12-01 09:23:35 +01:00