summaryrefslogtreecommitdiff
path: root/target/linux/adm5120-2.6/files/arch/mips/adm5120/irq.c
diff options
context:
space:
mode:
authorflorian <florian@3c298f89-4303-0410-b956-a3cf2f4a3e73>2007-05-30 09:48:57 +0000
committerflorian <florian@3c298f89-4303-0410-b956-a3cf2f4a3e73>2007-05-30 09:48:57 +0000
commitf203cd4d6d968d81d98c76ef992ae91c17552b03 (patch)
tree7e4adaf8444d577096d54326c9c344e5bb36c6c0 /target/linux/adm5120-2.6/files/arch/mips/adm5120/irq.c
parent438c1a7f7eeb14b3f2e7a2661d2c0be3b407e1ab (diff)
Minor fixes, do not count interrupts without interrupt source as spurious (#1755)
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@7391 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'target/linux/adm5120-2.6/files/arch/mips/adm5120/irq.c')
-rw-r--r--target/linux/adm5120-2.6/files/arch/mips/adm5120/irq.c11
1 files changed, 6 insertions, 5 deletions
diff --git a/target/linux/adm5120-2.6/files/arch/mips/adm5120/irq.c b/target/linux/adm5120-2.6/files/arch/mips/adm5120/irq.c
index 46f3bb05ee..c53272e1e0 100644
--- a/target/linux/adm5120-2.6/files/arch/mips/adm5120/irq.c
+++ b/target/linux/adm5120-2.6/files/arch/mips/adm5120/irq.c
@@ -48,11 +48,12 @@ void adm5120_hw0_irqdispatch(struct pt_regs *regs)
intsrc = ADM5120_INTC_STATUS & ADM5120_IRQ_MASK;
- for (i = 0; intsrc; intsrc >>= 1, i++)
- if (intsrc & 0x1)
- do_IRQ(i);
- else
- spurious_interrupt();
+ if (intsrc) {
+ for (i = 0; intsrc; intsrc >>= 1, i++)
+ if (intsrc & 0x1)
+ do_IRQ(i);
+ } else
+ spurious_interrupt();
}
void mips_timer_interrupt(struct pt_regs *regs)