All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH for 7.2-rc? v2 0/5] continuing efforts to fix vhost-user issues
@ 2022-11-25 17:30 Alex Bennée
  2022-11-25 17:30 ` [PATCH v2 1/5] include/hw: attempt to document VirtIO feature variables Alex Bennée
                   ` (6 more replies)
  0 siblings, 7 replies; 15+ messages in thread
From: Alex Bennée @ 2022-11-25 17:30 UTC (permalink / raw)
  To: qemu-devel
  Cc: slp, mst, marcandre.lureau, stefanha, mathieu.poirier,
	viresh.kumar, sgarzare, Alex Bennée

Hi,

This is continuing to attempt to fix the various vhost-user issues
that are currently plaguing the release. One concrete bug I've come
across is that all qtest MMIO devices where being treated as legacy
which caused the VIRTIO_F_VERSION_1 flag to get missed causing s390x
to fall back to trying to set the endian value for the virt-queues.

I've patched it for the GPIO tests and raised a tracking bug (#1342)
for the general problem. This might explain why the only other VirtIO
vhost-user MMIO device tested via qtest are the virtio-net-tests. The
vhost networking support is its own special implementation so its hard
to compare the code for GPIO. It does make me wonder if disabling the
mmio version of the test for now would be worthwhile. FWIW I did try
disabling force-legacy for all machine types and that caused a bunch
of the other tests to fail.

I made some progress in tracking down the memory leak that clang
complains about. It comes down to the line:

  gpio->vhost_dev.vqs = g_new0(struct vhost_virtqueue, gpio->vhost_dev.nvqs);

which is never cleared up because we never call
vu_gpio_device_unrealize() in the test. However its unclear why this
is the case. We don't seem to unrealize the vhost-user-network tests
either and clang doesn't complain about that.

I can replicate some of the other failures I've been seeing in CI by
running:

  ../../meson/meson.py test --repeat 10 --print-errorlogs qtest-arm/qos-test

however this seems to run everything in parallel and maybe is better
at exposing race conditions. Perhaps the CI system makes those races
easier to hit? Unfortunately I've not been able to figure out exactly
how things go wrong in the failure case. 

I've included Stefano's:

  vhost: enable vrings in vhost_dev_start() for vhost-user devices

in this series as it makes sense and improves the vring state errors.
However it's up to you if you want to include it in the eventual PR.
There are still CI errors I'm trying to track down but I thought it
would be worth posting the current state of my tree.

Please review.


Alex Bennée (4):
  include/hw: attempt to document VirtIO feature variables
  include/hw: VM state takes precedence in virtio_device_should_start
  tests/qtests: override "force-legacy" for gpio virtio-mmio tests
  hw/virtio: ensure a valid host_feature set for virtio-user-gpio

Stefano Garzarella (1):
  vhost: enable vrings in vhost_dev_start() for vhost-user devices

 include/hw/virtio/vhost.h        | 31 ++++++++++++++++++----
 include/hw/virtio/virtio.h       | 43 ++++++++++++++++++++++++++-----
 backends/cryptodev-vhost.c       |  4 +--
 backends/vhost-user.c            |  4 +--
 hw/block/vhost-user-blk.c        |  4 +--
 hw/net/vhost_net.c               |  8 +++---
 hw/scsi/vhost-scsi-common.c      |  4 +--
 hw/virtio/vhost-user-fs.c        |  4 +--
 hw/virtio/vhost-user-gpio.c      | 10 ++++++--
 hw/virtio/vhost-user-i2c.c       |  4 +--
 hw/virtio/vhost-user-rng.c       |  4 +--
 hw/virtio/vhost-vsock-common.c   |  4 +--
 hw/virtio/vhost.c                | 44 ++++++++++++++++++++++++++++----
 tests/qtest/libqos/virtio-gpio.c |  3 ++-
 hw/virtio/trace-events           |  4 +--
 15 files changed, 134 insertions(+), 41 deletions(-)

-- 
2.34.1



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

end of thread, other threads:[~2022-11-27 18:05 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-11-25 17:30 [PATCH for 7.2-rc? v2 0/5] continuing efforts to fix vhost-user issues Alex Bennée
2022-11-25 17:30 ` [PATCH v2 1/5] include/hw: attempt to document VirtIO feature variables Alex Bennée
2022-11-25 17:30 ` [PATCH v2 2/5] include/hw: VM state takes precedence in virtio_device_should_start Alex Bennée
2022-11-27 10:17   ` Bernhard Beschow
2022-11-25 17:30 ` [PATCH v2 3/5] tests/qtests: override "force-legacy" for gpio virtio-mmio tests Alex Bennée
2022-11-25 17:30 ` [PATCH v2 4/5] hw/virtio: ensure a valid host_feature set for virtio-user-gpio Alex Bennée
2022-11-25 17:30 ` [PATCH v2 5/5] vhost: enable vrings in vhost_dev_start() for vhost-user devices Alex Bennée
2022-11-25 17:30   ` [Virtio-fs] " Alex Bennée
2022-11-25 18:20 ` [PATCH for 7.2-rc? v2 0/5] continuing efforts to fix vhost-user issues Stefan Weil via
2022-11-25 20:08   ` Alex Bennée
2022-11-25 19:58 ` Alex Bennée
2022-11-26  9:42   ` Alex Bennée
2022-11-26 11:24     ` Stefan Hajnoczi
2022-11-26 14:12       ` Alex Bennée
2022-11-27 18:04         ` Stefan Hajnoczi

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.