diff options
author | Luis R. Rodriguez <lrodriguez@atheros.com> | 2010-04-16 01:38:32 +0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2010-04-16 23:43:23 +0400 |
commit | 7152451aa12558ab032f319a119ceb928396b905 (patch) | |
tree | 0b84c7516d4264bc9f57f5a88aa67c0d74abc03b /drivers/net/wireless/ath/ath9k/ar9002_phy.c | |
parent | da6f1d7f5f46d71f85d69a6521a16b83ad00e7e3 (diff) | |
download | linux-7152451aa12558ab032f319a119ceb928396b905.tar.xz |
ath9k_hw: add common channel select helpers for ar900[23]
Signed-off-by: Luis R. Rodriguez <lrodriguez@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/ath/ath9k/ar9002_phy.c')
-rw-r--r-- | drivers/net/wireless/ath/ath9k/ar9002_phy.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/wireless/ath/ath9k/ar9002_phy.c b/drivers/net/wireless/ath/ath9k/ar9002_phy.c index 87541a8440c0..1f8ac0ae471a 100644 --- a/drivers/net/wireless/ath/ath9k/ar9002_phy.c +++ b/drivers/net/wireless/ath/ath9k/ar9002_phy.c @@ -83,7 +83,7 @@ static int ar9002_hw_set_channel(struct ath_hw *ah, struct ath9k_channel *chan) bMode = 1; fracMode = 1; aModeRefSel = 0; - channelSel = (freq * 0x10000) / 15; + channelSel = CHANSEL_2G(freq); if (AR_SREV_9287_11_OR_LATER(ah)) { if (freq == 2484) { @@ -126,7 +126,7 @@ static int ar9002_hw_set_channel(struct ath_hw *ah, struct ath9k_channel *chan) */ fracMode = 1; refDivA = 1; - channelSel = (freq * 0x8000) / 15; + channelSel = CHANSEL_5G(freq); /* RefDivA setting */ REG_RMW_FIELD(ah, AR_AN_SYNTH9, |