aboutsummaryrefslogtreecommitdiffstats
path: root/net/wireless/chan.c
diff options
context:
space:
mode:
authorIlan Peer <ilan.peer@intel.com>2014-04-23 09:22:58 +0300
committerJohannes Berg <johannes.berg@intel.com>2014-04-25 16:47:33 +0200
commit46d537245d8db96a4c282b449f8b582a71e5ec13 (patch)
tree3c3517409796cdbe24ae1541c9c8e63de8b03148 /net/wireless/chan.c
parentmac80211: mesh: always use the latest target_sn (diff)
downloadlinux-dev-46d537245d8db96a4c282b449f8b582a71e5ec13.tar.xz
linux-dev-46d537245d8db96a4c282b449f8b582a71e5ec13.zip
cfg80211: Fix GO Concurrent relaxation on UNII-3
At some locations, channels 149-165 are considered a single bundle, while at some other locations, e.g., Indonesia, channels 149-161 are considered a single bundle, while channel 165 belongs to a different bundle. This means that: 1. A station interface connection to an AP on channel 165 allows the instantiation of a P2P GO on channels 149-165. 2. A station interface connection to an AP on channels 149-161 does NOT allow the instantiation of a P2P GO on channel 165. Fix this. Signed-off-by: Ilan Peer <ilan.peer@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'net/wireless/chan.c')
-rw-r--r--net/wireless/chan.c18
1 files changed, 17 insertions, 1 deletions
diff --git a/net/wireless/chan.c b/net/wireless/chan.c
index c61bcdd3dfbc..fb8f6a3c9ec5 100644
--- a/net/wireless/chan.c
+++ b/net/wireless/chan.c
@@ -750,8 +750,24 @@ static bool cfg80211_go_permissive_chan(struct cfg80211_registered_device *rdev,
r1 = cfg80211_get_unii(chan->center_freq);
r2 = cfg80211_get_unii(other_chan->center_freq);
- if (r1 != -EINVAL && r1 == r2)
+ if (r1 != -EINVAL && r1 == r2) {
+ /*
+ * At some locations channels 149-165 are considered a
+ * bundle, but at other locations, e.g., Indonesia,
+ * channels 149-161 are considered a bundle while
+ * channel 165 is left out and considered to be in a
+ * different bundle. Thus, in case that there is a
+ * station interface connected to an AP on channel 165,
+ * it is assumed that channels 149-161 are allowed for
+ * GO operations. However, having a station interface
+ * connected to an AP on channels 149-161, does not
+ * allow GO operation on channel 165.
+ */
+ if (chan->center_freq == 5825 &&
+ other_chan->center_freq != 5825)
+ continue;
return true;
+ }
}
return false;