Skip to content

Commit

Permalink
ath9k: Rename ath_setcurmode() to ath_cache_conf_rate()
Browse files Browse the repository at this point in the history
ath_setcurmode() is a bit misleading, all we are doing is
caching the rate for the corresponding configuration we
are using.

Signed-off-by: Luis R. Rodriguez <lrodriguez@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
  • Loading branch information
Luis R. Rodriguez authored and John W. Linville committed Jan 29, 2009
1 parent 9674225 commit ce111ba
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions drivers/net/wireless/ath9k/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,8 @@ static void bus_read_cachesize(struct ath_softc *sc, int *csz)
*csz = DEFAULT_CACHELINE >> 2; /* Use the default size */
}

static void ath_setcurmode(struct ath_softc *sc, struct ieee80211_conf *conf)
static void ath_cache_conf_rate(struct ath_softc *sc,
struct ieee80211_conf *conf)
{
switch (conf->channel->band) {
case IEEE80211_BAND_2GHZ:
Expand Down Expand Up @@ -91,6 +92,7 @@ static void ath_setcurmode(struct ath_softc *sc, struct ieee80211_conf *conf)
sc->hw_rate_table[ATH9K_MODE_11A];
break;
default:
BUG_ON(1);
break;
}
}
Expand Down Expand Up @@ -316,7 +318,7 @@ static int ath_set_channel(struct ath_softc *sc, struct ath9k_channel *hchan)
return -EIO;
}

ath_setcurmode(sc, &hw->conf);
ath_cache_conf_rate(sc, &hw->conf);
ath_update_txpow(sc);
ath9k_hw_set_interrupts(ah, sc->sc_imask);
}
Expand Down Expand Up @@ -1647,7 +1649,7 @@ int ath_reset(struct ath_softc *sc, bool retry_tx)
* that changes the channel so update any state that
* might change as a result.
*/
ath_setcurmode(sc, &hw->conf);
ath_cache_conf_rate(sc, &hw->conf);

ath_update_txpow(sc);

Expand Down Expand Up @@ -1944,7 +1946,7 @@ static int ath9k_start(struct ieee80211_hw *hw)
!sc->sc_config.swBeaconProcess)
sc->sc_imask |= ATH9K_INT_TIM;

ath_setcurmode(sc, &hw->conf);
ath_cache_conf_rate(sc, &hw->conf);

sc->sc_flags &= ~SC_OP_INVALID;

Expand Down

0 comments on commit ce111ba

Please sign in to comment.