aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJosef Karthauser <joe@FreeBSD.org>2003-07-14 19:39:16 +0000
committerJosef Karthauser <joe@FreeBSD.org>2003-07-14 19:39:16 +0000
commit99112dddf26b2d53d7841e27cecb3b8b1812e1db (patch)
treecaa8dcc1a189987b1509d4057a2de96eb6caad53
parent69e07da0ff40d99571b8d68be0ab8b52826b02b9 (diff)
downloadsrc-99112dddf26b2d53d7841e27cecb3b8b1812e1db.tar.gz
src-99112dddf26b2d53d7841e27cecb3b8b1812e1db.zip
MFNetBSD: revision 1.129
date: 2002/09/29 20:58:25; author: augustss; Add some spl calls to protect critical regions. From kern/18440, Takeshi Nakayama. (No functional change on FreeBSD).
Notes
Notes: svn path=/head/; revision=117580
-rw-r--r--sys/dev/usb/ohci.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/sys/dev/usb/ohci.c b/sys/dev/usb/ohci.c
index f67872ae666a..acc6bf495297 100644
--- a/sys/dev/usb/ohci.c
+++ b/sys/dev/usb/ohci.c
@@ -3,6 +3,8 @@
/* Also, already ported:
* $NetBSD: ohci.c,v 1.127 2002/08/07 20:03:19 augustss Exp $
+ * $NetBSD: ohci.c,v 1.128 2002/09/27 15:37:35 provos Exp $
+ * $NetBSD: ohci.c,v 1.129 2002/09/29 20:58:25 augustss Exp $
* $NetBSD: ohci.c,v 1.138 2003/02/08 03:32:50 ichiro Exp $
* $NetBSD: ohci.c,v 1.140 2003/05/13 04:42:00 gson Exp $
*/
@@ -637,6 +639,7 @@ ohci_alloc_sitd(ohci_softc_t *sc)
OHCI_ITD_ALIGN, &dma);
if (err)
return (NULL);
+ s = splusb();
for(i = 0; i < OHCI_SITD_CHUNK; i++) {
offs = i * OHCI_SITD_SIZE;
sitd = KERNADDR(&dma, offs);
@@ -644,6 +647,7 @@ ohci_alloc_sitd(ohci_softc_t *sc)
sitd->nextitd = sc->sc_freeitds;
sc->sc_freeitds = sitd;
}
+ splx(s);
}
s = splusb();
@@ -1255,8 +1259,11 @@ void
ohci_rhsc_enable(void *v_sc)
{
ohci_softc_t *sc = v_sc;
+ int s;
+ s = splhardusb();
ohci_rhsc_able(sc, 1);
+ splx(s);
}
#ifdef USB_DEBUG