qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/3] virtio-net: Only enable userland vq if using tap backend
@ 2021-11-17 19:28 Eugenio Pérez
  2021-11-17 19:28 ` [PATCH 1/3] virtio-net: Fix indentation Eugenio Pérez
                   ` (2 more replies)
  0 siblings, 3 replies; 12+ messages in thread
From: Eugenio Pérez @ 2021-11-17 19:28 UTC (permalink / raw)
  To: qemu-devel; +Cc: Laurent Vivier, Jason Wang, Cindy Lu, Michael S . Tsirkin

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




^ permalink raw reply	[flat|nested] 12+ messages in thread
* [PATCH 0/3] vdpa: Fix SIGSEGV on failed vdpa devices
@ 2021-11-19 10:20 Eugenio Pérez
  2021-11-19 10:20 ` [PATCH 3/3] virtio-net: Fix log message Eugenio Pérez
  0 siblings, 1 reply; 12+ messages in thread
From: Eugenio Pérez @ 2021-11-19 10:20 UTC (permalink / raw)
  To: qemu-devel
  Cc: Laurent Vivier, Jason Wang, qemu-stable, Cindy Lu,
	Michael S. Tsirkin

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. Add dummy receivers that return no progress so it can keep
running.

Tested with a modified version of vp_vdpa to fail negotiation.

This is another bersion of the patch proposed in [1], but the subject
didn't match the patch anymore.

[1] https://lists.nongnu.org/archive/html/qemu-devel/2021-11/msg03719.html

Eugenio Pérez (3):
  virtio-net: Fix indentation
  vdpa: Add dummy receive callbacks
  virtio-net: Fix log message

 hw/net/virtio-net.c | 13 +++++++------
 net/vhost-vdpa.c    | 16 ++++++++++++++++
 2 files changed, 23 insertions(+), 6 deletions(-)

-- 
2.27.0




^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2021-11-22  6:32 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-11-17 19:28 [PATCH 0/3] virtio-net: Only enable userland vq if using tap backend Eugenio Pérez
2021-11-17 19:28 ` [PATCH 1/3] virtio-net: Fix indentation Eugenio Pérez
2021-11-17 19:28 ` [PATCH 2/3] virtio-net: Only enable userland vq if using tap backend Eugenio Pérez
2021-11-18  5:06   ` Jason Wang
2021-11-18  7:56     ` Eugenio Perez Martin
2021-11-19  2:44       ` Jason Wang
2021-11-19  7:49         ` Eugenio Perez Martin
2021-11-22  2:39           ` Jason Wang
2021-11-22  6:23             ` Eugenio Perez Martin
2021-11-22  6:30               ` Jason Wang
2021-11-17 19:28 ` [PATCH 3/3] virtio-net: Fix log message Eugenio Pérez
  -- strict thread matches above, loose matches on Subject: below --
2021-11-19 10:20 [PATCH 0/3] vdpa: Fix SIGSEGV on failed vdpa devices Eugenio Pérez
2021-11-19 10:20 ` [PATCH 3/3] virtio-net: Fix log message Eugenio Pérez

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).