[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <5165abfc-9f42-93ea-a888-11eaa4ab3420@bytedance.com>
Date: Thu, 25 Aug 2022 21:29:48 +0800
From: Chengming Zhou <zhouchengming@...edance.com>
To: Johannes Weiner <hannes@...xchg.org>
Cc: tj@...nel.org, mkoutny@...e.com, surenb@...gle.com,
gregkh@...uxfoundation.org, corbet@....net, mingo@...hat.com,
peterz@...radead.org, songmuchun@...edance.com,
cgroups@...r.kernel.org, linux-doc@...r.kernel.org,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH v3 10/10] sched/psi: per-cgroup PSI accounting
disable/re-enable interface
On 2022/8/25 21:20, Johannes Weiner wrote:
> On Thu, Aug 25, 2022 at 08:28:39PM +0800, Chengming Zhou wrote:
>> On 2022/8/24 17:59, Johannes Weiner wrote:
>>> Hi Chengming,
>>>
>>> Thanks for incorporating all the feedback. I have a few nitpicks
>>> below, but with those considered, please add:
>>>
>>> Acked-by: Johannes Weiner <hannes@...xchg.org>
>>>
>>> On Wed, Aug 24, 2022 at 04:18:29PM +0800, Chengming Zhou wrote:
>>>> @@ -5171,12 +5220,19 @@ static struct cftype cgroup_base_files[] = {
>>>> {
>>>> .name = "irq.pressure",
>>>> .flags = CFTYPE_PRESSURE,
>>>> + .file_offset = offsetof(struct cgroup, psi_files[PSI_IRQ]),
>>>> .seq_show = cgroup_irq_pressure_show,
>>>> .write = cgroup_irq_pressure_write,
>>>> .poll = cgroup_pressure_poll,
>>>> .release = cgroup_pressure_release,
>>>> },
>>>> #endif
>>>> + {
>>>> + .name = "cgroup.pressure",
>>>> + .flags = CFTYPE_PRESSURE,
>>>> + .seq_show = cgroup_psi_show,
>>>> + .write = cgroup_psi_write,
>>>
>>> To match the naming convention, these should be called
>>> cgroup_pressure_show() and cgroup_pressure_write().
>>
>> I just find cgroup_pressure_write() already exists, so I change the names
>> to cgroup_pressure_enable_show() and cgroup_pressure_enable_write(),
>> since this file name is simplified from "cgroup.pressure.enable".
>
> That makes two outliers instead of one. It's probably better to steal
> cgroup_pressure_write for cgroup.pressure, and rename the currently
> misnamed helper. How about do_pressure_write()? pressure_write()?
Ok, I will change that helper to pressure_write().
Thanks.
Powered by blists - more mailing lists