]> git.baikalelectronics.ru Git - kernel.git/commit
virtio_net: Keep vnet header zeroed if XDP is loaded for small buffer
authorYuya Kusakabe <yuya.kusakabe@gmail.com>
Tue, 25 Feb 2020 03:32:11 +0000 (12:32 +0900)
committerDaniel Borkmann <daniel@iogearbox.net>
Tue, 25 Feb 2020 21:50:55 +0000 (22:50 +0100)
commitb285dc5317f3c9912c40a7ee3d2eac3d90939f55
tree8dc007db074025902c81b2d0a43e5df0c9fd0fb1
parent292e8151994e09f6af950c6cca778b5e43cdb0c6
virtio_net: Keep vnet header zeroed if XDP is loaded for small buffer

We do not want to care about the vnet header in receive_small() if XDP
is loaded, since we can not know whether or not the packet is modified
by XDP.

Fixes: 00af65285676 ("virtio-net: switch to use build_skb() for small buffer")
Signed-off-by: Yuya Kusakabe <yuya.kusakabe@gmail.com>
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
Acked-by: Jason Wang <jasowang@redhat.com>
Acked-by: Michael S. Tsirkin <mst@redhat.com>
Link: https://lore.kernel.org/bpf/20200225033212.437563-1-yuya.kusakabe@gmail.com
drivers/net/virtio_net.c