[POWERPC] pasemi: Fix NMI handling check
authorOlof Johansson <olof@lixom.net>
Wed, 2 Jan 2008 18:35:50 +0000 (12:35 -0600)
committerOlof Johansson <olof@lixom.net>
Wed, 2 Jan 2008 18:40:29 +0000 (12:40 -0600)
The logic that checks to see if a machine check is caused by an NMI will
always match when NMI hasn't been initialized, since the mpic routine
will return NO_IRQ (and that's what the nmi_virq value is as well).

Signed-off-by: Olof Johansson <olof@lixom.net>
arch/powerpc/platforms/pasemi/setup.c

index 1940e678878ef0e6d0adf324f1b3c5111d308116..a89d098e41bf8821334b53d94b786d2b5185d588 100644 (file)
@@ -264,7 +264,7 @@ static int pas_machine_check_handler(struct pt_regs *regs)
        srr0 = regs->nip;
        srr1 = regs->msr;
 
-       if (mpic_get_mcirq() == nmi_virq) {
+       if (nmi_virq != NO_IRQ && mpic_get_mcirq() == nmi_virq) {
                printk(KERN_ERR "NMI delivered\n");
                debugger(regs);
                mpic_end_irq(nmi_virq);