summaryrefslogtreecommitdiff
path: root/drivers/net/wireless/mwl8k.c
diff options
context:
space:
mode:
authorNishant Sarmukadam <nishants@marvell.com>2011-04-05 14:18:09 +0530
committerJohn W. Linville <linville@tuxdriver.com>2011-04-07 15:49:40 -0400
commit0321708748d8f2ecfffa4a9feafb332312e4e57f (patch)
tree303f04a76b6577adeea6c27ca83c3841b35a2ac0 /drivers/net/wireless/mwl8k.c
parent99e4d43ad5ff5778f92ee3bc40a29ac7cd8a28f4 (diff)
mwl8k: Do not configure tx power unconditionally
Instead of configuring tx power unconditionally, check for IEEE80211_CONF_CHANGE_POWER and configure it only when stack sets this flag Signed-off-by: Nishant Sarmukadam <nishants@marvell.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/mwl8k.c')
-rw-r--r--drivers/net/wireless/mwl8k.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/drivers/net/wireless/mwl8k.c b/drivers/net/wireless/mwl8k.c
index ae56d2f32b2e..d5e047970345 100644
--- a/drivers/net/wireless/mwl8k.c
+++ b/drivers/net/wireless/mwl8k.c
@@ -4463,9 +4463,12 @@ static int mwl8k_config(struct ieee80211_hw *hw, u32 changed)
conf->power_level = 18;
if (priv->ap_fw) {
- rc = mwl8k_cmd_tx_power(hw, conf, conf->power_level);
- if (rc)
- goto out;
+
+ if (conf->flags & IEEE80211_CONF_CHANGE_POWER) {
+ rc = mwl8k_cmd_tx_power(hw, conf, conf->power_level);
+ if (rc)
+ goto out;
+ }
rc = mwl8k_cmd_rf_antenna(hw, MWL8K_RF_ANTENNA_RX, 0x3);
if (rc)