diff options
author | Ryder Lee <ryder.lee@mediatek.com> | 2021-04-13 13:34:56 +0800 |
---|---|---|
committer | Felix Fietkau <nbd@nbd.name> | 2021-04-21 11:42:20 +0200 |
commit | 8ab31da7b89f71c4c2defcca989fab7b42f87d71 (patch) | |
tree | c9b7c35c9279cd1792132d5c9cb85b8e49498bf5 /drivers/net/wireless/mediatek | |
parent | cc91747be98f2a3fc305cf3efc8f3a9b7f6a9f3b (diff) | |
download | linux-stable-8ab31da7b89f71c4c2defcca989fab7b42f87d71.tar.gz linux-stable-8ab31da7b89f71c4c2defcca989fab7b42f87d71.tar.bz2 linux-stable-8ab31da7b89f71c4c2defcca989fab7b42f87d71.zip |
mt76: mt7615: fix memleak when mt7615_unregister_device()
mt7615_tx_token_put() should get call before mt76_free_pending_txwi().
Fixes: a6275e934605 ("mt76: mt7615: reset token when mac_reset happens")
Signed-off-by: Ryder Lee <ryder.lee@mediatek.com>
Signed-off-by: Felix Fietkau <nbd@nbd.name>
Diffstat (limited to 'drivers/net/wireless/mediatek')
-rw-r--r-- | drivers/net/wireless/mediatek/mt76/mt7615/pci_init.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/net/wireless/mediatek/mt76/mt7615/pci_init.c b/drivers/net/wireless/mediatek/mt76/mt7615/pci_init.c index a629d9cb3806..a03484e34bb4 100644 --- a/drivers/net/wireless/mediatek/mt76/mt7615/pci_init.c +++ b/drivers/net/wireless/mediatek/mt76/mt7615/pci_init.c @@ -164,10 +164,9 @@ void mt7615_unregister_device(struct mt7615_dev *dev) mt76_unregister_device(&dev->mt76); if (mcu_running) mt7615_mcu_exit(dev); - mt7615_dma_cleanup(dev); mt7615_tx_token_put(dev); - + mt7615_dma_cleanup(dev); tasklet_disable(&dev->irq_tasklet); mt76_free_device(&dev->mt76); |