diff options
author | Vasanthakumar Thiagarajan <vasanth@atheros.com> | 2009-03-20 05:57:50 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2009-03-27 20:13:03 -0400 |
commit | 6b2c40326f9569283444d483448bcaadeca903e9 (patch) | |
tree | 6d000bda9d3769cdc5a0ec569bd02df0f02e07fa /drivers | |
parent | 8a92e2ee02dee127d309c73969aeb2a56567c9a0 (diff) |
ath9k: Nuke struct ath_xmit_status
Signed-off-by: Vasanthakumar Thiagarajan <vasanth@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/net/wireless/ath9k/ath9k.h | 4 | ||||
-rw-r--r-- | drivers/net/wireless/ath9k/xmit.c | 25 |
2 files changed, 8 insertions, 21 deletions
diff --git a/drivers/net/wireless/ath9k/ath9k.h b/drivers/net/wireless/ath9k/ath9k.h index 2b0256455118..2689a08a2844 100644 --- a/drivers/net/wireless/ath9k/ath9k.h +++ b/drivers/net/wireless/ath9k/ath9k.h | |||
@@ -295,13 +295,9 @@ struct ath_tx_control { | |||
295 | enum ath9k_internal_frame_type frame_type; | 295 | enum ath9k_internal_frame_type frame_type; |
296 | }; | 296 | }; |
297 | 297 | ||
298 | struct ath_xmit_status { | ||
299 | int retries; | ||
300 | int flags; | ||
301 | #define ATH_TX_ERROR 0x01 | 298 | #define ATH_TX_ERROR 0x01 |
302 | #define ATH_TX_XRETRY 0x02 | 299 | #define ATH_TX_XRETRY 0x02 |
303 | #define ATH_TX_BAR 0x04 | 300 | #define ATH_TX_BAR 0x04 |
304 | }; | ||
305 | 301 | ||
306 | /* All RSSI values are noise floor adjusted */ | 302 | /* All RSSI values are noise floor adjusted */ |
307 | struct ath_tx_stat { | 303 | struct ath_tx_stat { |
diff --git a/drivers/net/wireless/ath9k/xmit.c b/drivers/net/wireless/ath9k/xmit.c index 21e90bca3501..689bdbf78808 100644 --- a/drivers/net/wireless/ath9k/xmit.c +++ b/drivers/net/wireless/ath9k/xmit.c | |||
@@ -1750,7 +1750,7 @@ exit: | |||
1750 | /*****************/ | 1750 | /*****************/ |
1751 | 1751 | ||
1752 | static void ath_tx_complete(struct ath_softc *sc, struct sk_buff *skb, | 1752 | static void ath_tx_complete(struct ath_softc *sc, struct sk_buff *skb, |
1753 | struct ath_xmit_status *tx_status) | 1753 | int tx_flags) |
1754 | { | 1754 | { |
1755 | struct ieee80211_hw *hw = sc->hw; | 1755 | struct ieee80211_hw *hw = sc->hw; |
1756 | struct ieee80211_tx_info *tx_info = IEEE80211_SKB_CB(skb); | 1756 | struct ieee80211_tx_info *tx_info = IEEE80211_SKB_CB(skb); |
@@ -1771,12 +1771,10 @@ static void ath_tx_complete(struct ath_softc *sc, struct sk_buff *skb, | |||
1771 | tx_info->rate_driver_data[0] = NULL; | 1771 | tx_info->rate_driver_data[0] = NULL; |
1772 | } | 1772 | } |
1773 | 1773 | ||
1774 | if (tx_status->flags & ATH_TX_BAR) { | 1774 | if (tx_flags & ATH_TX_BAR) |
1775 | tx_info->flags |= IEEE80211_TX_STAT_AMPDU_NO_BACK; | 1775 | tx_info->flags |= IEEE80211_TX_STAT_AMPDU_NO_BACK; |
1776 | tx_status->flags &= ~ATH_TX_BAR; | ||
1777 | } | ||
1778 | 1776 | ||
1779 | if (!(tx_status->flags & (ATH_TX_ERROR | ATH_TX_XRETRY))) { | 1777 | if (!(tx_flags & (ATH_TX_ERROR | ATH_TX_XRETRY))) { |
1780 | /* Frame was ACKed */ | 1778 | /* Frame was ACKed */ |
1781 | tx_info->flags |= IEEE80211_TX_STAT_ACK; | 1779 | tx_info->flags |= IEEE80211_TX_STAT_ACK; |
1782 | } | 1780 | } |
@@ -1803,29 +1801,22 @@ static void ath_tx_complete_buf(struct ath_softc *sc, struct ath_buf *bf, | |||
1803 | int txok, int sendbar) | 1801 | int txok, int sendbar) |
1804 | { | 1802 | { |
1805 | struct sk_buff *skb = bf->bf_mpdu; | 1803 | struct sk_buff *skb = bf->bf_mpdu; |
1806 | struct ath_xmit_status tx_status; | ||
1807 | unsigned long flags; | 1804 | unsigned long flags; |
1805 | int tx_flags = 0; | ||
1808 | 1806 | ||
1809 | /* | ||
1810 | * Set retry information. | ||
1811 | * NB: Don't use the information in the descriptor, because the frame | ||
1812 | * could be software retried. | ||
1813 | */ | ||
1814 | tx_status.retries = bf->bf_retries; | ||
1815 | tx_status.flags = 0; | ||
1816 | 1807 | ||
1817 | if (sendbar) | 1808 | if (sendbar) |
1818 | tx_status.flags = ATH_TX_BAR; | 1809 | tx_flags = ATH_TX_BAR; |
1819 | 1810 | ||
1820 | if (!txok) { | 1811 | if (!txok) { |
1821 | tx_status.flags |= ATH_TX_ERROR; | 1812 | tx_flags |= ATH_TX_ERROR; |
1822 | 1813 | ||
1823 | if (bf_isxretried(bf)) | 1814 | if (bf_isxretried(bf)) |
1824 | tx_status.flags |= ATH_TX_XRETRY; | 1815 | tx_flags |= ATH_TX_XRETRY; |
1825 | } | 1816 | } |
1826 | 1817 | ||
1827 | dma_unmap_single(sc->dev, bf->bf_dmacontext, skb->len, DMA_TO_DEVICE); | 1818 | dma_unmap_single(sc->dev, bf->bf_dmacontext, skb->len, DMA_TO_DEVICE); |
1828 | ath_tx_complete(sc, skb, &tx_status); | 1819 | ath_tx_complete(sc, skb, tx_flags); |
1829 | 1820 | ||
1830 | /* | 1821 | /* |
1831 | * Return the list of ath_buf of this mpdu to free queue | 1822 | * Return the list of ath_buf of this mpdu to free queue |