Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 203307
b: refs/heads/master
c: 78c4653
h: refs/heads/master
i:
  203305: c50b6d6
  203303: 7d8b094
v: v3
  • Loading branch information
Felix Fietkau authored and John W. Linville committed Jun 28, 2010
1 parent 0832735 commit 1fe9a0d
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 4 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 6665b54e79d52c813914481783d82398ca2451f6
refs/heads/master: 78c4653a2274479547e259e1f416d2b3d04c42a8
11 changes: 8 additions & 3 deletions trunk/drivers/net/wireless/ath/ath9k/xmit.c
Original file line number Diff line number Diff line change
Expand Up @@ -328,13 +328,16 @@ static void ath_tx_complete_aggr(struct ath_softc *sc, struct ath_txq *txq,
u32 ba[WME_BA_BMP_SIZE >> 5];
int isaggr, txfail, txpending, sendbar = 0, needreset = 0, nbad = 0;
bool rc_update = true;
struct ieee80211_tx_rate rates[4];

skb = bf->bf_mpdu;
hdr = (struct ieee80211_hdr *)skb->data;

tx_info = IEEE80211_SKB_CB(skb);
hw = bf->aphy->hw;

memcpy(rates, tx_info->control.rates, sizeof(rates));

rcu_read_lock();

/* XXX: use ieee80211_find_sta! */
Expand Down Expand Up @@ -375,6 +378,9 @@ static void ath_tx_complete_aggr(struct ath_softc *sc, struct ath_txq *txq,
txfail = txpending = 0;
bf_next = bf->bf_next;

skb = bf->bf_mpdu;
tx_info = IEEE80211_SKB_CB(skb);

if (ATH_BA_ISSET(ba, ATH_BA_INDEX(seq_st, bf->bf_seqno))) {
/* transmit completion, subframe is
* acked by block ack */
Expand Down Expand Up @@ -428,6 +434,7 @@ static void ath_tx_complete_aggr(struct ath_softc *sc, struct ath_txq *txq,
spin_unlock_bh(&txq->axq_lock);

if (rc_update && (acked_cnt == 1 || txfail_cnt == 1)) {
memcpy(tx_info->control.rates, rates, sizeof(rates));
ath_tx_rc_status(bf, ts, nbad, txok, true);
rc_update = false;
} else {
Expand Down Expand Up @@ -2033,7 +2040,7 @@ static void ath_tx_rc_status(struct ath_buf *bf, struct ath_tx_status *ts,
tx_info->status.rates[i].idx = -1;
}

tx_info->status.rates[tx_rateindex].count = bf->bf_retries + 1;
tx_info->status.rates[tx_rateindex].count = ts->ts_longretry + 1;
}

static void ath_wake_mac80211_queue(struct ath_softc *sc, struct ath_txq *txq)
Expand Down Expand Up @@ -2144,7 +2151,6 @@ static void ath_tx_processq(struct ath_softc *sc, struct ath_txq *txq)
* This frame is sent out as a single frame.
* Use hardware retry status for this frame.
*/
bf->bf_retries = ts.ts_longretry;
if (ts.ts_status & ATH9K_TXERR_XRETRY)
bf->bf_state.bf_type |= BUF_XRETRY;
ath_tx_rc_status(bf, &ts, 0, txok, true);
Expand Down Expand Up @@ -2274,7 +2280,6 @@ void ath_tx_edma_tasklet(struct ath_softc *sc)
}

if (!bf_isampdu(bf)) {
bf->bf_retries = txs.ts_longretry;
if (txs.ts_status & ATH9K_TXERR_XRETRY)
bf->bf_state.bf_type |= BUF_XRETRY;
ath_tx_rc_status(bf, &txs, 0, txok, true);
Expand Down

0 comments on commit 1fe9a0d

Please sign in to comment.