From a44bed2f54185b795d8d8141bd810b554bcb750b Mon Sep 17 00:00:00 2001 From: Paolo Bonzini Date: Thu, 9 Jun 2022 08:49:21 +0200 Subject: virtio-mmio: stop ioeventfd on legacy reset If the queue PFN is set to zero on a virtio-mmio device, the device is reset. In that case however the virtio_bus_stop_ioeventfd function was not called; add it so that the behavior is similar to when status is set to 0. Reviewed-by: Cornelia Huck Signed-off-by: Paolo Bonzini --- hw/virtio/virtio-mmio.c | 1 + 1 file changed, 1 insertion(+) (limited to 'hw/virtio') diff --git a/hw/virtio/virtio-mmio.c b/hw/virtio/virtio-mmio.c index 688eccda94..41a35d31c8 100644 --- a/hw/virtio/virtio-mmio.c +++ b/hw/virtio/virtio-mmio.c @@ -376,6 +376,7 @@ static void virtio_mmio_write(void *opaque, hwaddr offset, uint64_t value, return; } if (value == 0) { + virtio_mmio_stop_ioeventfd(proxy); virtio_reset(vdev); } else { virtio_queue_set_addr(vdev, vdev->queue_sel, -- cgit v1.2.3