Bug 11503

Summary: iso image not booting in EFI mode
Product: [Runtime] Installation Reporter: California Sullivan <california.l.sullivan>
Component: InstallationAssignee: California Sullivan <california.l.sullivan>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: Medium+ CC: kevin.tian, sgw
Version: unspecified   
Target Milestone: 2.4 M1   
Hardware: x86   
OS: Multiple   
Whiteboard:
OS type for building Yocto: --- Type of Regression: ---
Verified: Documentation change: No (bug/feature does not impact docs)

Description California Sullivan 2017-05-11 22:37:18 UTC
Since we're in EFI mode it falls back to the bootloader specified by EFI_PROVIDER. With systemd-boot, we get the prompt "Reboot into firmware interface" and nothing else. With grub-efi, we get the grub command line interface with no boot targets.

Looking at the secondary EFI partition used in EFI mode, it looks like there is no bootloader configuration added:
  [clsulliv@clsulliv clsulliv]$ ls mnt2/
  EFI  initrd  startup.nsh  vmlinuz

Compared to the primary partition used in legacy mode:
  [clsulliv@clsulliv clsulliv]$ ls mnt/
  EFI  efi.img  initrd  isolinux  loader  rmc.db  rootfs.img  startup.nsh  vmlinuz

Copying the loader directory from the primary partition into the secondary partition, I was able to boot in EFI mode.

An easy way to reproduce is by adding meta-intel to your bblayers, setting MACHINE to intel-corei7-64, building core-image-minimal, then run the following:
  runqemu core-image-minimal intel-corei7-64 iso ovmf
Comment 1 California Sullivan 2017-05-22 19:50:18 UTC
Patch sent for the systemd-boot side.

After more investigation, grub might be broken in a different way, as grub.cfg already exists in the ISO's secondary partition.
Comment 2 California Sullivan 2017-06-19 23:29:59 UTC
Patch for systemd-boot merged to master. Awaiting backport to pyro now.

http://git.yoctoproject.org/cgit.cgi/poky/commit/?id=1431210bb0f76743a631967cead87a6f1a09d070

Going to open a new bug specifically for grub, as that one appears to be a different issue that will take more investigation.