提交 d2b46f66 编写于 作者: P Pierre Ossman

mmc: allow suspended block driver to be removed

Make sure we don't deadlock when removing a suspended block
queue, something that might happen if the card is removed during
suspend.
Signed-off-by: NPierre Ossman <drzeus@drzeus.cx>
上级 3b91e550
...@@ -191,6 +191,9 @@ void mmc_cleanup_queue(struct mmc_queue *mq) ...@@ -191,6 +191,9 @@ void mmc_cleanup_queue(struct mmc_queue *mq)
q->queuedata = NULL; q->queuedata = NULL;
spin_unlock_irqrestore(q->queue_lock, flags); spin_unlock_irqrestore(q->queue_lock, flags);
/* Make sure the queue isn't suspended, as that will deadlock */
mmc_queue_resume(mq);
/* Then terminate our worker thread */ /* Then terminate our worker thread */
kthread_stop(mq->thread); kthread_stop(mq->thread);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册