From a93512febdf60b17373ac251481c01f0c8bcd88c Mon Sep 17 00:00:00 2001 From: ru Date: Sun, 11 Apr 2004 18:28:14 +0000 Subject: Fixed resetting of the watchdog timer and queue full flag. --- sys/dev/nge/if_nge.c | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) (limited to 'sys/dev') diff --git a/sys/dev/nge/if_nge.c b/sys/dev/nge/if_nge.c index 2b85ed1..b281e87 100644 --- a/sys/dev/nge/if_nge.c +++ b/sys/dev/nge/if_nge.c @@ -1412,15 +1412,12 @@ static void nge_txeof(sc) struct nge_softc *sc; { - struct nge_desc *cur_tx = NULL; + struct nge_desc *cur_tx; struct ifnet *ifp; u_int32_t idx; ifp = &sc->arpcom.ac_if; - /* Clear the timeout timer. */ - ifp->if_timer = 0; - /* * Go through our tx list and free mbufs for those * frames that have been transmitted. @@ -1453,17 +1450,17 @@ nge_txeof(sc) if (cur_tx->nge_mbuf != NULL) { m_freem(cur_tx->nge_mbuf); cur_tx->nge_mbuf = NULL; + ifp->if_flags &= ~IFF_OACTIVE; } sc->nge_cdata.nge_tx_cnt--; NGE_INC(idx, NGE_TX_LIST_CNT); - ifp->if_timer = 0; } sc->nge_cdata.nge_tx_cons = idx; - if (cur_tx != NULL) - ifp->if_flags &= ~IFF_OACTIVE; + if (idx == sc->nge_cdata.nge_tx_prod) + ifp->if_timer = 0; return; } -- cgit v1.1