From: Kemeng Shi <shikemeng@huaweicloud.com>
To: Tejun Heo <tj@kernel.org>
Cc: willy@infradead.org, akpm@linux-foundation.org,
linux-fsdevel@vger.kernel.org, linux-mm@kvack.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH v2 8/8] writeback: factor out balance_wb_limits to remove repeated code
Date: Thu, 6 Jun 2024 11:24:34 +0800 [thread overview]
Message-ID: <6d5e260e-4910-92d1-faf4-8aee0b78b16d@huaweicloud.com> (raw)
In-Reply-To: <Zl4G0tI_0CHKIWHh@slm.duckdns.org>
on 6/4/2024 2:09 AM, Tejun Heo wrote:
> Hello,
>
> On Mon, Jun 03, 2024 at 02:39:18PM +0800, Kemeng Shi wrote:
>>> Isn't this a bit nasty? The helper skips updating states because it knows
>>> the caller is not going to use them? I'm not sure the slight code reduction
>>> justifies the added subtlety.
>>
>> It's a general rule that wb should not be limited if the wb is in freerun state.
>> So I think it's intuitive to obey the rule in both balance_wb_limits and it's
>> caller in which case balance_wb_limits and it's caller should stop to do anything
>> when freerun state of wb is first seen.
>> But no insistant on this...
>
> Hmm... can you at least add comments pointing out that if freerun, the
> limits fields are invalid?
Sure, will add it in next version. Thanks
>
> Thanks.
>
next prev parent reply other threads:[~2024-06-06 3:24 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-05-14 12:52 [PATCH v2 0/8] Add helper functions to remove repeated code and improve readability of cgroup writeback Kemeng Shi
2024-05-14 12:52 ` [PATCH v2 1/8] writeback: factor out wb_bg_dirty_limits to remove repeated code Kemeng Shi
2024-05-14 12:52 ` [PATCH v2 2/8] writeback: add general function domain_dirty_avail to calculate dirty and avail of domain Kemeng Shi
2024-05-30 18:19 ` Tejun Heo
2024-05-14 12:52 ` [PATCH v2 3/8] writeback: factor out domain_over_bg_thresh to remove repeated code Kemeng Shi
2024-05-14 12:52 ` [PATCH v2 4/8] writeback: Factor out code of freerun " Kemeng Shi
2024-05-14 12:52 ` [PATCH v2 5/8] writeback: factor out wb_dirty_freerun to remove more repeated freerun code Kemeng Shi
2024-05-30 18:29 ` Tejun Heo
2024-05-14 12:52 ` [PATCH v2 6/8] writeback: factor out balance_domain_limits to remove repeated code Kemeng Shi
2024-05-14 12:52 ` [PATCH v2 7/8] writeback: factor out wb_dirty_exceeded " Kemeng Shi
2024-05-30 18:31 ` Tejun Heo
2024-05-14 12:52 ` [PATCH v2 8/8] writeback: factor out balance_wb_limits " Kemeng Shi
2024-05-30 18:33 ` Tejun Heo
2024-06-03 6:39 ` Kemeng Shi
2024-06-03 18:09 ` Tejun Heo
2024-06-06 3:24 ` Kemeng Shi [this message]
2024-05-30 18:35 ` [PATCH v2 0/8] Add helper functions to remove repeated code and improve readability of cgroup writeback Tejun Heo
2024-05-30 18:55 ` Andrew Morton
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=6d5e260e-4910-92d1-faf4-8aee0b78b16d@huaweicloud.com \
--to=shikemeng@huaweicloud.com \
--cc=akpm@linux-foundation.org \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=tj@kernel.org \
--cc=willy@infradead.org \
/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;
as well as URLs for NNTP newsgroup(s).