]> asedeno.scripts.mit.edu Git - linux.git/commit
blk-mq-sched: decide how to handle flush rq via RQF_FLUSH_SEQ
authorMing Lei <ming.lei@redhat.com>
Thu, 2 Nov 2017 15:24:36 +0000 (23:24 +0800)
committerJens Axboe <axboe@kernel.dk>
Sat, 4 Nov 2017 18:38:50 +0000 (12:38 -0600)
commita6a252e6491443c1c18eab7e254daee63d4a7a04
treee87705015ce4b4722e271acf2f99db7dfdfe7d2d
parent598906f814280762157629ba8833bf5cb11def74
blk-mq-sched: decide how to handle flush rq via RQF_FLUSH_SEQ

In case of IO scheduler we always pre-allocate one driver tag before
calling blk_insert_flush(), and flush request will be marked as
RQF_FLUSH_SEQ once it is in flush machinery.

So if RQF_FLUSH_SEQ isn't set, we call blk_insert_flush() to handle
the request, otherwise the flush request is dispatched to ->dispatch
list directly.

This is a preparation patch for not preallocating a driver tag for flush
requests, and for not treating flush requests as a special case. This is
similar to what the legacy path does.

Signed-off-by: Ming Lei <ming.lei@redhat.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
block/blk-mq-sched.c