qemu-devel
[Top][All Lists]
Advanced

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

[Qemu-devel] [PATCH] Initialize the VMware VGA console after vga_init


From: Alexander Graf
Subject: [Qemu-devel] [PATCH] Initialize the VMware VGA console after vga_init
Date: Tue, 08 Jul 2008 16:15:47 +0200
User-agent: Thunderbird 2.0.0.12 (X11/20071114)

Hi,

while trying the -vmwarevga switch I stumbled across this nifty problem: vga_common_init calls vga_reset, which memsets the whole VGAState to 0. Unfortunately the console initialization code is before that, so it gets overwritten by 0 which breaks later on.

To circumvent this I reordered the console initialization to after the vga_init. I am not 100% sure if that's correct, but it works so far. Please double-check if this is the right approach.

Alex

Signed-off-by: Alexander Graf <address@hidden>


Index: hw/vmware_vga.c
===================================================================
--- hw/vmware_vga.c     (revision 4852)
+++ hw/vmware_vga.c     (working copy)
@@ -1123,16 +1123,16 @@
 
     vmsvga_reset(s);
 
-    s->console = graphic_console_init(ds, vmsvga_update_display,
-                                      vmsvga_invalidate_display,
-                                      vmsvga_screen_dump,
-                                      vmsvga_text_update, s);
-
 #ifdef EMBED_STDVGA
     vga_common_init((VGAState *) s, ds,
                     vga_ram_base, vga_ram_offset, vga_ram_size);
     vga_init((VGAState *) s);
 #endif
+
+    s->console = graphic_console_init(ds, vmsvga_update_display,
+                                      vmsvga_invalidate_display,
+                                      vmsvga_screen_dump,
+                                      vmsvga_text_update, s);
 }
 
 static void pci_vmsvga_save(QEMUFile *f, void *opaque)

reply via email to

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