]> git.baikalelectronics.ru Git - 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)
commit3c39b12b24c06c50f40ceb4e8e59ae316b9166c6
tree3fb73f7fd7545d53be8ba17d64285fffc4768eed
parentad1c816961cbff5f07e50266e0f63fc4bc3987c8
virtio-net: XDP support for small buffers

Commit 11c1dea1f3b7 ("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