diff options
author | Arthur Heymans <arthur@aheymans.xyz> | 2022-05-18 21:37:58 +0200 |
---|---|---|
committer | Felix Held <felix-coreboot@felixheld.de> | 2022-05-20 11:22:32 +0000 |
commit | 2efd8315f20ff1fbdccdc0b6f0af97b4a7512981 (patch) | |
tree | cdce33a0b5aeb080ff3d2ef7281a7cc7aff3579f /src/lib/Makefile.inc | |
parent | 5b757b597a3e75c6d0d17025288de8d162a77f52 (diff) |
lib/Makefile.inc: Add cbfs header pointer on !BOOTBLOCK_IN_CBFS
On some x86 targets it the bootblock is loaded via a different
mechanism, like via the AMD PSP or Intel IFWI. Some payloads need that
pointer so add it to cbfs.
Note that on Intel APL this file is not used, which is why the
bootblock still needs to contain the pointer in the ARCH_X86 part.
It is not worth it to add logic to specifically deal with APL as this is
a legacy feature anyway.
For AMD non-car platform this fixes cbfs access in SeaBIOS.
Change-Id: If46e80e3eed5cc3f59964ac58e507f927fc563c4
Signed-off-by: Arthur Heymans <arthur@aheymans.xyz>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/64483
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Felix Held <felix-coreboot@felixheld.de>
Diffstat (limited to 'src/lib/Makefile.inc')
-rw-r--r-- | src/lib/Makefile.inc | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/src/lib/Makefile.inc b/src/lib/Makefile.inc index 57b0c7a122..505dc4684b 100644 --- a/src/lib/Makefile.inc +++ b/src/lib/Makefile.inc @@ -402,9 +402,18 @@ cbfs_master_header-position := 0 ifeq ($(CONFIG_ARCH_X86),y) $(call src-to-obj,bootblock,$(dir)/master_header_pointer.c): $(obj)/fmap_config.h bootblock-y += master_header_pointer.c -else -cbfs-files-y += header_pointer +endif + +NEED_CBFS_POINTER= + +ifneq ($(CONFIG_ARCH_X86),y) +NEED_CBFS_POINTER=y +endif +ifneq ($(CONFIG_BOOTBLOCK_IN_CBFS),y) +NEED_CBFS_POINTER=y +endif + +cbfs-files-$(NEED_CBFS_POINTER) += header_pointer header_pointer-file := master_header_pointer.c:struct header_pointer-position := -4 header_pointer-type := "cbfs header" -endif |