]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
iwlwifi: mvm: cancel the scan delayed work when scan is aborted
authorEmmanuel Grumbach <emmanuel.grumbach@intel.com>
Fri, 5 Feb 2021 09:06:39 +0000 (11:06 +0200)
committerLuca Coelho <luciano.coelho@intel.com>
Fri, 5 Feb 2021 09:56:45 +0000 (11:56 +0200)
When we abort the scan because of a firmware crash, we
need to cancel the delayed work that monitors the scan
completion. Otherwise it'll kick and try to restart the
firmware yet another time.

Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
Link: https://lore.kernel.org/r/iwlwifi.20210205110447.a497faa942dd.Ibc155ad36da9de7eb0ddcdd826ddf8dd6607d2ac@changeid
Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
drivers/net/wireless/intel/iwlwifi/mvm/scan.c

index e89f4f1e44c6301ca1b4210a85c7fea1662f00d8..42e790ed8caa617b988178473e91b817f0618573 100644 (file)
@@ -2854,6 +2854,8 @@ void iwl_mvm_report_scan_aborted(struct iwl_mvm *mvm)
                                .aborted = true,
                        };
 
+                       cancel_delayed_work(&mvm->scan_timeout_dwork);
+
                        ieee80211_scan_completed(mvm->hw, &info);
                        mvm->scan_uid_status[uid] = 0;
                }
@@ -2894,6 +2896,7 @@ void iwl_mvm_report_scan_aborted(struct iwl_mvm *mvm)
                                .aborted = true,
                        };
 
+                       cancel_delayed_work(&mvm->scan_timeout_dwork);
                        ieee80211_scan_completed(mvm->hw, &info);
                }