linux-imx/arch/powerpc/kexec
Nicholas Piggin d10e3c3900 powerpc/pseries: Fix scv instruction crash with kexec
commit 21a741eb75 upstream.

kexec on pseries disables AIL (reloc_on_exc), required for scv
instruction support, before other CPUs have been shut down. This means
they can execute scv instructions after AIL is disabled, which causes an
interrupt at an unexpected entry location that crashes the kernel.

Change the kexec sequence to disable AIL after other CPUs have been
brought down.

As a refresher, the real-mode scv interrupt vector is 0x17000, and the
fixed-location head code probably couldn't easily deal with implementing
such high addresses so it was just decided not to support that interrupt
at all.

Fixes: 7fa95f9ada ("powerpc/64s: system call support for scv/rfscv instructions")
Cc: stable@vger.kernel.org # v5.9+
Reported-by: Sourabh Jain <sourabhjain@linux.ibm.com>
Closes: https://lore.kernel.org/3b4b2943-49ad-4619-b195-bc416f1d1409@linux.ibm.com
Signed-off-by: Nicholas Piggin <npiggin@gmail.com>
Tested-by: Gautam Menghani <gautam@linux.ibm.com>
Tested-by: Sourabh Jain <sourabhjain@linux.ibm.com>
Link: https://msgid.link/20240625134047.298759-1-npiggin@gmail.com
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2024-07-11 12:49:17 +02:00
..
core_32.c
core_64.c powerpc/pseries: Fix scv instruction crash with kexec 2024-07-11 12:49:17 +02:00
core.c powerpc/vmcore: Add MMU information to vmcoreinfo 2023-11-20 11:59:29 +01:00
crash.c powerpc: mark more local variables as volatile 2023-08-14 21:54:04 +10:00
elf_64.c
file_load_64.c powerpc: Move DMA64_PROPNAME define to a header 2023-08-18 17:03:15 +10:00
file_load.c
Makefile
ranges.c
relocate_32.S