[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20220521073523.3118246-3-yukuai3@huawei.com>
Date: Sat, 21 May 2022 15:35:19 +0800
From: Yu Kuai <yukuai3@...wei.com>
To: <jack@...e.cz>, <axboe@...nel.dk>, <paolo.valente@...aro.org>
CC: <cgroups@...r.kernel.org>, <linux-block@...r.kernel.org>,
<linux-kernel@...r.kernel.org>, <yukuai3@...wei.com>,
<yi.zhang@...wei.com>
Subject: [PATCH -next v2 2/6] block, bfq: cleanup __bfq_weights_tree_remove()
It's the same with bfq_weights_tree_remove() now.
Signed-off-by: Yu Kuai <yukuai3@...wei.com>
Reviewed-by: Jan Kara <jack@...e.cz>
---
block/bfq-iosched.c | 13 +------------
block/bfq-iosched.h | 1 -
block/bfq-wf2q.c | 2 +-
3 files changed, 2 insertions(+), 14 deletions(-)
diff --git a/block/bfq-iosched.c b/block/bfq-iosched.c
index c408c5a79d97..c0bc463d236c 100644
--- a/block/bfq-iosched.c
+++ b/block/bfq-iosched.c
@@ -944,8 +944,7 @@ void bfq_weights_tree_add(struct bfq_data *bfqd, struct bfq_queue *bfqq)
* See the comments to the function bfq_weights_tree_add() for considerations
* about overhead.
*/
-void __bfq_weights_tree_remove(struct bfq_data *bfqd,
- struct bfq_queue *bfqq)
+void bfq_weights_tree_remove(struct bfq_data *bfqd, struct bfq_queue *bfqq)
{
struct rb_root_cached *root;
@@ -965,16 +964,6 @@ void __bfq_weights_tree_remove(struct bfq_data *bfqd,
bfq_put_queue(bfqq);
}
-/*
- * Invoke __bfq_weights_tree_remove on bfqq and decrement the number
- * of active groups for each queue's inactive parent entity.
- */
-void bfq_weights_tree_remove(struct bfq_data *bfqd,
- struct bfq_queue *bfqq)
-{
- __bfq_weights_tree_remove(bfqd, bfqq);
-}
-
/*
* Return expired entry, or NULL to just start from scratch in rbtree.
*/
diff --git a/block/bfq-iosched.h b/block/bfq-iosched.h
index 0a3415abb994..bc54b9824b1e 100644
--- a/block/bfq-iosched.h
+++ b/block/bfq-iosched.h
@@ -933,7 +933,6 @@ void bic_set_bfqq(struct bfq_io_cq *bic, struct bfq_queue *bfqq, bool is_sync);
struct bfq_data *bic_to_bfqd(struct bfq_io_cq *bic);
void bfq_pos_tree_add_move(struct bfq_data *bfqd, struct bfq_queue *bfqq);
void bfq_weights_tree_add(struct bfq_data *bfqd, struct bfq_queue *bfqq);
-void __bfq_weights_tree_remove(struct bfq_data *bfqd, struct bfq_queue *bfqq);
void bfq_weights_tree_remove(struct bfq_data *bfqd, struct bfq_queue *bfqq);
void bfq_bfqq_expire(struct bfq_data *bfqd, struct bfq_queue *bfqq,
bool compensate, enum bfqq_expiration reason);
diff --git a/block/bfq-wf2q.c b/block/bfq-wf2q.c
index ccd227fed1c3..2f3fb45a32c3 100644
--- a/block/bfq-wf2q.c
+++ b/block/bfq-wf2q.c
@@ -790,7 +790,7 @@ __bfq_entity_update_weight_prio(struct bfq_service_tree *old_st,
* there is a counter associated with the entity).
*/
if (prev_weight != new_weight && bfqq)
- __bfq_weights_tree_remove(bfqd, bfqq);
+ bfq_weights_tree_remove(bfqd, bfqq);
entity->weight = new_weight;
/*
* Add the entity, if it is not a weight-raised queue,
--
2.31.1
Powered by blists - more mailing lists