From: Sebastian Andrzej Siewior Date: Wed, 5 Aug 2009 19:41:12 +0000 (+0200) Subject: powerpc/ipic: unmask all interrupt sources X-Git-Tag: v3.12-rc1~13353^2~75 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=8640d3bf71fa0f25adf86527fe69a32372427d4b;p=kernel%2Fkernel-generic.git powerpc/ipic: unmask all interrupt sources in case the interrupt controller was used in an earlier life then it is possible it is that some of its sources were used and are still unmask. If the (unmasked) device is active and is creating interrupts (or one interrupts was pending since the interrupts were disabled) then the boot process "ends" very soon. Once external interrupts are enabled, we land in -> do_IRQ -> call ppc_md.get_irq() -> ipic_read() gets the source number -> irq_linear_revmap(source) -> revmap[source] == NO_IRQ -> irq_find_mapping(source) returns NO_IRQ because no source is registered -> source is NO_IRQ, ppc_spurious_interrupts gets incremented, no further action. Signed-off-by: Sebastian Andrzej Siewior Signed-off-by: Kumar Gala Signed-off-by: Benjamin Herrenschmidt --- diff --git a/arch/powerpc/sysdev/ipic.c b/arch/powerpc/sysdev/ipic.c index 69e2630..ebb7e58 100644 --- a/arch/powerpc/sysdev/ipic.c +++ b/arch/powerpc/sysdev/ipic.c @@ -781,6 +781,9 @@ struct ipic * __init ipic_init(struct device_node *node, unsigned int flags) primary_ipic = ipic; irq_set_default_host(primary_ipic->irqhost); + ipic_write(ipic->regs, IPIC_SIMSR_H, 0); + ipic_write(ipic->regs, IPIC_SIMSR_L, 0); + printk ("IPIC (%d IRQ sources) at %p\n", NR_IPIC_INTS, primary_ipic->regs);