]> git.baikalelectronics.ru Git - kernel.git/commit
vhost_net: Avoid rx queue wake-ups during busypoll
authorToshiaki Makita <makita.toshiaki@lab.ntt.co.jp>
Tue, 3 Jul 2018 07:31:33 +0000 (16:31 +0900)
committerDavid S. Miller <davem@davemloft.net>
Wed, 4 Jul 2018 12:30:46 +0000 (21:30 +0900)
commit98862ad2cbd06e2a819f045d8e5da5c42a77a95e
treef0f243eb398195ac71bc9f6b741aec7047d04171
parenteb5ebf962d819c0dc40d7784b737402f96544f88
vhost_net: Avoid rx queue wake-ups during busypoll

We may run handle_rx() while rx work is queued. For example a packet can
push the rx work during the window before handle_rx calls
vhost_net_disable_vq().
In that case busypoll immediately exits due to vhost_has_work()
condition and enables vq again. This can lead to another unnecessary rx
wake-ups, so poll rx work instead of enabling the vq.

Signed-off-by: Toshiaki Makita <makita.toshiaki@lab.ntt.co.jp>
Acked-by: Jason Wang <jasowang@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/vhost/net.c