diff options
author | phk <phk@FreeBSD.org> | 2002-09-04 18:50:40 +0000 |
---|---|---|
committer | phk <phk@FreeBSD.org> | 2002-09-04 18:50:40 +0000 |
commit | fdadf6ba89fc07723ed65edfda879fc6ae036577 (patch) | |
tree | 82decb87337e588f9b6f3cc89e4c1f974e9a3f15 /sys/dev/puc | |
parent | 62b64ef5096f7e5fea8821a947396d7053eca143 (diff) | |
download | FreeBSD-src-fdadf6ba89fc07723ed65edfda879fc6ae036577.zip FreeBSD-src-fdadf6ba89fc07723ed65edfda879fc6ae036577.tar.gz |
Don't let children attach fast interrupts if the parent interrupt is normal.
Submitted by: bde
Diffstat (limited to 'sys/dev/puc')
-rw-r--r-- | sys/dev/puc/puc.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/dev/puc/puc.c b/sys/dev/puc/puc.c index 195cb84..9cde9d6 100644 --- a/sys/dev/puc/puc.c +++ b/sys/dev/puc/puc.c @@ -163,7 +163,7 @@ puc_attach(device_t dev, const struct puc_device_description *desc) irq_setup = BUS_SETUP_INTR(device_get_parent(dev), dev, res, INTR_TYPE_TTY | INTR_FAST, puc_intr, sc, &sc->intr_cookie); if (irq_setup == 0) - sc->fastintr = 1; + sc->fastintr = INTR_FAST; else irq_setup = BUS_SETUP_INTR(device_get_parent(dev), dev, res, INTR_TYPE_TTY, puc_intr, sc, &sc->intr_cookie); @@ -461,7 +461,7 @@ puc_setup_intr(device_t dev, device_t child, struct resource *r, int flags, struct puc_softc *sc; sc = (struct puc_softc *)device_get_softc(dev); - if ((flags & INTR_FAST) && !sc->fastintr) + if ((flags & INTR_FAST) != sc->fastintr) return (ENXIO); for (i = 0; PUC_PORT_VALID(sc->sc_desc, i); i++) { if (sc->sc_ports[i].dev == child) { |