diff options
author | Yuri Benditovich <yuri.benditovich@daynix.com> | 2016-12-13 10:12:06 +0200 |
---|---|---|
committer | Michael S. Tsirkin <mst@redhat.com> | 2017-01-10 07:02:53 +0200 |
commit | aa94d52142f674c7abe638f9cfb19bd89a99f154 (patch) | |
tree | 3de76db8c376cc57de41c801d6aa991a78083122 /hw/virtio/vhost.c | |
parent | 312d3b35349a153e5a069e53170fd929e6b73a2b (diff) |
net: vhost stop updates virtio queue state
Make virtio queue suitable for push operation from qemu
after vhost was stopped.
Signed-off-by: Yuri Benditovich <yuri.benditovich@daynix.com>
Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Diffstat (limited to 'hw/virtio/vhost.c')
-rw-r--r-- | hw/virtio/vhost.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/hw/virtio/vhost.c b/hw/virtio/vhost.c index f7f70237db..d396b22531 100644 --- a/hw/virtio/vhost.c +++ b/hw/virtio/vhost.c @@ -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. |