]> git.ipfire.org Git - thirdparty/ipxe.git/commit
[riscv] Allow for a non-zero link-time address
authorMichael Brown <mcb30@ipxe.org>
Thu, 1 May 2025 13:24:33 +0000 (14:24 +0100)
committerMichael Brown <mcb30@ipxe.org>
Thu, 1 May 2025 13:49:53 +0000 (14:49 +0100)
commitdad20602609438e72f2fe8d9dd49b9a92b8490fa
tree77feb259ada9a98d0fc6e0dacca32d891330b4e8
parenta4b5dd63c5a99df3cfa2c4dd3cd0fd9019635b92
[riscv] Allow for a non-zero link-time address

Using paging (rather than relocation records) will be easier on 64-bit
RISC-V if we place iPXE within the negative (kernel) virtual address
space.

Allow the link-time address to be non-zero and to vary between 32-bit
and 64-bit builds.  Choose addresses that are expected to be amenable
to the use of paging.

There is no particular need to use a non-zero address in the 32-bit
builds, but doing so allows us to validate that the relocation code is
handling this case correctly.

Signed-off-by: Michael Brown <mcb30@ipxe.org>
src/arch/riscv/scripts/sbi.lds
src/arch/riscv32/Makefile.sbi
src/arch/riscv64/Makefile.sbi