From: "Luis R. Rodriguez" <lrodriguez@atheros.com>
To: linville@tuxdriver.com, johannes@sipsolutions.net
To: johannes@sipsolutions.net, linville@tuxdriver.com
Cc: linux-wireless@vger.kernel.org,
"Luis R. Rodriguez" <lrodriguez@atheros.com>
Subject: [PATCH v4 3/6] mac80211: check if HT40+/- is allowed before sending assoc
Date: Thu, 19 Mar 2009 02:41:26 -0400 [thread overview]
Message-ID: <1237444886-24530-1-git-send-email-lrodriguez@atheros.com> (raw)
We weren't checking this at all.
Signed-off-by: Luis R. Rodriguez <lrodriguez@atheros.com>
---
Another mistake on my part, caught by sujith -- we were disabling HT
completley if NOHT40 was set, we now stick to HT20 when HT40 is not
set.
net/mac80211/ht.c | 11 ++++++++---
1 files changed, 8 insertions(+), 3 deletions(-)
diff --git a/net/mac80211/ht.c b/net/mac80211/ht.c
index 4e3c72f..9c4faa4 100644
--- a/net/mac80211/ht.c
+++ b/net/mac80211/ht.c
@@ -119,13 +119,18 @@ u32 ieee80211_enable_ht(struct ieee80211_sub_if_data *sdata,
if (!(ap_ht_cap_flags & IEEE80211_HT_CAP_40MHZ_INTOLERANT) &&
(sband->ht_cap.cap & IEEE80211_HT_CAP_SUP_WIDTH_20_40) &&
- (hti->ht_param & IEEE80211_HT_PARAM_CHAN_WIDTH_ANY)) {
+ (hti->ht_param & IEEE80211_HT_PARAM_CHAN_WIDTH_ANY) &&
+ !(local->hw.conf.channel->flags & IEEE80211_CHAN_NO_HT40)) {
switch(hti->ht_param & IEEE80211_HT_PARAM_CHA_SEC_OFFSET) {
case IEEE80211_HT_PARAM_CHA_SEC_ABOVE:
- channel_type = NL80211_CHAN_HT40PLUS;
+ if (!(local->hw.conf.channel->flags &
+ IEEE80211_CHAN_NO_HT40PLUS))
+ channel_type = NL80211_CHAN_HT40PLUS;
break;
case IEEE80211_HT_PARAM_CHA_SEC_BELOW:
- channel_type = NL80211_CHAN_HT40MINUS;
+ if (!(local->hw.conf.channel->flags &
+ IEEE80211_CHAN_NO_HT40MINUS))
+ channel_type = NL80211_CHAN_HT40MINUS;
break;
}
}
--
1.5.6.4
next reply other threads:[~2009-03-19 6:41 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-03-19 6:41 Luis R. Rodriguez [this message]
2009-03-20 10:48 ` [PATCH v4 3/6] mac80211: check if HT40+/- is allowed before sending assoc Johannes Berg
2009-03-20 14:29 ` Luis R. Rodriguez
2009-03-21 8:02 ` Johannes Berg
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1237444886-24530-1-git-send-email-lrodriguez@atheros.com \
--to=lrodriguez@atheros.com \
--cc=johannes@sipsolutions.net \
--cc=linux-wireless@vger.kernel.org \
--cc=linville@tuxdriver.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.