startup: add $global.autoboot to make behavior configurable
We already have a global_autoboot_state variable that controls barebox
init behavior on startup:

* ABORT      abort and fall into shell
* MENU       display boot menu
* BOOT       boot immediately, only abortable via ctrl+c
             during init
* COUNTDOWN  regular boot after count down

Exporting this as a device parameter allows us to support some
different boot scenarios:

* COUNTDOWN is the default
* ABORT boot always while debugging
* display MENU by default (e.g. for graphical boots)
* BOOT while ignoring external code calling console_countdown_abort()

Signed-off-by: Ahmad Fatoum <ahmad@a3f.at>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
1 parent 1973892 commit 10062129e708a23b354424d0134a9ccd3e56b4bc
@Ahmad Fatoum Ahmad Fatoum authored on 22 Apr 2020
Sascha Hauer committed on 27 Apr 2020
Showing 1 changed file
View
common/startup.c