aboutsummaryrefslogtreecommitdiffstats
path: root/include/asm-powerpc
diff options
context:
space:
mode:
authorMichael Ellerman <michael@ellerman.id.au>2005-11-11 08:06:05 -0500
committerPaul Mackerras <paulus@samba.org>2005-11-14 00:33:09 -0500
commitc5e24354efae9f962e0e369d875d45f47e0bb9aa (patch)
tree9a92ab7168cd45eb5104ce662e82626b62609aa4 /include/asm-powerpc
parent5cd16ee934eafca74a6bb790328950cec68a8b78 (diff)
[PATCH] powerpc: Turn cpu_irq_down into kexec_cpu_down
We currently have a ppc_md member called cpu_irq_down, which disables IRQs for the cpu in question. The only caller of cpu_irq_down is the kexec code. On pSeries we need to do more than just teardown IRQs at kexec time, so rename the ppc_md member to kexec_cpu_down and expand it. The pSeries code needs to know, and other platforms might too, whether we're doing a crash shutdown (ie. panicking) or a regular kexec, so add a flag for that. The pSeries implementation of kexec_cpu_down does an unregister VPA call, which tells the Hypervisor to stop writing stuff into our pacas. Without this we can get weird memory corruption bugs when we kexec, caused by the Hypervisor writing into the first kernel's pacas which happens to be somewhere interesting in the second kernel's memory. Signed-off-by: Michael Ellerman <michael@ellerman.id.au> Signed-off-by: Paul Mackerras <paulus@samba.org>
Diffstat (limited to 'include/asm-powerpc')
-rw-r--r--include/asm-powerpc/machdep.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/include/asm-powerpc/machdep.h b/include/asm-powerpc/machdep.h
index 5670f0cd6143..c011abb8b600 100644
--- a/include/asm-powerpc/machdep.h
+++ b/include/asm-powerpc/machdep.h
@@ -93,7 +93,9 @@ struct machdep_calls {
93 93
94 void (*init_IRQ)(void); 94 void (*init_IRQ)(void);
95 int (*get_irq)(struct pt_regs *); 95 int (*get_irq)(struct pt_regs *);
96 void (*cpu_irq_down)(int secondary); 96#ifdef CONFIG_KEXEC
97 void (*kexec_cpu_down)(int crash_shutdown, int secondary);
98#endif
97 99
98 /* PCI stuff */ 100 /* PCI stuff */
99 /* Called after scanning the bus, before allocating resources */ 101 /* Called after scanning the bus, before allocating resources */