irqchip: armada-370-xp: Mask all interrupts during initialization.
authorThomas Petazzoni <thomas.petazzoni@free-electrons.com>
Fri, 30 May 2014 20:18:18 +0000 (22:18 +0200)
committerJason Cooper <jason@lakedaemon.net>
Sat, 21 Jun 2014 00:39:04 +0000 (00:39 +0000)
commitb73842b75646da3810d6e1e161f223a288c64bd8
tree180670b2241d76a3815a2494918b6e6346eb2873
parent7171511eaec5bf23fb06078f59784a3a0626b38f
irqchip: armada-370-xp: Mask all interrupts during initialization.

Until now, the irq-armada-370-xp irqchip driver was not masking all
interrupts at initialization. While in most cases this is not a
problem because the bootloader has probably masked all interrupts, it
becomes a problem when you use kexec: you're in kernel A, with many
interrupts enabled, and then kexec into kernel B, without going
through the bootloader. So during the boot process, if an interrupt
occurs while the corresponding driver has not been loaded, you would
get spurious interrupts.

This commit fixes that by ensuring all interrupts are properly masked
when the irqchip driver is initialized. Note that interrupt masking
takes place at two level: at the global level (main_int_base) and at
the per-CPU level (per_cpu_int_base).

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Link: https://lkml.kernel.org/r/1401481098-23326-6-git-send-email-thomas.petazzoni@free-electrons.com
Signed-off-by: Jason Cooper <jason@lakedaemon.net>
drivers/irqchip/irq-armada-370-xp.c