linux/arch/riscv
Damien Le Moal 09accc3a05 riscv: Disable data start offset in flat binaries
uclibc/gcc combined with elf2flt riscv linker file fully resolve the
PC relative __global_pointer$ value at compile time and do not generate
a relocation entry to set a correct value of the gp register at runtime.
As a result, if the flatbin loader offsets the start of the data
section, the relative position change between the text and data sections
compared to the compile time positions results in an incorrect gp value
being used. This causes flatbin executables to crash.

Avoid this problem by enabling CONFIG_BINFMT_FLAT_NO_DATA_START_OFFSET
automatically when CONFIG_RISCV is enabled and CONFIG_MMU is disabled.

Signed-off-by: Damien Le Moal <damien.lemoal@wdc.com>
Acked-by: Palmer Dabbelt <palmerdabbelt@google.com>
Signed-off-by: Greg Ungerer <gerg@linux-m68k.org>
2021-04-23 15:33:40 +10:00
..
boot RISC-V Patches for the 5.12 Merge Window 2021-02-26 10:28:35 -08:00
configs RISC-V: Enable CPU Hotplug in defconfigs 2021-02-26 21:24:02 -08:00
include riscv: evaluate put_user() arg before enabling user access 2021-04-01 21:37:04 -07:00
kernel riscv: keep interrupts disabled for BREAKPOINT exception 2021-04-15 21:32:40 -07:00
lib riscv: Add support for function error injection 2021-01-14 15:09:09 -08:00
mm riscv: add do_page_fault and do_trap_break into the kprobes blacklist 2021-04-15 21:32:28 -07:00
net bpf: Rename BPF_XADD and prepare to encode other atomics in .imm 2021-01-14 18:34:29 -08:00
Kbuild riscv: Allow device trees to be built into the kernel 2020-05-18 11:38:05 -07:00
Kconfig riscv: Disable data start offset in flat binaries 2021-04-23 15:33:40 +10:00
Kconfig.debug RISC-V: Remove EARLY_PRINTK support 2018-12-17 10:23:46 -08:00
Kconfig.socs riscv: Fix compilation error with Canaan SoC 2021-03-16 21:54:27 -07:00
Makefile riscv: Enable per-task stack canaries 2021-01-14 15:09:10 -08:00