Date: Sat, 25 Dec 2004 19:28:03 GMT From: Sam Leffler <sam@FreeBSD.org> To: Perforce Change Reviews <perforce@freebsd.org> Subject: PERFORCE change 67687 for review Message-ID: <200412251928.iBPJS3HH056152@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=67687 Change 67687 by sam@sam_ebb on 2004/12/25 19:27:40 remove code to purge any node references held by buffers on the tx queues; this is no longer needed with the revised node table management Affected files ... .. //depot/projects/wifi/sys/dev/ath/if_ath.c#45 edit Differences ... ==== //depot/projects/wifi/sys/dev/ath/if_ath.c#45 (text+ko) ==== @@ -2304,43 +2304,14 @@ return &an->an_node; } -/* - * Clear any references to a node in a transmit queue. - * This happens when the node is cleaned so we don't - * need to worry about the reference count going to zero; - * we just reclaim the reference w/o dropping the txq lock. - * Then we null the pointer and the right thing happens - * when the buffer is cleaned in ath_tx_processq. - */ static void -ath_tx_cleanq(struct ieee80211com *ic, struct ath_txq *txq, - struct ieee80211_node *ni) -{ - struct ath_buf *bf; - - ATH_TXQ_LOCK(txq); - STAILQ_FOREACH(bf, &txq->axq_q, bf_list) { - if (bf->bf_node == ni) { - /* NB: this clears the pointer too */ - ieee80211_unref_node(&bf->bf_node); - } - } - ATH_TXQ_UNLOCK(txq); -} - -static void ath_node_free(struct ieee80211_node *ni) { struct ieee80211com *ic = ni->ni_ic; struct ath_softc *sc = ic->ic_ifp->if_softc; - int i; DPRINTF(sc, ATH_DEBUG_NODE, "%s: ni %p\n", __func__, ni); - /* XXX can this happen since refcnt must be zero for us to be called? */ - for (i = 0; i < HAL_NUM_TX_QUEUES; i++) - if (ATH_TXQ_SETUP(sc, i)) - ath_tx_cleanq(ic, &sc->sc_txq[i], ni); ath_rate_node_cleanup(sc, ATH_NODE(ni)); sc->sc_node_free(ni); }
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200412251928.iBPJS3HH056152>