From f899fed4421d6b098ed6a9d69303c70e590bf2c0 Mon Sep 17 00:00:00 2001 From: Jens Axboe Date: Wed, 4 Jun 2014 09:11:53 -0600 Subject: blk-mq: fix regression from commit 624dbe475416 When the code was collapsed to avoid duplication, the recent patch for ensuring that a queue is idled before free was dropped, which was added by commit 19c5d84f14d2. Add back the blk_mq_tag_idle(), to ensure we don't leak a reference to an active queue when it is freed. Signed-off-by: Jens Axboe --- block/blk-mq.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'block') diff --git a/block/blk-mq.c b/block/blk-mq.c index 96e6eb638f00..4e8e8cf00815 100644 --- a/block/blk-mq.c +++ b/block/blk-mq.c @@ -1552,6 +1552,8 @@ static void blk_mq_exit_hw_queues(struct request_queue *q, if (i == nr_queue) break; + blk_mq_tag_idle(hctx); + if (set->ops->exit_hctx) set->ops->exit_hctx(hctx, i); -- cgit v1.2.3-58-ga151