]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
wifi: iwlwifi: mld: Remove wrong channel flags in scan cmd
authorDaniel Gabay <daniel.gabay@intel.com>
Mon, 10 Nov 2025 13:02:13 +0000 (15:02 +0200)
committerMiri Korenblit <miriam.rachel.korenblit@intel.com>
Wed, 21 Jan 2026 12:23:01 +0000 (14:23 +0200)
Erroneously, the channel flags in the scan command for 6 GHz scan
were mistakenly set using iwl_mld_scan_get_cmd_gen_flags, which
actually calculates a different field (the general flags) in the
command.

However, these flags are not relevant for 6 GHz scan part, except for
IWL_SCAN_CHANNEL_FLAG_6G_PSC_NO_FILTER, which is already set
correctly. Since the incorrect flags are only applied in the
6 GHz scan part and are ignored by the firmware, this has no
adverse effect. Therefore, we can simply remove this helper
function call and explicitly clear the flags.

Signed-off-by: Daniel Gabay <daniel.gabay@intel.com>
Reviewed-by: Ilan Peer <ilan.peer@intel.com>
Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com>
Link: https://patch.msgid.link/20251110150012.a8a931e1abef.I8f7dc66b23198b83083685ef76dec59cfb407f57@changeid
drivers/net/wireless/intel/iwlwifi/mld/scan.c

index fd1022ddc9122be5dcf1f3713b93299b2a2babab..16f48087a888fbe352507910576215374e437a83 100644 (file)
@@ -1063,14 +1063,15 @@ static int
 iwl_mld_scan_cmd_set_6ghz_chan_params(struct iwl_mld *mld,
                                      struct iwl_mld_scan_params *params,
                                      struct ieee80211_vif *vif,
-                                     struct iwl_scan_req_params_v17 *scan_p,
-                                     enum iwl_mld_scan_status scan_status)
+                                     struct iwl_scan_req_params_v17 *scan_p)
 {
        struct iwl_scan_channel_params_v7 *chan_p = &scan_p->channel_params;
        struct iwl_scan_probe_params_v4 *probe_p = &scan_p->probe_params;
 
-       chan_p->flags = iwl_mld_scan_get_cmd_gen_flags(mld, params, vif,
-                                                      scan_status);
+       /* Explicitly clear the flags since most of them are not
+        * relevant for 6 GHz scan.
+        */
+       chan_p->flags = 0;
        chan_p->count = iwl_mld_scan_cfg_channels_6g(mld, params,
                                                     params->n_channels,
                                                     probe_p, chan_p,
@@ -1106,8 +1107,7 @@ iwl_mld_scan_cmd_set_chan_params(struct iwl_mld *mld,
 
        if (params->scan_6ghz)
                return iwl_mld_scan_cmd_set_6ghz_chan_params(mld, params,
-                                                            vif, scan_p,
-                                                            scan_status);
+                                                            vif, scan_p);
 
        /* relevant only for 2.4 GHz/5 GHz scan */
        cp->flags = iwl_mld_scan_cmd_set_chan_flags(mld, params, vif,