qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-devel] [PATCH 2/2] virtio-mmio: fix features negotiation bug


From: Ying-Shiuan Pan
Subject: [Qemu-devel] [PATCH 2/2] virtio-mmio: fix features negotiation bug
Date: Tue, 3 Jan 2012 15:06:43 +0800

virtio-mmio: fix features negotiation problem

virtio-mmio should invoke virtio_set_features() when it gets
VIRTIO_MMIO_GUESTFEATURES command, since some devices (at least, virtio-net)
register their own set_features method and setup their features in that.

Signed-off-by: Ying-Shiuan Pan <address@hidden>
---
 hw/virtio-mmio.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/hw/virtio-mmio.c b/hw/virtio-mmio.c
index 05d886a..729faad 100644
--- a/hw/virtio-mmio.c
+++ b/hw/virtio-mmio.c
@@ -186,7 +186,7 @@ static void virtio_mmio_write(void *opaque,
target_phys_addr_t offset,
         break;
     case VIRTIO_MMIO_GUESTFEATURES:
         if (!proxy->guest_features_sel) {
-            vdev->guest_features = value;
+            virtio_set_features(vdev, value);
         }
         break;
     case VIRTIO_MMIO_GUESTFEATURESSEL:
--



reply via email to

[Prev in Thread] Current Thread [Next in Thread]