From: Reinette Chatre <reinette.chatre@intel.com>
To: Ben Horgan <ben.horgan@arm.com>
Cc: <linux-kernel@vger.kernel.org>, <tony.luck@intel.com>,
<Dave.Martin@arm.com>, <james.morse@arm.com>,
<babu.moger@amd.com>, <tglx@kernel.org>, <mingo@redhat.com>,
<bp@alien8.de>, <dave.hansen@linux.intel.com>, <x86@kernel.org>,
<hpa@zytor.com>, <fenghuay@nvidia.com>,
<tan.shaopeng@fujitsu.com>
Subject: Re: [PATCH v1 1/4] x86,fs/resctrl: Make resctrl_arch_is_evt_configurable() aware of mbm_assign_mode
Date: Thu, 5 Mar 2026 09:22:55 -0800 [thread overview]
Message-ID: <940210db-1447-4a0e-8605-a3e83989afb2@intel.com> (raw)
In-Reply-To: <fa0eedce-cc38-4c39-8c9a-2aa3e0ce606f@arm.com>
Hi Ben,
On 3/5/26 2:01 AM, Ben Horgan wrote:
> On 3/4/26 22:50, Reinette Chatre wrote:
>> On 3/4/26 1:01 PM, Ben Horgan wrote:
>>> So, to try and bring this back to what we can be done now for MPAM to
>>> fit into the counter mode assignment interface. Just support
>>> mbm_total_bytes and then num_mbm_cntrs is correct (nothing to do). Make
>>> the event_filter file always display all the bandwidth types and make
>>> that the only value that be the only value it accepts (instead of hiding
>>> the event_filter file). If you agree I'll respin with that.
>>
>> From resctrl side this sounds fine. I don't have any insight into what, if any,
>> kind of gymnastics the MPAM driver needs to do to make the discovered MSCs with
>> their varying scope and internal vs external counts fit into this. If initial
>> implementation indeed forces some components into categories that are not a good
>> match then when resctrl later does get support for diverse components there may
>> be surprises to user space along the way. For example, user space may not see the
>> same memory bandwidth numbers reported by the same events on the same system as
>> the interface evolves.
>
> Indeed, we have already weeded a few things out of the MPAM driver for
> similar reasons. If we start with mpam only supporting a
> non-configurable mbm_total_bytes with ABMC I think we're ok. I'll drop
> the non-ABMC bandwidth counter support from the MPAM driver as even if
> we've got enough counters, one per (CTRL_MON/MON, evt), we can use ABMC.
It sounds like the expectation is that when there are enough counters the user
will then run with "mbm_assign_on_mkdir" set so that counters are always dynamically
assigned and thus essentially be "non-ABMC bandwidth counter support"?
Since "mbm_assign_on_mkdir" is set by default then user space should get sane
behavior by default.
Alternatively, a user space would just always run with "mbm_assign_on_mkdir"
off and have full control over monitor assignment even when it is not necessary.
Sounds good to me.
> Also, when event configuration (read/write filtering) using user defined
> (or new) events is added this will mean that enough counters becomes a
> higher limit. That will mean that the software controller is not usable
> but for now I think we can just fail when that mount option, mba_MBps,
> is used. Later we can consider using non-ABMC bandwidth counters when
> the software controller is requested.
ok. Since info/last_cmd_status is not available to to user when mount fail,
please do add a message to kernel log to help diagnose resctrl mount failure.
>
>>
>> "make that the only value that be the only value it accepts" - are you saying that
>> whatever is displayed when user views the "event_filter" file is what the
>> user can write to the "event_filter" file? I find this a challenging interface
>> for user space to use. The expectation is that the user can write any supported
>> memory transaction to that file and when writing fails it can only be because
>> of an invalid memory transaction. How can user space know that events are not
>> configurable at all? It sounds as though user space is expected to try configuring
>> the event with a memory transaction and then, presumably, check last_cmd_status?
>>
>> Could this not be simplified by making the "event_filter" file read-only on
>> MPAM systems?
>
> Yes, we'll need some finer grained control for which sets of bandwidth
> types can be configured further down the line but going with read-only
> for when there is only one fixed set seems good to me.
Thank you very much.
Reinette
next prev parent reply other threads:[~2026-03-05 17:23 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-02-25 20:19 [PATCH v1 0/4] x86,fs/resctrl: Pave the way for MPAM counter assignment Ben Horgan
2026-02-25 20:19 ` [PATCH v1 1/4] x86,fs/resctrl: Make resctrl_arch_is_evt_configurable() aware of mbm_assign_mode Ben Horgan
2026-03-02 23:11 ` Reinette Chatre
2026-03-03 12:29 ` Ben Horgan
2026-03-03 18:09 ` Reinette Chatre
2026-03-04 11:07 ` Ben Horgan
2026-03-04 17:02 ` Reinette Chatre
2026-03-04 17:37 ` Ben Horgan
2026-03-04 19:23 ` Reinette Chatre
2026-03-04 21:01 ` Ben Horgan
2026-03-04 22:50 ` Reinette Chatre
2026-03-05 10:01 ` Ben Horgan
2026-03-05 17:22 ` Reinette Chatre [this message]
2026-03-05 17:34 ` Ben Horgan
2026-02-25 20:19 ` [PATCH v1 2/4] fs/resctrl: Only show 'event_filter' files if events are configurable Ben Horgan
2026-03-02 23:12 ` Reinette Chatre
2026-03-03 14:00 ` Ben Horgan
2026-03-03 18:14 ` Reinette Chatre
2026-03-04 11:31 ` Ben Horgan
2026-03-04 17:03 ` Reinette Chatre
2026-03-04 17:53 ` Ben Horgan
2026-02-25 20:19 ` [PATCH v1 3/4] fs/resctrl: Disallow the software controller when mbm counters are assignable Ben Horgan
2026-02-25 20:19 ` [PATCH v1 4/4] arm_mpam: resctrl: Use new signature for resctrl_arch_is_evt_configurable() Ben Horgan
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=940210db-1447-4a0e-8605-a3e83989afb2@intel.com \
--to=reinette.chatre@intel.com \
--cc=Dave.Martin@arm.com \
--cc=babu.moger@amd.com \
--cc=ben.horgan@arm.com \
--cc=bp@alien8.de \
--cc=dave.hansen@linux.intel.com \
--cc=fenghuay@nvidia.com \
--cc=hpa@zytor.com \
--cc=james.morse@arm.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@redhat.com \
--cc=tan.shaopeng@fujitsu.com \
--cc=tglx@kernel.org \
--cc=tony.luck@intel.com \
--cc=x86@kernel.org \
/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
all inboxes | Powered by JetHome®