[SeaBIOS] [PATCH v6 3/3] Boot up with a splash picture configurable

Wayne Xia xiawenc at linux.vnet.ibm.com
Thu Jul 7 11:39:34 CEST 2011


try show the splash picture without menu=on, if user want to show it as a brand

Signed-off-by: Wayne Xia <xiawenc at linux.vnet.ibm.com>
---
 src/boot.c |   19 ++++++++++++++-----
 1 files changed, 14 insertions(+), 5 deletions(-)

diff --git a/src/boot.c b/src/boot.c
index fcc95ab..d27d44e 100644
--- a/src/boot.c
+++ b/src/boot.c
@@ -383,17 +383,26 @@ boot_add_cbfs(void *data, const char *desc, int prio)
 static void
 interactive_bootmenu(void)
 {
-    if (! CONFIG_BOOTMENU || ! qemu_cfg_show_boot_menu())
-        return;
-
+    int scan_code;
     while (get_keystroke(0) >= 0)
         ;
+    u32 menutime = romfile_loadint("etc/boot-menu-wait", 0);
+    if (!CONFIG_BOOTMENU || !qemu_cfg_show_boot_menu()) {
+        if (menutime > 0) {
+            enable_bootsplash();
+            scan_code = get_keystroke(menutime);
+            disable_bootsplash();
+        }
+        return;
+    }
+
 
     printf("Press F12 for boot menu.\n\n");
 
-    u32 menutime = romfile_loadint("etc/boot-menu-wait", DEFAULT_BOOTMENU_WAIT);
+    if (menutime == 0)
+        menutime = DEFAULT_BOOTMENU_WAIT;
     enable_bootsplash();
-    int scan_code = get_keystroke(menutime);
+    scan_code = get_keystroke(menutime);
     disable_bootsplash();
     if (scan_code != 0x86)
         /* not F12 */
-- 
1.7.6.rc1.1.g2c162b




More information about the SeaBIOS mailing list