[PATCH RFC v4 05/18] fs/resctrl: Add RDT_RESOURCE_MB_MIN and RDT_RESOURCE_MB_WGHT
Drew Fustini
fustini at kernel.org
Sun May 10 22:11:01 PDT 2026
Introduce bandwidth controls which are semantically different from
the throttle-based MB resource:
- RDT_RESOURCE_MB_MIN: minimum reserved bandwidth
- RDT_RESOURCE_MB_WGHT: weighted share of unreserved bandwidth
Assisted-by: Claude:claude-opus-4-7
Signed-off-by: Drew Fustini <fustini at kernel.org>
---
fs/resctrl/rdtgroup.c | 4 +++-
include/linux/resctrl.h | 2 ++
2 files changed, 5 insertions(+), 1 deletion(-)
diff --git a/fs/resctrl/rdtgroup.c b/fs/resctrl/rdtgroup.c
index 0f331bf5ce82..02733b11e115 100644
--- a/fs/resctrl/rdtgroup.c
+++ b/fs/resctrl/rdtgroup.c
@@ -1555,7 +1555,7 @@ bool is_mba_sc(struct rdt_resource *r)
return r->membw.mba_sc;
}
-/* RANGE schema is bandwidth (MBA/SMBA). BITMAP is cache. */
+/* RANGE schema is bandwidth (MBA/SMBA/MB_MIN/MB_WGHT). BITMAP is cache. */
bool resctrl_is_membw(struct rdt_resource *r)
{
return r->schema_fmt == RESCTRL_SCHEMA_RANGE;
@@ -2402,6 +2402,8 @@ static unsigned long fflags_from_resource(struct rdt_resource *r)
return RFTYPE_RES_CACHE;
case RDT_RESOURCE_MBA:
case RDT_RESOURCE_SMBA:
+ case RDT_RESOURCE_MB_MIN:
+ case RDT_RESOURCE_MB_WGHT:
return RFTYPE_RES_MB;
case RDT_RESOURCE_PERF_PKG:
return RFTYPE_RES_PERF_PKG;
diff --git a/include/linux/resctrl.h b/include/linux/resctrl.h
index 006e57fd7ca5..9529ed0d1fdf 100644
--- a/include/linux/resctrl.h
+++ b/include/linux/resctrl.h
@@ -53,6 +53,8 @@ enum resctrl_res_level {
RDT_RESOURCE_L2,
RDT_RESOURCE_MBA,
RDT_RESOURCE_SMBA,
+ RDT_RESOURCE_MB_MIN,
+ RDT_RESOURCE_MB_WGHT,
RDT_RESOURCE_PERF_PKG,
/* Must be the last */
--
2.43.0
More information about the linux-riscv
mailing list