qemu-devel
[Top][All Lists]
Advanced

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

[Qemu-devel] [6471] Don't notify virtio devices before S_DRIVER_OK (Mark


From: Anthony Liguori
Subject: [Qemu-devel] [6471] Don't notify virtio devices before S_DRIVER_OK (Mark McLoughlin)
Date: Thu, 29 Jan 2009 17:02:13 +0000

Revision: 6471
          http://svn.sv.gnu.org/viewvc/?view=rev&root=qemu&revision=6471
Author:   aliguori
Date:     2009-01-29 17:02:13 +0000 (Thu, 29 Jan 2009)

Log Message:
-----------
Don't notify virtio devices before S_DRIVER_OK (Mark McLoughlin)

Current Linux guests oops if the host notifies of a
config change before a driver has been bound to the
device.

It's pretty pointless for us to do notify of config
changes before status is S_DRIVER_OK anyway, so let's
just not do it.

Signed-off-by: Mark McLoughlin <address@hidden>
Signed-off-by: Anthony Liguori <address@hidden>

Modified Paths:
--------------
    trunk/hw/virtio.c

Modified: trunk/hw/virtio.c
===================================================================
--- trunk/hw/virtio.c   2009-01-29 17:02:08 UTC (rev 6470)
+++ trunk/hw/virtio.c   2009-01-29 17:02:13 UTC (rev 6471)
@@ -738,6 +738,9 @@
 
 void virtio_notify_config(VirtIODevice *vdev)
 {
+    if (!(vdev->status & VIRTIO_CONFIG_S_DRIVER_OK))
+        return;
+
     vdev->isr |= 0x03;
     virtio_update_irq(vdev);
 }






reply via email to

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