Skip to content

Commit cc7f6ec

Browse files
author
Paweł Szulik
committed
config-linux: Add Intel RDT CMT and MBM Linux support
Add support for Intel Resource Director Technology (RDT) / Cache Monitoring Technology (CMT) and Memory Bandwidth Monitoring (MBM). Example: "linux": { "intelRdt": { "enableCMT": true, "enableMBM": true } } This is the prerequisite of this runc proposal: opencontainers/runc#2519 For more information about Intel RDT CMT and MBM, please refer to: opencontainers/runc#2519 Signed-off-by: Paweł Szulik <[email protected]>
1 parent e6143ca commit cc7f6ec

File tree

3 files changed

+25
-3
lines changed

3 files changed

+25
-3
lines changed

config-linux.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -549,6 +549,13 @@ The following parameters can be specified for the container:
549549

550550
* If `closID` is set, and neither of `l3CacheSchema` and `memBwSchema` are set, runtime MUST check if corresponding pre-configured directory `closID` is present in mounted `resctrl`. If such pre-configured directory `closID` exists, runtime MUST assign container to this `closID` and [generate an error](runtime.md#errors) if directory does not exist.
551551

552+
* **`enableCMT`** *(boolean, OPTIONAL)* - specifies if Intel RDT CMT should be enabled:
553+
* CMT (Cache Monitoring Technology) supports monitoring of the last-level cache (LLC) occupancy
554+
for the container.
555+
556+
* **`enableMBM`** *(boolean, OPTIONAL)* - specifies if Intel RDT MBM should be enabled:
557+
* MBM (Memory Bandwidth Monitoring) supports monitoring of total and local memory bandwidth
558+
for the container.
552559

553560
### Example
554561

schema/config-linux.json

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -250,6 +250,12 @@
250250
"memBwSchema": {
251251
"type": "string",
252252
"pattern": "^MB:[^\\n]*$"
253+
},
254+
"enableCMT": {
255+
"type": "boolean"
256+
},
257+
"enableMBM": {
258+
"type": "boolean"
253259
}
254260
}
255261
},

specs-go/config.go

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -178,7 +178,7 @@ type Linux struct {
178178
// MountLabel specifies the selinux context for the mounts in the container.
179179
MountLabel string `json:"mountLabel,omitempty"`
180180
// IntelRdt contains Intel Resource Director Technology (RDT) information for
181-
// handling resource constraints (e.g., L3 cache, memory bandwidth) for the container
181+
// handling resource constraints and monitoring metrics (e.g., L3 cache, memory bandwidth) for the container
182182
IntelRdt *LinuxIntelRdt `json:"intelRdt,omitempty"`
183183
// Personality contains configuration for the Linux personality syscall
184184
Personality *LinuxPersonality `json:"personality,omitempty"`
@@ -678,8 +678,9 @@ type LinuxSyscall struct {
678678
Args []LinuxSeccompArg `json:"args,omitempty"`
679679
}
680680

681-
// LinuxIntelRdt has container runtime resource constraints for Intel RDT
682-
// CAT and MBA features which introduced in Linux 4.10 and 4.12 kernel
681+
// LinuxIntelRdt has container runtime resource constraints for Intel RDT CAT and MBA
682+
// features and flags enabling Intel RDT CMT and MBM features.
683+
// Intel RDT features are available in Linux 4.14 and newer kernel versions.
683684
type LinuxIntelRdt struct {
684685
// The identity for RDT Class of Service
685686
ClosID string `json:"closID,omitempty"`
@@ -692,4 +693,12 @@ type LinuxIntelRdt struct {
692693
// The unit of memory bandwidth is specified in "percentages" by
693694
// default, and in "MBps" if MBA Software Controller is enabled.
694695
MemBwSchema string `json:"memBwSchema,omitempty"`
696+
697+
// EnableCMT is the flag to indicate if the Intel RDT CMT is enabled. CMT (Cache Monitoring Technology) supports monitoring of
698+
// the last-level cache (LLC) occupancy for the container.
699+
EnableCMT bool `json:"enableCMT,omitempty"`
700+
701+
// EnableMBM is the flag to indicate if the Intel RDT MBM is enabled. MBM (Memory Bandwidth Monitoring) supports monitoring of
702+
// total and local memory bandwidth for the container.
703+
EnableMBM bool `json:"enableMBM,omitempty"`
695704
}

0 commit comments

Comments
 (0)