]> git.ipfire.org Git - thirdparty/linux.git/commitdiff
blk-mq: use blk_mq_sched_mark_restart_hctx to set RESTART
authorYufen Yu <yuyufen@huawei.com>
Fri, 15 Mar 2019 03:05:10 +0000 (11:05 +0800)
committerJens Axboe <axboe@kernel.dk>
Mon, 18 Mar 2019 14:14:51 +0000 (08:14 -0600)
Let blk_mq_mark_tag_wait() use the blk_mq_sched_mark_restart_hctx()
to set BLK_MQ_S_SCHED_RESTART.

Signed-off-by: Yufen Yu <yuyufen@huawei.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
block/blk-mq.c

index a9c181603cbda2df9f9b59d9c447b19d3f9c2889..ea01c23b58a3d8bdd102786e43b0c956a0e1a8d7 100644 (file)
@@ -1093,8 +1093,7 @@ static bool blk_mq_mark_tag_wait(struct blk_mq_hw_ctx *hctx,
        bool ret;
 
        if (!(hctx->flags & BLK_MQ_F_TAG_SHARED)) {
-               if (!test_bit(BLK_MQ_S_SCHED_RESTART, &hctx->state))
-                       set_bit(BLK_MQ_S_SCHED_RESTART, &hctx->state);
+               blk_mq_sched_mark_restart_hctx(hctx);
 
                /*
                 * It's possible that a tag was freed in the window between the