summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authorStefan Sperling <stsp@cvs.openbsd.org>2012-07-17 14:43:13 +0000
committerStefan Sperling <stsp@cvs.openbsd.org>2012-07-17 14:43:13 +0000
commitaa604d02f15b0e1949a264cbcf1481deaf25022d (patch)
tree507ba09b443ae479bf481a65e09cce2565f1a9a9 /sys
parent6c128ffc1de8ec14efcc669905a00c621be3dc8e (diff)
Revert my previous change for rt2661. It is causing excessive "ral0: device
timeout" messages on my soekris and doesn't fix the real problem.
Diffstat (limited to 'sys')
-rw-r--r--sys/dev/ic/rt2661.c20
-rw-r--r--sys/dev/ic/rt2661var.h4
2 files changed, 5 insertions, 19 deletions
diff --git a/sys/dev/ic/rt2661.c b/sys/dev/ic/rt2661.c
index 7221371a8c0..cf48f7c045a 100644
--- a/sys/dev/ic/rt2661.c
+++ b/sys/dev/ic/rt2661.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: rt2661.c,v 1.66 2012/07/13 10:08:15 stsp Exp $ */
+/* $OpenBSD: rt2661.c,v 1.67 2012/07/17 14:43:12 stsp Exp $ */
/*-
* Copyright (c) 2006
@@ -986,18 +986,9 @@ rt2661_tx_intr(struct rt2661_softc *sc)
txq->stat = 0;
}
- if (sc->mgtq.queued == 0 && sc->txq[0].queued == 0)
- sc->sc_tx_timer = 0;
- if (sc->mgtq.queued < RT2661_MGT_RING_COUNT &&
- sc->txq[0].queued < RT2661_TX_RING_COUNT - 1) {
- if (sc->mgtq.queued < RT2661_MGT_RING_COUNT)
- sc->sc_flags &= ~RT2661_MGT_OACTIVE;
- if (sc->txq[0].queued < RT2661_TX_RING_COUNT - 1)
- sc->sc_flags &= ~RT2661_DATA_OACTIVE;
- if (!(sc->sc_flags & (RT2661_MGT_OACTIVE|RT2661_DATA_OACTIVE)))
- ifp->if_flags &= ~IFF_OACTIVE;
- rt2661_start(ifp);
- }
+ sc->sc_tx_timer = 0;
+ ifp->if_flags &= ~IFF_OACTIVE;
+ rt2661_start(ifp);
}
void
@@ -1814,7 +1805,6 @@ rt2661_start(struct ifnet *ifp)
if (m0 != NULL) {
if (sc->mgtq.queued >= RT2661_MGT_RING_COUNT) {
ifp->if_flags |= IFF_OACTIVE;
- sc->sc_flags |= RT2661_MGT_OACTIVE;
break;
}
IF_DEQUEUE(&ic->ic_mgtq, m0);
@@ -1837,7 +1827,6 @@ rt2661_start(struct ifnet *ifp)
if (sc->txq[0].queued >= RT2661_TX_RING_COUNT - 1) {
/* there is no place left in this ring */
ifp->if_flags |= IFF_OACTIVE;
- sc->sc_flags |= RT2661_DATA_OACTIVE;
break;
}
IFQ_DEQUEUE(&ifp->if_snd, m0);
@@ -2613,7 +2602,6 @@ rt2661_stop(struct ifnet *ifp, int disable)
int ac;
sc->sc_tx_timer = 0;
- sc->sc_flags &= ~(RT2661_MGT_OACTIVE|RT2661_DATA_OACTIVE);
ifp->if_timer = 0;
ifp->if_flags &= ~(IFF_RUNNING | IFF_OACTIVE);
diff --git a/sys/dev/ic/rt2661var.h b/sys/dev/ic/rt2661var.h
index f95d6207d89..504a0b76e6b 100644
--- a/sys/dev/ic/rt2661var.h
+++ b/sys/dev/ic/rt2661var.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: rt2661var.h,v 1.15 2012/07/13 10:08:15 stsp Exp $ */
+/* $OpenBSD: rt2661var.h,v 1.16 2012/07/17 14:43:12 stsp Exp $ */
/*-
* Copyright (c) 2006
@@ -111,8 +111,6 @@ struct rt2661_softc {
#define RT2661_UPDATE_SLOT (1 << 1)
#define RT2661_SET_SLOTTIME (1 << 2)
#define RT2661_FWLOADED (1 << 3)
-#define RT2661_MGT_OACTIVE (1 << 4)
-#define RT2661_DATA_OACTIVE (1 << 5)
int sc_tx_timer;