[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <be1db2e1-b6e2-425c-81b0-00c8227b298d@amd.com>
Date: Tue, 16 Sep 2025 12:00:10 -0500
From: "Moger, Babu" <babu.moger@....com>
To: Reinette Chatre <reinette.chatre@...el.com>,
Borislav Petkov <bp@...en8.de>
Cc: corbet@....net, tony.luck@...el.com, Dave.Martin@....com,
james.morse@....com, tglx@...utronix.de, mingo@...hat.com,
dave.hansen@...ux.intel.com, x86@...nel.org, hpa@...or.com, kas@...nel.org,
rick.p.edgecombe@...el.com, akpm@...ux-foundation.org, paulmck@...nel.org,
frederic@...nel.org, pmladek@...e.com, rostedt@...dmis.org, kees@...nel.org,
arnd@...db.de, fvdl@...gle.com, seanjc@...gle.com, thomas.lendacky@....com,
pawan.kumar.gupta@...ux.intel.com, perry.yuan@....com,
manali.shukla@....com, sohil.mehta@...el.com, xin@...or.com,
Neeraj.Upadhyay@....com, peterz@...radead.org, tiala@...rosoft.com,
mario.limonciello@....com, dapeng1.mi@...ux.intel.com, michael.roth@....com,
chang.seok.bae@...el.com, linux-doc@...r.kernel.org,
linux-kernel@...r.kernel.org, linux-coco@...ts.linux.dev,
kvm@...r.kernel.org, peternewman@...gle.com, eranian@...gle.com,
gautham.shenoy@....com
Subject: Re: [PATCH v18 00/33] x86,fs/resctrl: Support AMD Assignable
Bandwidth Monitoring Counters (ABMC)
Hi Boris/Reinette,
On 9/15/25 16:07, Reinette Chatre wrote:
> Hi Boris,
>
> On 9/15/25 4:25 AM, Borislav Petkov wrote:
>> On Fri, Sep 05, 2025 at 04:33:59PM -0500, Babu Moger wrote:
>>> .../admin-guide/kernel-parameters.txt | 2 +-
>>> Documentation/filesystems/resctrl.rst | 325 ++++++
>>> MAINTAINERS | 1 +
>>> arch/x86/include/asm/cpufeatures.h | 1 +
>>> arch/x86/include/asm/msr-index.h | 2 +
>>> arch/x86/include/asm/resctrl.h | 16 -
>>> arch/x86/kernel/cpu/resctrl/core.c | 81 +-
>>> arch/x86/kernel/cpu/resctrl/internal.h | 56 +-
>>> arch/x86/kernel/cpu/resctrl/monitor.c | 248 +++-
>>> arch/x86/kernel/cpu/scattered.c | 1 +
>>> fs/resctrl/ctrlmondata.c | 26 +-
>>> fs/resctrl/internal.h | 58 +-
>>> fs/resctrl/monitor.c | 1008 ++++++++++++++++-
>>> fs/resctrl/rdtgroup.c | 252 ++++-
>>> include/linux/resctrl.h | 148 ++-
>>> include/linux/resctrl_types.h | 18 +-
>>> 16 files changed, 2019 insertions(+), 224 deletions(-)
>>
>> Ok, I've rebased and pushed out the pile into tip:x86/cache.
>>
>> Please run it one more time to make sure all is good.
>
> Thank you very much.
>
> I successfully completed as much testing as I can do without the hardware that has
> the feature. Will leave the actual feature sanity check to Babu.
I’ve completed the overnight test runs, and everything is working as expected.
However, I discovered an issue with automatic counter assignment that I
introduced during the v17 → v18 rebase. This is my bad. The automatic
merge mistakenly placed the code snippet in rdtgroup_unassign_cntrs()
instead of under mbm_assign_on_mkdir.
Here is the patch snippet. Will send the fix patch separately.
diff --git a/fs/resctrl/monitor.c b/fs/resctrl/monitor.c
index 50c24460d992..4076336fbba6 100644
--- a/fs/resctrl/monitor.c
+++ b/fs/resctrl/monitor.c
@@ -1200,7 +1200,8 @@ void rdtgroup_assign_cntrs(struct rdtgroup *rdtgrp)
{
struct rdt_resource *r = resctrl_arch_get_resource(RDT_RESOURCE_L3);
- if (!r->mon_capable || !resctrl_arch_mbm_cntr_assign_enabled(r))
+ if (!r->mon_capable || !resctrl_arch_mbm_cntr_assign_enabled(r) ||
+ !r->mon.mbm_assign_on_mkdir)
return;
if (resctrl_is_mon_event_enabled(QOS_L3_MBM_TOTAL_EVENT_ID))
@@ -1258,8 +1259,7 @@ void rdtgroup_unassign_cntrs(struct rdtgroup *rdtgrp)
{
struct rdt_resource *r = resctrl_arch_get_resource(RDT_RESOURCE_L3);
- if (!r->mon_capable || !resctrl_arch_mbm_cntr_assign_enabled(r) ||
- !r->mon.mbm_assign_on_mkdir)
+ if (!r->mon_capable || !resctrl_arch_mbm_cntr_assign_enabled(r))
return;
if (resctrl_is_mon_event_enabled(QOS_L3_MBM_TOTAL_EVENT_ID))
--
2.34.1
--
Thanks
Babu Moger
Powered by blists - more mailing lists