From aaba7ade89f72e23b1eab48c7812ff4178dd7f3e Mon Sep 17 00:00:00 2001 From: Ajay Parida Date: Wed, 7 Jun 2023 19:44:28 +0530 Subject: [PATCH] drivers: wifi: Support for forced Passive scan Default scan mode is set as Active scan. User can force passive scan from Kconfig or from shell using 'passive' option. Once set it will override regulatory settings and forces all channels to be passive. Use the scan type param to decide active/passive scan. Signed-off-by: Ajay Parida --- drivers/wifi/nrf700x/zephyr/src/zephyr_wifi_mgmt.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/wifi/nrf700x/zephyr/src/zephyr_wifi_mgmt.c b/drivers/wifi/nrf700x/zephyr/src/zephyr_wifi_mgmt.c index 3f385e40a197..5dc264944ca6 100644 --- a/drivers/wifi/nrf700x/zephyr/src/zephyr_wifi_mgmt.c +++ b/drivers/wifi/nrf700x/zephyr/src/zephyr_wifi_mgmt.c @@ -115,7 +115,7 @@ int wifi_nrf_disp_scan_zep(const struct device *dev, struct wifi_scan_params *pa scan_info.scan_mode = AUTO_SCAN; scan_info.scan_reason = SCAN_DISPLAY; - if (!vif_ctx_zep->passive_scan) { + if (params->scan_type == WIFI_SCAN_TYPE_ACTIVE) { /* Wildcard SSID to trigger active scan */ scan_info.scan_params.num_scan_ssids = 1; }