Skip to content

Commit

Permalink
blk-mq: don't call into depth limiting for reserved tags
Browse files Browse the repository at this point in the history
It's not useful, they are internal and/or error handling recovery
commands.

Acked-by: Paolo Valente <paolo.valente@linaro.org>
Reviewed-by: Omar Sandoval <osandov@fb.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
  • Loading branch information
Jens Axboe committed May 10, 2018
1 parent 18e5a57 commit 17a5119
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions block/blk-mq.c
Original file line number Diff line number Diff line change
Expand Up @@ -360,9 +360,11 @@ static struct request *blk_mq_get_request(struct request_queue *q,

/*
* Flush requests are special and go directly to the
* dispatch list.
* dispatch list. Don't include reserved tags in the
* limiting, as it isn't useful.
*/
if (!op_is_flush(op) && e->type->ops.mq.limit_depth)
if (!op_is_flush(op) && e->type->ops.mq.limit_depth &&
!(data->flags & BLK_MQ_REQ_RESERVED))
e->type->ops.mq.limit_depth(op, data);
}

Expand Down

0 comments on commit 17a5119

Please sign in to comment.