virtio: clear signalled_used_valid when switching from dataplane
authorStefan Hajnoczi <stefanha@redhat.com>
Mon, 12 Aug 2013 09:08:09 +0000 (11:08 +0200)
committerMichael S. Tsirkin <mst@redhat.com>
Mon, 12 Aug 2013 09:19:04 +0000 (12:19 +0300)
commit6793dfd1b6a99a79b9f2e3c4d6625ccd6513f240
tree9bb84f2c48451af01e72111e68279a3112c87262
parent4965b7f056177ddfb816319e9ff5e766898d0bc5
virtio: clear signalled_used_valid when switching from dataplane

When the dataplane thread stops, its vring.c implementation synchronizes
vring state back to virtio.c so we can continue emulating the virtio
device.

This patch ensures that virtio.c's signalled_used_valid flag is reset so
that we do not suppress guest notifications due to stale signalled_used
values.

Suggested-by: Kevin Wolf <kwolf@redhat.com>
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
hw/virtio/dataplane/vring.c
hw/virtio/virtio.c
include/hw/virtio/virtio.h