Arthur Heymans has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/36422 )
Change subject: lib/Kconfig: Flip the meaning of RAMSTAGE_CBMEM_TOP_ARG ......................................................................
lib/Kconfig: Flip the meaning of RAMSTAGE_CBMEM_TOP_ARG
Now that only a few exceptions have their own cbmem_top implementation, flip the meanining of RAMSTAGE_CBMEM_TOP_ARG around.
Change-Id: Ie7467629e58700e4d29f6e735840c22ed687f880 Signed-off-by: Arthur Heymans arthur@aheymans.xyz --- M src/arch/arm/Kconfig M src/arch/arm64/Kconfig M src/arch/mips/Kconfig M src/arch/ppc64/Kconfig M src/arch/riscv/Kconfig M src/arch/x86/Kconfig M src/lib/Kconfig M src/lib/Makefile.inc M src/soc/nvidia/tegra124/Kconfig M src/soc/nvidia/tegra210/Kconfig 10 files changed, 11 insertions(+), 11 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/22/36422/1
diff --git a/src/arch/arm/Kconfig b/src/arch/arm/Kconfig index d668039..47c333b 100644 --- a/src/arch/arm/Kconfig +++ b/src/arch/arm/Kconfig @@ -17,7 +17,6 @@ config ARCH_RAMSTAGE_ARM bool select ARCH_ARM - select RAMSTAGE_CBMEM_TOP_ARG if !SOC_NVIDIA_TEGRA124
source src/arch/arm/armv4/Kconfig source src/arch/arm/armv7/Kconfig diff --git a/src/arch/arm64/Kconfig b/src/arch/arm64/Kconfig index 0438ded..3d1d184 100644 --- a/src/arch/arm64/Kconfig +++ b/src/arch/arm64/Kconfig @@ -17,7 +17,6 @@ config ARCH_RAMSTAGE_ARM64 bool select ARCH_ARM64 - select RAMSTAGE_CBMEM_TOP_ARG if !SOC_NVIDIA_TEGRA210
source src/arch/arm64/armv8/Kconfig
diff --git a/src/arch/mips/Kconfig b/src/arch/mips/Kconfig index 321bfc9..9df514b 100644 --- a/src/arch/mips/Kconfig +++ b/src/arch/mips/Kconfig @@ -22,7 +22,6 @@ default n select BOOTBLOCK_CUSTOM select C_ENVIRONMENT_BOOTBLOCK - select RAMSTAGE_CBMEM_TOP_ARG
config ARCH_VERSTAGE_MIPS bool diff --git a/src/arch/ppc64/Kconfig b/src/arch/ppc64/Kconfig index da9c155..0699e91 100644 --- a/src/arch/ppc64/Kconfig +++ b/src/arch/ppc64/Kconfig @@ -1,6 +1,5 @@ config ARCH_PPC64 bool - select RAMSTAGE_CBMEM_TOP_ARG
config ARCH_BOOTBLOCK_PPC64 bool diff --git a/src/arch/riscv/Kconfig b/src/arch/riscv/Kconfig index f2ca571..cb534db 100644 --- a/src/arch/riscv/Kconfig +++ b/src/arch/riscv/Kconfig @@ -86,6 +86,7 @@ config ARCH_ROMSTAGE_RISCV bool default n + select CUSTOM_CBMEM_TOP
config ARCH_RAMSTAGE_RISCV bool diff --git a/src/arch/x86/Kconfig b/src/arch/x86/Kconfig index 8ce5977..502e774 100644 --- a/src/arch/x86/Kconfig +++ b/src/arch/x86/Kconfig @@ -16,7 +16,6 @@ default n select PCI select RELOCATABLE_MODULES - select RAMSTAGE_CBMEM_TOP_ARG
# stage selectors for x86
diff --git a/src/lib/Kconfig b/src/lib/Kconfig index aede4b3..a882b72 100644 --- a/src/lib/Kconfig +++ b/src/lib/Kconfig @@ -24,11 +24,10 @@ help Selected by features that require `libhwbase` in ramstage.
-config RAMSTAGE_CBMEM_TOP_ARG +config CUSTOM_CBMEM_TOP bool help - Select this if stages run after romstage get the cbmem_top - pointer the function arguments when called from romstage. + Select this if a platform has a custom implementation of cbmem_top.
config FLATTENED_DEVICE_TREE bool diff --git a/src/lib/Makefile.inc b/src/lib/Makefile.inc index 5b9d827..5aecf4e 100644 --- a/src/lib/Makefile.inc +++ b/src/lib/Makefile.inc @@ -149,18 +149,15 @@ ramstage-$(CONFIG_PAYLOAD_FIT_SUPPORT) += fit.c ramstage-$(CONFIG_PAYLOAD_FIT_SUPPORT) += fit_payload.c
-romstage-$(CONFIG_RAMSTAGE_CBMEM_TOP_ARG) += cbmem_top.c romstage-y += cbmem_common.c romstage-y += imd_cbmem.c romstage-y += imd.c
-ramstage-$(CONFIG_RAMSTAGE_CBMEM_TOP_ARG) += cbmem_top.c ramstage-y += cbmem_common.c ramstage-y += imd_cbmem.c ramstage-y += imd.c
postcar-$(CONFIG_VENDOR_EMULATION) += ramdetect.c -postcar-$(CONFIG_RAMSTAGE_CBMEM_TOP_ARG) += cbmem_top.c postcar-y += cbmem_common.c postcar-$(CONFIG_CONSOLE_CBMEM) += cbmem_console.c postcar-y += imd_cbmem.c @@ -187,6 +184,12 @@ romstage-$(CONFIG_CBMEM_STAGE_CACHE) += cbmem_stage_cache.c postcar-$(CONFIG_CBMEM_STAGE_CACHE) += cbmem_stage_cache.c
+ifneq ($(CONFIG_CUSTOM_CBMEM_TOP),y) +ramstage-y += cbmem_top.c +romstage-y += cbmem_top.c +postcar-y += cbmem_top.c +endif + romstage-y += boot_device.c ramstage-y += boot_device.c
diff --git a/src/soc/nvidia/tegra124/Kconfig b/src/soc/nvidia/tegra124/Kconfig index c962aea..0df23e9 100644 --- a/src/soc/nvidia/tegra124/Kconfig +++ b/src/soc/nvidia/tegra124/Kconfig @@ -12,6 +12,7 @@ select MAINBOARD_HAS_NATIVE_VGA_INIT select MAINBOARD_FORCE_NATIVE_VGA_INIT select HAVE_LINEAR_FRAMEBUFFER + select CUSTOM_CBMEM_TOP
if SOC_NVIDIA_TEGRA124
diff --git a/src/soc/nvidia/tegra210/Kconfig b/src/soc/nvidia/tegra210/Kconfig index 0e1efd7..d3d99dc 100644 --- a/src/soc/nvidia/tegra210/Kconfig +++ b/src/soc/nvidia/tegra210/Kconfig @@ -10,6 +10,7 @@ select HAVE_UART_SPECIAL select ARM64_USE_ARM_TRUSTED_FIRMWARE select GENERIC_GPIO_LIB + select CUSTOM_CBMEM_TOP
if SOC_NVIDIA_TEGRA210