From: Sujith Manoharan <sujith@msujith.org>
To: linux-wireless@vger.kernel.org
Cc: ath9k-devel@qca.qualcomm.com
Subject: [RFC 1/4] ath9k: Fix queue management
Date: Wed, 24 Sep 2014 10:07:29 +0530 [thread overview]
Message-ID: <1411533452-22921-2-git-send-email-sujith@msujith.org> (raw)
In-Reply-To: <1411533452-22921-1-git-send-email-sujith@msujith.org>
From: Sujith Manoharan <c_manoha@qca.qualcomm.com>
Since we use IEEE80211_HW_QUEUE_CONTROL now, the
CAB/Offchannel queues are registered as the last
two queues. There is no need to check and reassign
the queues in the TX start()/done() routines.
CAB frames will not reach the tx() callback since
we set IEEE80211_HW_HOST_BROADCAST_PS_BUFFERING and
pull the buffered frames during beacon transmission.
We also don't have a special HW queue for handling
off-channel frames.
Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com>
---
drivers/net/wireless/ath/ath9k/xmit.c | 10 +++-------
1 file changed, 3 insertions(+), 7 deletions(-)
diff --git a/drivers/net/wireless/ath/ath9k/xmit.c b/drivers/net/wireless/ath/ath9k/xmit.c
index 93ad31b..2c8327f 100644
--- a/drivers/net/wireless/ath/ath9k/xmit.c
+++ b/drivers/net/wireless/ath/ath9k/xmit.c
@@ -158,7 +158,6 @@ static void ath_txq_skb_done(struct ath_softc *sc, struct ath_txq *txq,
{
struct ieee80211_tx_info *info = IEEE80211_SKB_CB(skb);
struct ath_frame_info *fi = get_frame_info(skb);
- int hw_queue;
int q = fi->txq;
if (q < 0)
@@ -168,10 +167,9 @@ static void ath_txq_skb_done(struct ath_softc *sc, struct ath_txq *txq,
if (WARN_ON(--txq->pending_frames < 0))
txq->pending_frames = 0;
- hw_queue = (info->hw_queue >= sc->hw->queues - 2) ? q : info->hw_queue;
if (txq->stopped &&
txq->pending_frames < sc->tx.txq_max_pending[q]) {
- ieee80211_wake_queue(sc->hw, hw_queue);
+ ieee80211_wake_queue(sc->hw, info->hw_queue);
txq->stopped = false;
}
}
@@ -2208,8 +2206,7 @@ int ath_tx_start(struct ieee80211_hw *hw, struct sk_buff *skb,
struct ath_atx_tid *tid = NULL;
struct ath_buf *bf;
bool queue;
- int q, hw_queue;
- int ret;
+ int q, ret;
if (vif)
avp = (void *)vif->drv_priv;
@@ -2228,14 +2225,13 @@ int ath_tx_start(struct ieee80211_hw *hw, struct sk_buff *skb,
*/
q = skb_get_queue_mapping(skb);
- hw_queue = (info->hw_queue >= sc->hw->queues - 2) ? q : info->hw_queue;
ath_txq_lock(sc, txq);
if (txq == sc->tx.txq_map[q]) {
fi->txq = q;
if (++txq->pending_frames > sc->tx.txq_max_pending[q] &&
!txq->stopped) {
- ieee80211_stop_queue(sc->hw, hw_queue);
+ ieee80211_stop_queue(sc->hw, info->hw_queue);
txq->stopped = true;
}
}
--
2.1.0
next prev parent reply other threads:[~2014-09-24 4:37 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-09-24 4:37 [RFC 0/4] ath9k patches Sujith Manoharan
2014-09-24 4:37 ` Sujith Manoharan [this message]
2014-09-24 4:37 ` [RFC 2/4] ath9k: Use normal queues for offchannel frames Sujith Manoharan
2014-09-24 4:37 ` [RFC 3/4] ath9k: Fix force_channel usage " Sujith Manoharan
2014-09-24 5:49 ` Sujith Manoharan
2014-09-24 4:37 ` [RFC 4/4] ath9k: Fix offchannel queuing Sujith Manoharan
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1411533452-22921-2-git-send-email-sujith@msujith.org \
--to=sujith@msujith.org \
--cc=ath9k-devel@qca.qualcomm.com \
--cc=linux-wireless@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox