summaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/ath/ath5k/reset.c
diff options
context:
space:
mode:
authorNick Kossifidis2009-04-30 21:55:44 +0200
committerJohn W. Linville2009-05-06 21:14:55 +0200
commita082381044ce026e83dbd17f8837722b028fc07d (patch)
tree181ef0bcdf8b69fa5aaf20da4b1e811feb57abd6 /drivers/net/wireless/ath/ath5k/reset.c
parentrt2x00: Synchronize initialization with rt2870 driver (diff)
downloadkernel-qcow2-linux-a082381044ce026e83dbd17f8837722b028fc07d.tar.gz
kernel-qcow2-linux-a082381044ce026e83dbd17f8837722b028fc07d.tar.xz
kernel-qcow2-linux-a082381044ce026e83dbd17f8837722b028fc07d.zip
ath5k: Allow user/driver to set txpower
* Now that we have regulatory control enable the driver to set txpower on hw * Also use txpower table offset so that we can match power range set by user/driver with indices on power table. Tested 2 different cards (a CM9 and an RF5112-based ubnt) and got the same output using a remote machine to measure per-packet rssi (conected the cards using attenuators). I also switched between various tx power levels and i saw an equal power change on the remote machine (so txpower changes as expected) and verified that we have the same output on each rate. Signed-off-by: Nick Kossifidis <mickflemm@gmail.com> Signed-off-by: Bob Copeland <me@bobcopeland.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/ath/ath5k/reset.c')
-rw-r--r--drivers/net/wireless/ath/ath5k/reset.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/wireless/ath/ath5k/reset.c b/drivers/net/wireless/ath/ath5k/reset.c
index 775fdf78554b..cb8a9a1398c9 100644
--- a/drivers/net/wireless/ath/ath5k/reset.c
+++ b/drivers/net/wireless/ath/ath5k/reset.c
@@ -1000,7 +1000,7 @@ int ath5k_hw_reset(struct ath5k_hw *ah, enum nl80211_iftype op_mode,
* Set TX power (FIXME)
*/
ret = ath5k_hw_txpower(ah, channel, ee_mode,
- AR5K_TUNE_DEFAULT_TXPOWER);
+ ah->ah_txpower.txp_max_pwr / 2);
if (ret)
return ret;