[PATCH v5 2/3] mkimage: Align efi sections on 4k boundary

2019-01-25 Thread Alexander Graf
There is UEFI firmware popping up in the wild now that implements stricter permission checks using NX and write protect page table entry bits. This means that firmware now may fail to load binaries if its individual sections are not page aligned, as otherwise it can not ensure permission boundarie

[PATCH v5 0/3] arm64: Support HP Envy X2

2019-01-25 Thread Alexander Graf
I got a new toy recently: 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

[PATCH v5 1/3] mkimage: Use EFI32_HEADER_SIZE define in arm-efi case

2019-01-25 Thread Alexander Graf
The efi-arm case was defining its own header size calculation, even though it's 100% identical to the common EFI32_HEADER_SIZE definition. So let's clean it up to use the common define. Signed-off-by: Alexander Graf --- util/mkimage.c | 7 +-- 1 file changed, 1 insertion(+), 6 deletions(-)

[PATCH v5 3/3] mkimage: Clarify file alignment in efi case

2019-01-25 Thread Alexander Graf
There are a few spots in the PE generation code for EFI binaries that uses the section alignment rather than file alignment, even though the alignment is really only file bound. Replace those cases with the file alignment constant instead. Reported-by: Daniel Kiper Signed-off-by: Alexander Graf