]> git.ipfire.org Git - thirdparty/linux.git/commitdiff
wifi: iwlwifi: mld: fix NAN max channel switch time unit
authorIsrael Kozitz <israel.kozitz@intel.com>
Sun, 10 May 2026 20:48:39 +0000 (23:48 +0300)
committerMiri Korenblit <miriam.rachel.korenblit@intel.com>
Tue, 26 May 2026 12:17:09 +0000 (15:17 +0300)
The max_channel_switch_time in wiphy_nan_capa is in microseconds, but
the value was set to 4, which is only 4 microseconds instead of the
intended 4 milliseconds.

Fix by using 4 * USEC_PER_MSEC.

Signed-off-by: Israel Kozitz <israel.kozitz@intel.com>
Reviewed-by: Ilan Peer <ilan.peer@intel.com>
Link: https://patch.msgid.link/20260510234534.cb3c05e5d334.I89d9f336aaf388c6e48769de5fe1e5db19295057@changeid
Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com>
drivers/net/wireless/intel/iwlwifi/mld/mac80211.c

index cad10f01107255aac7f5c195a9c43caacd28143f..49c75d4ee9a61db2800a0f773d53b261435eba54 100644 (file)
@@ -298,7 +298,7 @@ static void iwl_mld_hw_set_nan(struct iwl_mld *mld)
                 NAN_DEV_CAPA_NUM_RX_ANT_MASK);
 
        /* Maximal channel switch time is 4 msec */
-       hw->wiphy->nan_capa.max_channel_switch_time = 4;
+       hw->wiphy->nan_capa.max_channel_switch_time = 4 * USEC_PER_MSEC;
 
        hw->wiphy->nan_capa.phy.ht = mld->nvm_data->nan_phy_capa.ht;
        hw->wiphy->nan_capa.phy.vht = mld->nvm_data->nan_phy_capa.vht;