From f7dc96fe4c9e0964f1e6bfdfe63a9a0eb1e6f724 Mon Sep 17 00:00:00 2001 From: augustss Date: Sat, 20 Jan 2001 23:36:02 +0000 Subject: [PATCH] Change some splusb() to splhardusb(). --- sys/dev/usb/ohci.c | 4 ++-- sys/dev/usb/uhci.c | 13 ++++++------- 2 files changed, 8 insertions(+), 9 deletions(-) diff --git a/sys/dev/usb/ohci.c b/sys/dev/usb/ohci.c index 14ed1657ed10..afe125539d6c 100644 --- a/sys/dev/usb/ohci.c +++ b/sys/dev/usb/ohci.c @@ -1,4 +1,4 @@ -/* $NetBSD: ohci.c,v 1.97 2000/12/31 14:29:54 augustss Exp $ */ +/* $NetBSD: ohci.c,v 1.98 2001/01/20 23:36:03 augustss Exp $ */ /* $FreeBSD: src/sys/dev/usb/ohci.c,v 1.22 1999/11/17 22:33:40 n_hibma Exp $ */ /* @@ -948,7 +948,7 @@ ohci_power(int why, void *v) ohci_dumpregs(sc); #endif - s = splusb(); + s = splhardusb(); switch (why) { case PWR_SUSPEND: case PWR_STANDBY: diff --git a/sys/dev/usb/uhci.c b/sys/dev/usb/uhci.c index e59a68850a02..da3b8316fafe 100644 --- a/sys/dev/usb/uhci.c +++ b/sys/dev/usb/uhci.c @@ -1,4 +1,4 @@ -/* $NetBSD: uhci.c,v 1.131 2000/12/29 01:24:56 augustss Exp $ */ +/* $NetBSD: uhci.c,v 1.132 2001/01/20 23:36:02 augustss Exp $ */ /* $FreeBSD: src/sys/dev/usb/uhci.c,v 1.33 1999/11/17 22:33:41 n_hibma Exp $ */ /* @@ -688,7 +688,7 @@ uhci_power(int why, void *v) int cmd; int s; - s = splusb(); + s = splhardusb(); cmd = UREAD2(sc, UHCI_CMD); DPRINTF(("uhci_power: sc=%p, why=%d (was %d), cmd=0x%x\n", @@ -1207,10 +1207,9 @@ uhci_intr(void *arg) } - if (ack) /* acknowledge the ints */ - UWRITE2(sc, UHCI_STS, ack); - else /* nothing to acknowledge */ - return (0); + if (!ack) + return (0); /* nothing to acknowledge */ + UWRITE2(sc, UHCI_STS, ack); /* acknowledge the ints */ sc->sc_bus.no_intrs++; usb_schedsoftintr(&sc->sc_bus); @@ -1511,7 +1510,7 @@ uhci_run(uhci_softc_t *sc, int run) u_int16_t cmd; run = run != 0; - s = splusb(); + s = splhardusb(); DPRINTF(("uhci_run: setting run=%d\n", run)); cmd = UREAD2(sc, UHCI_CMD); if (run)