]> git.baikalelectronics.ru Git - kernel.git/commit
virtio_net: use dev_kfree_skb for small buffer XDP receive
authorJohn Fastabend <john.fastabend@gmail.com>
Thu, 26 Jan 2017 02:22:48 +0000 (18:22 -0800)
committerDavid S. Miller <davem@davemloft.net>
Thu, 26 Jan 2017 03:48:17 +0000 (22:48 -0500)
commitee446fb67ef62c85ae5651a11d42bb7e7d7080dc
tree6591853f9de1cc61b8ebdd0cd705da4a3fa440f9
parent3364126c274535c457ebff1cb323988f4e7a0a11
virtio_net: use dev_kfree_skb for small buffer XDP receive

In the small buffer case during driver unload we currently use
put_page instead of dev_kfree_skb. Resolve this by adding a check
for virtnet mode when checking XDP queue type. Also name the
function so that the code reads correctly to match the additional
check.

Fixes: b763d5061bab ("virtio-net: XDP support for small buffers")
Signed-off-by: John Fastabend <john.r.fastabend@intel.com>
Acked-by: Jason Wang <jasowang@redhat.com>
Acked-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/virtio_net.c