summaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless
diff options
context:
space:
mode:
authorChristian Lamparter <chunkeey@googlemail.com>2010-09-26 22:49:34 +0200
committerJohn W. Linville <linville@tuxdriver.com>2010-09-28 15:47:56 -0400
commitcb139ecc0c030e8ccc736bd86cfef502c200825a (patch)
tree9d7a09f50e584d7f75689840bf7e78c941e80c07 /drivers/net/wireless
parent042c53f6e84896701b67012ad525bc44ea6de25f (diff)
downloadblackbird-op-linux-cb139ecc0c030e8ccc736bd86cfef502c200825a.tar.gz
blackbird-op-linux-cb139ecc0c030e8ccc736bd86cfef502c200825a.zip
carl9170: fix tx_ampdu_upload counter
tx_ampdu_upload was not decreased when an a-MPDU frame had to be kicked out from the tx_pending queues. This broke ampdu aggregation, because the scheduler waits until tx_ampdu_upload drops to zero, before making the next aggregate. Signed-off-by: Christian Lamparter <chunkeey@googlemail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless')
-rw-r--r--drivers/net/wireless/ath/carl9170/main.c15
1 files changed, 14 insertions, 1 deletions
diff --git a/drivers/net/wireless/ath/carl9170/main.c b/drivers/net/wireless/ath/carl9170/main.c
index d28b4ff8d281..a8b0cec78b32 100644
--- a/drivers/net/wireless/ath/carl9170/main.c
+++ b/drivers/net/wireless/ath/carl9170/main.c
@@ -230,8 +230,15 @@ static void carl9170_flush(struct ar9170 *ar, bool drop_queued)
for (i = 0; i < ar->hw->queues; i++) {
struct sk_buff *skb;
- while ((skb = skb_dequeue(&ar->tx_pending[i])))
+ while ((skb = skb_dequeue(&ar->tx_pending[i]))) {
+ struct ieee80211_tx_info *info;
+
+ info = IEEE80211_SKB_CB(skb);
+ if (info->flags & IEEE80211_TX_CTL_AMPDU)
+ atomic_dec(&ar->tx_ampdu_upload);
+
carl9170_tx_status(ar, skb, false);
+ }
}
}
@@ -1462,6 +1469,7 @@ static void carl9170_op_sta_notify(struct ieee80211_hw *hw,
skb_queue_walk_safe(&ar->tx_pending[i], skb, tmp) {
struct _carl9170_tx_superframe *super;
struct ieee80211_hdr *hdr;
+ struct ieee80211_tx_info *info;
super = (void *) skb->data;
hdr = (void *) super->frame_data;
@@ -1470,6 +1478,11 @@ static void carl9170_op_sta_notify(struct ieee80211_hw *hw,
continue;
__skb_unlink(skb, &ar->tx_pending[i]);
+
+ info = IEEE80211_SKB_CB(skb);
+ if (info->flags & IEEE80211_TX_CTL_AMPDU)
+ atomic_dec(&ar->tx_ampdu_upload);
+
carl9170_tx_status(ar, skb, false);
}
spin_unlock_bh(&ar->tx_pending[i].lock);
OpenPOWER on IntegriCloud