ath6kl: Fix scan related issue on suspend-resume
authorVivek Natarajan <nataraja@qca.qualcomm.com>
Wed, 28 Mar 2012 13:51:26 +0000 (19:21 +0530)
committerKalle Valo <kvalo@qca.qualcomm.com>
Tue, 3 Apr 2012 18:26:01 +0000 (21:26 +0300)
When a scan request is pending while going to suspend, any new
scan request after resume will fail. So, cancel all scan requests
in all the vifs before moving to suspend state.

Signed-off-by: PingYang Zhang <pingzhan@qca.qualcomm.com>
Signed-off-by: Vivek Natarajan <nataraja@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
drivers/net/wireless/ath/ath6kl/cfg80211.c

index 0c49708..1272508 100644 (file)
@@ -2220,6 +2220,7 @@ int ath6kl_cfg80211_suspend(struct ath6kl *ar,
                            enum ath6kl_cfg_suspend_mode mode,
                            struct cfg80211_wowlan *wow)
 {
+       struct ath6kl_vif *vif;
        enum ath6kl_state prev_state;
        int ret;
 
@@ -2289,6 +2290,9 @@ int ath6kl_cfg80211_suspend(struct ath6kl *ar,
                break;
        }
 
+       list_for_each_entry(vif, &ar->vif_list, list)
+               ath6kl_cfg80211_scan_complete_event(vif, true);
+
        return 0;
 }
 EXPORT_SYMBOL(ath6kl_cfg80211_suspend);