mt76: mt7915: fix memleak when mt7915_unregister_device()
mt7915_tx_token_put() should get call before mt76_free_pending_txwi().
Fixes: f285dfb985
("mt76: mt7915: reset token when mac_reset happens")
Signed-off-by: Ryder Lee <ryder.lee@mediatek.com>
Signed-off-by: Felix Fietkau <nbd@nbd.name>
This commit is contained in:
parent
8ab31da7b8
commit
e9d32af478
|
@ -740,9 +740,8 @@ void mt7915_unregister_device(struct mt7915_dev *dev)
|
|||
mt7915_unregister_ext_phy(dev);
|
||||
mt76_unregister_device(&dev->mt76);
|
||||
mt7915_mcu_exit(dev);
|
||||
mt7915_dma_cleanup(dev);
|
||||
|
||||
mt7915_tx_token_put(dev);
|
||||
mt7915_dma_cleanup(dev);
|
||||
|
||||
mt76_free_device(&dev->mt76);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue