svn commit: r225413 - user/adrian/if_ath_tx/sys/dev/ath
Adrian Chadd
adrian at FreeBSD.org
Tue Sep 6 05:06:49 UTC 2011
Author: adrian
Date: Tue Sep 6 05:06:49 2011
New Revision: 225413
URL: http://svn.freebsd.org/changeset/base/225413
Log:
Two fixes:
* Clarify the software queue handling a little better;
* Don't add a frame to the BAW if it's not in the BAW - specifically,
NULL frames.
Modified:
user/adrian/if_ath_tx/sys/dev/ath/if_ath_tx.c
Modified: user/adrian/if_ath_tx/sys/dev/ath/if_ath_tx.c
==============================================================================
--- user/adrian/if_ath_tx/sys/dev/ath/if_ath_tx.c Tue Sep 6 03:17:11 2011 (r225412)
+++ user/adrian/if_ath_tx/sys/dev/ath/if_ath_tx.c Tue Sep 6 05:06:49 2011 (r225413)
@@ -2032,8 +2032,10 @@ ath_tx_xmit_aggr(struct ath_softc *sc, s
tid->hwq_depth++;
/* Add to BAW */
- ath_tx_addto_baw(sc, an, tid, bf);
- bf->bf_state.bfs_addedbaw = 1;
+ if (bf->bf_state.bfs_dobaw) {
+ ath_tx_addto_baw(sc, an, tid, bf);
+ bf->bf_state.bfs_addedbaw = 1;
+ }
/* Set completion handler, multi-frame aggregate or not */
bf->bf_comp = ath_tx_aggr_comp;
@@ -2085,10 +2087,14 @@ ath_tx_swq(struct ath_softc *sc, struct
} else if (ath_tx_ampdu_pending(sc, an, tid)) {
/* AMPDU pending; queue */
ATH_TXQ_INSERT_TAIL(atid, bf, bf_list);
- } else if (txq->axq_depth < sc->sc_hwq_limit &&
- ath_tx_ampdu_running(sc, an, tid)) {
- /* AMPDU running, attempt direct dispatch */
- ath_tx_xmit_aggr(sc, an, bf);
+ } else if (ath_tx_ampdu_running(sc, an, tid)) {
+ /* AMPDU running, attempt direct dispatch if possible */
+ if (txq->axq_depth < sc->sc_hwq_limit)
+ ath_tx_xmit_aggr(sc, an, bf);
+ else {
+ ATH_TXQ_INSERT_TAIL(atid, bf, bf_list);
+ ath_tx_tid_sched(sc, an, atid);
+ }
} else if (txq->axq_depth < sc->sc_hwq_limit) {
/* AMPDU not running, attempt direct dispatch */
ath_tx_xmit_normal(sc, txq, bf);
More information about the svn-src-user
mailing list