]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/commit
virtio-net: XDP support for small buffers
authorJason Wang <jasowang@redhat.com>
Fri, 23 Dec 2016 14:37:32 +0000 (22:37 +0800)
committerDavid S. Miller <davem@davemloft.net>
Fri, 23 Dec 2016 18:48:56 +0000 (13:48 -0500)
commitbb91accf27335c6dc460e202991ca140fa21e1b5
tree3fb73f7fd7545d53be8ba17d64285fffc4768eed
parentc47a43d3004ad6ff2a94a670cb3274cd6338d41e
virtio-net: XDP support for small buffers

Commit f600b6905015 ("virtio_net: Add XDP support") leaves the case of
small receive buffer untouched. This will confuse the user who want to
set XDP but use small buffers. Other than forbid XDP in small buffer
mode, let's make it work. XDP then can only work at skb->data since
virtio-net create skbs during refill, this is sub optimal which could
be optimized in the future.

Cc: John Fastabend <john.r.fastabend@intel.com>
Signed-off-by: Jason Wang <jasowang@redhat.com>
Acked-by: John Fastabend <john.r.fastabend@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/virtio_net.c