[PATCH 0/3] virtio-net: Only enable userland vq if using tap backend

Eugenio Pérez posted 3 patches 2 years, 5 months ago
Test checkpatch passed
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/qemu tags/patchew/20211117192851.65529-1-eperezma@redhat.com
include/hw/virtio/virtio.h |  2 ++
hw/net/virtio-net.c        | 17 +++++++++++------
hw/virtio/virtio.c         | 21 +++++++++++++--------
3 files changed, 26 insertions(+), 14 deletions(-)
[PATCH 0/3] virtio-net: Only enable userland vq if using tap backend
Posted by Eugenio Pérez 2 years, 5 months ago
Qemu falls back on userland handlers even if vhost-user and vhost-vdpa
cases. These assumes a tap device can handle the packets.

If a vdpa device fail to start, it can trigger a sigsegv because of
that. Do not resort on them unless actually possible.

Tested with tap backend vhost=on and vhost=off, and with vp_vdpa
modified to fail negotiation.

Eugenio Pérez (3):
  virtio-net: Fix indentation
  virtio-net: Only enable userland vq if using tap backend
  virtio-net: Fix log message

 include/hw/virtio/virtio.h |  2 ++
 hw/net/virtio-net.c        | 17 +++++++++++------
 hw/virtio/virtio.c         | 21 +++++++++++++--------
 3 files changed, 26 insertions(+), 14 deletions(-)

-- 
2.27.0