Hi Heinrich, On Wed, 8 Sept 2021 at 12:22, Heinrich Schuchardt <[email protected]> wrote: > > > > On 9/8/21 3:33 PM, Simon Glass wrote: > > 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 <[email protected]> > > --- > > > > arch/x86/lib/bootm.c | 11 +++++++---- > > 1 file changed, 7 insertions(+), 4 deletions(-) > > > > diff --git a/arch/x86/lib/bootm.c b/arch/x86/lib/bootm.c > > index 733dd712570..ff0e9f6a085 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. > > Did you test launching an EFI application with EFI_LOADER from the EFI > app? If you get it working, please provide a defconfig and a testcase > that runs helloworld.efi.
No unfortunately that cannot be built at present. This is just for kernels that don't use EFI_LOADER. I am pretty sure it could be made to work, perhaps by passing the original UEFI system table through to the kernel. Regards, Simon

