mbox series

[v2,0/2] vhost: implement VHOST_SET_VRING_ERR

Message ID 20220623161325.18813-1-vsementsov@yandex-team.ru (mailing list archive)
Headers show
Series vhost: implement VHOST_SET_VRING_ERR | expand

Message

Vladimir Sementsov-Ogievskiy June 23, 2022, 4:13 p.m. UTC
Both vhost-user and kernel vhost can inform Qemu about virt-queue error
through separate eventfd. Let's use this possibility.

For now just dump a message on error like elsewhere in vhost.c.

Further plan is implement QAPI event for this and may be some other
vhost/virtio errors to make it possible to instantly notify user about
problems in vm. That would be a separate patch or patchset.

v2: don't add QAPI event for now. Let's first realize the vhost
interface.

Yandex-ST: CLOUD-101375

Konstantin Khlebnikov (2):
  vhost: add method vhost_set_vring_err
  vhost: setup error eventfd and dump errors

 hw/virtio/vhost-backend.c         |  7 ++++++
 hw/virtio/vhost-user.c            |  6 +++++
 hw/virtio/vhost.c                 | 37 +++++++++++++++++++++++++++++++
 include/hw/virtio/vhost-backend.h |  3 +++
 include/hw/virtio/vhost.h         |  1 +
 5 files changed, 54 insertions(+)