diff options
author | Helge Deller <deller@gmx.de> | 2023-06-24 00:42:39 +0200 |
---|---|---|
committer | Helge Deller <deller@gmx.de> | 2023-06-24 02:19:13 +0200 |
commit | fa008172af24ba3288d325e3c8631f2150bee22b (patch) | |
tree | 7a3e6335a14db3c3ec60d75524bd9b0dadb60895 | |
parent | a385f17c5c3ddf44ec0bdf28045d3736e84d138e (diff) | |
download | seabios-hppa-fa008172af24ba3288d325e3c8631f2150bee22b.zip seabios-hppa-fa008172af24ba3288d325e3c8631f2150bee22b.tar.gz seabios-hppa-fa008172af24ba3288d325e3c8631f2150bee22b.tar.bz2 |
parisc: Show qemu version in boot menu
Get the qemu version from the fw_cfg interface and show it
during bootup.
Signed-off-by: Helge Deller <deller@gmx.de>
-rw-r--r-- | src/parisc/parisc.c | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/src/parisc/parisc.c b/src/parisc/parisc.c index 05549ae..fc75235 100644 --- a/src/parisc/parisc.c +++ b/src/parisc/parisc.c @@ -117,6 +117,8 @@ int pdc_console; int sti_font; +char qemu_version[16] = "unknown version"; + /* Want PDC boot menu? Enable via qemu "-boot menu=on" option. */ unsigned int show_boot_menu; unsigned int interact_ipl; @@ -2183,6 +2185,10 @@ void __VISIBLE start_parisc_firmware(void) model.sw_id = romfile_loadstring_to_int("opt/hostid", model.sw_id); dprintf(0, "fw_cfg: machine hostid %lu\n", model.sw_id); + str = romfile_loadfile("/etc/qemu-version", NULL); + if (str) + strtcpy(qemu_version, str, sizeof(qemu_version)); + /* Do not initialize PAGE0. We have the boot args stored there. */ /* memset((void*)PAGE0, 0, sizeof(*PAGE0)); */ @@ -2294,10 +2300,10 @@ void __VISIBLE start_parisc_firmware(void) } printf("\n"); - printf("SeaBIOS PA-RISC Firmware Version %d\n" - "\n" + printf("SeaBIOS PA-RISC Firmware Version " SEABIOS_HPPA_VERSION_STR + " (QEMU %s)\n\n" "Duplex Console IO Dependent Code (IODC) revision 1\n" - "\n", SEABIOS_HPPA_VERSION); + "\n", qemu_version); printf("------------------------------------------------------------------------------\n" " (c) Copyright 2017-2023 Helge Deller <deller@gmx.de> and SeaBIOS developers.\n" "------------------------------------------------------------------------------\n\n"); |