Commit 2eb2fa67 authored by Bob Copeland's avatar Bob Copeland Committed by John W. Linville
Browse files

ath5k: allow setting txpower to 0

As a holdover from earlier code when we used to set
the power limit to '0' after a reset to configure the
default transmit power, ath5k interprets txpower=0 as
12.5 dBm.  Fix that by just passing 0 through.

This fixes

Reported-by: default avatarDaniel Folkers <>
Tested-by: default avatarDaniel Folkers <>
Signed-off-by: default avatarBob Copeland <>
Signed-off-by: default avatarJohn W. Linville <>
parent 634a555c
......@@ -3025,8 +3025,6 @@ ath5k_hw_txpower(struct ath5k_hw *ah, struct ieee80211_channel *channel,
ATH5K_ERR(ah->ah_sc, "invalid tx power: %u\n", txpower);
return -EINVAL;
if (txpower == 0)
/* Reset TX power values */
memset(&ah->ah_txpower, 0, sizeof(ah->ah_txpower));
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment