aboutsummaryrefslogtreecommitdiff
path: root/drivers/net/wireless/bcm43xx/bcm43xx_phy.c
diff options
context:
space:
mode:
authorMichael Buesch <mbuesch@freenet.de>2006-02-05 15:28:20 +0100
committerJohn W. Linville <linville@tuxdriver.com>2006-03-27 11:18:30 -0500
commit393344f67b598aaed594b9006e9eaa44ab62caa0 (patch)
tree1662df544434f228eb2d728d2a0c43722a4bff11 /drivers/net/wireless/bcm43xx/bcm43xx_phy.c
parent67093a65c08dc45374f642b1ec1b86e7095a4dc8 (diff)
[PATCH] bcm43xx: fix txpower reporting in WE.
Signed-off-by: Michael Buesch <mbuesch@freenet.de> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/bcm43xx/bcm43xx_phy.c')
-rw-r--r--drivers/net/wireless/bcm43xx/bcm43xx_phy.c9
1 files changed, 2 insertions, 7 deletions
diff --git a/drivers/net/wireless/bcm43xx/bcm43xx_phy.c b/drivers/net/wireless/bcm43xx/bcm43xx_phy.c
index d90f207b247..d3c2fc1df37 100644
--- a/drivers/net/wireless/bcm43xx/bcm43xx_phy.c
+++ b/drivers/net/wireless/bcm43xx/bcm43xx_phy.c
@@ -1768,14 +1768,9 @@ void bcm43xx_phy_xmitpower(struct bcm43xx_private *bcm)
where REG is the max power as per the regulatory domain
*/
- /*TODO: Get desired_pwr from wx_handlers or the stack
- limit_value(desired_pwr, 0, max_pwr);
- */
-
- desired_pwr = max_pwr; /* remove this when we have a real desired_pwr */
-
+ desired_pwr = limit_value(radio->txpower_desired, 0, max_pwr);
+ /* Check if we need to adjust the current power. */
pwr_adjust = desired_pwr - estimated_pwr;
-
radio_att_delta = -(pwr_adjust + 7) >> 3;
baseband_att_delta = -(pwr_adjust >> 1) - (4 * radio_att_delta);
if ((radio_att_delta == 0) && (baseband_att_delta == 0)) {