summaryrefslogtreecommitdiff
path: root/package/kernel/mac80211
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@nbd.name>2016-08-28 13:49:48 +0200
committerFelix Fietkau <nbd@nbd.name>2016-09-02 14:43:51 +0200
commit1e72d1bf16e6f2e2a9579bc5c91bae61402da3aa (patch)
tree78323de47a5bbef6e8c447456730c78b16c1fa3d /package/kernel/mac80211
parent4f40f22fb31772097df95f93970aabbd63ae289e (diff)
downloadmtk-20170518-1e72d1bf16e6f2e2a9579bc5c91bae61402da3aa.zip
mtk-20170518-1e72d1bf16e6f2e2a9579bc5c91bae61402da3aa.tar.gz
mtk-20170518-1e72d1bf16e6f2e2a9579bc5c91bae61402da3aa.tar.bz2
mac80211: add a powersave handling fix
Signed-off-by: Felix Fietkau <nbd@nbd.name>
Diffstat (limited to 'package/kernel/mac80211')
-rw-r--r--package/kernel/mac80211/patches/338-mac80211-fix-tim-recalculation-after-PS-response.patch31
1 files changed, 31 insertions, 0 deletions
diff --git a/package/kernel/mac80211/patches/338-mac80211-fix-tim-recalculation-after-PS-response.patch b/package/kernel/mac80211/patches/338-mac80211-fix-tim-recalculation-after-PS-response.patch
new file mode 100644
index 0000000..6c0852e
--- /dev/null
+++ b/package/kernel/mac80211/patches/338-mac80211-fix-tim-recalculation-after-PS-response.patch
@@ -0,0 +1,31 @@
+From: Felix Fietkau <nbd@nbd.name>
+Date: Fri, 26 Aug 2016 21:57:16 +0200
+Subject: [PATCH] mac80211: fix tim recalculation after PS response
+
+Handle the case where the mac80211 intermediate queues are empty and the
+driver has buffered frames
+
+Fixes: ba8c3d6f16a1 ("mac80211: add an intermediate software queue implementation")
+Signed-off-by: Felix Fietkau <nbd@nbd.name>
+---
+
+--- a/net/mac80211/sta_info.c
++++ b/net/mac80211/sta_info.c
+@@ -1616,7 +1616,6 @@ ieee80211_sta_ps_deliver_response(struct
+
+ sta_info_recalc_tim(sta);
+ } else {
+- unsigned long tids = sta->txq_buffered_tids & driver_release_tids;
+ int tid;
+
+ /*
+@@ -1648,7 +1647,8 @@ ieee80211_sta_ps_deliver_response(struct
+ for (tid = 0; tid < ARRAY_SIZE(sta->sta.txq); tid++) {
+ struct txq_info *txqi = to_txq_info(sta->sta.txq[tid]);
+
+- if (!(tids & BIT(tid)) || txqi->tin.backlog_packets)
++ if (!(driver_release_tids & BIT(tid)) ||
++ txqi->tin.backlog_packets)
+ continue;
+
+ sta_info_recalc_tim(sta);