mac80211: fix check for buffered powersave frames with txq
authorFelix Fietkau <nbd@nbd.name>
Mon, 11 Jul 2016 13:09:15 +0000 (15:09 +0200)
committerJohannes Berg <johannes.berg@intel.com>
Tue, 2 Aug 2016 07:50:26 +0000 (09:50 +0200)
The logic was inverted here, set the bit if frames are pending.

Fixes: ba8c3d6f16a1 ("mac80211: add an intermediate software queue implementation")
Signed-off-by: Felix Fietkau <nbd@nbd.name>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
net/mac80211/rx.c

index 2e8a9024625a2ae49ac046bccac671c77911120f..9dce3b157908b3d229fb293a8f5acbce9057ea63 100644 (file)
@@ -1268,7 +1268,7 @@ static void sta_ps_start(struct sta_info *sta)
        for (tid = 0; tid < ARRAY_SIZE(sta->sta.txq); tid++) {
                struct txq_info *txqi = to_txq_info(sta->sta.txq[tid]);
 
-               if (!txqi->tin.backlog_packets)
+               if (txqi->tin.backlog_packets)
                        set_bit(tid, &sta->txq_buffered_tids);
                else
                        clear_bit(tid, &sta->txq_buffered_tids);