diff options
| author | Adrian Hunter <[email protected]> | 2017-11-29 13:40:59 +0000 |
|---|---|---|
| committer | Ulf Hansson <[email protected]> | 2017-12-11 11:44:31 +0000 |
| commit | 41e3efd07d5a02c80f503e29d755aa1bbb4245de (patch) | |
| tree | a2a8fdcdcabf25d49ccf50204ce9502bcf9d5cd5 /drivers/mmc/core/queue.c | |
| parent | mmc: block: No need to export mmc_cleanup_queue() (diff) | |
| download | kernel-41e3efd07d5a02c80f503e29d755aa1bbb4245de.tar.gz kernel-41e3efd07d5a02c80f503e29d755aa1bbb4245de.zip | |
mmc: block: Simplify cleaning up the queue
Use blk_cleanup_queue() to shutdown the queue when the driver is removed,
and instead get an extra reference to the queue to prevent the queue being
freed before the final mmc_blk_put().
Signed-off-by: Adrian Hunter <[email protected]>
Acked-by: Linus Walleij <[email protected]>
Signed-off-by: Ulf Hansson <[email protected]>
Tested-by: Linus Walleij <[email protected]>
Diffstat (limited to 'drivers/mmc/core/queue.c')
| -rw-r--r-- | drivers/mmc/core/queue.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/mmc/core/queue.c b/drivers/mmc/core/queue.c index 26f8da30ebe5..ae6d9da68735 100644 --- a/drivers/mmc/core/queue.c +++ b/drivers/mmc/core/queue.c @@ -268,6 +268,8 @@ void mmc_cleanup_queue(struct mmc_queue *mq) blk_start_queue(q); spin_unlock_irqrestore(q->queue_lock, flags); + blk_cleanup_queue(q); + mq->card = NULL; } |
