Skip to content

Commit

Permalink
blk-mq: update hctx->dispatch_busy in case of real scheduler
Browse files Browse the repository at this point in the history
[ Upstream commit cb9516b ]

Commit 6e6fcbc ("blk-mq: support batching dispatch in case of io")
starts to support io batching submission by using hctx->dispatch_busy.

However, blk_mq_update_dispatch_busy() isn't changed to update hctx->dispatch_busy
in that commit, so fix the issue by updating hctx->dispatch_busy in case
of real scheduler.

Reported-by: Jan Kara <jack@suse.cz>
Reviewed-by: Jan Kara <jack@suse.cz>
Fixes: 6e6fcbc ("blk-mq: support batching dispatch in case of io")
Signed-off-by: Ming Lei <ming.lei@redhat.com>
Link: https://lore.kernel.org/r/20210625020248.1630497-1-ming.lei@redhat.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Signed-off-by: Sasha Levin <sashal@kernel.org>
  • Loading branch information
Ming Lei authored and gregkh committed Jul 14, 2021
1 parent 577072d commit 98c8147
Showing 1 changed file with 0 additions and 3 deletions.
3 changes: 0 additions & 3 deletions block/blk-mq.c
Original file line number Diff line number Diff line change
Expand Up @@ -1223,9 +1223,6 @@ static void blk_mq_update_dispatch_busy(struct blk_mq_hw_ctx *hctx, bool busy)
{
unsigned int ewma;

if (hctx->queue->elevator)
return;

ewma = hctx->dispatch_busy;

if (!ewma && !busy)
Expand Down

0 comments on commit 98c8147

Please sign in to comment.