diff options
author | Anthony Liguori <aliguori@us.ibm.com> | 2013-08-12 08:32:55 -0500 |
---|---|---|
committer | Anthony Liguori <aliguori@us.ibm.com> | 2013-08-12 08:32:55 -0500 |
commit | 3ee1ee80d22b3153dd6cbd3bec6d48a026eac31c (patch) | |
tree | e58fb6c2c9d263cac2528c7807ff91e43f5d86a3 /hw/virtio | |
parent | 6624fecd8e4df6be13f86846abce979702917931 (diff) | |
parent | 3561ba14188b3c1e54246ed6db97896bbc082d2f (diff) |
Merge remote-tracking branch 'mst/tags/for_anthony' into staging
pci,virtio fixes for 1.6
This includes some last-minute bugfixes for 1.6.
All very small patches that also look very safe to me.
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
# gpg: Signature made Mon 12 Aug 2013 04:28:57 AM CDT using RSA key ID D28D5469
# gpg: Can't check signature: public key not found
# By Michael S. Tsirkin (2) and others
# Via Michael S. Tsirkin
* mst/tags/for_anthony:
vhost: clear signalled_used_valid on vhost stop
virtio: clear signalled_used_valid when switching from dataplane
i82801b11: Fix i82801b11 PCI host bridge config space
pc: disable pci-info for 1.6
Message-id: 1376308831-19978-1-git-send-email-mst@redhat.com
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Diffstat (limited to 'hw/virtio')
-rw-r--r-- | hw/virtio/dataplane/vring.c | 1 | ||||
-rw-r--r-- | hw/virtio/vhost.c | 1 | ||||
-rw-r--r-- | hw/virtio/virtio.c | 5 |
3 files changed, 7 insertions, 0 deletions
diff --git a/hw/virtio/dataplane/vring.c b/hw/virtio/dataplane/vring.c index 82cc151b17..351a343806 100644 --- a/hw/virtio/dataplane/vring.c +++ b/hw/virtio/dataplane/vring.c @@ -52,6 +52,7 @@ bool vring_setup(Vring *vring, VirtIODevice *vdev, int n) void vring_teardown(Vring *vring, VirtIODevice *vdev, int n) { virtio_queue_set_last_avail_idx(vdev, n, vring->last_avail_idx); + virtio_queue_invalidate_signalled_used(vdev, n); hostmem_finalize(&vring->hostmem); } diff --git a/hw/virtio/vhost.c b/hw/virtio/vhost.c index 8f6ab130ee..9e336ad81e 100644 --- a/hw/virtio/vhost.c +++ b/hw/virtio/vhost.c @@ -762,6 +762,7 @@ static void vhost_virtqueue_stop(struct vhost_dev *dev, fflush(stderr); } virtio_queue_set_last_avail_idx(vdev, idx, state.num); + virtio_queue_invalidate_signalled_used(vdev, idx); assert (r >= 0); cpu_physical_memory_unmap(vq->ring, virtio_queue_get_ring_size(vdev, idx), 0, virtio_queue_get_ring_size(vdev, idx)); diff --git a/hw/virtio/virtio.c b/hw/virtio/virtio.c index 60653f764e..f03c45dff5 100644 --- a/hw/virtio/virtio.c +++ b/hw/virtio/virtio.c @@ -1065,6 +1065,11 @@ void virtio_queue_set_last_avail_idx(VirtIODevice *vdev, int n, uint16_t idx) vdev->vq[n].last_avail_idx = idx; } +void virtio_queue_invalidate_signalled_used(VirtIODevice *vdev, int n) +{ + vdev->vq[n].signalled_used_valid = false; +} + VirtQueue *virtio_get_queue(VirtIODevice *vdev, int n) { return vdev->vq + n; |