diff options
author | Babu Moger <babu.moger@amd.com> | 2023-01-13 09:20:29 -0600 |
---|---|---|
committer | Borislav Petkov (AMD) <bp@alien8.de> | 2023-01-23 17:38:22 +0100 |
commit | a5b699665580725de8c0c01f2163a15af78b6866 (patch) | |
tree | f2b8c9eb96cfe081aa428e330831d09e57fd5e9b /arch/x86/kernel/cpu/resctrl/core.c | |
parent | f334f723a63cfc25789b1cdf70a08ffbaea4bf2e (diff) | |
download | linux-a5b699665580725de8c0c01f2163a15af78b6866.tar.gz linux-a5b699665580725de8c0c01f2163a15af78b6866.tar.bz2 linux-a5b699665580725de8c0c01f2163a15af78b6866.zip |
x86/resctrl: Add a new resource type RDT_RESOURCE_SMBA
Add a new resource type RDT_RESOURCE_SMBA to handle the QoS enforcement
policies on the external slow memory.
Mostly initialization of the essentials. Setting fflags to RFTYPE_RES_MB
configures the SMBA resource to have the same resctrl files as the
existing MBA resource. The SMBA resource has identical properties to
the existing MBA resource. These properties will be enumerated in an
upcoming change and exposed via resctrl because of this flag.
Signed-off-by: Babu Moger <babu.moger@amd.com>
Signed-off-by: Borislav Petkov (AMD) <bp@alien8.de>
Reviewed-by: Reinette Chatre <reinette.chatre@intel.com>
Link: https://lore.kernel.org/r/20230113152039.770054-4-babu.moger@amd.com
Diffstat (limited to 'arch/x86/kernel/cpu/resctrl/core.c')
-rw-r--r-- | arch/x86/kernel/cpu/resctrl/core.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/arch/x86/kernel/cpu/resctrl/core.c b/arch/x86/kernel/cpu/resctrl/core.c index c98e52ff5f20..f6af3ac1ef20 100644 --- a/arch/x86/kernel/cpu/resctrl/core.c +++ b/arch/x86/kernel/cpu/resctrl/core.c @@ -100,6 +100,18 @@ struct rdt_hw_resource rdt_resources_all[] = { .fflags = RFTYPE_RES_MB, }, }, + [RDT_RESOURCE_SMBA] = + { + .r_resctrl = { + .rid = RDT_RESOURCE_SMBA, + .name = "SMBA", + .cache_level = 3, + .domains = domain_init(RDT_RESOURCE_SMBA), + .parse_ctrlval = parse_bw, + .format_str = "%d=%*u", + .fflags = RFTYPE_RES_MB, + }, + }, }; /* |