diff options
author | Aneesh Kumar K.V <aneesh.kumar@linux.ibm.com> | 2020-07-09 05:29:41 +0200 |
---|---|---|
committer | Michael Ellerman <mpe@ellerman.id.au> | 2020-07-20 14:57:59 +0200 |
commit | 000a42b35a54372597f0657f6b9875b38c641864 (patch) | |
tree | 755256c0c901e1437d79c4c336de70075ff40975 /arch/powerpc/kexec | |
parent | powerpc/book3s64/keys: Print information during boot. (diff) | |
download | linux-000a42b35a54372597f0657f6b9875b38c641864.tar.xz linux-000a42b35a54372597f0657f6b9875b38c641864.zip |
powerpc/book3s64/keys/kuap: Reset AMR/IAMR values on kexec
As we kexec across kernels that use AMR/IAMR for different purposes
we need to ensure that new kernels get kexec'd with a reset value
of AMR/IAMR. For ex: the new kernel can use key 0 for kernel mapping and the old
AMR value prevents access to key 0.
This patch also removes reset if IAMR and AMOR in kexec_sequence. Reset of AMOR
is not needed and the IAMR reset is partial (it doesn't do the reset
on secondary cpus) and is redundant with this patch.
Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.ibm.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/20200709032946.881753-19-aneesh.kumar@linux.ibm.com
Diffstat (limited to 'arch/powerpc/kexec')
-rw-r--r-- | arch/powerpc/kexec/core_64.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/arch/powerpc/kexec/core_64.c b/arch/powerpc/kexec/core_64.c index b4184092172a..8a449b2d8715 100644 --- a/arch/powerpc/kexec/core_64.c +++ b/arch/powerpc/kexec/core_64.c @@ -152,6 +152,8 @@ static void kexec_smp_down(void *arg) if (ppc_md.kexec_cpu_down) ppc_md.kexec_cpu_down(0, 1); + reset_sprs(); + kexec_smp_wait(); /* NOTREACHED */ } |