From: Ben Horgan <ben.horgan@arm.com>
To: Reinette Chatre <reinette.chatre@intel.com>,
Babu Moger <babu.moger@amd.com>,
corbet@lwn.net, tony.luck@intel.com, Dave.Martin@arm.com,
james.morse@arm.com, tglx@kernel.org, mingo@redhat.com,
bp@alien8.de, dave.hansen@linux.intel.com
Cc: x86@kernel.org, hpa@zytor.com, peterz@infradead.org,
juri.lelli@redhat.com, vincent.guittot@linaro.org,
dietmar.eggemann@arm.com, rostedt@goodmis.org,
bsegall@google.com, mgorman@suse.de, vschneid@redhat.com,
akpm@linux-foundation.org, pawan.kumar.gupta@linux.intel.com,
pmladek@suse.com, feng.tang@linux.alibaba.com, kees@kernel.org,
arnd@arndb.de, fvdl@google.com, lirongqing@baidu.com,
bhelgaas@google.com, seanjc@google.com, xin@zytor.com,
manali.shukla@amd.com, dapeng1.mi@linux.intel.com,
chang.seok.bae@intel.com, mario.limonciello@amd.com,
naveen@kernel.org, elena.reshetova@intel.com,
thomas.lendacky@amd.com, linux-doc@vger.kernel.org,
linux-kernel@vger.kernel.org, kvm@vger.kernel.org,
peternewman@google.com, eranian@google.com,
gautham.shenoy@amd.com
Subject: Re: [RFC PATCH 09/19] x86/resctrl: Add plza_capable in rdt_resource data structure
Date: Wed, 11 Feb 2026 17:48:16 +0000 [thread overview]
Message-ID: <fd528a50-50c9-4376-9486-7b8eb3f026aa@arm.com> (raw)
In-Reply-To: <ed2d089b-0249-4f1a-8da2-5e61d5d1158f@intel.com>
Hi Babu, Reinette,
On 2/11/26 16:54, Reinette Chatre wrote:
> Hi Ben,
>
> On 2/11/26 7:19 AM, Ben Horgan wrote:
>> Hi Babu,
>>
>> On 1/21/26 21:12, Babu Moger wrote:
>>> Add plza_capable field to the rdt_resource structure to indicate whether
>>> Privilege Level Zero Association (PLZA) is supported for that resource
>>> type.
>>>
>>> Signed-off-by: Babu Moger <babu.moger@amd.com>
>>> ---
>>> arch/x86/kernel/cpu/resctrl/core.c | 6 ++++++
>>> arch/x86/kernel/cpu/resctrl/rdtgroup.c | 5 +++++
>>> include/linux/resctrl.h | 3 +++
>>> 3 files changed, 14 insertions(+)
>>>
>>> diff --git a/arch/x86/kernel/cpu/resctrl/core.c b/arch/x86/kernel/cpu/resctrl/core.c
>>> index 2de3140dd6d1..e41fe5fa3f30 100644
>>> --- a/arch/x86/kernel/cpu/resctrl/core.c
>>> +++ b/arch/x86/kernel/cpu/resctrl/core.c
>>> @@ -295,6 +295,9 @@ static __init bool __rdt_get_mem_config_amd(struct rdt_resource *r)
>>>
>>> r->alloc_capable = true;
>>>
>>> + if (rdt_cpu_has(X86_FEATURE_PLZA))
>>> + r->plza_capable = true;
>>> +
>>> return true;
>>> }
>>>
>>> @@ -314,6 +317,9 @@ static void rdt_get_cache_alloc_cfg(int idx, struct rdt_resource *r)
>>> if (boot_cpu_data.x86_vendor == X86_VENDOR_INTEL)
>>> r->cache.arch_has_sparse_bitmasks = ecx.split.noncont;
>>> r->alloc_capable = true;
>>> +
>>> + if (rdt_cpu_has(X86_FEATURE_PLZA))
>>> + r->plza_capable = true;
>>> }
>>>
>>> static void rdt_get_cdp_config(int level)
>>> diff --git a/arch/x86/kernel/cpu/resctrl/rdtgroup.c b/arch/x86/kernel/cpu/resctrl/rdtgroup.c
>>> index 885026468440..540e1e719d7f 100644
>>> --- a/arch/x86/kernel/cpu/resctrl/rdtgroup.c
>>> +++ b/arch/x86/kernel/cpu/resctrl/rdtgroup.c
>>> @@ -229,6 +229,11 @@ bool resctrl_arch_get_cdp_enabled(enum resctrl_res_level l)
>>> return rdt_resources_all[l].cdp_enabled;
>>> }
>>>
>>> +bool resctrl_arch_get_plza_capable(enum resctrl_res_level l)
>>> +{
>>> + return rdt_resources_all[l].r_resctrl.plza_capable;
>>> +}
>>> +
>>> void resctrl_arch_reset_all_ctrls(struct rdt_resource *r)
>>> {
>>> struct rdt_hw_resource *hw_res = resctrl_to_arch_res(r);
>>> diff --git a/include/linux/resctrl.h b/include/linux/resctrl.h
>>> index 63d74c0dbb8f..ae252a0e6d92 100644
>>> --- a/include/linux/resctrl.h
>>> +++ b/include/linux/resctrl.h
>>> @@ -319,6 +319,7 @@ struct resctrl_mon {
>>> * @name: Name to use in "schemata" file.
>>> * @schema_fmt: Which format string and parser is used for this schema.
>>> * @cdp_capable: Is the CDP feature available on this resource
>>> + * @plza_capable: Is Privilege Level Zero Association capable?
>>> */
>>> struct rdt_resource {
>>> int rid;
>>> @@ -334,6 +335,7 @@ struct rdt_resource {
>>> char *name;
>>> enum resctrl_schema_fmt schema_fmt;
>>> bool cdp_capable;
>>> + bool plza_capable;
>>
>> Why are you making plza a resource property? Certainly for MPAM we'd
>> want this to be global across resources and I see above that you are
>> just checking a cpu property rather then anything per resource.
>
> I agree. For reference: https://lore.kernel.org/lkml/6fe647ce-2e65-45dd-9c79-d1c2cb0991fe@intel.com/
Ah, didn't mean to duplicate. Glad we agree.
> > One possible concern for MPAM related to this caught my eye. From
> https://lore.kernel.org/lkml/20260203214342.584712-10-ben.horgan@arm.com/ :
>
> If an SMCU is not shared with other cpus then it is implementation
> defined whether the configuration from MPAMSM_EL1 is used or that from
> the appropriate MPAMy_ELx. As we set the same, PMG_D and PARTID_D,
> configuration for MPAM0_EL1, MPAM1_EL1 and MPAMSM_EL1 the resulting
> configuration is the same regardless.
>
> I admit that I am not yet comfortable with the MPAM register usages ... but from
> above it sounds to me as though if resctrl associates different CLOSID/PARTID and
> RMID/PMG with a task to be used at different privilege levels as planned with this
> work then the mapping to MPAM0_EL1 and MPAM1_EL1 may be easy but MPAMSM_EL1 may be
> difficult?
Thanks for bringing this up. The kernel has limited usage of the SMCU.
The SMCU performs matrix and simd instructions for the cpu. In the
kernel these are just used for save/restore of the simd/matrix register
state at context switch and possibly in the future usage could be
extended in a similar way to old style simd, neon, and be guarded by
something like neon_begin(), neon_end(). If we wish to use kernel
specific pmg/partids for those load/stores we can copy the MPAM1_EL1
configuration into MPAMSM_EL1. (Then it doesn't matter if the
configuration from MPAMSM_EL1 or MPAM1_EL1 is used.) This is analogous
to how we copy MPAM1_EL1 to MPAM2_EL2 to provide a configuration for the
kvm nvhe hypervisor.
See:
https://lore.kernel.org/kvmarm/9a8a163e-887a-45fc-aae5-45e564360c8b@arm.com/T/#m23281370dbcdaca98482769de1eae496afadc3b0
>
>
> Reinette
>
>
Thanks,
Ben
next prev parent reply other threads:[~2026-02-11 17:48 UTC|newest]
Thread overview: 114+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-01-21 21:12 [RFC PATCH 00/19] x86,fs/resctrl: Support for Global Bandwidth Enforcement and Priviledge Level Zero Association Babu Moger
2026-01-21 21:12 ` [RFC PATCH 01/19] x86,fs/resctrl: Add support for Global Bandwidth Enforcement (GLBE) Babu Moger
2026-02-09 18:44 ` Reinette Chatre
2026-02-11 1:07 ` Moger, Babu
2026-02-11 16:54 ` Reinette Chatre
2026-02-11 21:18 ` Babu Moger
2026-02-12 3:51 ` Reinette Chatre
2026-02-12 19:09 ` Babu Moger
2026-02-13 0:05 ` Reinette Chatre
2026-02-13 1:51 ` Moger, Babu
2026-02-13 16:17 ` Reinette Chatre
2026-02-13 23:14 ` Moger, Babu
2026-02-14 0:01 ` Reinette Chatre
2026-02-16 16:05 ` Babu Moger
2026-02-20 10:07 ` Ben Horgan
2026-02-20 18:39 ` Reinette Chatre
2026-02-23 9:29 ` Ben Horgan
2026-02-21 0:12 ` Moger, Babu
2026-02-23 13:21 ` Fenghua Yu
2026-02-23 17:38 ` Reinette Chatre
2026-02-23 13:21 ` Fenghua Yu
2026-01-21 21:12 ` [RFC PATCH 02/19] x86,fs/resctrl: Add the resource for Global Memory Bandwidth Allocation Babu Moger
2026-01-21 21:12 ` [RFC PATCH 03/19] fs/resctrl: Add new interface max_bandwidth Babu Moger
2026-02-06 23:58 ` Reinette Chatre
2026-02-09 23:52 ` Moger, Babu
2026-01-21 21:12 ` [RFC PATCH 04/19] fs/resctrl: Add the documentation for Global Memory Bandwidth Allocation Babu Moger
2026-02-03 0:00 ` Luck, Tony
2026-02-03 16:38 ` Babu Moger
2026-02-09 16:32 ` Reinette Chatre
2026-02-10 19:44 ` Babu Moger
2026-01-21 21:12 ` [RFC PATCH 05/19] x86,fs/resctrl: Add support for Global Slow Memory Bandwidth Allocation (GSMBA) Babu Moger
2026-01-21 21:12 ` [RFC PATCH 06/19] x86,fs/resctrl: Add the resource for Global Slow Memory Bandwidth Enforcement(GLSBE) Babu Moger
2026-01-21 21:12 ` [RFC PATCH 07/19] fs/resctrl: Add the documentation for Global Slow Memory Bandwidth Allocation Babu Moger
2026-01-21 21:12 ` [RFC PATCH 08/19] x86/resctrl: Support Privilege-Level Zero Association (PLZA) Babu Moger
2026-01-21 21:12 ` [RFC PATCH 09/19] x86/resctrl: Add plza_capable in rdt_resource data structure Babu Moger
2026-02-11 15:19 ` Ben Horgan
2026-02-11 16:54 ` Reinette Chatre
2026-02-11 17:48 ` Ben Horgan [this message]
2026-02-13 15:50 ` Moger, Babu
2026-01-21 21:12 ` [RFC PATCH 10/19] fs/resctrl: Expose plza_capable via control info file Babu Moger
2026-01-21 21:12 ` [RFC PATCH 11/19] resctrl: Introduce PLZA static key enable/disable helpers Babu Moger
2026-01-21 21:12 ` [RFC PATCH 12/19] x86/resctrl: Add data structures and definitions for PLZA configuration Babu Moger
2026-01-21 21:12 ` [RFC PATCH 13/19] x86/resctrl: Add PLZA state tracking and context switch handling Babu Moger
2026-01-27 22:30 ` Luck, Tony
2026-01-28 16:01 ` Moger, Babu
2026-01-28 17:12 ` Luck, Tony
2026-01-28 17:41 ` Moger, Babu
2026-01-28 17:44 ` Moger, Babu
2026-01-28 19:17 ` Luck, Tony
2026-02-10 16:17 ` Reinette Chatre
2026-02-10 18:04 ` Reinette Chatre
2026-02-11 16:40 ` Ben Horgan
2026-02-11 19:46 ` Luck, Tony
2026-02-11 22:22 ` Reinette Chatre
2026-02-12 13:55 ` Ben Horgan
2026-02-12 18:37 ` Reinette Chatre
2026-02-16 15:18 ` Ben Horgan
2026-02-17 18:51 ` Reinette Chatre
2026-02-17 21:44 ` Luck, Tony
2026-02-17 22:37 ` Reinette Chatre
2026-02-17 22:52 ` Luck, Tony
2026-02-17 23:55 ` Reinette Chatre
2026-02-18 16:44 ` Luck, Tony
2026-02-19 17:03 ` Luck, Tony
2026-02-19 17:45 ` Ben Horgan
2026-02-20 8:21 ` Drew Fustini
2026-02-19 17:33 ` Ben Horgan
2026-02-20 2:53 ` Reinette Chatre
2026-02-20 22:44 ` Moger, Babu
2026-02-23 17:12 ` Reinette Chatre
2026-02-23 22:35 ` Moger, Babu
2026-02-23 23:13 ` Reinette Chatre
2026-02-24 19:37 ` Babu Moger
2026-02-23 10:08 ` Ben Horgan
2026-02-23 16:38 ` Reinette Chatre
2026-02-24 9:36 ` Ben Horgan
2026-02-24 16:13 ` Reinette Chatre
2026-02-19 11:06 ` Ben Horgan
2026-02-19 18:12 ` Luck, Tony
2026-02-19 18:36 ` Reinette Chatre
2026-02-19 10:21 ` Ben Horgan
2026-02-19 18:14 ` Reinette Chatre
2026-02-23 9:48 ` Ben Horgan
2026-02-13 16:37 ` Moger, Babu
2026-02-13 17:02 ` Luck, Tony
2026-02-16 19:24 ` Babu Moger
2026-02-14 0:10 ` Reinette Chatre
2026-02-16 15:41 ` Ben Horgan
2026-02-16 22:52 ` Moger, Babu
2026-02-17 15:56 ` Ben Horgan
2026-02-17 16:38 ` Babu Moger
2026-02-18 9:54 ` Ben Horgan
2026-02-18 6:22 ` Stephane Eranian
2026-02-18 9:35 ` Ben Horgan
2026-02-19 10:27 ` Ben Horgan
2026-02-16 22:36 ` Moger, Babu
2026-02-12 10:00 ` Ben Horgan
2026-01-21 21:12 ` [RFC PATCH 14/19] x86,fs/resctrl: Add the functionality to configure PLZA Babu Moger
2026-01-29 19:13 ` Luck, Tony
2026-01-29 19:53 ` Babu Moger
2026-01-21 21:12 ` [RFC PATCH 15/19] fs/resctrl: Introduce PLZA attribute in rdtgroup interface Babu Moger
2026-01-21 21:12 ` [RFC PATCH 16/19] fs/resctrl: Implement rdtgroup_plza_write() to configure PLZA in a group Babu Moger
2026-01-28 22:03 ` Luck, Tony
2026-01-29 18:54 ` Luck, Tony
2026-01-29 19:31 ` Babu Moger
2026-01-29 19:42 ` Babu Moger
2026-02-10 0:05 ` Reinette Chatre
2026-02-11 23:10 ` Moger, Babu
2026-01-21 21:12 ` [RFC PATCH 17/19] fs/resctrl: Update PLZA configuration when cpu_mask changes Babu Moger
2026-01-21 21:12 ` [RFC PATCH 18/19] x86/resctrl: Refactor show_rdt_tasks() to support PLZA task matching Babu Moger
2026-01-21 21:12 ` [RFC PATCH 19/19] fs/resctrl: Add per-task PLZA enable support via rdtgroup Babu Moger
2026-02-03 19:58 ` [RFC PATCH 00/19] x86,fs/resctrl: Support for Global Bandwidth Enforcement and Priviledge Level Zero Association Luck, Tony
2026-02-10 0:27 ` Reinette Chatre
2026-02-11 0:40 ` Drew Fustini
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=fd528a50-50c9-4376-9486-7b8eb3f026aa@arm.com \
--to=ben.horgan@arm.com \
--cc=Dave.Martin@arm.com \
--cc=akpm@linux-foundation.org \
--cc=arnd@arndb.de \
--cc=babu.moger@amd.com \
--cc=bhelgaas@google.com \
--cc=bp@alien8.de \
--cc=bsegall@google.com \
--cc=chang.seok.bae@intel.com \
--cc=corbet@lwn.net \
--cc=dapeng1.mi@linux.intel.com \
--cc=dave.hansen@linux.intel.com \
--cc=dietmar.eggemann@arm.com \
--cc=elena.reshetova@intel.com \
--cc=eranian@google.com \
--cc=feng.tang@linux.alibaba.com \
--cc=fvdl@google.com \
--cc=gautham.shenoy@amd.com \
--cc=hpa@zytor.com \
--cc=james.morse@arm.com \
--cc=juri.lelli@redhat.com \
--cc=kees@kernel.org \
--cc=kvm@vger.kernel.org \
--cc=linux-doc@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=lirongqing@baidu.com \
--cc=manali.shukla@amd.com \
--cc=mario.limonciello@amd.com \
--cc=mgorman@suse.de \
--cc=mingo@redhat.com \
--cc=naveen@kernel.org \
--cc=pawan.kumar.gupta@linux.intel.com \
--cc=peternewman@google.com \
--cc=peterz@infradead.org \
--cc=pmladek@suse.com \
--cc=reinette.chatre@intel.com \
--cc=rostedt@goodmis.org \
--cc=seanjc@google.com \
--cc=tglx@kernel.org \
--cc=thomas.lendacky@amd.com \
--cc=tony.luck@intel.com \
--cc=vincent.guittot@linaro.org \
--cc=vschneid@redhat.com \
--cc=x86@kernel.org \
--cc=xin@zytor.com \
/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
Powered by JetHome