Stefan Reinauer (stefan.reinauer@coreboot.org) just uploaded a new patch set to gerrit, which you can find at http://review.coreboot.org/8225
-gerrit
commit c8d51027d0d932b88468bcbeadded374a6e104b6 Author: Stefan Reinauer reinauer@chromium.org Date: Wed Jan 14 11:07:49 2015 -0800
vboot2: fix up "add verstage"
Architecture support was incomplete, which lead to toolchain.inc choking on some of its implicit expectations from Kconfig.
Fix config variable usage in tegra124 bootblock and remove extra whitespace.
Change-Id: I0a504f01d10302fbf2bd1bbc82cfd047ed02157f Signed-off-by: Stefan Reinauer stefan.reinauer@coreboot.org --- src/arch/arm/Kconfig | 4 ++-- src/arch/arm/Makefile.inc | 2 +- src/arch/arm64/Kconfig | 4 ++++ src/arch/arm64/armv8/Kconfig | 3 +++ src/arch/riscv/Kconfig | 4 ++++ src/arch/x86/Kconfig | 4 ++++ src/soc/nvidia/tegra124/bootblock.c | 12 ++++-------- 7 files changed, 22 insertions(+), 11 deletions(-)
diff --git a/src/arch/arm/Kconfig b/src/arch/arm/Kconfig index f73ad27..1c3a339 100644 --- a/src/arch/arm/Kconfig +++ b/src/arch/arm/Kconfig @@ -4,8 +4,8 @@ config ARCH_BOOTBLOCK_ARM select ARCH_ARM
config ARCH_VERSTAGE_ARM - bool - default n + bool + default n
config ARCH_ROMSTAGE_ARM bool diff --git a/src/arch/arm/Makefile.inc b/src/arch/arm/Makefile.inc index ba7fb60..6f65a71 100644 --- a/src/arch/arm/Makefile.inc +++ b/src/arch/arm/Makefile.inc @@ -61,7 +61,7 @@ bootblock-y += memcpy.S bootblock-y += memmove.S bootblock-y += div0.c
-$(objcbfs)/bootblock.debug: $(src)/arch/arm/bootblock.ld $(obj)/ldoptions $$(bootblock-objs) $$(VERSTAGE_LIB) +$(objcbfs)/bootblock.debug: $(src)/arch/arm/bootblock.ld $(obj)/ldoptions $$(bootblock-objs) $$(VERSTAGE_LIB) @printf " LINK $(subst $(obj)/,,$(@))\n" $(LD_bootblock) --gc-sections -static -o $@ -L$(obj) --start-group $(bootblock-objs) --end-group -T $(src)/arch/arm/bootblock.ld
diff --git a/src/arch/arm64/Kconfig b/src/arch/arm64/Kconfig index dc0e332..186dd44 100644 --- a/src/arch/arm64/Kconfig +++ b/src/arch/arm64/Kconfig @@ -3,6 +3,10 @@ config ARCH_BOOTBLOCK_ARM64 default n select ARCH_ARM64
+config ARCH_VERSTAGE_ARM64 + bool + default n + config ARCH_ROMSTAGE_ARM64 bool default n diff --git a/src/arch/arm64/armv8/Kconfig b/src/arch/arm64/armv8/Kconfig index fc2e668..5840e81 100644 --- a/src/arch/arm64/armv8/Kconfig +++ b/src/arch/arm64/armv8/Kconfig @@ -1,6 +1,9 @@ config ARCH_BOOTBLOCK_ARM_V8_64 def_bool n select ARCH_BOOTBLOCK_ARM64 +config ARCH_VERSTAGE_ARM_V8_64 + def_bool n + select ARCH_VERSTAGE_ARM64 config ARCH_ROMSTAGE_ARM_V8_64 def_bool n select ARCH_ROMSTAGE_ARM64 diff --git a/src/arch/riscv/Kconfig b/src/arch/riscv/Kconfig index 120203d..f2dc41e 100644 --- a/src/arch/riscv/Kconfig +++ b/src/arch/riscv/Kconfig @@ -3,6 +3,10 @@ config ARCH_BOOTBLOCK_RISCV default n select ARCH_RISCV
+config ARCH_VERSTAGE_RISCV + bool + default n + config ARCH_ROMSTAGE_RISCV bool default n diff --git a/src/arch/x86/Kconfig b/src/arch/x86/Kconfig index 56d8f88..edbc67a 100644 --- a/src/arch/x86/Kconfig +++ b/src/arch/x86/Kconfig @@ -3,6 +3,10 @@ config ARCH_BOOTBLOCK_X86_32 default n select ARCH_X86
+config ARCH_VERSTAGE_X86_32 + bool + default n + config ARCH_ROMSTAGE_X86_32 bool default n diff --git a/src/soc/nvidia/tegra124/bootblock.c b/src/soc/nvidia/tegra124/bootblock.c index 0456b48..5f1e850 100644 --- a/src/soc/nvidia/tegra124/bootblock.c +++ b/src/soc/nvidia/tegra124/bootblock.c @@ -25,10 +25,7 @@ #include <soc/nvidia/tegra/apbmisc.h> #include "pinmux.h" #include "power.h" - -#if CONFIG_VBOOT2_VERIFY_FIRMWARE #include "verstage.h" -#endif
void main(void) { @@ -75,11 +72,10 @@ void main(void) power_enable_cpu_rail(); power_ungate_cpu();
-#if CONFIG_VBOOT2_VERIFY_FIRMWARE - entry = (void *)verstage_vboot_main; -#else - entry = cbfs_load_stage(CBFS_DEFAULT_MEDIA, "fallback/romstage"); -#endif + if (IS_ENABLED(CONFIG_VBOOT2_VERIFY_FIRMWARE)) + entry = (void *)verstage_vboot_main; + else + entry = cbfs_load_stage(CBFS_DEFAULT_MEDIA, "fallback/romstage");
if (entry) clock_cpu0_config_and_reset(entry);