diff options
author | Felix Fietkau <nbd@openwrt.org> | 2010-11-14 09:20:09 -0500 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2010-11-17 16:19:21 -0500 |
commit | c5992618259598ade82c386aa1595bf105e92d1f (patch) | |
tree | 52772f46c243d754409c894e22debc1bed0e359d /drivers | |
parent | 76e4522177de81ac89ade01a394aeb3704a66f1b (diff) |
ath9k: remove bf_tx_aborted from struct ath_buf
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/net/wireless/ath/ath9k/ath9k.h | 1 | ||||
-rw-r--r-- | drivers/net/wireless/ath/ath9k/xmit.c | 23 |
2 files changed, 9 insertions, 15 deletions
diff --git a/drivers/net/wireless/ath/ath9k/ath9k.h b/drivers/net/wireless/ath/ath9k/ath9k.h index 84518dc0925f..3fecd03cfb23 100644 --- a/drivers/net/wireless/ath/ath9k/ath9k.h +++ b/drivers/net/wireless/ath/ath9k/ath9k.h | |||
@@ -227,7 +227,6 @@ struct ath_buf { | |||
227 | dma_addr_t bf_daddr; /* physical addr of desc */ | 227 | dma_addr_t bf_daddr; /* physical addr of desc */ |
228 | dma_addr_t bf_buf_addr; /* physical addr of data buffer, for DMA */ | 228 | dma_addr_t bf_buf_addr; /* physical addr of data buffer, for DMA */ |
229 | bool bf_stale; | 229 | bool bf_stale; |
230 | bool bf_tx_aborted; | ||
231 | u16 bf_flags; | 230 | u16 bf_flags; |
232 | struct ath_buf_state bf_state; | 231 | struct ath_buf_state bf_state; |
233 | struct ath_wiphy *aphy; | 232 | struct ath_wiphy *aphy; |
diff --git a/drivers/net/wireless/ath/ath9k/xmit.c b/drivers/net/wireless/ath/ath9k/xmit.c index 527151e44f10..c35033f1a5e0 100644 --- a/drivers/net/wireless/ath/ath9k/xmit.c +++ b/drivers/net/wireless/ath/ath9k/xmit.c | |||
@@ -334,9 +334,6 @@ static void ath_tx_count_frames(struct ath_softc *sc, struct ath_buf *bf, | |||
334 | *nbad = 0; | 334 | *nbad = 0; |
335 | *nframes = 0; | 335 | *nframes = 0; |
336 | 336 | ||
337 | if (bf->bf_lastbf->bf_tx_aborted) | ||
338 | return; | ||
339 | |||
340 | isaggr = bf_isaggr(bf); | 337 | isaggr = bf_isaggr(bf); |
341 | if (isaggr) { | 338 | if (isaggr) { |
342 | seq_st = ts->ts_seqnum; | 339 | seq_st = ts->ts_seqnum; |
@@ -357,7 +354,7 @@ static void ath_tx_count_frames(struct ath_softc *sc, struct ath_buf *bf, | |||
357 | 354 | ||
358 | static void ath_tx_complete_aggr(struct ath_softc *sc, struct ath_txq *txq, | 355 | static void ath_tx_complete_aggr(struct ath_softc *sc, struct ath_txq *txq, |
359 | struct ath_buf *bf, struct list_head *bf_q, | 356 | struct ath_buf *bf, struct list_head *bf_q, |
360 | struct ath_tx_status *ts, int txok) | 357 | struct ath_tx_status *ts, int txok, bool retry) |
361 | { | 358 | { |
362 | struct ath_node *an = NULL; | 359 | struct ath_node *an = NULL; |
363 | struct sk_buff *skb; | 360 | struct sk_buff *skb; |
@@ -461,8 +458,7 @@ static void ath_tx_complete_aggr(struct ath_softc *sc, struct ath_txq *txq, | |||
461 | /* transmit completion */ | 458 | /* transmit completion */ |
462 | acked_cnt++; | 459 | acked_cnt++; |
463 | } else { | 460 | } else { |
464 | if (!(tid->state & AGGR_CLEANUP) && | 461 | if (!(tid->state & AGGR_CLEANUP) && retry) { |
465 | !bf_last->bf_tx_aborted) { | ||
466 | if (bf->bf_retries < ATH_MAX_SW_RETRIES) { | 462 | if (bf->bf_retries < ATH_MAX_SW_RETRIES) { |
467 | ath_tx_set_retry(sc, txq, bf); | 463 | ath_tx_set_retry(sc, txq, bf); |
468 | txpending = 1; | 464 | txpending = 1; |
@@ -1132,8 +1128,6 @@ void ath_draintxq(struct ath_softc *sc, struct ath_txq *txq, bool retry_tx) | |||
1132 | } | 1128 | } |
1133 | 1129 | ||
1134 | lastbf = bf->bf_lastbf; | 1130 | lastbf = bf->bf_lastbf; |
1135 | if (!retry_tx) | ||
1136 | lastbf->bf_tx_aborted = true; | ||
1137 | 1131 | ||
1138 | if (sc->sc_ah->caps.hw_caps & ATH9K_HW_CAP_EDMA) { | 1132 | if (sc->sc_ah->caps.hw_caps & ATH9K_HW_CAP_EDMA) { |
1139 | list_cut_position(&bf_head, | 1133 | list_cut_position(&bf_head, |
@@ -1150,7 +1144,8 @@ void ath_draintxq(struct ath_softc *sc, struct ath_txq *txq, bool retry_tx) | |||
1150 | spin_unlock_bh(&txq->axq_lock); | 1144 | spin_unlock_bh(&txq->axq_lock); |
1151 | 1145 | ||
1152 | if (bf_isampdu(bf)) | 1146 | if (bf_isampdu(bf)) |
1153 | ath_tx_complete_aggr(sc, txq, bf, &bf_head, &ts, 0); | 1147 | ath_tx_complete_aggr(sc, txq, bf, &bf_head, &ts, 0, |
1148 | retry_tx); | ||
1154 | else | 1149 | else |
1155 | ath_tx_complete_buf(sc, bf, txq, &bf_head, &ts, 0, 0); | 1150 | ath_tx_complete_buf(sc, bf, txq, &bf_head, &ts, 0, 0); |
1156 | } | 1151 | } |
@@ -1171,7 +1166,7 @@ void ath_draintxq(struct ath_softc *sc, struct ath_txq *txq, bool retry_tx) | |||
1171 | 1166 | ||
1172 | if (bf_isampdu(bf)) | 1167 | if (bf_isampdu(bf)) |
1173 | ath_tx_complete_aggr(sc, txq, bf, &bf_head, | 1168 | ath_tx_complete_aggr(sc, txq, bf, &bf_head, |
1174 | &ts, 0); | 1169 | &ts, 0, retry_tx); |
1175 | else | 1170 | else |
1176 | ath_tx_complete_buf(sc, bf, txq, &bf_head, | 1171 | ath_tx_complete_buf(sc, bf, txq, &bf_head, |
1177 | &ts, 0, 0); | 1172 | &ts, 0, 0); |
@@ -1657,8 +1652,6 @@ static struct ath_buf *ath_tx_setup_buffer(struct ieee80211_hw *hw, | |||
1657 | return NULL; | 1652 | return NULL; |
1658 | } | 1653 | } |
1659 | 1654 | ||
1660 | bf->bf_tx_aborted = false; | ||
1661 | |||
1662 | return bf; | 1655 | return bf; |
1663 | } | 1656 | } |
1664 | 1657 | ||
@@ -2094,7 +2087,8 @@ static void ath_tx_processq(struct ath_softc *sc, struct ath_txq *txq) | |||
2094 | qnum = skb_get_queue_mapping(bf->bf_mpdu); | 2087 | qnum = skb_get_queue_mapping(bf->bf_mpdu); |
2095 | 2088 | ||
2096 | if (bf_isampdu(bf)) | 2089 | if (bf_isampdu(bf)) |
2097 | ath_tx_complete_aggr(sc, txq, bf, &bf_head, &ts, txok); | 2090 | ath_tx_complete_aggr(sc, txq, bf, &bf_head, &ts, txok, |
2091 | true); | ||
2098 | else | 2092 | else |
2099 | ath_tx_complete_buf(sc, bf, txq, &bf_head, &ts, txok, 0); | 2093 | ath_tx_complete_buf(sc, bf, txq, &bf_head, &ts, txok, 0); |
2100 | 2094 | ||
@@ -2216,7 +2210,8 @@ void ath_tx_edma_tasklet(struct ath_softc *sc) | |||
2216 | qnum = skb_get_queue_mapping(bf->bf_mpdu); | 2210 | qnum = skb_get_queue_mapping(bf->bf_mpdu); |
2217 | 2211 | ||
2218 | if (bf_isampdu(bf)) | 2212 | if (bf_isampdu(bf)) |
2219 | ath_tx_complete_aggr(sc, txq, bf, &bf_head, &txs, txok); | 2213 | ath_tx_complete_aggr(sc, txq, bf, &bf_head, &txs, |
2214 | txok, true); | ||
2220 | else | 2215 | else |
2221 | ath_tx_complete_buf(sc, bf, txq, &bf_head, | 2216 | ath_tx_complete_buf(sc, bf, txq, &bf_head, |
2222 | &txs, txok, 0); | 2217 | &txs, txok, 0); |