[PATCH 1/1] defaultenv-2: execute init/* before timeout

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



so we can have splash, usb serial, etc...

Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@xxxxxxxxxxxx>
---
 defaultenv-2/base/bin/init |   12 ++++++++++--
 1 file changed, 10 insertions(+), 2 deletions(-)

diff --git a/defaultenv-2/base/bin/init b/defaultenv-2/base/bin/init
index 2a1f6a1..b606b63 100644
--- a/defaultenv-2/base/bin/init
+++ b/defaultenv-2/base/bin/init
@@ -21,8 +21,9 @@ else
 	echo -e -n "\nHit any key to stop autoboot: "
 fi
 
-timeout -a $global.autoboot_timeout -v key
-autoboot="$?"
+# allow to stop the boot before execute the /env/init/*
+# but without waiting
+timeout -s -a -v key 0
 
 if [ "${key}" = "q" ]; then
 	exit
@@ -32,6 +33,13 @@ for i in /env/init/*; do
 	. $i
 done
 
+timeout -a $global.autoboot_timeout -v key
+autoboot="$?"
+
+if [ "${key}" = "q" ]; then
+	exit
+fi
+
 if [ "$autoboot" = 0 ]; then
 	boot
 fi
-- 
1.7.10.4


_______________________________________________
barebox mailing list
barebox@xxxxxxxxxxxxxxxxxxx
http://lists.infradead.org/mailman/listinfo/barebox


[Index of Archives]     [Linux Embedded]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux