Hi, Recently, while looking at some stuff I saw the below patch done by Pierre which is part of the drivers/mmc/card/queue.c file. I wonder if someone can through more light on this to understand where could be a potential deadlock without calling mmc_queue_resume. Is there a need for the mmc queue to be resumed before calling del_gendisk(md->disk) in the card removal path?? Regards, Madhu commit d2b46f66b4b342be07a4194bd5e82384d07e470d Author: Pierre Ossman <drzeus@xxxxxxxxx> Date: Sat Apr 28 16:52:12 2007 +0200 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: Pierre Ossman <drzeus@xxxxxxxxx> diff --git a/drivers/mmc/card/queue.c b/drivers/mmc/card/queue.c index aa75ac1..2e77963 100644 --- a/drivers/mmc/card/queue.c +++ b/drivers/mmc/card/queue.c @@ -191,6 +191,9 @@ void mmc_cleanup_queue(struct mmc_queue *mq) q->queuedata = NULL; 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 */ kthread_stop(mq->thread); -- To unsubscribe from this list: send the line "unsubscribe linux-mmc" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html