]> git.ipfire.org Git - thirdparty/glibc.git/commit
aarch64: morello: add purecap start code
authorSzabolcs Nagy <szabolcs.nagy@arm.com>
Thu, 20 Oct 2022 11:18:26 +0000 (12:18 +0100)
committerSzabolcs Nagy <szabolcs.nagy@arm.com>
Tue, 22 Nov 2022 14:31:25 +0000 (14:31 +0000)
commit0b888aef9a0f9ef17fcb62458101b550bce7a776
treeb77141c3db3603f67c5946280241ba2cb6019dcd
parent60c96035fff8d1d3e2cc0c2279f8b3c7c0ccb09a
aarch64: morello: add purecap start code

Written in C so the self relocation code in crt1.o is easier to
maintain.

The purecap ELF entry is special: passes separate argc, argv, envp,
auxv in registers instead of on the stack.

For each module there will be separate RW and RX capabilities that
cover the writable and all load segments respectively. The relative
reloc processing code is prepared for such separate capabilities.

The static link detection (for self relocation) is not ideal, it
relies on relocations that don't work in PIC, so it is ifdefed out
for Scrt1.o. (Currently adrp of undefined weak symbol is not fixed
up by the linker to be 0 so we use movz to detect the presence of
__rela_dyn_start.)
sysdeps/aarch64/morello/cheri-rel.h [new file with mode: 0644]
sysdeps/aarch64/morello/start.c [new file with mode: 0644]