diff mbox

ath5k: fix RTS/CTS by using proper rate flags

Message ID 1447945488-13665-1-git-send-email-me@bobcopeland.com (mailing list archive)
State Accepted
Delegated to: Kalle Valo
Headers show

Commit Message

Bob Copeland Nov. 19, 2015, 3:04 p.m. UTC
The rates in the tx control rateset do not have the protection
flags applied, so RTS/CTS would never get enabled if requested.

Fix by using the rate flags in the rates returned by
ieee80211_get_tx_rates().

Signed-off-by: Bob Copeland <me@bobcopeland.com>
---
 drivers/net/wireless/ath/ath5k/base.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Felix Fietkau Nov. 19, 2015, 3:22 p.m. UTC | #1
On 2015-11-19 16:04, Bob Copeland wrote:
> The rates in the tx control rateset do not have the protection
> flags applied, so RTS/CTS would never get enabled if requested.
> 
> Fix by using the rate flags in the rates returned by
> ieee80211_get_tx_rates().
> 
> Signed-off-by: Bob Copeland <me@bobcopeland.com>
Acked-by: Felix Fietkau <nbd@openwrt.org>
--
To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Kalle Valo Dec. 8, 2015, 2:57 p.m. UTC | #2
Bob Copeland <me@bobcopeland.com> writes:

> The rates in the tx control rateset do not have the protection
> flags applied, so RTS/CTS would never get enabled if requested.
>
> Fix by using the rate flags in the rates returned by
> ieee80211_get_tx_rates().
>
> Signed-off-by: Bob Copeland <me@bobcopeland.com>

Applied, thanks.
diff mbox

Patch

diff --git a/drivers/net/wireless/ath/ath5k/base.c b/drivers/net/wireless/ath/ath5k/base.c
index 342563a..3d946d8 100644
--- a/drivers/net/wireless/ath/ath5k/base.c
+++ b/drivers/net/wireless/ath/ath5k/base.c
@@ -767,7 +767,7 @@  ath5k_txbuf_setup(struct ath5k_hw *ah, struct ath5k_buf *bf,
 	if (info->flags & IEEE80211_TX_CTL_NO_ACK)
 		flags |= AR5K_TXDESC_NOACK;
 
-	rc_flags = info->control.rates[0].flags;
+	rc_flags = bf->rates[0].flags;
 
 	hw_rate = ath5k_get_rate_hw_value(ah->hw, info, bf, 0);