]> git.baikalelectronics.ru Git - kernel.git/commit
virtio-net: rx busy polling support
authorJason Wang <jasowang@redhat.com>
Wed, 23 Jul 2014 08:33:55 +0000 (16:33 +0800)
committerDavid S. Miller <davem@davemloft.net>
Wed, 23 Jul 2014 22:12:02 +0000 (15:12 -0700)
commit5a00c7fd64c9a8bfb42f82e332a5959d205c2d67
tree0b55a52980362bd053ef02615bb0b7630e86e02f
parent0ec0f8ab1f8f872a4fe30c581625de74830f96f5
virtio-net: rx busy polling support

Add basic support for rx busy polling. Instead of introducing new
states and spinlock to synchronize between NAPI and polling method,
this patch just reuse NAPI state to avoid extra overhead for fast path
and simplified the codes.

Test was done between a kvm guest and an external host. Two hosts were
connected through 40gb mlx4 cards. With both busy_poll and busy_read
are set to 50 in guest, 1 byte netperf tcp_rr shows 127% improvement:
transaction rate was increased from 8353.33 to 18966.87.

Cc: Rusty Russell <rusty@rustcorp.com.au>
Cc: Michael S. Tsirkin <mst@redhat.com>
Cc: Vlad Yasevich <vyasevic@redhat.com>
Cc: Eric Dumazet <eric.dumazet@gmail.com>
Signed-off-by: Jason Wang <jasowang@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/virtio_net.c