diff mbox series

[12/15] iwlwifi: mvm: advertise support for protected ranging negotiation

Message ID 20240204235836.608a307e4dd0.I578af1c9836e91069ce318b265bd221f42955992@changeid
State Superseded
Headers show
Series wifi: iwlwifi: updates - 2024-02-05 | expand

Commit Message

Miri Korenblit Feb. 4, 2024, 10:06 p.m. UTC
From: Avraham Stern <avraham.stern@intel.com>

Advertise support for protected ranging negotiation if the firmware
supports it.

Signed-off-by: Avraham Stern <avraham.stern@intel.com>
Reviewed-by: Luciano Coelho <luciano.coelho@intel.com>
Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com>
---
 drivers/net/wireless/intel/iwlwifi/mvm/mac80211.c | 7 +++++++
 1 file changed, 7 insertions(+)

Comments

Kalle Valo Feb. 6, 2024, 10:18 a.m. UTC | #1
Miri Korenblit <miriam.rachel.korenblit@intel.com> writes:

> From: Avraham Stern <avraham.stern@intel.com>
>
> Advertise support for protected ranging negotiation if the firmware
> supports it.
>
> Signed-off-by: Avraham Stern <avraham.stern@intel.com>
> Reviewed-by: Luciano Coelho <luciano.coelho@intel.com>
> Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com>

"wifi:" prefix missing.
diff mbox series

Patch

diff --git a/drivers/net/wireless/intel/iwlwifi/mvm/mac80211.c b/drivers/net/wireless/intel/iwlwifi/mvm/mac80211.c
index bc8d1760f36c..e62fcfd1a65f 100644
--- a/drivers/net/wireless/intel/iwlwifi/mvm/mac80211.c
+++ b/drivers/net/wireless/intel/iwlwifi/mvm/mac80211.c
@@ -705,6 +705,13 @@  int iwl_mvm_mac_setup_register(struct iwl_mvm *mvm)
 		}
 	}
 
+	if (iwl_fw_lookup_cmd_ver(mvm->fw, WIDE_ID(LOCATION_GROUP,
+						   TOF_RANGE_REQ_CMD),
+				  IWL_FW_CMD_VER_UNKNOWN) >= 11) {
+		wiphy_ext_feature_set(hw->wiphy,
+				      NL80211_EXT_FEATURE_PROT_RANGE_NEGO_AND_MEASURE);
+	}
+
 	mvm->rts_threshold = IEEE80211_MAX_RTS_THRESHOLD;
 
 #ifdef CONFIG_PM_SLEEP