|
@@ -508,6 +508,7 @@ static void iwl_bg_scan_completed(struct work_struct *work)
|
|
struct iwl_priv *priv =
|
|
struct iwl_priv *priv =
|
|
container_of(work, struct iwl_priv, scan_completed);
|
|
container_of(work, struct iwl_priv, scan_completed);
|
|
bool internal = false;
|
|
bool internal = false;
|
|
|
|
+ bool scan_completed = false;
|
|
|
|
|
|
IWL_DEBUG_SCAN(priv, "SCAN complete scan\n");
|
|
IWL_DEBUG_SCAN(priv, "SCAN complete scan\n");
|
|
|
|
|
|
@@ -518,7 +519,8 @@ static void iwl_bg_scan_completed(struct work_struct *work)
|
|
priv->is_internal_short_scan = false;
|
|
priv->is_internal_short_scan = false;
|
|
IWL_DEBUG_SCAN(priv, "internal short scan completed\n");
|
|
IWL_DEBUG_SCAN(priv, "internal short scan completed\n");
|
|
internal = true;
|
|
internal = true;
|
|
- } else {
|
|
|
|
|
|
+ } else if (priv->scan_request) {
|
|
|
|
+ scan_completed = true;
|
|
priv->scan_request = NULL;
|
|
priv->scan_request = NULL;
|
|
priv->scan_vif = NULL;
|
|
priv->scan_vif = NULL;
|
|
}
|
|
}
|
|
@@ -549,7 +551,7 @@ static void iwl_bg_scan_completed(struct work_struct *work)
|
|
* into driver again into functions that will attempt to take
|
|
* into driver again into functions that will attempt to take
|
|
* mutex.
|
|
* mutex.
|
|
*/
|
|
*/
|
|
- if (!internal)
|
|
|
|
|
|
+ if (scan_completed)
|
|
ieee80211_scan_completed(priv->hw, false);
|
|
ieee80211_scan_completed(priv->hw, false);
|
|
}
|
|
}
|
|
|
|
|