mirror of
https://github.com/outbackdingo/mt76.git
synced 2026-10-24 13:26:48 +00:00
wifi: mt76: mt7996: Fix tx-queues initialization for second phy on mt7996
Fix the second phy tx queue initialization if hif device is not
available for MT7990 chipset.
Fixes: 83eafc9251d6d ("wifi: mt76: mt7996: add wed tx support")
Co-developed-by: Sujuan Chen <[email protected]>
Signed-off-by: Sujuan Chen <[email protected]>
Co-developed-by: Benjamin Lin <[email protected]>
Signed-off-by: Benjamin Lin <[email protected]>
Co-developed-by: Rex Lu <[email protected]>
Signed-off-by: Rex Lu <[email protected]>
Signed-off-by: Lorenzo Bianconi <[email protected]>
Link: https://patch.msgid.link/[email protected]
Signed-off-by: Felix Fietkau <[email protected]>
This commit is contained in:
committed by
Felix Fietkau
parent
8134055d34
commit
4f81d751b5
+14
-7
@@ -704,13 +704,20 @@ static int mt7996_register_phy(struct mt7996_dev *dev, enum mt76_band_id band)
|
||||
|
||||
/* init wiphy according to mphy and phy */
|
||||
mt7996_init_wiphy_band(mphy->hw, phy);
|
||||
ret = mt7996_init_tx_queues(mphy->priv,
|
||||
MT_TXQ_ID(band),
|
||||
MT7996_TX_RING_SIZE,
|
||||
MT_TXQ_RING_BASE(band) + hif1_ofs,
|
||||
wed);
|
||||
if (ret)
|
||||
goto error;
|
||||
|
||||
if (is_mt7996(&dev->mt76) && !dev->hif2 && band == MT_BAND1) {
|
||||
int i;
|
||||
|
||||
for (i = 0; i <= MT_TXQ_PSD; i++)
|
||||
mphy->q_tx[i] = dev->mt76.phys[MT_BAND0]->q_tx[0];
|
||||
} else {
|
||||
ret = mt7996_init_tx_queues(mphy->priv, MT_TXQ_ID(band),
|
||||
MT7996_TX_RING_SIZE,
|
||||
MT_TXQ_RING_BASE(band) + hif1_ofs,
|
||||
wed);
|
||||
if (ret)
|
||||
goto error;
|
||||
}
|
||||
|
||||
ret = mt76_register_phy(mphy, true, mt76_rates,
|
||||
ARRAY_SIZE(mt76_rates));
|
||||
|
||||
Reference in New Issue
Block a user