]> git.ipfire.org Git - thirdparty/qemu.git/commitdiff
cirrus: Force use of shadow pixmap when HW cursor is enabled
authorBenjamin Herrenschmidt <benh@kernel.crashing.org>
Mon, 7 Jul 2014 00:28:39 +0000 (10:28 +1000)
committerGerd Hoffmann <kraxel@redhat.com>
Tue, 16 Dec 2014 14:14:42 +0000 (15:14 +0100)
The HW cursor cannot be painted on a shared surface. This fixes HW
cursor display in Windows NT 4.0 and Windows 98.

Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
hw/display/cirrus_vga.c

index 27252646bc7817aa8b79c4fd2042769f6627b7cc..686b06205caf669ce8726ae29de64ac114701c52 100644 (file)
@@ -1351,7 +1351,6 @@ static void cirrus_vga_write_sr(CirrusVGAState * s, uint32_t val)
     case 0x0d:                 // VCLK 2
     case 0x0e:                 // VCLK 3
     case 0x0f:                 // DRAM Control
-    case 0x12:                 // Graphics Cursor Attribute
     case 0x13:                 // Graphics Cursor Pattern Address
     case 0x14:                 // Scratch Register 2
     case 0x15:                 // Scratch Register 3
@@ -1370,6 +1369,14 @@ static void cirrus_vga_write_sr(CirrusVGAState * s, uint32_t val)
               s->vga.sr_index, val);
 #endif
        break;
+    case 0x12:                 // Graphics Cursor Attribute
+       s->vga.sr[0x12] = val;
+        s->vga.force_shadow = !!(val & CIRRUS_CURSOR_SHOW);
+#ifdef DEBUG_CIRRUS
+        printf("cirrus: cursor ctl SR12=%02x (force shadow: %d)\n",
+               val, s->vga.force_shadow);
+#endif
+        break;
     case 0x17:                 // Configuration Readback and Extended Control
        s->vga.sr[s->vga.sr_index] = (s->vga.sr[s->vga.sr_index] & 0x38)
                                    | (val & 0xc7);