]> xenbits.xensource.com Git - qemu-xen.git/commitdiff
vl: initialize displays _after_ exiting preconfiguration
authorPaolo Bonzini <pbonzini@redhat.com>
Thu, 17 Dec 2020 09:10:12 +0000 (10:10 +0100)
committerPaolo Bonzini <pbonzini@redhat.com>
Sat, 2 Jan 2021 20:03:09 +0000 (21:03 +0100)
Due to the renumbering of text consoles when graphical consoles are
created, init_displaystate must be called after all QemuConsoles are
created, i.e. after devices are created.

vl.c calls it from qemu_init_displays, while qmp_x_exit_preconfig is
where devices are created.  If qemu_init_displays is called before it,
the VGA graphical console does not come up.

Reported-by: Howard Spoelstra <hsp.cat7@gmail.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
softmmu/vl.c

index 0ed5c5ba9348160f8864858b99d84e8b6128654c..7ddf405d76747005c8e7a790b31e0b1a4261f65c 100644 (file)
@@ -3529,10 +3529,10 @@ void qemu_init(int argc, char **argv, char **envp)
         exit(0);
     }
 
-    qemu_init_displays();
     if (!preconfig_requested) {
         qmp_x_exit_preconfig(&error_fatal);
     }
+    qemu_init_displays();
     accel_setup_post(current_machine);
     os_setup_post();
     resume_mux_open();