summaryrefslogtreecommitdiffstats
path: root/sys/dev
diff options
context:
space:
mode:
authoradrian <adrian@FreeBSD.org>2013-02-07 02:15:25 +0000
committeradrian <adrian@FreeBSD.org>2013-02-07 02:15:25 +0000
commitc05e12cd73e3f0e6f8d35b37fb4396e5852bb17b (patch)
treedeaefc1df9ec08c652bb4475dcbff187f1af7fb3 /sys/dev
parent1d08d5f677c1dfa810e381073590adbae19cc69f (diff)
downloadFreeBSD-src-c05e12cd73e3f0e6f8d35b37fb4396e5852bb17b.zip
FreeBSD-src-c05e12cd73e3f0e6f8d35b37fb4396e5852bb17b.tar.gz
Methodize the process of adding the software TX queue to the taskqueue.
Move it (for now) to the TX taskqueue.
Diffstat (limited to 'sys/dev')
-rw-r--r--sys/dev/ath/if_ath.c4
-rw-r--r--sys/dev/ath/if_ath_misc.h14
-rw-r--r--sys/dev/ath/if_ath_tx.c8
-rw-r--r--sys/dev/ath/if_ath_tx_edma.c2
4 files changed, 21 insertions, 7 deletions
diff --git a/sys/dev/ath/if_ath.c b/sys/dev/ath/if_ath.c
index 41019fb..c492592 100644
--- a/sys/dev/ath/if_ath.c
+++ b/sys/dev/ath/if_ath.c
@@ -4230,9 +4230,9 @@ ath_tx_processq(struct ath_softc *sc, struct ath_txq *txq, int dosched)
ieee80211_ff_flush(ic, txq->axq_ac);
#endif
- /* Kick the TXQ scheduler */
+ /* Kick the software TXQ scheduler */
if (dosched) {
- taskqueue_enqueue(sc->sc_tx_tq, &sc->sc_txqtask);
+ ath_tx_swq_kick(sc);
}
ATH_KTR(sc, ATH_KTR_TXCOMP, 1,
diff --git a/sys/dev/ath/if_ath_misc.h b/sys/dev/ath/if_ath_misc.h
index a97f897..d81ef4c 100644
--- a/sys/dev/ath/if_ath_misc.h
+++ b/sys/dev/ath/if_ath_misc.h
@@ -120,12 +120,24 @@ extern void ath_tx_update_tim(struct ath_softc *sc,
extern void ath_start(struct ifnet *ifp);
extern void ath_start_task(void *arg, int npending);
+/*
+ * Kick the frame TX task.
+ */
static inline void
ath_tx_kick(struct ath_softc *sc)
{
- /* XXX eventually try sc_tx_tq? */
taskqueue_enqueue(sc->sc_tx_tq, &sc->sc_txpkttask);
}
+/*
+ * Kick the software TX queue task.
+ */
+static inline void
+ath_tx_swq_kick(struct ath_softc *sc)
+{
+
+ taskqueue_enqueue(sc->sc_tx_tq, &sc->sc_txqtask);
+}
+
#endif
diff --git a/sys/dev/ath/if_ath_tx.c b/sys/dev/ath/if_ath_tx.c
index b3b6079..e19a637 100644
--- a/sys/dev/ath/if_ath_tx.c
+++ b/sys/dev/ath/if_ath_tx.c
@@ -2999,9 +2999,11 @@ ath_tx_tid_resume(struct ath_softc *sc, struct ath_tid *tid)
}
ath_tx_tid_sched(sc, tid);
- /* Punt some frames to the hardware if needed */
- //ath_txq_sched(sc, sc->sc_ac2q[tid->ac]);
- taskqueue_enqueue(sc->sc_tx_tq, &sc->sc_txqtask);
+
+ /*
+ * Queue the software TX scheduler.
+ */
+ ath_tx_swq_kick(sc);
}
/*
diff --git a/sys/dev/ath/if_ath_tx_edma.c b/sys/dev/ath/if_ath_tx_edma.c
index a2eef65..6c6889c 100644
--- a/sys/dev/ath/if_ath_tx_edma.c
+++ b/sys/dev/ath/if_ath_tx_edma.c
@@ -655,7 +655,7 @@ ath_edma_tx_processq(struct ath_softc *sc, int dosched)
* the txq task for _one_ TXQ. This should be fixed.
*/
if (dosched)
- taskqueue_enqueue(sc->sc_tx_tq, &sc->sc_txqtask);
+ ath_tx_swq_kick(sc);
}
static void
OpenPOWER on IntegriCloud