diff options
author | David Gwynne <dlg@cvs.openbsd.org> | 2006-09-25 22:44:57 +0000 |
---|---|---|
committer | David Gwynne <dlg@cvs.openbsd.org> | 2006-09-25 22:44:57 +0000 |
commit | 4353a4b644ad53abdb9e6f53e83018c7fa3ca5dd (patch) | |
tree | 9515741a6ea0649dbb799539e1c53ff81698f3b4 /sys/dev | |
parent | 676ed682e6f64c8658af38e697809cd89bb71a8b (diff) |
enabling interrupts isnt a bug, so dont put XXX next to it.
only ack the interrupts we deal with in the interrupt handler.
use the correct macros when setting the interrupt mask.
Diffstat (limited to 'sys/dev')
-rw-r--r-- | sys/dev/pci/arc.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/sys/dev/pci/arc.c b/sys/dev/pci/arc.c index e1c9f6a2f8b..f90d1b0a686 100644 --- a/sys/dev/pci/arc.c +++ b/sys/dev/pci/arc.c @@ -1,4 +1,4 @@ -/* $OpenBSD: arc.c,v 1.48 2006/08/28 05:36:00 dlg Exp $ */ +/* $OpenBSD: arc.c,v 1.49 2006/09/25 22:44:56 dlg Exp $ */ /* * Copyright (c) 2006 David Gwynne <dlg@openbsd.org> @@ -527,7 +527,7 @@ arc_attach(struct device *parent, struct device *self, void *aux) child = config_found(self, &sc->sc_link, scsiprint); sc->sc_scsibus = (struct scsibus_softc *)child; - /* XXX enable interrupts */ + /* enable interrupts */ arc_write(sc, ARC_REG_INTRMASK, ~(ARC_REG_INTRMASK_POSTQUEUE|ARC_REG_INTRSTAT_DOORBELL)); @@ -565,6 +565,7 @@ arc_intr(void *arg) intrstat = arc_read(sc, ARC_REG_INTRSTAT); if (intrstat == 0x0) return (0); + intrstat &= ARC_REG_INTRSTAT_POSTQUEUE | ARC_REG_INTRSTAT_DOORBELL; arc_write(sc, ARC_REG_INTRSTAT, intrstat); if (intrstat & ARC_REG_INTRSTAT_DOORBELL) { @@ -1486,7 +1487,7 @@ arc_unlock(struct arc_softc *sc) s = splbio(); sc->sc_talking = 0; arc_write(sc, ARC_REG_INTRMASK, - ~(ARC_REG_INTRMASK_POSTQUEUE|ARC_REG_INTRSTAT_DOORBELL)); + ~(ARC_REG_INTRMASK_POSTQUEUE|ARC_REG_INTRMASK_DOORBELL)); splx(s); rw_exit_write(&sc->sc_lock); } @@ -1498,7 +1499,7 @@ arc_wait(struct arc_softc *sc) s = splbio(); arc_write(sc, ARC_REG_INTRMASK, - ~(ARC_REG_INTRMASK_POSTQUEUE|ARC_REG_INTRSTAT_DOORBELL)); + ~(ARC_REG_INTRMASK_POSTQUEUE|ARC_REG_INTRMASK_DOORBELL)); if (tsleep(sc, PWAIT, "arcdb", hz) == EWOULDBLOCK) arc_write(sc, ARC_REG_INTRMASK, ~ARC_REG_INTRMASK_POSTQUEUE); splx(s); |