macintosh/via-pmu: Don't clear shift register interrupt flag twice
authorFinn Thain <fthain@telegraphics.com.au>
Mon, 2 Jul 2018 08:21:18 +0000 (04:21 -0400)
committerMichael Ellerman <mpe@ellerman.id.au>
Tue, 31 Jul 2018 09:56:39 +0000 (19:56 +1000)
The shift register interrupt flag gets cleared in via_pmu_interrupt()
and once again in pmu_sr_intr(). Fix this theoretical race condition.

Tested-by: Stan Johnson <userm57@yahoo.com>
Signed-off-by: Finn Thain <fthain@telegraphics.com.au>
Reviewed-by: Geert Uytterhoeven <geert@linux-m68k.org>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
drivers/macintosh/via-pmu.c

index ba41220f618eeca3ed4ec3bec9d8df8b5a1af413..c313ddfdb17a626e3d6a2f984dcea227e482a5b1 100644 (file)
@@ -1421,7 +1421,6 @@ pmu_sr_intr(void)
 
        if (in_8(&via[B]) & TREQ) {
                printk(KERN_ERR "PMU: spurious SR intr (%x)\n", in_8(&via[B]));
-               out_8(&via[IFR], SR_INT);
                return NULL;
        }
        /* The ack may not yet be low when we get the interrupt */