X-Git-Url: https://git.rohieb.name/openwrt.git/blobdiff_plain/aa53129b196400b5f0b4104509baca51d8be83bb..eaafa6fa91f3ec477e798edf02419a7556675814:/package/mac80211/patches/300-pending_work.patch?ds=sidebyside diff --git a/package/mac80211/patches/300-pending_work.patch b/package/mac80211/patches/300-pending_work.patch index 4f9138cbc..494c7942f 100644 --- a/package/mac80211/patches/300-pending_work.patch +++ b/package/mac80211/patches/300-pending_work.patch @@ -9,6 +9,19 @@ mgmt->frame_control = cpu_to_le16(IEEE80211_FTYPE_MGMT | IEEE80211_STYPE_ACTION); +@@ -262,7 +264,11 @@ void ieee80211_process_addba_request(str + "%pM on tid %u\n", + mgmt->sa, tid); + #endif /* CONFIG_MAC80211_HT_DEBUG */ +- goto end; ++ ++ /* delete existing Rx BA session on the same tid */ ++ ___ieee80211_stop_rx_ba_session(sta, tid, WLAN_BACK_RECIPIENT, ++ WLAN_STATUS_UNSPECIFIED_QOS, ++ false); + } + + /* prepare A-MPDU MLME for Rx aggregation */ --- a/net/mac80211/agg-tx.c +++ b/net/mac80211/agg-tx.c @@ -79,7 +79,8 @@ static void ieee80211_send_addba_request @@ -247,7 +260,15 @@ WLAN_STA_BLOCK_BA = 1<<11, --- a/drivers/net/wireless/ath/ath9k/beacon.c +++ b/drivers/net/wireless/ath/ath9k/beacon.c -@@ -384,7 +384,9 @@ void ath_beacon_tasklet(unsigned long da +@@ -360,6 +360,7 @@ void ath_beacon_tasklet(unsigned long da + struct ath_common *common = ath9k_hw_common(ah); + struct ath_buf *bf = NULL; + struct ieee80211_vif *vif; ++ struct ath_tx_status ts; + int slot; + u32 bfaddr, bc = 0; + +@@ -384,7 +385,9 @@ void ath_beacon_tasklet(unsigned long da ath_dbg(common, ATH_DBG_BSTUCK, "beacon is officially stuck\n"); sc->sc_flags |= SC_OP_TSF_RESET; @@ -257,6 +278,18 @@ } return; +@@ -464,6 +467,11 @@ void ath_beacon_tasklet(unsigned long da + ath9k_hw_txstart(ah, sc->beacon.beaconq); + + sc->beacon.ast_be_xmit += bc; /* XXX per-vif? */ ++ if (ah->caps.hw_caps & ATH9K_HW_CAP_EDMA) { ++ spin_lock_bh(&sc->sc_pcu_lock); ++ ath9k_hw_txprocdesc(ah, bf->bf_desc, (void *)&ts); ++ spin_unlock_bh(&sc->sc_pcu_lock); ++ } + } + } + --- a/drivers/net/wireless/ath/ath9k/main.c +++ b/drivers/net/wireless/ath/ath9k/main.c @@ -617,8 +617,11 @@ void ath_hw_check(struct work_struct *wo @@ -334,7 +367,17 @@ } static u32 ath_lookup_rate(struct ath_softc *sc, struct ath_buf *bf, -@@ -2169,7 +2166,9 @@ static void ath_tx_complete_poll_work(st +@@ -664,7 +661,8 @@ static int ath_compute_num_delims(struct + * TODO - this could be improved to be dependent on the rate. + * The hardware can keep up at lower rates, but not higher rates + */ +- if (fi->keyix != ATH9K_TXKEYIX_INVALID) ++ if ((fi->keyix != ATH9K_TXKEYIX_INVALID) && ++ !(sc->sc_ah->caps.hw_caps & ATH9K_HW_CAP_EDMA)) + ndelim += ATH_AGGR_ENCRYPTDELIM; + + /* +@@ -2169,7 +2167,9 @@ static void ath_tx_complete_poll_work(st if (needreset) { ath_dbg(ath9k_hw_common(sc->sc_ah), ATH_DBG_RESET, "tx hung, resetting the chip\n"); @@ -438,3 +481,54 @@ void ar9003_hw_set_chain_masks(struct ath_hw *ah, u8 rx, u8 tx); #endif /* AR9003_PHY_H */ +--- a/drivers/net/wireless/ath/ath5k/eeprom.c ++++ b/drivers/net/wireless/ath/ath5k/eeprom.c +@@ -691,14 +691,12 @@ ath5k_eeprom_free_pcal_info(struct ath5k + if (!chinfo[pier].pd_curves) + continue; + +- for (pdg = 0; pdg < ee->ee_pd_gains[mode]; pdg++) { ++ for (pdg = 0; pdg < AR5K_EEPROM_N_PD_CURVES; pdg++) { + struct ath5k_pdgain_info *pd = + &chinfo[pier].pd_curves[pdg]; + +- if (pd != NULL) { +- kfree(pd->pd_step); +- kfree(pd->pd_pwr); +- } ++ kfree(pd->pd_step); ++ kfree(pd->pd_pwr); + } + + kfree(chinfo[pier].pd_curves); +--- a/drivers/net/wireless/ath/ath9k/ar9003_mac.c ++++ b/drivers/net/wireless/ath/ath9k/ar9003_mac.c +@@ -229,6 +229,7 @@ static void ar9003_hw_fill_txdesc(struct + static int ar9003_hw_proc_txdesc(struct ath_hw *ah, void *ds, + struct ath_tx_status *ts) + { ++ struct ar9003_txc *txc = (struct ar9003_txc *) ds; + struct ar9003_txs *ads; + u32 status; + +@@ -238,7 +239,11 @@ static int ar9003_hw_proc_txdesc(struct + if ((status & AR_TxDone) == 0) + return -EINPROGRESS; + +- ah->ts_tail = (ah->ts_tail + 1) % ah->ts_size; ++ ts->qid = MS(ads->ds_info, AR_TxQcuNum); ++ if (!txc || (MS(txc->info, AR_TxQcuNum) == ts->qid)) ++ ah->ts_tail = (ah->ts_tail + 1) % ah->ts_size; ++ else ++ return -ENOENT; + + if ((MS(ads->ds_info, AR_DescId) != ATHEROS_VENDOR_ID) || + (MS(ads->ds_info, AR_TxRxDesc) != 1)) { +@@ -254,7 +259,6 @@ static int ar9003_hw_proc_txdesc(struct + ts->ts_seqnum = MS(status, AR_SeqNum); + ts->tid = MS(status, AR_TxTid); + +- ts->qid = MS(ads->ds_info, AR_TxQcuNum); + ts->desc_id = MS(ads->status1, AR_TxDescId); + ts->ts_tstamp = ads->status4; + ts->ts_status = 0;