Julius Werner has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/36908 )
Change subject: lib/fmap.c: Properly handle cache for !C_ENVIRONMENT_BOOTBLOCK ......................................................................
Patch Set 1:
(1 comment)
Thanks! There are so many different ways coreboot can run it's hard to keep track of them all.
https://review.coreboot.org/c/coreboot/+/36908/1/src/lib/fmap.c File src/lib/fmap.c:
https://review.coreboot.org/c/coreboot/+/36908/1/src/lib/fmap.c@81 PS1, Line 81: if (!ENV_BOOTBLOCK && CONFIG(C_ENVIRONMENT_BOOTBLOCK)) {
Looks like this will result in no signature checking for the !c_env_bootblock platforms post romstag […]
Yeah, I agree with Aaron, this needs to be written differently. Could be simplified to
if (!ENV_BOOTBLOCK && !(CONFIG(C_ENVIRONMENT_BOOTBLOCK) && ENV_ROMSTAGE))
Maybe we should also consider adding a new helper rule like ENV_FIRST_STAGE for this? (I guess the romstage isn't literally the first stage for those devices, but it's the first stage common code will see.)