[U-Boot] [PATCH 45/48] x86: baytrail: Support operation as an EFI payload

Simon Glass sjg at chromium.org
Wed Jul 22 17:49:37 CEST 2015


Disable a few things which interfere with the EFI init. This allows the
Minnowboard MAX to boot into EFI, load a U-Boot payload then boot to the
U-Boot prompt.

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

 arch/x86/cpu/baytrail/Kconfig      | 2 +-
 arch/x86/cpu/baytrail/cpu.c        | 2 ++
 arch/x86/cpu/baytrail/valleyview.c | 2 ++
 board/intel/minnowmax/Kconfig      | 5 +++--
 4 files changed, 8 insertions(+), 3 deletions(-)

diff --git a/arch/x86/cpu/baytrail/Kconfig b/arch/x86/cpu/baytrail/Kconfig
index e86cc01..407feb2 100644
--- a/arch/x86/cpu/baytrail/Kconfig
+++ b/arch/x86/cpu/baytrail/Kconfig
@@ -6,4 +6,4 @@
 
 config INTEL_BAYTRAIL
 	bool
-	select HAVE_FSP
+	select HAVE_FSP if !EFI
diff --git a/arch/x86/cpu/baytrail/cpu.c b/arch/x86/cpu/baytrail/cpu.c
index a011730..b1faf8c 100644
--- a/arch/x86/cpu/baytrail/cpu.c
+++ b/arch/x86/cpu/baytrail/cpu.c
@@ -45,6 +45,8 @@ static void set_max_freq(void)
 
 static int cpu_x86_baytrail_probe(struct udevice *dev)
 {
+	if (!ll_boot_init())
+		return 0;
 	debug("Init BayTrail core\n");
 
 	/*
diff --git a/arch/x86/cpu/baytrail/valleyview.c b/arch/x86/cpu/baytrail/valleyview.c
index 9915da5..f1c3578 100644
--- a/arch/x86/cpu/baytrail/valleyview.c
+++ b/arch/x86/cpu/baytrail/valleyview.c
@@ -20,6 +20,7 @@ int cpu_mmc_init(bd_t *bis)
 			    ARRAY_SIZE(mmc_supported));
 }
 
+#ifndef CONFIG_ARCH_EFI
 int arch_cpu_init(void)
 {
 	int ret;
@@ -35,3 +36,4 @@ int arch_cpu_init(void)
 
 	return 0;
 }
+#endif
diff --git a/board/intel/minnowmax/Kconfig b/board/intel/minnowmax/Kconfig
index f2a0b71..2052c52 100644
--- a/board/intel/minnowmax/Kconfig
+++ b/board/intel/minnowmax/Kconfig
@@ -13,11 +13,12 @@ config SYS_CONFIG_NAME
 	default "minnowmax"
 
 config SYS_TEXT_BASE
-	default 0xfff00000
+        default 0xfff00000 if !EFI_STUB
+        default 0x01110000 if EFI_STUB
 
 config BOARD_SPECIFIC_OPTIONS # dummy
 	def_bool y
-	select X86_RESET_VECTOR
+	select X86_RESET_VECTOR if !EFI_STUB
 	select INTEL_BAYTRAIL
 	select BOARD_ROMSIZE_KB_8192
 
-- 
2.4.3.573.g4eafbef



More information about the U-Boot mailing list