Arthur Heymans has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/36323 )
Change subject: lib/cbfs: Don't load XIP stages from bootblock ......................................................................
lib/cbfs: Don't load XIP stages from bootblock
This should improve boot times as it skips unnecessary read and writes.
Change-Id: I8cf36613903783e741b2e3bfeeee5bc29ab26d5b Signed-off-by: Arthur Heymans arthur@aheymans.xyz --- M src/lib/cbfs.c 1 file changed, 1 insertion(+), 1 deletion(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/23/36323/1
diff --git a/src/lib/cbfs.c b/src/lib/cbfs.c index 91368fb..1e8a93f 100644 --- a/src/lib/cbfs.c +++ b/src/lib/cbfs.c @@ -256,7 +256,7 @@
/* Hacky way to not load programs over read only media. The stages * that would hit this path initialize themselves. */ - if (ENV_VERSTAGE && !CONFIG(NO_XIP_EARLY_STAGES) && + if ((ENV_BOOTBLOCK || ENV_VERSTAGE) && !CONFIG(NO_XIP_EARLY_STAGES) && CONFIG(BOOT_DEVICE_MEMORY_MAPPED)) { void *mapping = rdev_mmap(fh, foffset, fsize); rdev_munmap(fh, mapping);
Aaron Durbin has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/36323 )
Change subject: lib/cbfs: Don't load XIP stages from bootblock ......................................................................
Patch Set 1: Code-Review+2
It'd be good to know if we were hitting the case this catch is trying to prevent. Logically, it makes sense.
Arthur Heymans has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/36323 )
Change subject: lib/cbfs: Don't load XIP stages from bootblock ......................................................................
Patch Set 1:
Patch Set 1: Code-Review+2
It'd be good to know if we were hitting the case this catch is trying to prevent. Logically, it makes sense.
It does on qemu at least.
Patrick Georgi has submitted this change. ( https://review.coreboot.org/c/coreboot/+/36323 )
Change subject: lib/cbfs: Don't load XIP stages from bootblock ......................................................................
lib/cbfs: Don't load XIP stages from bootblock
This should improve boot times as it skips unnecessary read and writes.
Change-Id: I8cf36613903783e741b2e3bfeeee5bc29ab26d5b Signed-off-by: Arthur Heymans arthur@aheymans.xyz Reviewed-on: https://review.coreboot.org/c/coreboot/+/36323 Tested-by: build bot (Jenkins) no-reply@coreboot.org Reviewed-by: Aaron Durbin adurbin@chromium.org --- M src/lib/cbfs.c 1 file changed, 1 insertion(+), 1 deletion(-)
Approvals: build bot (Jenkins): Verified Aaron Durbin: Looks good to me, approved
diff --git a/src/lib/cbfs.c b/src/lib/cbfs.c index 91368fb..1e8a93f 100644 --- a/src/lib/cbfs.c +++ b/src/lib/cbfs.c @@ -256,7 +256,7 @@
/* Hacky way to not load programs over read only media. The stages * that would hit this path initialize themselves. */ - if (ENV_VERSTAGE && !CONFIG(NO_XIP_EARLY_STAGES) && + if ((ENV_BOOTBLOCK || ENV_VERSTAGE) && !CONFIG(NO_XIP_EARLY_STAGES) && CONFIG(BOOT_DEVICE_MEMORY_MAPPED)) { void *mapping = rdev_mmap(fh, foffset, fsize); rdev_munmap(fh, mapping);