diff options
author | Gerd Hoffmann <kraxel@redhat.com> | 2017-09-18 10:47:22 +0200 |
---|---|---|
committer | Kevin O'Connor <kevin@koconnor.net> | 2017-09-22 11:13:22 -0400 |
commit | 0ebc29f9c4db27f7f0a9d3dcc49563811ce06546 (patch) | |
tree | 3a6a00f92a1487c3cf3fea4eda8f00a113f4b510 /src | |
parent | 1bda724cc5671f067d564d1ad18bba34384ff8f5 (diff) | |
download | seabios-hppa-0ebc29f9c4db27f7f0a9d3dcc49563811ce06546.zip seabios-hppa-0ebc29f9c4db27f7f0a9d3dcc49563811ce06546.tar.gz seabios-hppa-0ebc29f9c4db27f7f0a9d3dcc49563811ce06546.tar.bz2 |
paravirt: serial console configuration.
Read QEMU_CFG_NOGRAPHIC, if set add etc/sercon-port
file to enable the serial console.
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Diffstat (limited to 'src')
-rw-r--r-- | src/fw/paravirt.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/fw/paravirt.c b/src/fw/paravirt.c index 5b23d78..9674ab8 100644 --- a/src/fw/paravirt.c +++ b/src/fw/paravirt.c @@ -14,6 +14,7 @@ #include "hw/pci.h" // pci_config_readw #include "hw/pcidevice.h" // pci_probe_devices #include "hw/pci_regs.h" // PCI_DEVICE_ID +#include "hw/serialio.h" // PORT_SERIAL1 #include "hw/rtc.h" // CMOS_* #include "malloc.h" // malloc_tmp #include "output.h" // dprintf @@ -210,6 +211,7 @@ qemu_platform_setup(void) #define QEMU_CFG_SIGNATURE 0x00 #define QEMU_CFG_ID 0x01 #define QEMU_CFG_UUID 0x02 +#define QEMU_CFG_NOGRAPHIC 0x04 #define QEMU_CFG_NUMA 0x0d #define QEMU_CFG_BOOT_MENU 0x0e #define QEMU_CFG_NB_CPUS 0x05 @@ -511,6 +513,12 @@ qemu_cfg_legacy(void) qemu_romfile_add("etc/irq0-override", QEMU_CFG_IRQ0_OVERRIDE, 0, 1); qemu_romfile_add("etc/max-cpus", QEMU_CFG_MAX_CPUS, 0, 2); + // serial console + u16 nogfx = 0; + qemu_cfg_read_entry(&nogfx, QEMU_CFG_NOGRAPHIC, sizeof(nogfx)); + if (nogfx) + const_romfile_add_int("etc/sercon-port", PORT_SERIAL1); + // NUMA data u64 numacount; qemu_cfg_read_entry(&numacount, QEMU_CFG_NUMA, sizeof(numacount)); |