aboutsummaryrefslogtreecommitdiff
path: root/arch/x86
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2021-12-29 11:57:38 -0700
committerHeinrich Schuchardt <heinrich.schuchardt@canonical.com>2021-12-31 06:45:01 +0100
commit6e7ad4a45f6e2b036fc56942293b8471ece3341d (patch)
treea3ad44a79ff202b6e1f10eee1855f37aeca231b9 /arch/x86
parent299606611055075daef60be250eec80cd337a141 (diff)
downloadu-boot-6e7ad4a45f6e2b036fc56942293b8471ece3341d.zip
u-boot-6e7ad4a45f6e2b036fc56942293b8471ece3341d.tar.gz
u-boot-6e7ad4a45f6e2b036fc56942293b8471ece3341d.tar.bz2
x86: Allow booting a kernel from the EFI app
At present this is disabled, but it should work so long as the kernel does not need EFI services. Enable it and add a note about remaining work. Signed-off-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'arch/x86')
-rw-r--r--arch/x86/lib/bootm.c11
1 files changed, 7 insertions, 4 deletions
diff --git a/arch/x86/lib/bootm.c b/arch/x86/lib/bootm.c
index 667e5e6..57cba5c 100644
--- a/arch/x86/lib/bootm.c
+++ b/arch/x86/lib/bootm.c
@@ -179,10 +179,14 @@ int boot_linux_kernel(ulong setup_base, ulong load_address, bool image_64bit)
* U-Boot is setting them up that way for itself in
* arch/i386/cpu/cpu.c.
*
- * Note that we cannot currently boot a kernel while running as
- * an EFI application. Please use the payload option for that.
+ * Note: this is incomplete for EFI kernels!
+ *
+ * This can boot a kernel while running as an EFI application,
+ * but if the kernel requires EFI support then that support needs
+ * to be enabled first (see EFI_LOADER). Also the EFI information
+ * must enabled with setup_efi_info(). See setup_zimage() for
+ * how this is done with the stub.
*/
-#ifndef CONFIG_EFI_APP
__asm__ __volatile__ (
"movl $0, %%ebp\n"
"cli\n"
@@ -191,7 +195,6 @@ int boot_linux_kernel(ulong setup_base, ulong load_address, bool image_64bit)
[boot_params] "S"(setup_base),
"b"(0), "D"(0)
);
-#endif
}
/* We can't get to here */