summaryrefslogtreecommitdiffstats
path: root/sys/dev/fxp
diff options
context:
space:
mode:
authorluigi <luigi@FreeBSD.org>2002-06-30 22:28:00 +0000
committerluigi <luigi@FreeBSD.org>2002-06-30 22:28:00 +0000
commitb8b17193ed603a60f65f52bc95c7584309568bde (patch)
tree8d245dabe485bfa3cd255623e8769118f8cdfaba /sys/dev/fxp
parent36987f382b7fcdcfd13a44439a02485f0f5150c2 (diff)
downloadFreeBSD-src-b8b17193ed603a60f65f52bc95c7584309568bde.zip
FreeBSD-src-b8b17193ed603a60f65f52bc95c7584309568bde.tar.gz
Fix if_timer logic so that there is always a timeout pending if there
are packets queued for transmission. This driver is strange -- it never sets IFF_OACTIVE, so all transmissions always cause a call to fxp_start. However, if the link gets stuck, there was nothing to reset it, so there was still a possibility of lockups. MFC after: 3 days
Diffstat (limited to 'sys/dev/fxp')
-rw-r--r--sys/dev/fxp/if_fxp.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/sys/dev/fxp/if_fxp.c b/sys/dev/fxp/if_fxp.c
index 1d2ff03..50da42e 100644
--- a/sys/dev/fxp/if_fxp.c
+++ b/sys/dev/fxp/if_fxp.c
@@ -1253,11 +1253,13 @@ fxp_intr_body(struct fxp_softc *sc, u_int8_t statack, int count)
sc->tx_queued--;
}
sc->cbl_first = txp;
- ifp->if_timer = 0;
if (sc->tx_queued == 0) {
+ ifp->if_timer = 0;
if (sc->need_mcsetup)
fxp_mc_setup(sc);
- }
+ } else
+ ifp->if_timer = 5;
+
/*
* Try to start more packets transmitting.
*/
OpenPOWER on IntegriCloud