brcm80211: fix usage of set tx power
authorLuis R. Rodriguez <mcgrof@qca.qualcomm.com>
Mon, 28 Nov 2011 21:38:48 +0000 (16:38 -0500)
committerJohn W. Linville <linville@tuxdriver.com>
Wed, 30 Nov 2011 20:08:28 +0000 (15:08 -0500)
mBm is passed but dBm was assumed...

Signed-off-by: Luis R. Rodriguez <mcgrof@qca.qualcomm.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/brcm80211/brcmfmac/wl_cfg80211.c

index cc19a73..fc98981 100644 (file)
@@ -1429,7 +1429,7 @@ brcmf_cfg80211_disconnect(struct wiphy *wiphy, struct net_device *ndev,
 
 static s32
 brcmf_cfg80211_set_tx_power(struct wiphy *wiphy,
-                        enum nl80211_tx_power_setting type, s32 dbm)
+                           enum nl80211_tx_power_setting type, s32 mbm)
 {
 
        struct brcmf_cfg80211_priv *cfg_priv = wiphy_to_cfg(wiphy);
@@ -1437,6 +1437,7 @@ brcmf_cfg80211_set_tx_power(struct wiphy *wiphy,
        u16 txpwrmw;
        s32 err = 0;
        s32 disable = 0;
+       s32 dbm = MBM_TO_DBM(mbm);
 
        WL_TRACE("Enter\n");
        if (!check_sys_up(wiphy))