summaryrefslogtreecommitdiffstats
path: root/sys
diff options
context:
space:
mode:
authorimp <imp@FreeBSD.org>2002-02-12 05:32:58 +0000
committerimp <imp@FreeBSD.org>2002-02-12 05:32:58 +0000
commitf3e9446326ff27ba941a96a410fe268101848f7c (patch)
tree7578e98d92d30c7721eaf50cb288f91ee9e9e4cb /sys
parent5d2ae7a01f6466bf94dfb60faae6dfdccd172438 (diff)
downloadFreeBSD-src-f3e9446326ff27ba941a96a410fe268101848f7c.zip
FreeBSD-src-f3e9446326ff27ba941a96a410fe268101848f7c.tar.gz
Two fixes from Jonathan Hanna:
1) We shouldn't continue when we get a RX complete because we ack it and the TX complete. 2) Fix a couple of spl leaks (why splbio is needed in ISR, I cannot understand). MFC after: 3 days
Diffstat (limited to 'sys')
-rw-r--r--sys/dev/ep/if_ep.c10
1 files changed, 4 insertions, 6 deletions
diff --git a/sys/dev/ep/if_ep.c b/sys/dev/ep/if_ep.c
index 1118f11..7798325 100644
--- a/sys/dev/ep/if_ep.c
+++ b/sys/dev/ep/if_ep.c
@@ -548,13 +548,13 @@ ep_intr(arg)
sc = (struct ep_softc *)arg;
- if (sc->gone)
- return;
/*
* quick fix: Try to detect an interrupt when the card goes away.
*/
- if (inw(BASE + EP_STATUS) == 0xffff)
+ if (sc->gone || inw(BASE + EP_STATUS) == 0xffff) {
+ splx(x);
return;
+ }
ifp = &sc->arpcom.ac_if;
@@ -567,10 +567,8 @@ rescan:
/* first acknowledge all interrupt sources */
outw(BASE + EP_COMMAND, ACK_INTR | (status & S_MASK));
- if (status & (S_RX_COMPLETE | S_RX_EARLY)) {
+ if (status & (S_RX_COMPLETE | S_RX_EARLY))
epread(sc);
- continue;
- }
if (status & S_TX_AVAIL) {
/* we need ACK */
ifp->if_timer = 0;
OpenPOWER on IntegriCloud