summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sys/dev/eisa/aha1742.c8
-rw-r--r--sys/dev/ic/bha.c8
-rw-r--r--sys/dev/isa/wds.c14
3 files changed, 23 insertions, 7 deletions
diff --git a/sys/dev/eisa/aha1742.c b/sys/dev/eisa/aha1742.c
index 2b28fea37ad..b0b1a690b6d 100644
--- a/sys/dev/eisa/aha1742.c
+++ b/sys/dev/eisa/aha1742.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: aha1742.c,v 1.25 2007/05/08 16:03:20 deraadt Exp $ */
+/* $OpenBSD: aha1742.c,v 1.26 2007/11/05 17:12:41 krw Exp $ */
/* $NetBSD: aha1742.c,v 1.61 1996/05/12 23:40:01 mycroft Exp $ */
/*
@@ -372,14 +372,18 @@ ahb_poll(sc, xs, count)
{ /* in msec */
bus_space_tag_t iot = sc->sc_iot;
bus_space_handle_t ioh = sc->sc_ioh;
+ int s;
while (count) {
/*
* If we had interrupts enabled, would we
* have got an interrupt?
*/
- if (bus_space_read_1(iot, ioh, G2STAT) & G2STAT_INT_PEND)
+ if (bus_space_read_1(iot, ioh, G2STAT) & G2STAT_INT_PEND) {
+ s = splbio();
ahbintr(sc);
+ splx(s);
+ }
if (xs->flags & ITSDONE)
return 0;
delay(1000);
diff --git a/sys/dev/ic/bha.c b/sys/dev/ic/bha.c
index c0fbdc9685b..4e0d5ea7468 100644
--- a/sys/dev/ic/bha.c
+++ b/sys/dev/ic/bha.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: bha.c,v 1.10 2007/04/10 17:47:55 miod Exp $ */
+/* $OpenBSD: bha.c,v 1.11 2007/11/05 17:12:41 krw Exp $ */
/* $NetBSD: bha.c,v 1.27 1998/11/19 21:53:00 thorpej Exp $ */
#undef BHADEBUG
@@ -1549,6 +1549,7 @@ bha_poll(sc, xs, count)
{
bus_space_tag_t iot = sc->sc_iot;
bus_space_handle_t ioh = sc->sc_ioh;
+ int s;
/* timeouts are in msec, so we loop in 1000 usec cycles */
while (count) {
@@ -1557,8 +1558,11 @@ bha_poll(sc, xs, count)
* have got an interrupt?
*/
if (bus_space_read_1(iot, ioh, BHA_INTR_PORT) &
- BHA_INTR_ANYINTR)
+ BHA_INTR_ANYINTR) {
+ s = splbio();
bha_intr(sc);
+ splx(s);
+ }
if (xs->flags & ITSDONE)
return (0);
delay(1000); /* only happens in boot so ok */
diff --git a/sys/dev/isa/wds.c b/sys/dev/isa/wds.c
index 9b14b251eaa..1ec6603b487 100644
--- a/sys/dev/isa/wds.c
+++ b/sys/dev/isa/wds.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: wds.c,v 1.23 2006/11/28 23:59:45 dlg Exp $ */
+/* $OpenBSD: wds.c,v 1.24 2007/11/05 17:12:41 krw Exp $ */
/* $NetBSD: wds.c,v 1.13 1996/11/03 16:20:31 mycroft Exp $ */
#undef WDSDIAG
@@ -1355,6 +1355,7 @@ wds_poll(sc, xs, count)
{
bus_space_tag_t iot = sc->sc_iot;
bus_space_handle_t ioh = sc->sc_ioh;
+ int s;
/* timeouts are in msec, so we loop in 1000 usec cycles */
while (count) {
@@ -1362,8 +1363,11 @@ wds_poll(sc, xs, count)
* If we had interrupts enabled, would we
* have got an interrupt?
*/
- if (bus_space_read_1(iot, ioh, WDS_STAT) & WDSS_IRQ)
+ if (bus_space_read_1(iot, ioh, WDS_STAT) & WDSS_IRQ) {
+ s = splbio();
wdsintr(sc);
+ splx(s);
+ }
if (xs->flags & ITSDONE)
return 0;
delay(1000); /* only happens in boot so ok */
@@ -1383,6 +1387,7 @@ wds_ipoll(sc, scb, count)
{
bus_space_tag_t iot = sc->sc_iot;
bus_space_handle_t ioh = sc->sc_ioh;
+ int s;
/* timeouts are in msec, so we loop in 1000 usec cycles */
while (count) {
@@ -1390,8 +1395,11 @@ wds_ipoll(sc, scb, count)
* If we had interrupts enabled, would we
* have got an interrupt?
*/
- if (bus_space_read_1(iot, ioh, WDS_STAT) & WDSS_IRQ)
+ if (bus_space_read_1(iot, ioh, WDS_STAT) & WDSS_IRQ) {
+ s = splbio();
wdsintr(sc);
+ splx(s);
+ }
if (scb->flags & SCB_DONE)
return 0;
delay(1000); /* only happens in boot so ok */