[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CALPaoChkEkH_oKfUXut6WtXZiK6K8gM1eLk+2NWXkhJsAHtzCw@mail.gmail.com>
Date: Thu, 30 Mar 2023 14:50:26 +0200
From: Peter Newman <peternewman@...gle.com>
To: Reinette Chatre <reinette.chatre@...el.com>
Cc: fenghua.yu@...el.com, Babu.Moger@....com, bp@...en8.de,
dave.hansen@...ux.intel.com, eranian@...gle.com,
gupasani@...gle.com, hpa@...or.com, james.morse@....com,
linux-kernel@...r.kernel.org, mingo@...hat.com, skodak@...gle.com,
tglx@...utronix.de, tony.luck@...el.com, x86@...nel.org
Subject: Re: [PATCH v4 2/3] x86/resctrl: Parameterize rdt_move_group_tasks()
task matching
Hi Reinette,
On Thu, Mar 23, 2023 at 7:02 PM Reinette Chatre
<reinette.chatre@...el.com> wrote:
> On 3/8/2023 5:14 AM, Peter Newman wrote:
> > +/*
> > + * If @from is NULL, then all tasks in the systems are moved unconditionally
> > + * (used for teardown).
>
> Could this description be expanded to describe what the matching does? Just jumping
> in with the above sentence is quite cryptic.
>
> > + */
> > +static bool rmdir_match(struct task_struct *t, struct rdtgroup *from)
>
> Could the function's name please reflect what the function does as opposed to
> what the current users are doing at the time they call it? Perhaps
> something like "task_in_any_group()" (thinking ahead about a possible
> "task_in_mon_group()" for the next patch, please feel free to change).
> Also note that the "from" is another naming that reflects the usage as
> opposed to what the function does. It could just be "rdtgrp".
I read over the behavior of this function more carefully to try to come
up with a more descriptive name and realized that for MON groups it
behaves identically to the new one I created for rename().
The original rdt_move_group_tasks() was actually fine all along so I'm
just going to drop this patch.
-Peter
Powered by blists - more mailing lists