[Spice-commits] Branch 'bz700134' - hw/qxl.c

Gerd Hoffmann kraxel at kemper.freedesktop.org
Fri Jun 17 08:46:36 PDT 2011


 hw/qxl.c |    7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

New commits:
commit 9936468285406c31cc96f1ce90439b044dca477f
Author: Gerd Hoffmann <kraxel at redhat.com>
Date:   Fri Jun 17 17:45:55 2011 +0200

    async io fixup

diff --git a/hw/qxl.c b/hw/qxl.c
index 7b963f4..0168574 100644
--- a/hw/qxl.c
+++ b/hw/qxl.c
@@ -991,6 +991,11 @@ static void ioport_write(void *opaque, uint32_t addr, uint32_t val)
         if (d->mode == QXL_MODE_NATIVE || d->mode == QXL_MODE_COMPAT)
             break;
         dprint(d, 1, "%s: unexpected port 0x%x in vga mode\n", __FUNCTION__, io_port);
+        /* be nice to buggy guest drivers */
+        if (io_port >= QXL_IO_UPDATE_AREA_ASYNC &&
+            io_port <= QXL_IO_DESTROY_ALL_SURFACES_ASYNC) {
+            qxl_send_events(d, QXL_INTERRUPT_IO_CMD);
+        }
         return;
     }
 
@@ -1362,7 +1367,7 @@ static int qxl_init_common(PCIQXLDevice *qxl)
     qxl->vram_size = msb_mask(qxl->vram_size * 2 - 1);
     qxl->vram_offset = qemu_ram_alloc(&qxl->pci.qdev, "qxl.vram", qxl->vram_size);
 
-    io_size = msb_mask(QXL_IO_RANGE_SIZE * 2 - 1);
+    io_size = msb_mask((QXL_IO_RANGE_SIZE+7) * 2 - 1);
     if (qxl->revision == 1) {
         io_size = 8;
     }


More information about the Spice-commits mailing list