Linux-ARM-Kernel Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Reinette Chatre <reinette.chatre@intel.com>
To: Jinjie Ruan <ruanjinjie@huawei.com>, <ben.horgan@arm.com>,
	<james.morse@arm.com>, <Dave.Martin@arm.com>,
	<fenghuay@nvidia.com>
Cc: <tony.luck@intel.com>, <yu.c.chen@intel.com>,
	<babu.moger@amd.com>, <fustini@kernel.org>,
	<linux-arm-kernel@lists.infradead.org>,
	<linux-kernel@vger.kernel.org>, <patches@lists.linux.dev>
Subject: Re: [RFC PATCH v2 00/10] arm_mpam: resctrl: Separate MPAM domains
Date: Tue, 27 Oct 2026 07:23:34 -0700	[thread overview]
Message-ID: <3d64061e-e571-43ea-8216-170a726b4029@intel.com> (raw)
In-Reply-To: <9e0521af-4ae2-4a53-bbd5-2d86cceb69c3@huawei.com>

Hi Jinjie,

On 10/26/26 8:42 PM, Jinjie Ruan wrote:
> 
> 
> 在 2026/10/20 6:07, Reinette Chatre 写道:
>> RFC v1: https://lore.kernel.org/lkml/85ca29e89eacf12cfa7071249419e7cadb8f0691.1788220029.git.reinette.chatre@intel.com/
>>
>> The MPAM driver represents a resctrl domain with a single structure,
>> struct mpam_resctrl_dom, that holds both a control domain and a
>> monitoring domain. On a system that supports both allocation and
>> monitoring, one instance is created for each domain and its two
>> domains are added to the resource's control and monitoring domain
>> lists.
>>
>> Holding both domains in one structure requires control and monitoring
>> to be done at the same scope, and ties each control domain to a
>> monitoring domain. This does not fit the proposed support for multiple
>> controls per resource [1]. There, each control of a resource, for
>> example a "min" and a "max" memory bandwidth control, has its own list
>> of control domains while the resource keeps a single list of
>> monitoring domains. With one structure for both, every control domain
>> would come with a monitoring domain of its own, which does not reflect
>> the resource.
>>
>> This series gives control and monitoring domains their own structures,
>> set up and torn down independently as CPUs come online and go offline,
>> in preparation for supporting multiple controls per resource. Along
>> the way it stops failing CPU online when a domain cannot be set up,
>> and adds checks when setting up a monitoring domain.
>>
>>   1-2   Preparatory cleanups of domain allocation
>>   3     Do not fail CPU online when domain setup fails
>>   4-6   Separate the control and monitoring domain structures
>>   7-9   Checks when setting up a monitoring domain
>>   10    Comment update, kept separate for review
>>
>> An earlier version of the domain split was posted on its own [2]. This
>> version incorporates the feedback from that discussion. It gives each
>> type of domain its own structure instead of duplicating the shared
>> one, sets up each domain independently instead of undoing one domain
>> when setting up the other fails, and adds the checks in patches 8 and
>> 9.
>>
>> Patch 7 turns a WARN_ON_ONCE(0) into a warning that fires. It is a
>> separate patch because it is not clear whether the silent failure was
>> intended. If it was, the patch can instead drop the dead
>> WARN_ON_ONCE().
>>
>> This is an RFC because I am only able to compile test MPAM changes,
>> which is also why the patches are small and each change is justified
>> on its own. Patches can be squashed if preferred, for example patch 10
>> into patches 5 and 9. Testing on MPAM hardware would be greatly
>> appreciated, as is any other feedback.
> 
> Hi Reinette,
> 
> I tested it on a QEMU with MPAM rebased on v7.3-rc6 and all pass:
> 
> 1、Resctrl mounts,L3/L2 each report 32 closids (control IDs)
> 2、Cache and memory bandwidth controls
> 3、Priority, min, max, option and hard-limit: write, read back, and the
> 
>    emulated hardware shows the same value
> 4、CDP mode and usage/bandwidth counters
> 5、All builds pass without warnings: arm64/x86_64, debug on/off,
>    self-tests on/off, resctrl off, ACPI off
> 
> Test cases: https://github.com/ruanjinjie-eng/mpam_testcase/tree/qemu
> 
> Tested-by: Jinjie Ruan ruanjinjie@huawei.com
Thank you very much for this thorough testing. It is much appreciated.

Reinette



      reply	other threads:[~2026-10-27 14:23 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-10-19 22:07 [RFC PATCH v2 00/10] arm_mpam: resctrl: Separate MPAM domains Reinette Chatre
2026-10-19 22:07 ` [RFC PATCH v2 01/10] arm_mpam: resctrl: Use find_component() when allocating a domain Reinette Chatre
2026-10-23  8:07   ` Jinjie Ruan
2026-10-23 14:52     ` Reinette Chatre
2026-10-19 22:07 ` [RFC PATCH v2 02/10] arm_mpam: resctrl: Rename ctrl_comp in mpam_resctrl_alloc_domain() Reinette Chatre
2026-10-23  8:08   ` Jinjie Ruan
2026-10-23 14:53     ` Reinette Chatre
2026-10-19 22:07 ` [RFC PATCH v2 03/10] arm_mpam: resctrl: Do not fail CPU online when domain setup fails Reinette Chatre
2026-10-26  9:51   ` Jinjie Ruan
2026-10-19 22:07 ` [RFC PATCH v2 04/10] arm_mpam: resctrl: Split control and monitoring domain setup into helpers Reinette Chatre
2026-10-26 11:49   ` Jinjie Ruan
2026-10-19 22:07 ` [RFC PATCH v2 05/10] arm_mpam: resctrl: Give the monitoring domain its own structure Reinette Chatre
2026-10-26 12:14   ` Jinjie Ruan
2026-10-26 16:55     ` Reinette Chatre
2026-10-27  1:12       ` Jinjie Ruan
2026-10-19 22:07 ` [RFC PATCH v2 06/10] arm_mpam: resctrl: Rename struct mpam_resctrl_dom to mpam_resctrl_ctrl_dom Reinette Chatre
2026-10-26 12:40   ` Jinjie Ruan
2026-10-19 22:07 ` [RFC PATCH v2 07/10] arm_mpam: resctrl: Warn when no monitoring component is found for a CPU Reinette Chatre
2026-10-26 13:14   ` Jinjie Ruan
2026-10-19 22:07 ` [RFC PATCH v2 08/10] arm_mpam: resctrl: Require a component for each monitoring event Reinette Chatre
2026-10-19 22:07 ` [RFC PATCH v2 09/10] arm_mpam: resctrl: Require monitoring components to cover the same CPUs Reinette Chatre
2026-10-19 22:07 ` [RFC PATCH v2 10/10] arm_mpam: resctrl: Update the comment on monitoring domain setup Reinette Chatre
2026-10-22 10:45 ` [RFC PATCH v2 00/10] arm_mpam: resctrl: Separate MPAM domains Ben Horgan
2026-10-22 15:43   ` Reinette Chatre
2026-10-27  3:42 ` Jinjie Ruan
2026-10-27 14:23   ` Reinette Chatre [this message]

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=3d64061e-e571-43ea-8216-170a726b4029@intel.com \
    --to=reinette.chatre@intel.com \
    --cc=Dave.Martin@arm.com \
    --cc=babu.moger@amd.com \
    --cc=ben.horgan@arm.com \
    --cc=fenghuay@nvidia.com \
    --cc=fustini@kernel.org \
    --cc=james.morse@arm.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=patches@lists.linux.dev \
    --cc=ruanjinjie@huawei.com \
    --cc=tony.luck@intel.com \
    --cc=yu.c.chen@intel.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