Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 35ed4e75 authored by David S. Miller's avatar David S. Miller
Browse files

mac80211: Use queue_lock() in ieee80211_ht_agg_queue_remove().



qdisc_root_lock() is only %100 safe to use when the RTNL
semaphore is held.

Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 5fb66229
Loading
Loading
Loading
Loading
+4 −2
Original line number Diff line number Diff line
@@ -241,12 +241,14 @@ void ieee80211_ht_agg_queue_remove(struct ieee80211_local *local,
	} else {
		struct netdev_queue *txq;
		spinlock_t *root_lock;
		struct Qdisc *q;

		txq = netdev_get_tx_queue(local->mdev, agg_queue);
		root_lock = qdisc_root_lock(txq->qdisc);
		q = rcu_dereference(txq->qdisc);
		root_lock = qdisc_lock(q);

		spin_lock_bh(root_lock);
		qdisc_reset(txq->qdisc);
		qdisc_reset(q);
		spin_unlock_bh(root_lock);
	}
}