aboutsummaryrefslogtreecommitdiffstats
path: root/arch/powerpc/sysdev
diff options
context:
space:
mode:
authorShaohui Xie <b21989@freescale.com>2010-11-18 01:57:32 -0500
committerKumar Gala <galak@kernel.crashing.org>2011-05-20 09:46:57 -0400
commitcce1f106c64dc1d19d5e9406320fde18dfc662df (patch)
tree0fe38cf975577cb22de977ab36dc1cde82d80125 /arch/powerpc/sysdev
parentd08e44570ed611c527a1062eb4f8c6ac61832e6e (diff)
powerpc/fsl_rio: move machine_check handler
Add support for machine_check support into machine_check_e500 and machine_check_e500mc. Signed-off-by: Shaohui Xie <b21989@freescale.com> Cc: Li Yang <leoli@freescale.com> Cc: Roy Zang <tie-fei.zang@freescale.com> Cc: Alexandre Bounine <alexandre.bounine@idt.com> Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
Diffstat (limited to 'arch/powerpc/sysdev')
-rw-r--r--arch/powerpc/sysdev/fsl_rio.c15
1 files changed, 3 insertions, 12 deletions
diff --git a/arch/powerpc/sysdev/fsl_rio.c b/arch/powerpc/sysdev/fsl_rio.c
index 49798532b477..34440e1bac18 100644
--- a/arch/powerpc/sysdev/fsl_rio.c
+++ b/arch/powerpc/sysdev/fsl_rio.c
@@ -260,9 +260,7 @@ struct rio_priv {
260static void __iomem *rio_regs_win; 260static void __iomem *rio_regs_win;
261 261
262#ifdef CONFIG_E500 262#ifdef CONFIG_E500
263static int (*saved_mcheck_exception)(struct pt_regs *regs); 263int fsl_rio_mcheck_exception(struct pt_regs *regs)
264
265static int fsl_rio_mcheck_exception(struct pt_regs *regs)
266{ 264{
267 const struct exception_table_entry *entry = NULL; 265 const struct exception_table_entry *entry = NULL;
268 unsigned long reason = mfspr(SPRN_MCSR); 266 unsigned long reason = mfspr(SPRN_MCSR);
@@ -284,11 +282,9 @@ static int fsl_rio_mcheck_exception(struct pt_regs *regs)
284 } 282 }
285 } 283 }
286 284
287 if (saved_mcheck_exception) 285 return 0;
288 return saved_mcheck_exception(regs);
289 else
290 return cur_cpu_spec->machine_check(regs);
291} 286}
287EXPORT_SYMBOL_GPL(fsl_rio_mcheck_exception);
292#endif 288#endif
293 289
294/** 290/**
@@ -1538,11 +1534,6 @@ int fsl_rio_setup(struct platform_device *dev)
1538 fsl_rio_doorbell_init(port); 1534 fsl_rio_doorbell_init(port);
1539 fsl_rio_port_write_init(port); 1535 fsl_rio_port_write_init(port);
1540 1536
1541#ifdef CONFIG_E500
1542 saved_mcheck_exception = ppc_md.machine_check_exception;
1543 ppc_md.machine_check_exception = fsl_rio_mcheck_exception;
1544#endif
1545
1546 return 0; 1537 return 0;
1547err: 1538err:
1548 iounmap(priv->regs_win); 1539 iounmap(priv->regs_win);