diff options
author | Johannes Berg <johannes.berg@intel.com> | 2012-05-21 06:56:31 -0400 |
---|---|---|
committer | Johannes Berg <johannes.berg@intel.com> | 2012-06-06 07:09:51 -0400 |
commit | 20041ea622fcb1992df536d253de5120808e64a5 (patch) | |
tree | dd8eb0585793ce58d3d0d630e7e4d98048e90ce7 /drivers/net/wireless/iwlwifi/iwl-agn-sta.c | |
parent | 6468a01a7181f3572a3e686910016f89ee71ff45 (diff) |
iwlwifi: trust mac80211 HT40 setting
When mac80211 asks us to do HT40, it'll not do so
on a channel that we marked as not having HT40+/-
with IEEE80211_CHAN_NO_HT40PLUS (or MINUS). Thus,
there's no need to verify it again in the driver.
Reviewed-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'drivers/net/wireless/iwlwifi/iwl-agn-sta.c')
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-agn-sta.c | 24 |
1 files changed, 1 insertions, 23 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl-agn-sta.c b/drivers/net/wireless/iwlwifi/iwl-agn-sta.c index 36055ed1c069..01fbf06980c8 100644 --- a/drivers/net/wireless/iwlwifi/iwl-agn-sta.c +++ b/drivers/net/wireless/iwlwifi/iwl-agn-sta.c | |||
@@ -171,26 +171,6 @@ int iwl_send_add_sta(struct iwl_priv *priv, | |||
171 | return cmd.handler_status; | 171 | return cmd.handler_status; |
172 | } | 172 | } |
173 | 173 | ||
174 | static bool iwl_is_channel_extension(struct iwl_priv *priv, | ||
175 | enum ieee80211_band band, | ||
176 | u16 channel, u8 extension_chan_offset) | ||
177 | { | ||
178 | const struct iwl_channel_info *ch_info; | ||
179 | |||
180 | ch_info = iwl_get_channel_info(priv, band, channel); | ||
181 | if (!is_channel_valid(ch_info)) | ||
182 | return false; | ||
183 | |||
184 | if (extension_chan_offset == IEEE80211_HT_PARAM_CHA_SEC_ABOVE) | ||
185 | return !(ch_info->ht40_extension_channel & | ||
186 | IEEE80211_CHAN_NO_HT40PLUS); | ||
187 | else if (extension_chan_offset == IEEE80211_HT_PARAM_CHA_SEC_BELOW) | ||
188 | return !(ch_info->ht40_extension_channel & | ||
189 | IEEE80211_CHAN_NO_HT40MINUS); | ||
190 | |||
191 | return false; | ||
192 | } | ||
193 | |||
194 | bool iwl_is_ht40_tx_allowed(struct iwl_priv *priv, | 174 | bool iwl_is_ht40_tx_allowed(struct iwl_priv *priv, |
195 | struct iwl_rxon_context *ctx, | 175 | struct iwl_rxon_context *ctx, |
196 | struct ieee80211_sta_ht_cap *ht_cap) | 176 | struct ieee80211_sta_ht_cap *ht_cap) |
@@ -210,9 +190,7 @@ bool iwl_is_ht40_tx_allowed(struct iwl_priv *priv, | |||
210 | return false; | 190 | return false; |
211 | #endif | 191 | #endif |
212 | 192 | ||
213 | return iwl_is_channel_extension(priv, priv->band, | 193 | return true; |
214 | le16_to_cpu(ctx->staging.channel), | ||
215 | ctx->ht.extension_chan_offset); | ||
216 | } | 194 | } |
217 | 195 | ||
218 | static void iwl_sta_calc_ht_flags(struct iwl_priv *priv, | 196 | static void iwl_sta_calc_ht_flags(struct iwl_priv *priv, |