linux-stable/arch/powerpc/platforms/85xx
Michael Ellerman 2dc0bc1138 powerpc/64e: Fix secondary thread bringup for ELFv2 kernels
When booting on e6500 with an ELF v2 ABI kernel, the secondary threads do
not start correctly:

    [    0.051118] smp: Bringing up secondary CPUs ...
    [    5.072700] Processor 1 is stuck.

This occurs because the startup code is written to use function
descriptors when loading the entry point for the secondary threads. When
building with ELF v2 ABI there are no function descriptors, and the code
loads junk values for the entry point address.

Fix it by using ppc_function_entry() in C, and DOTSYM() in asm, both of
which work correctly for ELF v2 ABI as well as ELF v1 ABI kernels.

Fixes: 8c5fa3b5c4 ("powerpc/64: Make ELFv2 the default for big-endian builds")
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://msgid.link/20230801102650.48705-1-mpe@ellerman.id.au
2023-08-01 21:01:27 +10:00
..
bsc913x_qds.c powerpc: Make generic_calibrate_decr() the default 2023-03-16 08:56:48 +11:00
bsc913x_rdb.c powerpc: Make generic_calibrate_decr() the default 2023-03-16 08:56:48 +11:00
c293pcie.c powerpc: Make generic_calibrate_decr() the default 2023-03-16 08:56:48 +11:00
common.c powerpc/85xx: remove mostly pointless mpc85xx_qe_init() 2019-11-17 01:55:42 -06:00
corenet_generic.c powerpc: Make generic_calibrate_decr() the default 2023-03-16 08:56:48 +11:00
ge_imp3a.c powerpc: Make generic_calibrate_decr() the default 2023-03-16 08:56:48 +11:00
Kconfig powerpc/85xx: p2020: Enable boards by new config option CONFIG_PPC_P2020 2023-04-20 12:23:13 +10:00
ksi8560.c powerpc: Make generic_calibrate_decr() the default 2023-03-16 08:56:48 +11:00
Makefile powerpc: drop MPC85xx_CDS platform support 2023-06-21 14:08:53 +10:00
mpc85xx.h powerpc/85xx: p2020: Unify .setup_arch and .init_IRQ callbacks 2023-04-20 12:23:13 +10:00
mpc85xx_8259.c powerpc/85xx: mpc85xx_ds: Move i8259 code into own file 2023-04-20 12:22:51 +10:00
mpc85xx_ds.c powerpc/85xx: p2020: Unify .setup_arch and .init_IRQ callbacks 2023-04-20 12:23:13 +10:00
mpc85xx_mds.c powerpc/85xx: Remove DBG() macro 2023-04-20 10:20:50 +10:00
mpc85xx_pm_ops.c powerpc/85xx: Fix no previous prototype warning for mpc85xx_setup_pmc() 2021-11-29 22:49:09 +11:00
mpc85xx_rdb.c powerpc/85xx: p2020: Unify .setup_arch and .init_IRQ callbacks 2023-04-20 12:23:13 +10:00
mpc8536_ds.c powerpc: Make generic_calibrate_decr() the default 2023-03-16 08:56:48 +11:00
mvme2500.c powerpc: Make generic_calibrate_decr() the default 2023-03-16 08:56:48 +11:00
p1010rdb.c powerpc: Make generic_calibrate_decr() the default 2023-03-16 08:56:48 +11:00
p1022_ds.c powerpc: Make generic_calibrate_decr() the default 2023-03-16 08:56:48 +11:00
p1022_rdk.c powerpc: Make generic_calibrate_decr() the default 2023-03-16 08:56:48 +11:00
p1023_rdb.c powerpc: Make generic_calibrate_decr() the default 2023-03-16 08:56:48 +11:00
p2020.c powerpc/85xx: p2020: Define just one machine description 2023-04-20 12:23:13 +10:00
ppa8548.c powerpc: Make generic_calibrate_decr() the default 2023-03-16 08:56:48 +11:00
qemu_e500.c powerpc: Make generic_calibrate_decr() the default 2023-03-16 08:56:48 +11:00
sgy_cts1000.c powerpc/sgy_cts1000: convert to using gpiod API and facelift 2022-11-24 23:31:48 +11:00
smp.c powerpc/64e: Fix secondary thread bringup for ELFv2 kernels 2023-08-01 21:01:27 +10:00
smp.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
socrates.c powerpc: Make generic_calibrate_decr() the default 2023-03-16 08:56:48 +11:00
socrates_fpga_pic.c powerpc/85xx: Add __init attribute to eligible functions 2021-12-23 22:33:18 +11:00
socrates_fpga_pic.h powerpc/85xx: Add __init attribute to eligible functions 2021-12-23 22:33:18 +11:00
stx_gp3.c powerpc: Make generic_calibrate_decr() the default 2023-03-16 08:56:48 +11:00
t1042rdb_diu.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 152 2019-05-30 11:26:32 -07:00
tqm85xx.c powerpc: Make generic_calibrate_decr() the default 2023-03-16 08:56:48 +11:00
twr_p102x.c powerpc: Make generic_calibrate_decr() the default 2023-03-16 08:56:48 +11:00
xes_mpc85xx.c powerpc: Make generic_calibrate_decr() the default 2023-03-16 08:56:48 +11:00