diff --git a/tool/run/boot_dir/fiasco b/tool/run/boot_dir/fiasco index 3e9e518c5..52ed15d15 100644 --- a/tool/run/boot_dir/fiasco +++ b/tool/run/boot_dir/fiasco @@ -59,6 +59,11 @@ proc bin_dir { } { set fiasco_serial_esc_arg "-serial_esc " +proc run_boot_string { } { + return "L4 Bootstrapper" +} + + ## # Populate boot directory with binaries on fiasco # diff --git a/tool/run/boot_dir/foc b/tool/run/boot_dir/foc index 62b2b6be1..ce4500fd2 100644 --- a/tool/run/boot_dir/foc +++ b/tool/run/boot_dir/foc @@ -240,6 +240,11 @@ proc run_boot_dir_arm {binaries} { } +proc run_boot_string { } { + return "L4 Bootstrapper" +} + + ## # Populate boot directory with binaries on fiasco.OC # diff --git a/tool/run/boot_dir/hw b/tool/run/boot_dir/hw index f6d9b96c6..8213aff43 100644 --- a/tool/run/boot_dir/hw +++ b/tool/run/boot_dir/hw @@ -10,6 +10,11 @@ proc run_boot_dir_hook { } { } +proc run_boot_string { } { + return "kernel initialized" +} + + ## # Populate boot directory with binaries on hw # diff --git a/tool/run/boot_dir/nova b/tool/run/boot_dir/nova index 7057df455..ae5c8fbcd 100644 --- a/tool/run/boot_dir/nova +++ b/tool/run/boot_dir/nova @@ -24,6 +24,11 @@ proc nova_external { } { } +proc run_boot_string { } { + return "NOVA Microhypervisor" +} + + ## # Populate directory with binaries on NOVA # diff --git a/tool/run/boot_dir/okl4 b/tool/run/boot_dir/okl4 index 6036eebb1..e24789d19 100644 --- a/tool/run/boot_dir/okl4 +++ b/tool/run/boot_dir/okl4 @@ -101,6 +101,11 @@ set weaver_xml_template { } +proc run_boot_string { } { + return "OKL4 -" +} + + ## # Populate directory with binaries on OKL4 # diff --git a/tool/run/boot_dir/pistachio b/tool/run/boot_dir/pistachio index 8b6ae51c1..b91ab311f 100644 --- a/tool/run/boot_dir/pistachio +++ b/tool/run/boot_dir/pistachio @@ -63,6 +63,11 @@ proc kernel_external { } { } +proc run_boot_string { } { + return "L4Ka::Pistachio -" +} + + ## # Populdate boot directory with binaries on pistachio # diff --git a/tool/run/log/serial b/tool/run/log/serial index 65a3b6bfb..e4ddf3eac 100644 --- a/tool/run/log/serial +++ b/tool/run/log/serial @@ -22,21 +22,25 @@ proc log_serial_cmd { } { proc run_log { wait_for_re timeout_value } { global output_spawn_id - set timeout 60 - while {true} { - eval spawn [log_serial_cmd] - set output_spawn_id $spawn_id - expect { - "Genode \[0-9]\[0-9]\.\[0-9]\[0-9]" { - wait_for_output $wait_for_re $timeout_value $output_spawn_id; - return true; - } - eof { continue; } - timeout { - puts stderr "Boot process timed out"; - close; - return false; - } + set kernel_msg [run_boot_string] + + eval spawn [log_serial_cmd] + set output_spawn_id $spawn_id + + set timeout 210 + expect { + $kernel_msg { } + eof { + puts stderr "Serial command process died unexpectedly" + return false + } + timeout { + puts stderr "Boot process timed out" + close + return false } } + + wait_for_output $wait_for_re $timeout_value $output_spawn_id + return true } diff --git a/tool/run/run b/tool/run/run index 1a346769b..792fa4c81 100755 --- a/tool/run/run +++ b/tool/run/run @@ -489,6 +489,10 @@ proc wait_for_output { wait_for_re timeout_value running_spawn_id } { ## Fall-back implementations of all run module procedures ## +## +# Dummy boot_string procedure +proc run_boot_string { } { return ""; } + ## # Dummy boot_dir maodule proc run_boot_dir { } { return true; }