vhost: enable vhost without without MSI-X

We use vhostforce to enable vhost even if Guests don't have MSI-X
support and we fall back to QEMU virtio-net.

This gives a very small performance gain, but the disadvantage
is that guest now controls which virtio code is running
(qemu or vhost) so our attack surface is doubled.

This patch will enable vhost unconditionally whenever it's requested.
For compatibility, enable vhost when vhostforce is set, as well.

Signed-off-by: Pankaj Gupta <pagupta@redhat.com>
Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Reviewed-by: Jason Wang <jasowang@redhat.com>
This commit is contained in:
Pankaj Gupta 2015-06-16 13:48:59 +05:30 committed by Michael S. Tsirkin
parent 74de5504fd
commit 1e7398a140
8 changed files with 4 additions and 35 deletions

View file

@ -128,10 +128,6 @@ static void virtio_net_vhost_status(VirtIONet *n, uint8_t status)
if (!n->vhost_started) {
int r, i;
if (!vhost_net_query(get_vhost_net(nc->peer), vdev)) {
return;
}
/* Any packets outstanding? Purge them to avoid touching rings
* when vhost is running.
*/