linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Lorenzo Bianconi <lorenzo@kernel.org>
To: nbd@nbd.name
Cc: lorenzo.bianconi@redhat.com, linux-wireless@vger.kernel.org,
	ryder.lee@mediatek.com, royluo@google.com
Subject: [PATCH] mt76: mt7615: stop mcu first in mt7615_unregister_device
Date: Tue, 14 May 2019 14:20:45 +0200	[thread overview]
Message-ID: <e145d9f42b1cfcf525300d583c99773132381c34.1557836235.git.lorenzo@kernel.org> (raw)
In-Reply-To: <cover.1557836235.git.lorenzo@kernel.org>

Stop mcu engine and then dma one in mt7615_unregister_device
in order to avoid a mcu hang in mt7615_unregister_device

Signed-off-by: Lorenzo Bianconi <lorenzo@kernel.org>
---
This patch ca be squashed with 'mt76: mt7615: rearrange cleanup operations in
mt7615_unregister_device' since it is not upstream yet
---
 drivers/net/wireless/mediatek/mt76/mt7615/init.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/wireless/mediatek/mt76/mt7615/init.c b/drivers/net/wireless/mediatek/mt76/mt7615/init.c
index 59f604f3161f..369b9a8e07be 100644
--- a/drivers/net/wireless/mediatek/mt76/mt7615/init.c
+++ b/drivers/net/wireless/mediatek/mt76/mt7615/init.c
@@ -213,8 +213,8 @@ void mt7615_unregister_device(struct mt7615_dev *dev)
 	int id;
 
 	mt76_unregister_device(&dev->mt76);
-	mt7615_dma_cleanup(dev);
 	mt7615_mcu_exit(dev);
+	mt7615_dma_cleanup(dev);
 
 	spin_lock_bh(&dev->token_lock);
 	idr_for_each_entry(&dev->token, txwi, id) {
-- 
2.20.1


       reply	other threads:[~2019-05-14 12:21 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <cover.1557836235.git.lorenzo@kernel.org>
2019-05-14 12:20 ` Lorenzo Bianconi [this message]
2019-06-07 16:34   ` [PATCH] mt76: mt7615: stop mcu first in mt7615_unregister_device Felix Fietkau

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=e145d9f42b1cfcf525300d583c99773132381c34.1557836235.git.lorenzo@kernel.org \
    --to=lorenzo@kernel.org \
    --cc=linux-wireless@vger.kernel.org \
    --cc=lorenzo.bianconi@redhat.com \
    --cc=nbd@nbd.name \
    --cc=royluo@google.com \
    --cc=ryder.lee@mediatek.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).