summaryrefslogtreecommitdiffstats
path: root/arch/powerpc/kernel/setup_64.c
diff options
context:
space:
mode:
authorNicholas Piggin <npiggin@gmail.com>2018-02-14 01:08:20 +1000
committerMichael Ellerman <mpe@ellerman.id.au>2018-03-31 00:06:44 +1100
commit4890aea65ae7b5d424b5020e8be193b08a545990 (patch)
tree8b7dd5d5d9f0f994b90dfdceb4796e13028c96b1 /arch/powerpc/kernel/setup_64.c
parent59f577743d71bf796ceac10961bf6cfa5ca26786 (diff)
downloadlinux-4890aea65ae7b5d424b5020e8be193b08a545990.tar.bz2
powerpc/64: Allocate pacas per node
Per-node allocations are possible on 64s with radix that does not have the bolted SLB limitation. Hash would be able to do the same if all CPUs had the bottom of their node-local memory bolted as well. This is left as an exercise for the reader. Signed-off-by: Nicholas Piggin <npiggin@gmail.com> [mpe: Add dummy definition of boot_cpuid for !SMP] Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Diffstat (limited to 'arch/powerpc/kernel/setup_64.c')
-rw-r--r--arch/powerpc/kernel/setup_64.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/arch/powerpc/kernel/setup_64.c b/arch/powerpc/kernel/setup_64.c
index dde34d35d1e7..02fa358982e6 100644
--- a/arch/powerpc/kernel/setup_64.c
+++ b/arch/powerpc/kernel/setup_64.c
@@ -312,6 +312,10 @@ void __init early_setup(unsigned long dt_ptr)
early_init_devtree(__va(dt_ptr));
/* Now we know the logical id of our boot cpu, setup the paca. */
+ if (boot_cpuid != 0) {
+ /* Poison paca_ptrs[0] again if it's not the boot cpu */
+ memset(&paca_ptrs[0], 0x88, sizeof(paca_ptrs[0]));
+ }
setup_paca(paca_ptrs[boot_cpuid]);
fixup_boot_paca();