diff mbox series

[v3,12/46] PR: Add support to use stored 6GHz capability for PR

Message ID 20260513100010.1947710-13-kavita.kavita@oss.qualcomm.com
State Accepted
Headers show
Series PR: Add nl80211 support and ranging for Proximity Detection | expand

Commit Message

Kavita Kavita May 13, 2026, 9:59 a.m. UTC
From: Peddolla Harshavardhan Reddy <peddolla.reddy@oss.qualcomm.com>

Currently, wpas_pr_init uses a generic function wpas_is_6ghz_supported()
to determine Proximity Ranging (PR) 6 GHz support. This can be inaccurate
as the generic check may be true for reasons unrelated to PR.

Use the stored PMSR capability (capa->support_6ghz) which is parsed from
NL80211_PMSR_FTM_CAPA_ATTR_6GHZ_SUPPORT attribute. This ensures that PR
6GHz capability is determined by its specific PMSR attribute rather than
a generic system setting.

Fixes: f45cc220e4bb ("PR: Update PR device configs and capabilities from driver")
Signed-off-by: Peddolla Harshavardhan Reddy <peddolla.reddy@oss.qualcomm.com>
---
 wpa_supplicant/pr_supplicant.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/wpa_supplicant/pr_supplicant.c b/wpa_supplicant/pr_supplicant.c
index 544656bb3..be5477b44 100644
--- a/wpa_supplicant/pr_supplicant.c
+++ b/wpa_supplicant/pr_supplicant.c
@@ -379,7 +379,7 @@  int wpas_pr_init(struct wpa_global *global, struct wpa_supplicant *wpa_s,
 	pr.pr_max_peer_rsta_role = capa->rsta.max_peers;
 	pr.max_ftms_per_burst = capa->max_ftms_per_burst;
 
-	pr.support_6ghz = wpas_is_6ghz_supported(wpa_s, true);
+	pr.support_6ghz = capa->support_6ghz;
 
 	pr.pasn_send_mgmt = wpas_pr_pasn_send_mgmt;
 	pr.pasn_result = wpas_pr_pasn_result;