MIPS: IRQ: Fix disable_irq on CPU IRQs
authorFelix Fietkau <nbd@openwrt.org>
Thu, 15 Jan 2015 18:05:28 +0000 (19:05 +0100)
committerBen Hutchings <ben@decadent.org.uk>
Fri, 6 Mar 2015 00:39:17 +0000 (00:39 +0000)
commitc5780dc7c2c76e76cfc20d4b5a6bb2a4540fa92d
treead93340d6ab283676d45e8aa772f350fb7a1be98
parent6749fd110bf44164782df9bba86c0327474446b9
MIPS: IRQ: Fix disable_irq on CPU IRQs

commit a3e6c1eff54878506b2dddcc202df9cc8180facb upstream.

If the irq_chip does not define .irq_disable, any call to disable_irq
will defer disabling the IRQ until it fires while marked as disabled.
This assumes that the handler function checks for this condition, which
handle_percpu_irq does not. In this case, calling disable_irq leads to
an IRQ storm, if the interrupt fires while disabled.

This optimization is only useful when disabling the IRQ is slow, which
is not true for the MIPS CPU IRQ.

Disable this optimization by implementing .irq_disable and .irq_enable

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
Cc: linux-mips@linux-mips.org
Patchwork: https://patchwork.linux-mips.org/patch/8949/
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
arch/mips/kernel/irq_cpu.c