]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/commitdiff
block, bfq: fix occurrences of request finish method's old name
authorChiara Bruschi <bruschi.chiara@outlook.it>
Thu, 5 Jul 2018 13:24:00 +0000 (15:24 +0200)
committerStefan Bader <stefan.bader@canonical.com>
Tue, 14 Aug 2018 10:30:39 +0000 (12:30 +0200)
BugLink: https://launchpad.net/bugs/1780066
Commit '7b9e93616399' ("blk-mq-sched: unify request finished methods")
changed the old name of current bfq_finish_request method, but left it
unchanged elsewhere in the code (related comments, part of function
name bfq_put_rq_priv_body).

This commit fixes all occurrences of the old name of this method by
changing them into the current name.

Fixes: 7b9e93616399 ("blk-mq-sched: unify request finished methods")
Reviewed-by: Paolo Valente <paolo.valente@linaro.org>
Signed-off-by: Federico Motta <federico@willer.it>
Signed-off-by: Chiara Bruschi <bruschi.chiara@outlook.it>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
(cherry picked from commit 8993d445df388e3541f48920a2353cfc904b220a)
Signed-off-by: Wen-chien Jesse Sung <jesse.sung@canonical.com>
Acked-by: Kleber Sacilotto de Souza <kleber.souza@canonical.com>
Acked-by: Stefan Bader <stefan.bader@canonical.com>
Signed-off-by: Kleber Sacilotto de Souza <kleber.souza@canonical.com>
block/bfq-iosched.c

index 58e5c7cfa4ea6eb51aa5089c8b3f77793115721b..dbe335a17bc933c5625017c73ea741dd7812eafa 100644 (file)
@@ -3630,8 +3630,8 @@ static struct request *__bfq_dispatch_request(struct blk_mq_hw_ctx *hctx)
                }
 
                /*
-                * We exploit the put_rq_private hook to decrement
-                * rq_in_driver, but put_rq_private will not be
+                * We exploit the bfq_finish_request hook to decrement
+                * rq_in_driver, but bfq_finish_request will not be
                 * invoked on this request. So, to avoid unbalance,
                 * just start this request, without incrementing
                 * rq_in_driver. As a negative consequence,
@@ -3640,14 +3640,14 @@ static struct request *__bfq_dispatch_request(struct blk_mq_hw_ctx *hctx)
                 * bfq_schedule_dispatch to be invoked uselessly.
                 *
                 * As for implementing an exact solution, the
-                * put_request hook, if defined, is probably invoked
-                * also on this request. So, by exploiting this hook,
-                * we could 1) increment rq_in_driver here, and 2)
-                * decrement it in put_request. Such a solution would
-                * let the value of the counter be always accurate,
-                * but it would entail using an extra interface
-                * function. This cost seems higher than the benefit,
-                * being the frequency of non-elevator-private
+                * bfq_finish_request hook, if defined, is probably
+                * invoked also on this request. So, by exploiting
+                * this hook, we could 1) increment rq_in_driver here,
+                * and 2) decrement it in bfq_finish_request. Such a
+                * solution would let the value of the counter be
+                * always accurate, but it would entail using an extra
+                * interface function. This cost seems higher than the
+                * benefit, being the frequency of non-elevator-private
                 * requests very low.
                 */
                goto start_rq;
@@ -4482,7 +4482,7 @@ static void bfq_completed_request(struct bfq_queue *bfqq, struct bfq_data *bfqd)
                bfq_schedule_dispatch(bfqd);
 }
 
-static void bfq_put_rq_priv_body(struct bfq_queue *bfqq)
+static void bfq_finish_request_body(struct bfq_queue *bfqq)
 {
        bfqq->allocated--;
 
@@ -4512,7 +4512,7 @@ static void bfq_finish_request(struct request *rq)
                spin_lock_irqsave(&bfqd->lock, flags);
 
                bfq_completed_request(bfqq, bfqd);
-               bfq_put_rq_priv_body(bfqq);
+               bfq_finish_request_body(bfqq);
 
                spin_unlock_irqrestore(&bfqd->lock, flags);
        } else {
@@ -4533,7 +4533,7 @@ static void bfq_finish_request(struct request *rq)
                        bfqg_stats_update_io_remove(bfqq_group(bfqq),
                                                    rq->cmd_flags);
                }
-               bfq_put_rq_priv_body(bfqq);
+               bfq_finish_request_body(bfqq);
        }
 
        rq->elv.priv[0] = NULL;