mirror of
https://github.com/outbackdingo/mt76.git
synced 2026-10-24 13:26:48 +00:00
mt7603: initialize per-sta per-tid txq
Signed-off-by: Felix Fietkau <[email protected]>
This commit is contained in:
+9
-1
@@ -160,7 +160,7 @@ mt7603_sta_add(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
|
||||
{
|
||||
struct mt7603_dev *dev = hw->priv;
|
||||
struct mt7603_sta *msta = (struct mt7603_sta *) sta->drv_priv;
|
||||
int ret, idx;
|
||||
int i, ret, idx;
|
||||
|
||||
mutex_lock(&dev->mutex);
|
||||
|
||||
@@ -170,6 +170,9 @@ mt7603_sta_add(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
|
||||
goto out;
|
||||
}
|
||||
|
||||
for (i = 0; i < ARRAY_SIZE(sta->txq); i++)
|
||||
mt7603_txq_init(dev, sta->txq[i]);
|
||||
|
||||
msta->wcid.idx = idx;
|
||||
mt7603_wtbl_update_cap(dev, sta);
|
||||
|
||||
@@ -189,10 +192,15 @@ mt7603_sta_remove(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
|
||||
struct mt7603_dev *dev = hw->priv;
|
||||
struct mt7603_sta *msta = (struct mt7603_sta *) sta->drv_priv;
|
||||
int idx = msta->wcid.idx;
|
||||
int i;
|
||||
|
||||
mutex_lock(&dev->mutex);
|
||||
rcu_assign_pointer(dev->wcid[idx], NULL);
|
||||
mt7603_wtbl_clear(dev, idx);
|
||||
|
||||
for (i = 0; i < ARRAY_SIZE(sta->txq); i++)
|
||||
mt76_txq_remove(&dev->mt76, sta->txq[i]);
|
||||
|
||||
mutex_unlock(&dev->mutex);
|
||||
|
||||
return 0;
|
||||
|
||||
Reference in New Issue
Block a user