Skip to content

Commit

Permalink
iwlwifi: disable FAT channel when not permitted
Browse files Browse the repository at this point in the history
This patch disables FAT channel when it is not permitted according to
the EEPROM.

Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
  • Loading branch information
Emmanuel Grumbach authored and John W. Linville committed Jun 3, 2008
1 parent 9306102 commit 4d38c2e
Showing 1 changed file with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions drivers/net/wireless/iwlwifi/iwl-core.c
Original file line number Diff line number Diff line change
Expand Up @@ -486,6 +486,25 @@ static int iwlcore_init_geos(struct iwl_priv *priv)
if (ch->flags & EEPROM_CHANNEL_RADAR)
geo_ch->flags |= IEEE80211_CHAN_RADAR;

switch (ch->fat_extension_channel) {
case HT_IE_EXT_CHANNEL_ABOVE:
/* only above is allowed, disable below */
geo_ch->flags |= IEEE80211_CHAN_NO_FAT_BELOW;
break;
case HT_IE_EXT_CHANNEL_BELOW:
/* only below is allowed, disable above */
geo_ch->flags |= IEEE80211_CHAN_NO_FAT_ABOVE;
break;
case HT_IE_EXT_CHANNEL_NONE:
/* fat not allowed: disable both*/
geo_ch->flags |= (IEEE80211_CHAN_NO_FAT_ABOVE |
IEEE80211_CHAN_NO_FAT_BELOW);
break;
case HT_IE_EXT_CHANNEL_MAX:
/* both above and below are permitted */
break;
}

if (ch->max_power_avg > priv->max_channel_txpower_limit)
priv->max_channel_txpower_limit =
ch->max_power_avg;
Expand Down

0 comments on commit 4d38c2e

Please sign in to comment.