Skip to content

Commit a5b6996

Browse files
babumogerbp3tk0v
authored andcommitted
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 <[email protected]> Signed-off-by: Borislav Petkov (AMD) <[email protected]> Reviewed-by: Reinette Chatre <[email protected]> Link: https://lore.kernel.org/r/[email protected]
1 parent f334f72 commit a5b6996

File tree

2 files changed

+13
-0
lines changed

2 files changed

+13
-0
lines changed

arch/x86/kernel/cpu/resctrl/core.c

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -100,6 +100,18 @@ struct rdt_hw_resource rdt_resources_all[] = {
100100
.fflags = RFTYPE_RES_MB,
101101
},
102102
},
103+
[RDT_RESOURCE_SMBA] =
104+
{
105+
.r_resctrl = {
106+
.rid = RDT_RESOURCE_SMBA,
107+
.name = "SMBA",
108+
.cache_level = 3,
109+
.domains = domain_init(RDT_RESOURCE_SMBA),
110+
.parse_ctrlval = parse_bw,
111+
.format_str = "%d=%*u",
112+
.fflags = RFTYPE_RES_MB,
113+
},
114+
},
103115
};
104116

105117
/*

arch/x86/kernel/cpu/resctrl/internal.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -409,6 +409,7 @@ enum resctrl_res_level {
409409
RDT_RESOURCE_L3,
410410
RDT_RESOURCE_L2,
411411
RDT_RESOURCE_MBA,
412+
RDT_RESOURCE_SMBA,
412413

413414
/* Must be the last */
414415
RDT_NUM_RESOURCES,

0 commit comments

Comments
 (0)