ath9k: add some more fixes for the tx queueing rework
[openwrt/staging/yousong.git] / package / kernel / mac80211 / patches / 572-ath9k_multicast_node.patch
index cbe3816b12eb03ae1084f1be87c3f78cfc08581e..28ec6ee9dbffbf095d51aedb520138f52dde15ef 100644 (file)
@@ -69,7 +69,7 @@
        ieee80211_send_bar(tid->an->vif, tid->an->sta->addr, tid->tidno,
                           seqno << IEEE80211_SEQ_SEQ_SHIFT);
  }
-@@ -1352,7 +1355,7 @@ static bool ath_tx_sched_aggr(struct ath
+@@ -1354,7 +1357,7 @@ static bool ath_tx_sched_aggr(struct ath
        if (list_empty(&bf_q))
                return false;
  
                tid->ac->clear_ps_filter = false;
                tx_info->flags |= IEEE80211_TX_CTL_CLEAR_PS_FILT;
        }
-@@ -1542,7 +1545,7 @@ void ath9k_release_buffered_frames(struc
+@@ -1544,7 +1547,7 @@ void ath9k_release_buffered_frames(struc
                        sent++;
                        TX_STAT_INC(txq->axq_qnum, a_queued_hw);
  
--                      if (ath_tid_has_buffered(tid))
-+                      if (an->sta && ath_tid_has_buffered(tid))
+-                      if (!ath_tid_has_buffered(tid))
++                      if (an->sta && !ath_tid_has_buffered(tid))
                                ieee80211_sta_set_buffered(an->sta, i, false);
                }
                ath_txq_unlock_complete(sc, tid->ac->txq);
-@@ -2075,6 +2078,7 @@ static int ath_tx_prepare(struct ieee802
+@@ -2076,6 +2079,7 @@ static int ath_tx_prepare(struct ieee802
        struct ieee80211_tx_info *info = IEEE80211_SKB_CB(skb);
        struct ieee80211_sta *sta = txctl->sta;
        struct ieee80211_vif *vif = info->control.vif;
@@ -95,7 +95,7 @@
        struct ath_softc *sc = hw->priv;
        int frmlen = skb->len + FCS_LEN;
        int padpos, padsize;
-@@ -2082,6 +2086,10 @@ static int ath_tx_prepare(struct ieee802
+@@ -2083,6 +2087,10 @@ static int ath_tx_prepare(struct ieee802
        /* NOTE:  sta can be NULL according to net/mac80211.h */
        if (sta)
                txctl->an = (struct ath_node *)sta->drv_priv;