RE: [PATCH v9 04/13] x86/resctrl: Include new features in command line options

From: Moger, Babu
Date: Mon Dec 19 2022 - 10:34:04 EST


[AMD Official Use Only - General]



> -----Original Message-----
> From: Reinette Chatre <reinette.chatre@xxxxxxxxx>
> Sent: Thursday, December 15, 2022 11:12 AM
> To: Moger, Babu <Babu.Moger@xxxxxxx>; corbet@xxxxxxx;
> tglx@xxxxxxxxxxxxx; mingo@xxxxxxxxxx; bp@xxxxxxxxx
> Cc: fenghua.yu@xxxxxxxxx; dave.hansen@xxxxxxxxxxxxxxx; x86@xxxxxxxxxx;
> hpa@xxxxxxxxx; paulmck@xxxxxxxxxx; akpm@xxxxxxxxxxxxxxxxxxxx;
> quic_neeraju@xxxxxxxxxxx; rdunlap@xxxxxxxxxxxxx;
> damien.lemoal@xxxxxxxxxxxxxxxxxx; songmuchun@xxxxxxxxxxxxx;
> peterz@xxxxxxxxxxxxx; jpoimboe@xxxxxxxxxx; pbonzini@xxxxxxxxxx;
> chang.seok.bae@xxxxxxxxx; pawan.kumar.gupta@xxxxxxxxxxxxxxx;
> jmattson@xxxxxxxxxx; daniel.sneddon@xxxxxxxxxxxxxxx; Das1, Sandipan
> <Sandipan.Das@xxxxxxx>; tony.luck@xxxxxxxxx; james.morse@xxxxxxx;
> linux-doc@xxxxxxxxxxxxxxx; linux-kernel@xxxxxxxxxxxxxxx;
> bagasdotme@xxxxxxxxx; eranian@xxxxxxxxxx; christophe.leroy@xxxxxxxxxx;
> jarkko@xxxxxxxxxx; adrian.hunter@xxxxxxxxx; quic_jiles@xxxxxxxxxxx;
> peternewman@xxxxxxxxxx
> Subject: Re: [PATCH v9 04/13] x86/resctrl: Include new features in command
> line options
>
> Hi Babu,
>
> On 12/1/2022 7:36 AM, Babu Moger wrote:
> > Add the command line options to enable or disable the new resctrl features.
> > smba : Slow Memory Bandwidth Allocation bmec : Bandwidth Monitor Event
> > Configuration.
> >
> > Signed-off-by: Babu Moger <babu.moger@xxxxxxx>
> > ---
> > Documentation/admin-guide/kernel-parameters.txt | 2 +-
> > arch/x86/kernel/cpu/resctrl/core.c | 4 ++++
> > 2 files changed, 5 insertions(+), 1 deletion(-)
> >
> > diff --git a/Documentation/admin-guide/kernel-parameters.txt
> > b/Documentation/admin-guide/kernel-parameters.txt
> > index 42af9ca0127e..a7b6634f4426 100644
> > --- a/Documentation/admin-guide/kernel-parameters.txt
> > +++ b/Documentation/admin-guide/kernel-parameters.txt
> > @@ -5190,7 +5190,7 @@
> > rdt= [HW,X86,RDT]
> > Turn on/off individual RDT features. List is:
> > cmt, mbmtotal, mbmlocal, l3cat, l3cdp, l2cat, l2cdp,
> > - mba.
> > + mba, smba, bmec.
> > E.g. to turn on cmt and turn off mba use:
> > rdt=cmt,!mba
> >
> > diff --git a/arch/x86/kernel/cpu/resctrl/core.c
> > b/arch/x86/kernel/cpu/resctrl/core.c
> > index f6af3ac1ef20..10a8c9d96f32 100644
> > --- a/arch/x86/kernel/cpu/resctrl/core.c
> > +++ b/arch/x86/kernel/cpu/resctrl/core.c
> > @@ -659,6 +659,8 @@ enum {
> > RDT_FLAG_L2_CAT,
> > RDT_FLAG_L2_CDP,
> > RDT_FLAG_MBA,
> > + RDT_FLAG_SMBA,
> > + RDT_FLAG_BMEC,
> > };
> >
> > #define RDT_OPT(idx, n, f) \
> > @@ -682,6 +684,8 @@ static struct rdt_options rdt_options[] __initdata = {
> > RDT_OPT(RDT_FLAG_L2_CAT, "l2cat", X86_FEATURE_CAT_L2),
> > RDT_OPT(RDT_FLAG_L2_CDP, "l2cdp",
> X86_FEATURE_CDP_L2),
> > RDT_OPT(RDT_FLAG_MBA, "mba", X86_FEATURE_MBA),
> > + RDT_OPT(RDT_FLAG_SMBA, "smba", X86_FEATURE_SMBA),
> > + RDT_OPT(RDT_FLAG_BMEC, "bmec", X86_FEATURE_BMEC),
> > };
> > #define NUM_RDT_OPTIONS ARRAY_SIZE(rdt_options)
> >
> >
> >
>
> Reviewed-by: Reinette Chatre <reinette.chatre@xxxxxxxxx>

Thanks
Babu
>
> Reinette