diff mbox series

[17/42] x86: Simplify check for SPL

Message ID 20240926223814.1276764-18-sjg@chromium.org
State Changes Requested
Delegated to: Tom Rini
Headers show
Series Tidy up use of 'SPL' and CONFIG_SPL_BUILD | expand

Commit Message

Simon Glass Sept. 26, 2024, 10:35 p.m. UTC
Now that SPL means SPL (only) and is not defined for TPL, simplify some
checks for SPL.

Signed-off-by: Simon Glass <sjg@chromium.org>
---

 arch/x86/cpu/apollolake/fsp_bindings.c | 2 +-
 arch/x86/cpu/broadwell/cpu_full.c      | 2 +-
 arch/x86/lib/Makefile                  | 9 ++-------
 3 files changed, 4 insertions(+), 9 deletions(-)
diff mbox series

Patch

diff --git a/arch/x86/cpu/apollolake/fsp_bindings.c b/arch/x86/cpu/apollolake/fsp_bindings.c
index b4bb677f5cd..4b0756e77cc 100644
--- a/arch/x86/cpu/apollolake/fsp_bindings.c
+++ b/arch/x86/cpu/apollolake/fsp_bindings.c
@@ -653,7 +653,7 @@  int fsp_m_update_config_from_dtb(ofnode node, struct fsp_m_config *cfg)
 }
 #endif
 
-#if !defined(CONFIG_XPL_BUILD) && !defined(CONFIG_TPL_BUILD)
+#if !defined(CONFIG_SPL_BUILD)
 const struct fsp_binding fsp_s_bindings[] = {
 	{
 	.type = FSP_UINT8,
diff --git a/arch/x86/cpu/broadwell/cpu_full.c b/arch/x86/cpu/broadwell/cpu_full.c
index 529dab18d5d..46a6436be54 100644
--- a/arch/x86/cpu/broadwell/cpu_full.c
+++ b/arch/x86/cpu/broadwell/cpu_full.c
@@ -84,7 +84,7 @@  static const u8 power_limit_time_msr_to_sec[] = {
 	[0x11] = 128,
 };
 
-#if defined(CONFIG_XPL_BUILD) && !defined(CONFIG_TPL_BUILD)
+#if defined(CONFIG_SPL_BUILD)
 int arch_cpu_init(void)
 {
 	return 0;
diff --git a/arch/x86/lib/Makefile b/arch/x86/lib/Makefile
index 2738f0b577b..bf0605ad662 100644
--- a/arch/x86/lib/Makefile
+++ b/arch/x86/lib/Makefile
@@ -58,13 +58,8 @@  obj-$(CONFIG_FSP_VERSION1) += fsp1/
 obj-$(CONFIG_FSP_VERSION2) += fsp2/
 endif
 
-ifdef CONFIG_XPL_BUILD
-ifdef CONFIG_TPL_BUILD
-obj-y += tpl.o
-else
-obj-y += spl.o
-endif
-endif
+obj-$(CONFIG_SPL_BUILD) += spl.o
+obj-$(CONFIG_TPL_BUILD) += tpl.o
 
 lib-$(CONFIG_USE_PRIVATE_LIBGCC) += div64.o