Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 150172
b: refs/heads/master
c: 6752ee9
h: refs/heads/master
v: v3
  • Loading branch information
Bob Copeland authored and John W. Linville committed May 6, 2009
1 parent ec83164 commit fe3f89b
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 13 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 57e6c56dbb52d680f61dd629759fe2974840ed93
refs/heads/master: 6752ee90aa7c933294a10dbd9ea51f12dece7eb1
19 changes: 7 additions & 12 deletions trunk/drivers/net/wireless/ath/ath5k/phy.c
Original file line number Diff line number Diff line change
Expand Up @@ -2158,8 +2158,6 @@ ath5k_get_rate_pcal_data(struct ath5k_hw *ah,
* Get the max edge power for this channel if
* we have such data from EEPROM's Conformance Test
* Limits (CTL), and limit max power if needed.
*
* FIXME: Only works for world regulatory domains
*/
static void
ath5k_get_max_ctl_power(struct ath5k_hw *ah,
Expand All @@ -2175,26 +2173,23 @@ ath5k_get_max_ctl_power(struct ath5k_hw *ah,
u8 ctl_idx = 0xFF;
u32 target = channel->center_freq;

/* Find out a CTL for our mode that's not mapped
* on a specific reg domain.
*
* TODO: Map our current reg domain to one of the 3 available
* reg domain ids so that we can support more CTLs. */
ctl_mode = ath_regd_get_band_ctl(&ah->ah_regulatory, channel->band);

switch (channel->hw_value & CHANNEL_MODES) {
case CHANNEL_A:
ctl_mode = AR5K_CTL_11A | AR5K_CTL_NO_REGDOMAIN;
ctl_mode |= AR5K_CTL_11A;
break;
case CHANNEL_G:
ctl_mode = AR5K_CTL_11G | AR5K_CTL_NO_REGDOMAIN;
ctl_mode |= AR5K_CTL_11G;
break;
case CHANNEL_B:
ctl_mode = AR5K_CTL_11B | AR5K_CTL_NO_REGDOMAIN;
ctl_mode |= AR5K_CTL_11B;
break;
case CHANNEL_T:
ctl_mode = AR5K_CTL_TURBO | AR5K_CTL_NO_REGDOMAIN;
ctl_mode |= AR5K_CTL_TURBO;
break;
case CHANNEL_TG:
ctl_mode = AR5K_CTL_TURBOG | AR5K_CTL_NO_REGDOMAIN;
ctl_mode |= AR5K_CTL_TURBOG;
break;
case CHANNEL_XR:
/* Fall through */
Expand Down

0 comments on commit fe3f89b

Please sign in to comment.