From 6a1219cfe0e97af9aefc3b55397f5936af4e3e9d Mon Sep 17 00:00:00 2001 From: Andrey Petrov Date: Mon, 8 Feb 2016 17:13:35 -0800 Subject: arch/x86: Allow bootblock code to use CAR_GLOBAL variables Since cbmem is not initialized in bootblock, CAR_GLOBAL variables can only be accessed directly similar to verstage. Change-Id: Ifc705016290807c49dc8c49b581864cac2ad3f80 Signed-off-by: Andrey Petrov Reviewed-on: https://review.coreboot.org/13641 Reviewed-by: Aaron Durbin Tested-by: build bot (Jenkins) --- src/arch/x86/include/arch/early_variables.h | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'src/arch') diff --git a/src/arch/x86/include/arch/early_variables.h b/src/arch/x86/include/arch/early_variables.h index 34d4a7dbb1..16eeacce62 100644 --- a/src/arch/x86/include/arch/early_variables.h +++ b/src/arch/x86/include/arch/early_variables.h @@ -29,10 +29,11 @@ asm(".previous"); #endif /* __clang__ */ /* - * On x86 verstage, all CAR_GLOBAL variables are accessed unconditionally - * because cbmem is never initialized until romstage when dram comes up. + * In stages that use CAR (verstage, C bootblock) all CAR_GLOBAL variables are + * accessed unconditionally because cbmem is never initialized until romstage + * when dram comes up. */ -#if ENV_VERSTAGE +#if ENV_VERSTAGE || ENV_BOOTBLOCK static inline void *car_get_var_ptr(void *var) { return var; -- cgit v1.2.3