From: lizhaoxin <[email protected]> After the VM is suspended/resumed or live-migrated, we do not want the guest to output information such as the capacity of the block device, as this is noticeable to the tenant. Also, there is no need to immediately send a config notifier for the virtio device after vhost_dev_start.
Co-developed-by: Gao Shiyuan <[email protected]> Signed-off-by: Gao Shiyuan <[email protected]> Signed-off-by: Li Zhaoxin <[email protected]> --- hw/virtio/vhost.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/hw/virtio/vhost.c b/hw/virtio/vhost.c index 6557c58d12..1f8a495ef8 100644 --- a/hw/virtio/vhost.c +++ b/hw/virtio/vhost.c @@ -1847,15 +1847,10 @@ static void vhost_stop_config_intr(struct vhost_dev *dev) static void vhost_start_config_intr(struct vhost_dev *dev) { - int r; - assert(dev->vhost_ops); int fd = event_notifier_get_fd(&dev->vdev->config_notifier); if (dev->vhost_ops->vhost_set_config_call) { - r = dev->vhost_ops->vhost_set_config_call(dev, fd); - if (!r) { - event_notifier_set(&dev->vdev->config_notifier); - } + dev->vhost_ops->vhost_set_config_call(dev, fd); } } -- 2.34.1
