arm-trusted-firmware/bl31
Soby Mathew 931f7c6156 PIE: Position Independant Executable support for BL31
This patch introduces Position Independant Executable(PIE) support
in TF-A. As a initial prototype, only BL31 can support PIE. A trivial
dynamic linker is implemented which supports fixing up Global Offset
Table(GOT) and Dynamic relocations(.rela.dyn). The fixup_gdt_reloc()
helper function implements this linker and this needs to be called
early in the boot sequence prior to invoking C functions. The GOT is
placed in the RO section of BL31 binary for improved security and the
BL31 linker script is modified to export the appropriate symbols
required for the dynamic linker.

The C compiler always generates PC relative addresses to linker symbols
and hence referencing symbols exporting constants are a problem when
relocating the binary. Hence the reference to the
`__PERCPU_TIMESTAMP_SIZE__` symbol in PMF is removed and is now calculated
at runtime based on start and end addresses.

Change-Id: I1228583ff92cf432963b7cef052e95d995cca93d
Signed-off-by: Soby Mathew <soby.mathew@arm.com>
2018-10-29 09:54:32 +00:00
..
aarch64 PIE: Position Independant Executable support for BL31 2018-10-29 09:54:32 +00:00
bl31.ld.S PIE: Position Independant Executable support for BL31 2018-10-29 09:54:32 +00:00
bl31.mk Merge pull request #1533 from jeenu-arm/mpam 2018-08-22 10:24:24 +01:00
bl31_context_mgmt.c context_mgmt: Remove deprecated interfaces 2018-09-28 15:31:53 +01:00
bl31_main.c Mark BL31 initialization functions 2018-10-03 11:47:30 +01:00
ehf.c Mark BL31 initialization functions 2018-10-03 11:47:30 +01:00
interrupt_mgmt.c Fix MISRA defects in BL31 common code 2018-08-30 09:22:33 +01:00