All of lore.kernel.org
 help / color / mirror / Atom feed
From: Luca Coelho <luca@coelho.fi>
To: johannes@sipsolutions.net
Cc: luca@coelho.fi, linux-wireless@vger.kernel.org
Subject: [PATCH 04/14] cfg80211: don't add non transmitted BSS to 6GHz scanned channels
Date: Wed,  2 Feb 2022 10:49:37 +0200	[thread overview]
Message-ID: <iwlwifi.20220202104617.f6ddf099f934.I231e55885d3644f292d00dfe0f42653269f2559e@changeid> (raw)
In-Reply-To: <20220202084947.370289-1-luca@coelho.fi>

From: Avraham Stern <avraham.stern@intel.com>

When adding 6GHz channels to scan request based on reported
co-located APs, don't add channels that have only APs with
"non-transmitted" BSSes if they only match the wildcard SSID since
they will be found by probing the "transmitted" BSS.

Signed-off-by: Avraham Stern <avraham.stern@intel.com>
Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
---
 net/wireless/scan.c | 9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)

diff --git a/net/wireless/scan.c b/net/wireless/scan.c
index b888522f133b..b2fdac96bab0 100644
--- a/net/wireless/scan.c
+++ b/net/wireless/scan.c
@@ -700,8 +700,12 @@ static bool cfg80211_find_ssid_match(struct cfg80211_colocated_ap *ap,
 
 	for (i = 0; i < request->n_ssids; i++) {
 		/* wildcard ssid in the scan request */
-		if (!request->ssids[i].ssid_len)
+		if (!request->ssids[i].ssid_len) {
+			if (ap->multi_bss && !ap->transmitted_bssid)
+				continue;
+
 			return true;
+		}
 
 		if (ap->ssid_len &&
 		    ap->ssid_len == request->ssids[i].ssid_len) {
@@ -827,6 +831,9 @@ static int cfg80211_scan_6ghz(struct cfg80211_registered_device *rdev)
 		    !cfg80211_find_ssid_match(ap, request))
 			continue;
 
+		if (!request->n_ssids && ap->multi_bss && !ap->transmitted_bssid)
+			continue;
+
 		cfg80211_scan_req_add_chan(request, chan, true);
 		memcpy(scan_6ghz_params->bssid, ap->bssid, ETH_ALEN);
 		scan_6ghz_params->short_ssid = ap->short_ssid;
-- 
2.34.1


  parent reply	other threads:[~2022-02-02  8:50 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-02-02  8:49 [PATCH 00/14] cfg80211/mac80211 patches from our internal tree 2022-02-02 Luca Coelho
2022-02-02  8:49 ` [PATCH 01/14] mac80211: limit bandwidth in HE capabilities Luca Coelho
2022-02-02  8:49 ` [PATCH 02/14] mac80211: consider RX NSS in UHB connection Luca Coelho
2022-02-02  8:49 ` [PATCH 03/14] cfg80211/mac80211: assume CHECKSUM_COMPLETE includes SNAP Luca Coelho
2022-02-02  8:49 ` Luca Coelho [this message]
2022-02-02  8:49 ` [PATCH 05/14] ieee80211: fix -Wcast-qual warnings Luca Coelho
2022-02-02  8:49 ` [PATCH 06/14] cfg80211: " Luca Coelho
2022-02-02  8:49 ` [PATCH 07/14] ieee80211: radiotap: " Luca Coelho
2022-02-02  8:49 ` [PATCH 08/14] mac80211: vht: use HE macros for parsing HE capabilities Luca Coelho
2022-02-02  8:49 ` [PATCH 09/14] mac80211: mlme: add documentation from spec to code Luca Coelho
2022-02-08 22:45   ` Jeff Johnson
2022-02-02  8:49 ` [PATCH 10/14] mac80211: airtime: avoid variable shadowing Luca Coelho
2022-02-02  8:49 ` [PATCH 11/14] cfg80211: pmsr: remove useless ifdef guards Luca Coelho
2022-02-02  8:49 ` [PATCH 12/14] mac80211: remove unused macros Luca Coelho
2022-02-02  8:49 ` [PATCH 13/14] mac80211: mlme: validate peer HE supported rates Luca Coelho
2022-02-02  8:49 ` [PATCH 14/14] mac80211: fix struct ieee80211_tx_info size Luca Coelho

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=iwlwifi.20220202104617.f6ddf099f934.I231e55885d3644f292d00dfe0f42653269f2559e@changeid \
    --to=luca@coelho.fi \
    --cc=johannes@sipsolutions.net \
    --cc=linux-wireless@vger.kernel.org \
    /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.