From: Han Guangjiang <gj.han@foxmail.com>
To: yukuai1@huaweicloud.com
Cc: axboe@kernel.dk, buaajxlj@163.com, fanggeng@lixiang.com,
gj.han@foxmail.com, hailan@yukuai.org.cn,
hanguangjiang@lixiang.com, liangjie@lixiang.com,
linux-block@vger.kernel.org, linux-kernel@vger.kernel.org,
yangchen11@lixiang.com, yukuai3@huawei.com
Subject: Re: [PATCH] blk-throttle: check policy bit in blk_throtl_activated()
Date: Thu, 4 Sep 2025 16:23:10 +0800 [thread overview]
Message-ID: <tencent_8F4803A1271AF89895A2B3310C9F4126AB07@qq.com> (raw)
In-Reply-To: <f17231f5-61a0-8d2d-eef5-f9b838caad34@huaweicloud.com>
Hi,
> Yes, however, this can be fixed very similar:
>
> Set sq->parent_sq to NULL here, and add a helper parent_sq(q, sq):
>
> if (sq->parent_sq)
> return sq->parent_sq;
>
> td_sq = &q->td->service_queue;
> return sq == td_sq ? NULL : td_sq;
>
> And sq_to_tg() need to be changed as well. So far, I'm not sure how many
> code changes are required this way. We of course want a simple fix for
> stable backport, but we definitely still want this kind of fix in future
> release.
We preliminarily tried implementing this approach. But the changes are
scattered and backport might be complex. So we provide a simple fix first.
> Meanwhile, please remove the comment about freeze queue, turns out it
> can't protect blk_throtl_bio() becasue q_usage_coutner is not grabbed
> yet while issuing bio.
As discussed before, we also removed some outdated comments in
blk_should_throtl().
We just submitted v2 which includes the changes.
We look forward to your feedback and suggestions on the v2 patch.
Thanks,
Han Guangjiang
next prev parent reply other threads:[~2025-09-04 8:28 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-09-02 12:39 gj.han
2025-09-02 17:06 ` Yu Kuai
2025-09-03 2:55 ` Han Guangjiang
2025-09-03 6:03 ` Yu Kuai
2025-09-03 7:21 ` Liang Jie
2025-09-03 8:24 ` Yu Kuai
2025-09-04 8:23 ` Han Guangjiang [this message]
2025-09-04 8:17 ` [PATCH v2] blk-throttle: fix access race during throttle policy activation Han Guangjiang
2025-09-04 9:18 ` Yu Kuai
2025-09-04 10:05 ` [PATCH] blk-throttle: check policy bit in blk_throtl_activated() Han Guangjiang
2025-09-04 10:59 ` Yu Kuai
2025-09-05 6:53 ` Han Guangjiang
2025-09-05 7:19 ` Yu Kuai
2025-09-04 8:19 ` Han Guangjiang
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=tencent_8F4803A1271AF89895A2B3310C9F4126AB07@qq.com \
--to=gj.han@foxmail.com \
--cc=axboe@kernel.dk \
--cc=buaajxlj@163.com \
--cc=fanggeng@lixiang.com \
--cc=hailan@yukuai.org.cn \
--cc=hanguangjiang@lixiang.com \
--cc=liangjie@lixiang.com \
--cc=linux-block@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=yangchen11@lixiang.com \
--cc=yukuai1@huaweicloud.com \
--cc=yukuai3@huawei.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®