]> Git Repo - qemu.git/commitdiff
net: vhost stop updates virtio queue state
authorYuri Benditovich <[email protected]>
Tue, 13 Dec 2016 08:12:06 +0000 (10:12 +0200)
committerMichael S. Tsirkin <[email protected]>
Tue, 10 Jan 2017 05:02:53 +0000 (07:02 +0200)
Make virtio queue suitable for push operation from qemu
after vhost was stopped.

Signed-off-by: Yuri Benditovich <[email protected]>
Reviewed-by: Michael S. Tsirkin <[email protected]>
Signed-off-by: Michael S. Tsirkin <[email protected]>
hw/virtio/vhost.c

index f7f70237db8d24f20443168ca59caee952bf35e1..d396b225319447973ce6f43504f617f5da0e0218 100644 (file)
@@ -993,6 +993,7 @@ static void vhost_virtqueue_stop(struct vhost_dev *dev,
         virtio_queue_set_last_avail_idx(vdev, idx, state.num);
     }
     virtio_queue_invalidate_signalled_used(vdev, idx);
+    virtio_queue_update_used_idx(vdev, idx);
 
     /* In the cross-endian case, we need to reset the vring endianness to
      * native as legacy devices expect so by default.
This page took 0.028623 seconds and 4 git commands to generate.