Skip to contentSkip to conversation

runqemu: Add new option to disable vga emulation

PATCH In review Khem Raj 2 participants 2 messages Feb 20, 2021 – Feb 21, 2021

lore
Share & tools
lore

Khem Raj

author
#0 lore raw

PATCH v2 1/1 runqemu: Add new option to disable vga emulation

When using nographic, explicitly disabling vga is needed some cases since some qemu firmware (OpenFirmware ) defaults to std vga, and when vga is enabled then it disables output to serial and redirects that to vga which is by design, hwoever we expect the console output to go to serial when using nographic, therefore its important to disable vga with nographic especially on qemu based ppc platforms

Cc Alexander Kanavin <[email protected]>

---
v2: Add separate runqemu option instead of tagging along with nographic

 scripts/runqemu | 3 +++
 1 file changed, 3 insertions(+)
scripts/runqemu +3 -0
index dd92a64553..532f2e338d 100755
@@ -65,6 +65,7 @@ of the following environment variables (in any order):
   MACHINE - the machine name (optional, autodetected from KERNEL filename if unspecified)
   Simplified QEMU command-line options can be passed with:
     nographic - disable video console
+    novga - Disable VGA emulation completely
     sdl - choose the SDL UI frontend
     gtk - choose the Gtk UI frontend
     gl - enable virgl-based GL acceleration (also needs gtk or sdl options)
@@ -489,6 +490,8 @@ class BaseConfig(object):
             elif arg == 'egl-headless':
                 self.set_dri_path()
                 self.qemu_opt_script += ' -vga virtio -display egl-headless,show-cursor=on'
+            elif arg == 'novga':
+                self.qemu_opt_script += ' -vga none'
             elif arg == 'serial':
                 self.kernel_cmdline_script += ' console=ttyS0'
                 self.serialconsole = True
Signature · 1 line
2.30.1
#1 lore raw

Thanks! :)

Alex

Quoted 43 lines · Khem Raj

When using nographic, explicitly disabling vga is needed some cases since some qemu firmware (OpenFirmware ) defaults to std vga, and when vga is enabled then it disables output to serial and redirects that to vga which is by design, hwoever we expect the console output to go to serial when using nographic, therefore its important to disable vga with nographic especially on qemu based ppc platforms

Cc Alexander Kanavin <[email protected]>

---
v2: Add separate runqemu option instead of tagging along with nographic

 scripts/runqemu | 3 +++
 1 file changed, 3 insertions(+)
scripts/runqemu +1 -0
index dd92a64553..532f2e338d 100755
@@ -65,6 +65,7 @@ of the following environment variables (in any order):
   MACHINE - the machine name (optional, autodetected from KERNEL filename
 if unspecified)
   Simplified QEMU command-line options can be passed with:
     nographic - disable video console
+    novga - Disable VGA emulation completely
     sdl - choose the SDL UI frontend
     gtk - choose the Gtk UI frontend

gl - enable virgl-based GL acceleration (also needs gtk or sdl
options)

scripts/runqemu +0 -0
@@ -489,6 +490,8 @@ class BaseConfig(object):
             elif arg == 'egl-headless':
                 self.set_dri_path()
                 self.qemu_opt_script += ' -vga virtio -display

egl-headless,show-cursor=on'

scripts/runqemu +2 -1
+            elif arg == 'novga':
+                self.qemu_opt_script += ' -vga none'
             elif arg == 'serial':
                 self.kernel_cmdline_script += ' console=ttyS0'
                 self.serialconsole = True
--

2.30.1