aboutsummaryrefslogtreecommitdiffstats
path: root/net/mac80211/mlme.c
diff options
context:
space:
mode:
authorJohannes Berg <johannes.berg@intel.com>2012-05-30 09:57:00 -0400
committerJohn W. Linville <linville@tuxdriver.com>2012-06-06 15:19:01 -0400
commit1c4cb928e1b7c6ad30a9b7d3e720f26156d92925 (patch)
tree1cc99e416edf41ea8bba5ea71cbc1a2188ac837e /net/mac80211/mlme.c
parenta8ce85442e8ed7ae3c05e7e3b7e42adb32a371ec (diff)
mac80211: print info when disabling HT
Make mac80211 print a message when it disables HT due to the connection using WEP/TKIP or due to the AP not supporting WMM/QoS. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'net/mac80211/mlme.c')
-rw-r--r--net/mac80211/mlme.c13
1 files changed, 10 insertions, 3 deletions
diff --git a/net/mac80211/mlme.c b/net/mac80211/mlme.c
index da6bd81fec6d..e7c4ec4ce166 100644
--- a/net/mac80211/mlme.c
+++ b/net/mac80211/mlme.c
@@ -3317,11 +3317,15 @@ int ieee80211_mgd_assoc(struct ieee80211_sub_if_data *sdata,
3317 * We can set this to true for non-11n hardware, that'll be checked 3317 * We can set this to true for non-11n hardware, that'll be checked
3318 * separately along with the peer capabilities. 3318 * separately along with the peer capabilities.
3319 */ 3319 */
3320 for (i = 0; i < req->crypto.n_ciphers_pairwise; i++) 3320 for (i = 0; i < req->crypto.n_ciphers_pairwise; i++) {
3321 if (req->crypto.ciphers_pairwise[i] == WLAN_CIPHER_SUITE_WEP40 || 3321 if (req->crypto.ciphers_pairwise[i] == WLAN_CIPHER_SUITE_WEP40 ||
3322 req->crypto.ciphers_pairwise[i] == WLAN_CIPHER_SUITE_TKIP || 3322 req->crypto.ciphers_pairwise[i] == WLAN_CIPHER_SUITE_TKIP ||
3323 req->crypto.ciphers_pairwise[i] == WLAN_CIPHER_SUITE_WEP104) 3323 req->crypto.ciphers_pairwise[i] == WLAN_CIPHER_SUITE_WEP104) {
3324 ifmgd->flags |= IEEE80211_STA_DISABLE_11N; 3324 ifmgd->flags |= IEEE80211_STA_DISABLE_11N;
3325 netdev_info(sdata->dev,
3326 "disabling HT due to WEP/TKIP use\n");
3327 }
3328 }
3325 3329
3326 if (req->flags & ASSOC_REQ_DISABLE_HT) 3330 if (req->flags & ASSOC_REQ_DISABLE_HT)
3327 ifmgd->flags |= IEEE80211_STA_DISABLE_11N; 3331 ifmgd->flags |= IEEE80211_STA_DISABLE_11N;
@@ -3329,8 +3333,11 @@ int ieee80211_mgd_assoc(struct ieee80211_sub_if_data *sdata,
3329 /* Also disable HT if we don't support it or the AP doesn't use WMM */ 3333 /* Also disable HT if we don't support it or the AP doesn't use WMM */
3330 sband = local->hw.wiphy->bands[req->bss->channel->band]; 3334 sband = local->hw.wiphy->bands[req->bss->channel->band];
3331 if (!sband->ht_cap.ht_supported || 3335 if (!sband->ht_cap.ht_supported ||
3332 local->hw.queues < IEEE80211_NUM_ACS || !bss->wmm_used) 3336 local->hw.queues < IEEE80211_NUM_ACS || !bss->wmm_used) {
3333 ifmgd->flags |= IEEE80211_STA_DISABLE_11N; 3337 ifmgd->flags |= IEEE80211_STA_DISABLE_11N;
3338 netdev_info(sdata->dev,
3339 "disabling HT as WMM/QoS is not supported\n");
3340 }
3334 3341
3335 memcpy(&ifmgd->ht_capa, &req->ht_capa, sizeof(ifmgd->ht_capa)); 3342 memcpy(&ifmgd->ht_capa, &req->ht_capa, sizeof(ifmgd->ht_capa));
3336 memcpy(&ifmgd->ht_capa_mask, &req->ht_capa_mask, 3343 memcpy(&ifmgd->ht_capa_mask, &req->ht_capa_mask,