mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH v1 00/14] ARM: MPAM: add support for priority partitioning control
@ 2024-01-17 14:13 Amit Singh Tomar
  2024-01-17 14:13 ` [PATCH v1 01/14] fs/resctrl: group the resource control types for schemata list Amit Singh Tomar
                   ` (14 more replies)
  0 siblings, 15 replies; 21+ messages in thread
From: Amit Singh Tomar @ 2024-01-17 14:13 UTC (permalink / raw)
  To: linux-kernel, linux-arm-kernel
  Cc: fenghua.yu, reinette.chatre, james.morse, gcherian, robh,
	peternewman, dfustini, jonathan.cameron, Amit Singh Tomar

This patch-set is continuation to the RFC[1], we sent last year. The patches
that we sent earlier, embed the DSPRI (Downstream priority) value into already
existing schemata file, which is used to configure CAT (Cache Allocation Technology)
capabilities. For instance, in order to configure Downstream priority, DSPRI
value is passed in following way:

echo L3:0=ffff,a > schemata, where "a" dspri value, and ffff cache portion bitmaps.

But instead of using already existing, "L3" schemata, we can have new schemata
that is dedicated to this new/extended priority control (at the moment, extended
control is limited to only DSPRI but we can put new/more control same way). For
instance, this version uses new schemata L3DSPRI, and following is the way
to configure downstream priority value.

echo L3DSPRI:0=a > schemata, where "a" is dspri value.

Overall, the schemata for a system that support all these controls looks like:

MB:0=100
L3DSPRI:0=f
L3:0=ffff

and this approach aids in code decluttering, for instance, we don't have to 
really care about dspri flags (dspri_store, dspri_show, used in RFC version).

To help creating new schemata, Patch(1/14) is introduced (new one), It
basically divide the resource control type into two groups, and map it
to list of schemata(s).

"SCHEMA_BASIC" type is for already exiting schemata ("L3", and "MB") used
to configure features like CAT (Cache Allocation Technology), and MBA
(Memory Bandwidth Allocation).

"SCHEMA_DSPRI" type is for schemata (L3DSPRI), and used to configure
Downstream priority values. This is used in patch (3/14) when the
schemata list is extended to support priority partition control.

Took this idea from openEuler Kernel[1], pointed by Jonathan in previous discussion.

This division into groups help in configuring resource control of different
types based on control types (patch 6/14, and patch 8/14).

For now, patch (5/14), and (9/14) is split for easy review, eventually these
get squashed.

Patch (12/14) is reworked, and now priority value is inverted based on
DSPRI_0_IS_LOW value.

Patch(14/14) is a new patch, that export Maximum DSPRI value to resctrl's info
directory.

At the moment, these patches are restricted to support only the Downstream priority
control, but if this approach looks okay, can have support for both the priority controls
in next variant.

Also, these patches[3] are still based on older MPAM tree[3] from James, as facing some
trouble setting up the resource control with latest snapshots.

[1]: https://lore.kernel.org/lkml/20230901141731.00006f46@Huawei.com/T/
[2]: https://github.com/openeuler-mirror/kernel/commit/8139268b70398c37843a38bf8c7b243ad1f20c97
[3]: https://github.com/Amit-Radur/linux/commit/71ac4cca1eccb831ce04d3094f0cf794fc9d2d72
[4]: https://git.kernel.org/pub/scm/linux/kernel/git/morse/linux.git/log/?h=mpam/snapshot/v6.2

Amit Singh Tomar (14):
  fs/resctrl: group the resource control types for schemata list
  arm_mpam: resctrl: Detect priority partitioning capability
  arm_mpam: resctrl: extend the schemata list to support priority
    partition
  fs/resctrl: Set-up downstream priority partition resources
  fs/resctrl: fetch configuration based on control type
  arm_mpam: resctrl: Retrieve priority values from arch code
  fs/resctrl: Schemata write only for intended resource
  fs/resctrl: Extend schemata write for priority partition control
  fs/resctrl: set configuration based on Control type
  arm_mpam: resctrl: Facilitate writing downstream priority value
  arm_mpam: Fix Downstream and internal priority mask
  arm_mpam: Program Downstream priority value
  arm_mpam: Handle resource instances mapped to different controls
  arm64/mpam: resctrl: export DSPRI value to info directory

 arch/x86/kernel/cpu/resctrl/ctrlmondata.c |   9 +-
 drivers/platform/mpam/mpam_devices.c      |  72 +++++++++++----
 drivers/platform/mpam/mpam_internal.h     |   1 +
 drivers/platform/mpam/mpam_resctrl.c      |  81 +++++++++++++----
 fs/resctrl/ctrlmondata.c                  |  74 +++++++++++++--
 fs/resctrl/monitor.c                      |   6 +-
 fs/resctrl/rdtgroup.c                     | 105 ++++++++++++++++++----
 include/linux/resctrl.h                   |  19 +++-
 include/linux/resctrl_types.h             |   9 ++
 9 files changed, 309 insertions(+), 67 deletions(-)

-- 
2.25.1


^ permalink raw reply	[flat|nested] 21+ messages in thread

end of thread, other threads:[~2024-05-08 13:56 UTC | newest]

Thread overview: 21+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-01-17 14:13 [PATCH v1 00/14] ARM: MPAM: add support for priority partitioning control Amit Singh Tomar
2024-01-17 14:13 ` [PATCH v1 01/14] fs/resctrl: group the resource control types for schemata list Amit Singh Tomar
2024-01-17 19:21   ` Peter Newman
2024-01-17 14:13 ` [PATCH v1 02/14] arm_mpam: resctrl: Detect priority partitioning capability Amit Singh Tomar
2024-01-17 14:13 ` [PATCH v1 03/14] arm_mpam: resctrl: extend the schemata list to support priority partition Amit Singh Tomar
2024-01-17 14:13 ` [PATCH v1 04/14] fs/resctrl: Set-up downstream priority partition resources Amit Singh Tomar
2024-01-17 14:13 ` [PATCH v1 05/14] fs/resctrl: fetch configuration based on control type Amit Singh Tomar
2024-01-17 14:13 ` [PATCH v1 06/14] arm_mpam: resctrl: Retrieve priority values from arch code Amit Singh Tomar
2024-01-17 14:13 ` [PATCH v1 07/14] fs/resctrl: Schemata write only for intended resource Amit Singh Tomar
2024-01-17 14:13 ` [PATCH v1 08/14] fs/resctrl: Extend schemata write for priority partition control Amit Singh Tomar
2024-01-17 14:14 ` [PATCH v1 09/14] fs/resctrl: set configuration based on Control type Amit Singh Tomar
2024-01-17 14:14 ` [PATCH v1 10/14] arm_mpam: resctrl: Facilitate writing downstream priority value Amit Singh Tomar
2024-01-17 14:14 ` [PATCH v1 11/14] arm_mpam: Fix Downstream and internal priority mask Amit Singh Tomar
2024-01-17 14:14 ` [PATCH v1 12/14] arm_mpam: Program Downstream priority value Amit Singh Tomar
2024-01-17 14:14 ` [PATCH v1 13/14] arm_mpam: Handle resource instances mapped to different controls Amit Singh Tomar
2024-01-17 18:03   ` Peter Newman
2024-01-19 13:01     ` [EXT] " Amit Singh Tomar
2024-01-19 22:05       ` Peter Newman
2024-05-08 13:55         ` Amit Singh Tomar
2024-01-17 14:14 ` [PATCH v1 14/14] arm64/mpam: resctrl: export DSPRI value to info directory Amit Singh Tomar
2024-01-17 23:59 ` [PATCH v1 00/14] ARM: MPAM: add support for priority partitioning control Reinette Chatre

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®