]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - kernel/irq/spurious.c
Merge branch 'for-linus' of master.kernel.org:/pub/scm/linux/kernel/git/roland/infiniband
[linux-2.6-omap-h63xx.git] / kernel / irq / spurious.c
index 3a0a621233012e78cbfaf4a59f1ac232ccc23521..417e98092cf20a6e843c6ae973a6ee4c216cd435 100644 (file)
@@ -36,7 +36,7 @@ static int misrouted_irq(int irq, struct pt_regs *regs)
                         * Already running: If it is shared get the other
                         * CPU to go looking for our mystery interrupt too
                         */
-                       if (desc->action && (desc->action->flags & SA_SHIRQ))
+                       if (desc->action && (desc->action->flags & IRQF_SHARED))
                                desc->status |= IRQ_PENDING;
                        spin_unlock(&desc->lock);
                        continue;
@@ -48,7 +48,7 @@ static int misrouted_irq(int irq, struct pt_regs *regs)
 
                while (action) {
                        /* Only shared IRQ handlers are safe to call */
-                       if (action->flags & SA_SHIRQ) {
+                       if (action->flags & IRQF_SHARED) {
                                if (action->handler(i, action->dev_id, regs) ==
                                                IRQ_HANDLED)
                                        ok = 1;
@@ -79,7 +79,7 @@ static int misrouted_irq(int irq, struct pt_regs *regs)
                 * If we did actual work for the real IRQ line we must let the
                 * IRQ controller clean up too
                 */
-               if (work)
+               if (work && desc->chip && desc->chip->end)
                        desc->chip->end(i);
                spin_unlock(&desc->lock);
        }
@@ -168,6 +168,7 @@ void note_interrupt(unsigned int irq, struct irq_desc *desc,
                 */
                printk(KERN_EMERG "Disabling IRQ #%d\n", irq);
                desc->status |= IRQ_DISABLED;
+               desc->depth = 1;
                desc->chip->disable(irq);
        }
        desc->irqs_unhandled = 0;