On Wed, Nov 28, 2018 at 03:31:05PM +0100, Alexander Graf wrote: > I got a new toy this week: An HP Envy X2 system. This is one of those shiny > new Qualcomm Snapdragon based Windows tablet/notebook hybrid things. > > While running Windows on those is actually not a terribly bad experience now > that WSL is out, I would like to see Linux run on those as well in the future. > > Unfortunately as far as I'm aware so far nobody was able to run self built > binaries on the built-in UEFI version. > > Turns out, it's a problem with aligning the start of the header to 4k. Once > we do that, binaries can be loaded just fine and run. > > So to maintain compatibility with that device, this patch set just bumps the > header alignment to 4K always on arm64-efi. This shouldn't hurt too much for > not affected targets and allows us to have a single grub binary that can then > chain load Linux properly.
After further conversations with HP, they appear to be doing this in order to be able to enforce no-execute properties on the image header. Also, it seems Visual Studio always does this. So if you could tweak your set to refer to this aspect rather than a specific platform, drop mentions of HP Envy from other than the cover letter, and use EFI_PAGE_SIZE rather than 4096 in 2/2, I think this change is the right thing to do. We're going to move to this being the default for AArch64 in EDK2: https://lists.01.org/pipermail/edk2-devel/2018-December/033708.html (That the Envy X2 shouldn't hang silently on encountering a non-4K-aligned code offset is a different story, and an ongoing conversation.) / Leif > > Alex > > Alexander Graf (2): > mkimage: Simplify header size logic > mkimage: arm64-efi: Align first section to page > > util/mkimage.c | 8 +++----- > 1 file changed, 3 insertions(+), 5 deletions(-) > > -- > 2.19.0 > _______________________________________________ Grub-devel mailing list Grub-devel@gnu.org https://lists.gnu.org/mailman/listinfo/grub-devel