aboutsummaryrefslogtreecommitdiffstats
path: root/arch/powerpc/mm
diff options
context:
space:
mode:
authorMichael Neuling <mikey@neuling.org>2008-01-10 22:02:47 -0500
committerPaul Mackerras <paulus@samba.org>2008-01-11 00:33:55 -0500
commit473980a99316c0e788bca50996375a2815124ce1 (patch)
tree5fb9d5de6ee75299b32de0e0b66f5a868864c38f /arch/powerpc/mm
parent6f4347c969674ed45de7d08d4b26d6326a95b959 (diff)
[POWERPC] Fix CPU hotplug when using the SLB shadow buffer
Before we register the SLB shadow buffer, we need to invalidate the entries in the buffer, otherwise we can end up stale entries from when we previously offlined the CPU. This does this invalidate as well as unregistering the buffer with PHYP before we offline the cpu. Tested and fixes crashes seen on 970MP (thanks to tonyb) and POWER5. Signed-off-by: Michael Neuling <mikey@neuling.org> Signed-off-by: Paul Mackerras <paulus@samba.org>
Diffstat (limited to 'arch/powerpc/mm')
-rw-r--r--arch/powerpc/mm/slb.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/arch/powerpc/mm/slb.c b/arch/powerpc/mm/slb.c
index 27922dff8b94..a282bc212e80 100644
--- a/arch/powerpc/mm/slb.c
+++ b/arch/powerpc/mm/slb.c
@@ -82,6 +82,14 @@ static inline void slb_shadow_clear(unsigned long entry)
82 get_slb_shadow()->save_area[entry].esid = 0; 82 get_slb_shadow()->save_area[entry].esid = 0;
83} 83}
84 84
85void slb_shadow_clear_all(void)
86{
87 int i;
88
89 for (i = 0; i < SLB_NUM_BOLTED; i++)
90 slb_shadow_clear(i);
91}
92
85static inline void create_shadowed_slbe(unsigned long ea, int ssize, 93static inline void create_shadowed_slbe(unsigned long ea, int ssize,
86 unsigned long flags, 94 unsigned long flags,
87 unsigned long entry) 95 unsigned long entry)