]> git.proxmox.com Git - mirror_ubuntu-kernels.git/commitdiff
bfq/mq-deadline: remove redundant check for passthrough request
authorLin Feng <linf@wangsu.com>
Thu, 15 Apr 2021 03:43:26 +0000 (11:43 +0800)
committerJens Axboe <axboe@kernel.dk>
Fri, 16 Apr 2021 12:08:52 +0000 (06:08 -0600)
Since commit 01e99aeca39796003 'blk-mq: insert passthrough request into
hctx->dispatch directly', passthrough request should not appear in
IO-scheduler any more, so blk_rq_is_passthrough checking in addon IO
schedulers is redundant.

(Notes: this patch passes generic IO load test with hdds under SAS
controller and hdds under AHCI controller but obviously not covers all.
Not sure if passthrough request can still escape into IO scheduler from
blk_mq_sched_insert_requests, which is used by blk_mq_flush_plug_list and
has lots of indirect callers.)

Signed-off-by: Lin Feng <linf@wangsu.com>
Reviewed-by: Ming Lei <ming.lei@redhat.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
block/bfq-iosched.c
block/mq-deadline.c

index 9b7678ad5830ad41a5ecafe2b01d3e9b5dc6ccd7..0270cd7ca1658fd3e9022aa7cf65099ef7dfe9da 100644 (file)
@@ -5957,8 +5957,7 @@ static void bfq_insert_request(struct blk_mq_hw_ctx *hctx, struct request *rq,
             bfqd->in_service_queue != NULL &&
             bfq_tot_busy_queues(bfqd) == 1 + bfq_bfqq_busy(bfqq) &&
             (bfqq->waker_bfqq == bfqd->in_service_queue ||
-             bfqd->in_service_queue->waker_bfqq == bfqq)) ||
-           at_head || blk_rq_is_passthrough(rq)) {
+             bfqd->in_service_queue->waker_bfqq == bfqq)) || at_head) {
                if (at_head)
                        list_add(&rq->queuelist, &bfqd->dispatch);
                else
index f3631a28746676ec1f2aa7261501a9f79ae84e78..04aded71ead2732c7c5c16a8e591c741f84c47c1 100644 (file)
@@ -500,11 +500,8 @@ static void dd_insert_request(struct blk_mq_hw_ctx *hctx, struct request *rq,
 
        trace_block_rq_insert(rq);
 
-       if (at_head || blk_rq_is_passthrough(rq)) {
-               if (at_head)
-                       list_add(&rq->queuelist, &dd->dispatch);
-               else
-                       list_add_tail(&rq->queuelist, &dd->dispatch);
+       if (at_head) {
+               list_add(&rq->queuelist, &dd->dispatch);
        } else {
                deadline_add_rq_rb(dd, rq);