mirror of
https://github.com/outbackdingo/mt76.git
synced 2026-10-24 13:26:48 +00:00
wifi: mt76: move wed reset common code in mt76 module
Move WED reset code shared between mt7915 and mt7996 in common module. This is a preliminary patch to introduce WED reset support for mt7996. Signed-off-by: Lorenzo Bianconi <[email protected]> Signed-off-by: Felix Fietkau <[email protected]>
This commit is contained in:
committed by
Felix Fietkau
parent
abca260a15
commit
be2e74c0c4
@@ -1036,6 +1036,20 @@ void mt76_dma_attach(struct mt76_dev *dev)
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(mt76_dma_attach);
|
||||
|
||||
void mt76_dma_wed_reset(struct mt76_dev *dev)
|
||||
{
|
||||
struct mt76_mmio *mmio = &dev->mmio;
|
||||
|
||||
if (!test_bit(MT76_STATE_WED_RESET, &dev->phy.state))
|
||||
return;
|
||||
|
||||
complete(&mmio->wed_reset);
|
||||
|
||||
if (!wait_for_completion_timeout(&mmio->wed_reset_complete, 3 * HZ))
|
||||
dev_err(dev->dev, "wed reset complete timeout\n");
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(mt76_dma_wed_reset);
|
||||
|
||||
void mt76_dma_cleanup(struct mt76_dev *dev)
|
||||
{
|
||||
int i;
|
||||
|
||||
Reference in New Issue
Block a user