Arthur Heymans has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/52157 )
Change subject: drivers/mrc_cache: Fix with VBOOT & VBOOT_STARTS_IN_ROMSTAGE ......................................................................
drivers/mrc_cache: Fix with VBOOT & VBOOT_STARTS_IN_ROMSTAGE
This guards code accessing the vboot context which does not exist if vboot starts after romstage.
Change-Id: I2a38daa00d6d18df9c5e22858530814e23bb3e00 Signed-off-by: Arthur Heymans arthur@aheymans.xyz --- M src/drivers/mrc_cache/mrc_cache.c 1 file changed, 2 insertions(+), 1 deletion(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/57/52157/1
diff --git a/src/drivers/mrc_cache/mrc_cache.c b/src/drivers/mrc_cache/mrc_cache.c index 8b26ea5..f97031d 100644 --- a/src/drivers/mrc_cache/mrc_cache.c +++ b/src/drivers/mrc_cache/mrc_cache.c @@ -285,7 +285,8 @@ * In recovery mode, force retraining if the memory retrain * switch is set. */ - if (vboot_recovery_mode_enabled() && get_recovery_mode_retrain_switch()) + if (CONFIG(VBOOT_STARTS_IN_BOOTBLOCK) && vboot_recovery_mode_enabled() + && get_recovery_mode_retrain_switch()) return -1;
cr = lookup_region(®ion, type);