linux-stable/arch/powerpc
Russell Currey fec8a09f79 powerpc/64: Fix booting large kernels with STRICT_KERNEL_RWX
[ Upstream commit 56c46bba9b ]

With STRICT_KERNEL_RWX enabled anything marked __init is placed at a 16M
boundary.  This is necessary so that it can be repurposed later with
different permissions.  However, in kernels with text larger than 16M,
this pushes early_setup past 32M, incapable of being reached by the
branch instruction.

Fix this by setting the CTR and branching there instead.

Fixes: 1e0fc9d1eb ("powerpc/Kconfig: Enable STRICT_KERNEL_RWX for some configs")
Signed-off-by: Russell Currey <ruscur@russell.cc>
[mpe: Fix it to work on BE by using DOTSYM()]
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2019-05-31 06:46:18 -07:00
..
boot powerpc/boot: Fix missing check of lseek() return value 2019-05-31 06:46:11 -07:00
configs powerpc/mm/radix: Make Radix require HUGETLB_PAGE 2019-05-02 09:58:55 +02:00
crypto powerpc updates for 4.19 2018-08-17 11:32:50 -07:00
include powerpc/booke64: set RI in default MSR 2019-05-16 19:41:31 +02:00
kernel powerpc/64: Fix booting large kernels with STRICT_KERNEL_RWX 2019-05-31 06:46:18 -07:00
kvm powerpc/fsl: Flush branch predictor when entering KVM 2019-04-03 06:26:20 +02:00
lib powerpc/64: Fix memcmp reading past the end of src/dest 2019-04-03 06:26:29 +02:00
math-emu
mm powerpc/numa: improve control of topology updates 2019-05-31 06:46:18 -07:00
net powerpc: bpf: Fix generation of load/store DW instructions 2019-04-03 06:26:21 +02:00
oprofile treewide: kzalloc() -> kcalloc() 2018-06-12 16:19:22 -07:00
perf powerpc/perf: Fix loop exit condition in nest_imc_event_init 2019-05-31 06:46:11 -07:00
platforms powerpc/perf: Fix loop exit condition in nest_imc_event_init 2019-05-31 06:46:11 -07:00
purgatory powerpc updates for 4.19 2018-08-17 11:32:50 -07:00
sysdev treewide: correct "differenciate" and "instanciate" typos 2018-08-23 18:48:43 -07:00
tools powerpc: Add a checkpatch wrapper with our preferred settings 2018-08-07 21:49:25 +10:00
xmon powerpc/xmon: Fix opcode being uninitialized in print_insn_powerpc 2019-04-05 22:33:01 +02:00
Kconfig powerpc: disable support for relative ksymtab references 2018-08-29 16:12:07 -07:00
Kconfig.debug Kconfig: consolidate the "Kernel hacking" menu 2018-08-02 08:06:48 +09:00
Makefile powerpc: avoid -mno-sched-epilog on GCC 4.9 and newer 2019-01-13 09:51:05 +01:00
Makefile.postlink