On 08/05/2025 11:31 am, Marek Marczykowski-Górecki wrote: > On Thu, May 08, 2025 at 09:51:59AM +0100, Andrew Cooper wrote: >> Also, >> >>> ld: warning: orphan section `.sbat' from `prelink.o' being placed in >>> section `.sbat' >> This is because sbat.o is getting linked into the non-EFI build of Xen too. >> >> I'm less sure how to go about fixing this. There's no nice way I can >> see of of getting sbat.o only in the EFI build. The other option is to >> discard it for the ELF build. > This is kinda related to my question on Matrix - is multiboot2 binary > also supposed to (eventually) support UEFI SB?
This is mixing two things. Xen is either an ELF binary (ultimately zipped, so xen.gz) or is an EFI binary (xen.efi). Both of these binaries currently have an MB2 header. This was by accident, as xen.efi is a strict superset of the ELF build. AIUI, SBAT only makes sense to exist in the EFI binary. ~Andrew