Lines Matching refs:txq

189 static int	ath_tx_processq(struct ath_softc *sc, struct ath_txq *txq,
268 * include them when checking the txq setup mask.
1822 * may be being scheduled between sw->hw txq. Tsk.
2289 * Grab all the currently set bits in the HAL txq bitmap
3951 ath_txq_init(struct ath_softc *sc, struct ath_txq *txq, int qnum)
3953 txq->axq_qnum = qnum;
3954 txq->axq_ac = 0;
3955 txq->axq_depth = 0;
3956 txq->axq_aggr_depth = 0;
3957 txq->axq_intrcnt = 0;
3958 txq->axq_link = NULL;
3959 txq->axq_softc = sc;
3960 TAILQ_INIT(&txq->axq_q);
3961 TAILQ_INIT(&txq->axq_tidq);
3962 TAILQ_INIT(&txq->fifo.axq_q);
3963 ATH_TXQ_LOCK_INIT(sc, txq);
4034 struct ath_txq *txq;
4041 txq = ath_txq_setup(sc, HAL_TX_QUEUE_DATA, haltype);
4042 if (txq != NULL) {
4043 txq->axq_ac = ac;
4044 sc->sc_ac2q[ac] = txq;
4058 struct ath_txq *txq = sc->sc_ac2q[ac];
4067 ath_hal_gettxqueueprops(ah, txq->axq_qnum, &qi);
4113 __func__, txq->axq_qnum, qi.tqi_qflags,
4116 if (!ath_hal_settxqueueprops(ah, txq->axq_qnum, &qi)) {
4121 ath_hal_resettxqueue(ah, txq->axq_qnum); /* push to h/w */
4145 ath_tx_cleanupq(struct ath_softc *sc, struct ath_txq *txq)
4148 ath_hal_releasetxqueue(sc->sc_ah, txq->axq_qnum);
4149 sc->sc_txqsetup &= ~(1<<txq->axq_qnum);
4150 ATH_TXQ_LOCK_DESTROY(txq);
4340 ath_tx_process_buf_completion(struct ath_softc *sc, struct ath_txq *txq,
4346 ATH_TXQ_UNLOCK_ASSERT(txq);
4390 ath_tx_processq(struct ath_softc *sc, struct ath_txq *txq, int dosched)
4404 __func__, txq->axq_qnum,
4405 (caddr_t)(uintptr_t) ath_hal_gettxbuf(sc->sc_ah, txq->axq_qnum),
4406 txq->axq_link);
4409 "ath_tx_processq: txq=%u head %p link %p depth %p",
4410 txq->axq_qnum,
4411 (caddr_t)(uintptr_t) ath_hal_gettxbuf(sc->sc_ah, txq->axq_qnum),
4412 txq->axq_link,
4413 txq->axq_depth);
4417 ATH_TXQ_LOCK(txq);
4418 txq->axq_intrcnt = 0; /* reset periodic desc intr count */
4419 bf = TAILQ_FIRST(&txq->axq_q);
4421 ATH_TXQ_UNLOCK(txq);
4430 ath_printtxbuf(sc, bf, txq->axq_qnum, 0,
4433 ath_printtxbuf(sc, bf, txq->axq_qnum, 0,
4447 "ath_tx_processq: txq=%u, bf=%p ds=%p, HAL_EINPROGRESS",
4448 txq->axq_qnum, bf, ds);
4449 ATH_TXQ_UNLOCK(txq);
4452 ATH_TXQ_REMOVE(txq, bf, bf_list);
4457 if (txq->axq_qnum != bf->bf_state.bfs_tx_queue) {
4461 txq->axq_qnum,
4465 if (txq->axq_qnum != bf->bf_last->bf_state.bfs_tx_queue) {
4469 txq->axq_qnum,
4475 if (txq->axq_depth > 0) {
4487 txq->axq_link = NULL;
4492 txq->axq_aggr_depth--;
4497 "ath_tx_processq: txq=%u, bf=%p, ds=%p, ni=%p, ts_status=0x%08x",
4498 txq->axq_qnum, bf, ds, ni, ts->ts_status);
4513 ATH_TXQ_UNLOCK(txq);
4518 ath_tx_process_buf_completion(sc, txq, ts, bf);
4526 if (txq->axq_depth <= 1)
4527 ieee80211_ff_flush(ic, txq->axq_ac);
4533 ath_txq_sched(sc, txq);
4538 "ath_tx_processq: txq=%u: done",
4539 txq->axq_qnum);
4785 ath_txq_freeholdingbuf(struct ath_softc *sc, struct ath_txq *txq)
4788 ATH_TXQ_LOCK_ASSERT(txq);
4790 if (txq->axq_holdingbf == NULL)
4793 txq->axq_holdingbf->bf_flags &= ~ATH_BUF_BUSY;
4796 ath_returnbuf_tail(sc, txq->axq_holdingbf);
4799 txq->axq_holdingbf = NULL;
4809 struct ath_txq *txq;
4811 txq = &sc->sc_txq[bf->bf_state.bfs_tx_queue];
4814 ATH_TXQ_LOCK_ASSERT(txq);
4828 ath_txq_freeholdingbuf(sc, txq);
4829 txq->axq_holdingbf = bf;
4846 * always completed there (pushed onto a txq or ath_bufhead) so we knew
4852 struct ath_txq *txq;
4854 txq = &sc->sc_txq[bf->bf_state.bfs_tx_queue];
4863 ATH_TXQ_LOCK(txq);
4865 ATH_TXQ_UNLOCK(txq);
4911 ath_tx_draintxq_get_one(struct ath_softc *sc, struct ath_txq *txq)
4915 ATH_TXQ_LOCK_ASSERT(txq);
4921 bf = TAILQ_FIRST(&txq->fifo.axq_q);
4928 if (txq->axq_fifo_depth == 0) {
4932 txq->axq_qnum,
4933 txq->fifo.axq_depth);
4935 txq->axq_fifo_depth--;
4937 ATH_TXQ_REMOVE(&txq->fifo, bf, bf_list);
4944 if (txq->axq_fifo_depth != 0 || txq->fifo.axq_depth != 0) {
4948 txq->axq_qnum,
4949 txq->axq_fifo_depth,
4950 txq->fifo.axq_depth);
4956 bf = TAILQ_FIRST(&txq->axq_q);
4958 txq->axq_link = NULL;
4961 ATH_TXQ_REMOVE(txq, bf, bf_list);
4966 ath_tx_draintxq(struct ath_softc *sc, struct ath_txq *txq)
4979 ATH_TXQ_LOCK(txq);
4980 bf = ath_tx_draintxq_get_one(sc, txq);
4982 ATH_TXQ_UNLOCK(txq);
4986 txq->axq_aggr_depth--;
5003 ath_printtxbuf(sc, bf, txq->axq_qnum, ix, status);
5017 ATH_TXQ_UNLOCK(txq);
5028 ATH_TXQ_LOCK(txq);
5029 ath_txq_freeholdingbuf(sc, txq);
5030 ATH_TXQ_UNLOCK(txq);
5036 ath_tx_txq_drain(sc, txq);
5040 ath_tx_stopdma(struct ath_softc *sc, struct ath_txq *txq)
5044 ATH_TXQ_LOCK_ASSERT(txq);
5050 txq->axq_qnum,
5051 (caddr_t)(uintptr_t) ath_hal_gettxbuf(ah, txq->axq_qnum),
5052 (int) (!! ath_hal_txqenabled(ah, txq->axq_qnum)),
5053 (int) ath_hal_numtxpending(ah, txq->axq_qnum),
5054 txq->axq_flags,
5055 txq->axq_link,
5056 txq->axq_holdingbf);
5058 (void) ath_hal_stoptxdma(ah, txq->axq_qnum);
5060 txq->axq_flags &= ~ATH_TXQ_PUTRUNNING;
5064 && (txq->axq_holdingbf != NULL)) {
5065 ath_printtxbuf(sc, txq->axq_holdingbf, txq->axq_qnum, 0, 0);
5105 ath_tx_dump(struct ath_softc *sc, struct ath_txq *txq)
5115 __func__, txq->axq_qnum);
5116 TAILQ_FOREACH(bf, &txq->axq_q, bf_list) {
5117 ath_printtxbuf(sc, bf, txq->axq_qnum, i,
5123 __func__, txq->axq_qnum);
6603 struct ath_txq *txq = sc->sc_ac2q[i];
6606 txq->axq_qnum, ieee80211_wme_acnames[i]);