summaryrefslogtreecommitdiff
path: root/drivers/net/wireless/ath9k/main.c
diff options
context:
space:
mode:
authorLuis R. Rodriguez <lrodriguez@atheros.com>2008-12-23 23:58:38 (GMT)
committerJohn W. Linville <linville@tuxdriver.com>2009-01-29 20:59:28 (GMT)
commit96742256aba8c458d49af42610557977245be82d (patch)
tree5eef9aae2a70bf76fa39758837566e3c1ac0cafc /drivers/net/wireless/ath9k/main.c
parent030bb495c0c34aa74903ab8cf9c35e4f2f0aedea (diff)
downloadlinux-fsl-qoriq-96742256aba8c458d49af42610557977245be82d.tar.xz
ath9k: remove cache of rate preference when using 11g protection
No need to cache when we want to use 2Mbit/s for all protection frames for 802.11g as we can determine that dynamically on ath_buf_set_rate() itself. Signed-off-by: Luis R. Rodriguez <lrodriguez@atheros.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/ath9k/main.c')
-rw-r--r--drivers/net/wireless/ath9k/main.c13
1 files changed, 3 insertions, 10 deletions
diff --git a/drivers/net/wireless/ath9k/main.c b/drivers/net/wireless/ath9k/main.c
index 699d248..e26a9a6 100644
--- a/drivers/net/wireless/ath9k/main.c
+++ b/drivers/net/wireless/ath9k/main.c
@@ -61,12 +61,6 @@ static void bus_read_cachesize(struct ath_softc *sc, int *csz)
static void ath_setcurmode(struct ath_softc *sc, struct ieee80211_conf *conf)
{
- /*
- * All protection frames are transmited at 2Mb/s for
- * 11g, otherwise at 1Mb/s.
- * XXX select protection rate index from rate table.
- */
- sc->sc_protrix = 0;
switch (conf->channel->band) {
case IEEE80211_BAND_2GHZ:
if (conf_is_ht20(conf))
@@ -78,11 +72,9 @@ static void ath_setcurmode(struct ath_softc *sc, struct ieee80211_conf *conf)
else if (conf_is_ht40_plus(conf))
sc->cur_rate_table =
sc->hw_rate_table[ATH9K_MODE_11NG_HT40PLUS];
- else {
- sc->sc_protrix = 1;
+ else
sc->cur_rate_table =
sc->hw_rate_table[ATH9K_MODE_11G];
- }
break;
case IEEE80211_BAND_5GHZ:
if (conf_is_ht20(conf))
@@ -95,7 +87,8 @@ static void ath_setcurmode(struct ath_softc *sc, struct ieee80211_conf *conf)
sc->cur_rate_table =
sc->hw_rate_table[ATH9K_MODE_11NA_HT40PLUS];
else
- sc->cur_rate_table = sc->hw_rate_table[ATH9K_MODE_11A];
+ sc->cur_rate_table =
+ sc->hw_rate_table[ATH9K_MODE_11A];
break;
default:
break;