]> git.baikalelectronics.ru Git - kernel.git/commit
virtio-net: switch to use build_skb() for small buffer
authorJason Wang <jasowang@redhat.com>
Tue, 21 Feb 2017 08:46:28 +0000 (16:46 +0800)
committerDavid S. Miller <davem@davemloft.net>
Tue, 21 Feb 2017 17:24:52 +0000 (12:24 -0500)
commit00af6528567640b96fc8fad2cc4a5a35f48029d8
tree1ea85a3b2d3e1fa380508ce23917ea4384691ccc
parenta1e882634cd1be151f30b8cd4a2f89602ad9c9ff
virtio-net: switch to use build_skb() for small buffer

This patch switch to use build_skb() for small buffer which can have
better performance for both TCP and XDP (since we can work at page
before skb creation). It also remove lots of XDP codes since both
mergeable and small buffer use page frag during refill now.

                       Before   | After
XDP_DROP(xdp1) 64B  :  11.1Mpps | 14.4Mpps

Tested with xdp1/xdp2/xdp_ip_tx_tunnel and netperf.

Signed-off-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