Re: [PATCH v3 2/4] scan: Add a configuration option to disable 6GHz collocated scanning

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 4/10/22 12:51 AM, Ilan Peer wrote:
This configuration option can be used to disable 6GHz collocated scan
logic which would result with passively scanning 6GHz non PSC channels.

It would be nice if you could add the example config option to wpa_supplicant.conf
with appropriate comments about acceptable values and what it means.

Otherwise, a user has to get lucky reading code to even know the option is
available.

Also, even if this fixes the ax210 5.18 patch that causes the regression
(and I have not yet had time to test this), then you should probably revert
that ax210 patch so that it works with older supplicants?  It often takes a long
time to get supplicant updated in standard OS distributions.

Thanks,
Ben


Signed-off-by: Ilan Peer <ilan.peer@xxxxxxxxx>
---
  wpa_supplicant/config.c         | 1 +
  wpa_supplicant/config.h         | 9 +++++++++
  wpa_supplicant/config_file.c    | 2 ++
  wpa_supplicant/p2p_supplicant.c | 1 +
  wpa_supplicant/scan.c           | 7 +++++++
  5 files changed, 20 insertions(+)

diff --git a/wpa_supplicant/config.c b/wpa_supplicant/config.c
index 58ed8bc0ae..5b9c9ed7df 100644
--- a/wpa_supplicant/config.c
+++ b/wpa_supplicant/config.c
@@ -5265,6 +5265,7 @@ static const struct global_parse_data global_fields[] = {
  	{ INT_RANGE(pasn_corrupt_mic, 0, 1), 0 },
  #endif /* CONFIG_TESTING_OPTIONS */
  #endif /* CONFIG_PASN */
+	{ INT(non_coloc_6ghz), 0 },
  };
#undef FUNC
diff --git a/wpa_supplicant/config.h b/wpa_supplicant/config.h
index d22ef05fb8..721e214953 100644
--- a/wpa_supplicant/config.h
+++ b/wpa_supplicant/config.h
@@ -1699,6 +1699,15 @@ struct wpa_config {
#endif /* CONFIG_TESTING_OPTIONS */
  #endif /* CONFIG_PASN*/
+
+	/**
+	 * non_coloc_6ghz - Whether to follow 6GHz collocated scan logic or not
+	 *
+	 * This parameter can be used to disable collocated 6GHz scan logic,
+	 * resulting with passively scanning non PSC channels. By default, 6GHz
+	 * collocated scan logic is enabled.
+	 */
+	int non_coloc_6ghz;
  };
diff --git a/wpa_supplicant/config_file.c b/wpa_supplicant/config_file.c
index 2dd586391e..9641656b14 100644
--- a/wpa_supplicant/config_file.c
+++ b/wpa_supplicant/config_file.c
@@ -1559,6 +1559,8 @@ static void wpa_config_write_global(FILE *f, struct wpa_config *config)
  	if (config->wowlan_disconnect_on_deinit)
  		fprintf(f, "wowlan_disconnect_on_deinit=%d\n",
  			config->wowlan_disconnect_on_deinit);
+	if (config->non_coloc_6ghz)
+		fprintf(f, "non_coloc_6ghz=%d\n", config->non_coloc_6ghz);
  }
#endif /* CONFIG_NO_CONFIG_WRITE */
diff --git a/wpa_supplicant/p2p_supplicant.c b/wpa_supplicant/p2p_supplicant.c
index a996b436b4..80ef2a9e4d 100644
--- a/wpa_supplicant/p2p_supplicant.c
+++ b/wpa_supplicant/p2p_supplicant.c
@@ -2188,6 +2188,7 @@ do {                                    \
  	d->go_venue_group = s->go_venue_group;
  	d->go_venue_type = s->go_venue_type;
  	d->p2p_add_cli_chan = s->p2p_add_cli_chan;
+	d->non_coloc_6ghz = s->non_coloc_6ghz;
  }
diff --git a/wpa_supplicant/scan.c b/wpa_supplicant/scan.c
index 31b694713b..d7c73883e9 100644
--- a/wpa_supplicant/scan.c
+++ b/wpa_supplicant/scan.c
@@ -1328,6 +1328,13 @@ ssid_list_set:
  		}
  	}
+ if (!params.non_coloc_6ghz && wpa_s->conf->non_coloc_6ghz) {
+		wpa_dbg(wpa_s, MSG_DEBUG,
+			"Collocated 6GHz logic is disabled in configuration");
+
+		params.non_coloc_6ghz = 1;
+	}
+
  	scan_params = &params;
scan:



--
Ben Greear <greearb@xxxxxxxxxxxxxxx>
Candela Technologies Inc  http://www.candelatech.com

_______________________________________________
Hostap mailing list
Hostap@xxxxxxxxxxxxxxxxxxx
http://lists.infradead.org/mailman/listinfo/hostap



[Index of Archives]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]

  Powered by Linux