aboutsummaryrefslogtreecommitdiffstats
path: root/arch/powerpc/kernel/setup_32.c
diff options
context:
space:
mode:
authorChristophe Leroy <christophe.leroy@csgroup.eu>2021-03-12 12:50:25 +0000
committerMichael Ellerman <mpe@ellerman.id.au>2021-03-29 13:22:06 +1100
commita4719f5bb6d7dc220bffdc1b9f5ce5eaa5543581 (patch)
tree596e9c93efbd7043ae933a4d148d1aa25b722438 /arch/powerpc/kernel/setup_32.c
parentpowerpc/32: Enable instruction translation at the same time as data translation (diff)
downloadlinux-dev-a4719f5bb6d7dc220bffdc1b9f5ce5eaa5543581.tar.xz
linux-dev-a4719f5bb6d7dc220bffdc1b9f5ce5eaa5543581.zip
powerpc/32: Statically initialise first emergency context
The check of the emergency context initialisation in vmap_stack_overflow is buggy for the SMP case, as it compares r1 with 0 while in the SMP case r1 is offseted by the CPU id. Instead of fixing it, just perform static initialisation of the first emergency context. Signed-off-by: Christophe Leroy <christophe.leroy@csgroup.eu> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> Link: https://lore.kernel.org/r/4a67ba422be75713286dca0c86ee0d3df2eb6dfa.1615552867.git.christophe.leroy@csgroup.eu
Diffstat (limited to 'arch/powerpc/kernel/setup_32.c')
-rw-r--r--arch/powerpc/kernel/setup_32.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/powerpc/kernel/setup_32.c b/arch/powerpc/kernel/setup_32.c
index 8ba49a6bf515..d7c1f92152af 100644
--- a/arch/powerpc/kernel/setup_32.c
+++ b/arch/powerpc/kernel/setup_32.c
@@ -164,7 +164,7 @@ void __init irqstack_early_init(void)
}
#ifdef CONFIG_VMAP_STACK
-void *emergency_ctx[NR_CPUS] __ro_after_init;
+void *emergency_ctx[NR_CPUS] __ro_after_init = {[0] = &init_stack};
void __init emergency_stack_init(void)
{