diff mbox series

[-next,v4,1/5] block, bfq: remove set but not used variable in __bfq_entity_update_weight_prio

Message ID 20221102022542.3621219-2-yukuai1@huaweicloud.com (mailing list archive)
State New, archived
Headers show
Series multiple cleanup patches for bfqd | expand

Commit Message

Yu Kuai Nov. 2, 2022, 2:25 a.m. UTC
From: Yu Kuai <yukuai3@huawei.com>

After the patch "block, bfq: cleanup bfq_weights_tree add/remove apis"),
the local variable 'bfqd' is not used anymore, thus remove it.

Signed-off-by: Yu Kuai <yukuai3@huawei.com>
---
 block/bfq-wf2q.c | 15 ---------------
 1 file changed, 15 deletions(-)

Comments

Jens Axboe Nov. 2, 2022, 2:09 a.m. UTC | #1
On 11/1/22 8:25 PM, Yu Kuai wrote:
> From: Yu Kuai <yukuai3@huawei.com>
> 
> After the patch "block, bfq: cleanup bfq_weights_tree add/remove apis"),
> the local variable 'bfqd' is not used anymore, thus remove it.

Please add a Fixes tag.
Jens Axboe Nov. 2, 2022, 2:11 a.m. UTC | #2
On 11/1/22 8:09 PM, Jens Axboe wrote:
> On 11/1/22 8:25 PM, Yu Kuai wrote:
>> From: Yu Kuai <yukuai3@huawei.com>
>>
>> After the patch "block, bfq: cleanup bfq_weights_tree add/remove apis"),
>> the local variable 'bfqd' is not used anymore, thus remove it.
> 
> Please add a Fixes tag.

Looks like the rest were good to go, so I added it myself.
Yu Kuai Nov. 2, 2022, 2:18 a.m. UTC | #3
Hi,

在 2022/11/02 10:11, Jens Axboe 写道:
> On 11/1/22 8:09 PM, Jens Axboe wrote:
>> On 11/1/22 8:25 PM, Yu Kuai wrote:
>>> From: Yu Kuai <yukuai3@huawei.com>
>>>
>>> After the patch "block, bfq: cleanup bfq_weights_tree add/remove apis"),
>>> the local variable 'bfqd' is not used anymore, thus remove it.
>>
>> Please add a Fixes tag.
> 
> Looks like the rest were good to go, so I added it myself.

Thanks for helping out. I'm not sure which commit id to use since the
fixed patch is not in linux-next yet, does the commit id stay the same
when the patch applied from for-6.2 to next ?

Thanks,
Kuai
>
Jens Axboe Nov. 2, 2022, 2:24 a.m. UTC | #4
On 11/1/22 8:18 PM, Yu Kuai wrote:
> Hi,
> 
> 在 2022/11/02 10:11, Jens Axboe 写道:
>> On 11/1/22 8:09 PM, Jens Axboe wrote:
>>> On 11/1/22 8:25 PM, Yu Kuai wrote:
>>>> From: Yu Kuai <yukuai3@huawei.com>
>>>>
>>>> After the patch "block, bfq: cleanup bfq_weights_tree add/remove apis"),
>>>> the local variable 'bfqd' is not used anymore, thus remove it.
>>>
>>> Please add a Fixes tag.
>>
>> Looks like the rest were good to go, so I added it myself.
> 
> Thanks for helping out. I'm not sure which commit id to use since the
> fixed patch is not in linux-next yet, does the commit id stay the same
> when the patch applied from for-6.2 to next ?

linux-next shas are not stable, but since you're sending this to the
linux-block list and against the block tree, that's obviously where
you'd find that commit.
diff mbox series

Patch

diff --git a/block/bfq-wf2q.c b/block/bfq-wf2q.c
index 5a02cb94d86e..2faa29fcb1e9 100644
--- a/block/bfq-wf2q.c
+++ b/block/bfq-wf2q.c
@@ -706,21 +706,6 @@  __bfq_entity_update_weight_prio(struct bfq_service_tree *old_st,
 	if (entity->prio_changed) {
 		struct bfq_queue *bfqq = bfq_entity_to_bfqq(entity);
 		unsigned int prev_weight, new_weight;
-		struct bfq_data *bfqd = NULL;
-#ifdef CONFIG_BFQ_GROUP_IOSCHED
-		struct bfq_sched_data *sd;
-		struct bfq_group *bfqg;
-#endif
-
-		if (bfqq)
-			bfqd = bfqq->bfqd;
-#ifdef CONFIG_BFQ_GROUP_IOSCHED
-		else {
-			sd = entity->my_sched_data;
-			bfqg = container_of(sd, struct bfq_group, sched_data);
-			bfqd = (struct bfq_data *)bfqg->bfqd;
-		}
-#endif
 
 		/* Matches the smp_wmb() in bfq_group_set_weight. */
 		smp_rmb();