[coreboot-gerrit] Patch set updated for coreboot: dcab843 X86 Kconfig: Make the MAX_REBOOT_CNT selectable in X86_BOOTBLOCK_NORMAL mode.
Denis Carikli (GNUtoo@no-log.org)
gerrit at coreboot.org
Tue Nov 12 00:13:40 CET 2013
Denis Carikli (GNUtoo at no-log.org) just uploaded a new patch set to gerrit, which you can find at http://review.coreboot.org/3991
Author: Denis 'GNUtoo' Carikli <GNUtoo at no-log.org>
Date: Sun Oct 20 23:37:35 2013 +0200
X86 Kconfig: Make the MAX_REBOOT_CNT selectable in X86_BOOTBLOCK_NORMAL mode.
src/arch/x86/Kconfig defined MAX_REBOOT_CNT as 3.
In the bootblock, the reboot_bits cmos option is increased by one at each boot.
If the boot is successful, the respective nvram settings have to be reset to
boot on the normal/ prefix next time.
If KEEP_BOOT_COUNT is selected, it has to be done after the ramstage,
if not, it's done in the ramstage.
In case of a failed boot, the reboot_bits keeps increasing until it reach
KEEP_BOOT_COUNT. Once it is reached, it will swtich to fallback/ at next boot.
With KEEP_BOOT_COUNT beeing hidden in make menuconfig, and set to 3,
the user probably won't know that coreboot will only switch to fallback after
3 failed boots, and will act as if the computer will not boot anymore with its
current coreboot image.
This patch makes KEEP_BOOT_COUNT selectable.
This patch was tested on the Lenovo X60.
Signed-off-by: Denis 'GNUtoo' Carikli <GNUtoo at no-log.org>
src/arch/x86/Kconfig | 20 ++++++++++++++------
1 file changed, 14 insertions(+), 6 deletions(-)
diff --git a/src/arch/x86/Kconfig b/src/arch/x86/Kconfig
index 0a21fcc..52bafbd 100644
@@ -42,12 +42,6 @@ config STACK_SIZE
-# Maximum reboot count
-# TODO: Improve description.
- default 3
# This is something you almost certainly don't want to mess with.
# How many SIPIs do we send when starting up APs and cores?
# The answer in 2000 or so was '2'. Nowadays, on many systems,
@@ -72,6 +66,20 @@ config X86_BOOTBLOCK_NORMAL
+# Maximum reboot count
+ int "Number of failed boot attempts before switching back to fallback/"
+ default 3
+ depends on X86_BOOTBLOCK_NORMAL
+ Note that the minimum number of reset a machine has to do to boot
+ can vary across machines.
+ If you set it to a number that is less that the machine minimum,
+ the machine will then switch to fallback/ during the next boot.
+ Once in fallback/, the machine will keep that settings unless
+ the nvram is reset, which will make it switch to fallback/
+ again during the next boot.
default "bootblock_simple.c" if X86_BOOTBLOCK_SIMPLE
More information about the coreboot-gerrit