]> git.ipfire.org Git - thirdparty/ipxe.git/commit
[efi] Maximise image base address
authorMichael Brown <mcb30@ipxe.org>
Fri, 24 Nov 2023 12:26:43 +0000 (12:26 +0000)
committerMichael Brown <mcb30@ipxe.org>
Fri, 24 Nov 2023 21:57:39 +0000 (21:57 +0000)
commitb829b1750de041f7d4fd0f4f86fbf968bdccda6a
treeb87d73ffff26504448ef582fefa935823edff78d
parent03ff1bb99a28230397fb583853ab2160ff227e77
[efi] Maximise image base address

iPXE images are linked with a starting virtual address of zero.  Other
images (such as wimboot) may use a non-zero starting virtual address.

There is no direct equivalent of the PE ImageBase address field within
ELF object files.  Choose to use the highest possible address that
accommodates all sections and the PE header itself, since this will
minimise the memory allocated to hold the loaded image.

Signed-off-by: Michael Brown <mcb30@ipxe.org>
src/util/elf2efi.c