android_kernel_oneplus_msm8998/arch/powerpc
Paul Mackerras c7c77cdf7b powerpc: Fix COFF zImage booting on old powermacs
[ Upstream commit 5564597d51c8ff5b88d95c76255e18b13b760879 ]

Commit 6975a783d7 ("powerpc/boot: Allow building the zImage wrapper
as a relocatable ET_DYN", 2011-04-12) changed the procedure descriptor
at the start of crt0.S to have a hard-coded start address of 0x500000
rather than a reference to _zimage_start, presumably because having
a reference to a symbol introduced a relocation which is awkward to
handle in a position-independent executable.  Unfortunately, what is
at 0x500000 in the COFF image is not the first instruction, but the
procedure descriptor itself, that is, a word containing 0x500000,
which is not a valid instruction.  Hence, booting a COFF zImage
results in a "DEFAULT CATCH!, code=FFF00700" message from Open
Firmware.

This fixes the problem by (a) putting the procedure descriptor in the
data section and (b) adding a branch to _zimage_start as the first
instruction in the program.

Fixes: 6975a783d7 ("powerpc/boot: Allow building the zImage wrapper as a relocatable ET_DYN")
Signed-off-by: Paul Mackerras <paulus@ozlabs.org>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2019-01-13 10:05:31 +01:00
..
boot powerpc: Fix COFF zImage booting on old powermacs 2019-01-13 10:05:31 +01:00
configs
crypto
include powerpc/msi: Fix compile error on mpc83xx 2018-11-21 09:27:36 +01:00
kernel powerpc/msi: Fix NULL pointer access in teardown code 2018-12-21 14:09:51 +01:00
kvm KVM: PPC: Move and undef TRACE_INCLUDE_PATH/FILE 2018-12-01 09:46:34 +01:00
lib powerpc/lib: Fix off-by-one in alternate feature patching 2018-04-24 09:32:11 +02:00
math-emu
mm powerpc/numa: Suppress "VPHN is not supported" messages 2018-12-01 09:46:35 +01:00
net powerpc/bpf/jit: Fix 32-bit JIT for seccomp_data access 2018-05-30 07:49:00 +02:00
oprofile
perf powerpc/perf: Fix kernel address leak via sampling registers 2018-05-30 07:49:10 +02:00
platforms powerpc/powernv/ioda2: Reduce upper limit for DMA window size 2018-10-10 08:52:05 +02:00
sysdev powerpc: Fix size calculation using resource_size() 2018-09-15 09:40:39 +02:00
xmon
Kconfig powerpc/64s: Wire up cpu_show_meltdown() 2018-02-16 20:09:36 +01:00
Kconfig.debug
Makefile
relocs_check.sh