]> git.kernelconcepts.de Git - karo-tx-linux.git/commitdiff
mac80211: don't tear down aggregation on suspend in case of wowlan->any
authorEliad Peller <eliadx.peller@intel.com>
Mon, 21 Sep 2015 12:50:26 +0000 (15:50 +0300)
committerJohannes Berg <johannes.berg@intel.com>
Tue, 29 Sep 2015 13:56:47 +0000 (15:56 +0200)
In case of "any" wowlan trigger, there is no reason to tear down
aggregations, as we want the device to continue working normally.

Similarly, there's no reason to tear down aggregations on resume,
as they should have been torn down on suspend if needed.
However, since the reconfiguration flow is shared with HW restart,
tear down aggregations on reconfiguration when we are not resuming.

To keep things working after non-wowlan suspend, keep clearing the
WLAN_STA_BLOCK_BA flag.

Signed-off-by: Eliad Peller <eliadx.peller@intel.com>
Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
net/mac80211/pm.c
net/mac80211/util.c

index b676b9fa707b3c8872a1065d8582b8ff1463e607..ad88ad4e8eb1370d321931536f166d298e645dd8 100644 (file)
@@ -23,7 +23,8 @@ int __ieee80211_suspend(struct ieee80211_hw *hw, struct cfg80211_wowlan *wowlan)
 
        ieee80211_del_virtual_monitor(local);
 
-       if (ieee80211_hw_check(hw, AMPDU_AGGREGATION)) {
+       if (ieee80211_hw_check(hw, AMPDU_AGGREGATION) &&
+           !(wowlan && wowlan->any)) {
                mutex_lock(&local->sta_mtx);
                list_for_each_entry(sta, &local->sta_list, list) {
                        set_sta_flag(sta, WLAN_STA_BLOCK_BA);
index 9cabf076d7183a921ca80786729384505b3642ef..62948bbb062346d5549df6e72e736ed593a9e3a0 100644 (file)
@@ -2017,8 +2017,9 @@ int ieee80211_reconfig(struct ieee80211_local *local)
                mutex_lock(&local->sta_mtx);
 
                list_for_each_entry(sta, &local->sta_list, list) {
-                       ieee80211_sta_tear_down_BA_sessions(
-                                       sta, AGG_STOP_LOCAL_REQUEST);
+                       if (!local->resuming)
+                               ieee80211_sta_tear_down_BA_sessions(
+                                               sta, AGG_STOP_LOCAL_REQUEST);
                        clear_sta_flag(sta, WLAN_STA_BLOCK_BA);
                }