Skip to content

Commit 0d6cc58

Browse files
authored
Merge pull request opencontainers#1076 from Creatone/creatone/mon-support
config-linux: Add Intel RDT CMT and MBM Linux support
2 parents 20a2d97 + cc7f6ec commit 0d6cc58

File tree

3 files changed

+25
-3
lines changed

3 files changed

+25
-3
lines changed

config-linux.md

+7
Original file line numberDiff line numberDiff line change
@@ -554,6 +554,13 @@ The following rules on parameters MUST be applied:
554554

555555
* 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.
556556

557+
* **`enableCMT`** *(boolean, OPTIONAL)* - specifies if Intel RDT CMT should be enabled:
558+
* CMT (Cache Monitoring Technology) supports monitoring of the last-level cache (LLC) occupancy
559+
for the container.
560+
561+
* **`enableMBM`** *(boolean, OPTIONAL)* - specifies if Intel RDT MBM should be enabled:
562+
* MBM (Memory Bandwidth Monitoring) supports monitoring of total and local memory bandwidth
563+
for the container.
557564

558565
### Example
559566

schema/config-linux.json

+6
Original file line numberDiff line numberDiff line change
@@ -259,6 +259,12 @@
259259
"memBwSchema": {
260260
"type": "string",
261261
"pattern": "^MB:[^\\n]*$"
262+
},
263+
"enableCMT": {
264+
"type": "boolean"
265+
},
266+
"enableMBM": {
267+
"type": "boolean"
262268
}
263269
}
264270
},

specs-go/config.go

+12-3
Original file line numberDiff line numberDiff line change
@@ -180,7 +180,7 @@ type Linux struct {
180180
// MountLabel specifies the selinux context for the mounts in the container.
181181
MountLabel string `json:"mountLabel,omitempty"`
182182
// IntelRdt contains Intel Resource Director Technology (RDT) information for
183-
// handling resource constraints (e.g., L3 cache, memory bandwidth) for the container
183+
// handling resource constraints and monitoring metrics (e.g., L3 cache, memory bandwidth) for the container
184184
IntelRdt *LinuxIntelRdt `json:"intelRdt,omitempty"`
185185
// Personality contains configuration for the Linux personality syscall
186186
Personality *LinuxPersonality `json:"personality,omitempty"`
@@ -685,8 +685,9 @@ type LinuxSyscall struct {
685685
Args []LinuxSeccompArg `json:"args,omitempty"`
686686
}
687687

688-
// LinuxIntelRdt has container runtime resource constraints for Intel RDT
689-
// CAT and MBA features which introduced in Linux 4.10 and 4.12 kernel
688+
// LinuxIntelRdt has container runtime resource constraints for Intel RDT CAT and MBA
689+
// features and flags enabling Intel RDT CMT and MBM features.
690+
// Intel RDT features are available in Linux 4.14 and newer kernel versions.
690691
type LinuxIntelRdt struct {
691692
// The identity for RDT Class of Service
692693
ClosID string `json:"closID,omitempty"`
@@ -699,6 +700,14 @@ type LinuxIntelRdt struct {
699700
// The unit of memory bandwidth is specified in "percentages" by
700701
// default, and in "MBps" if MBA Software Controller is enabled.
701702
MemBwSchema string `json:"memBwSchema,omitempty"`
703+
704+
// EnableCMT is the flag to indicate if the Intel RDT CMT is enabled. CMT (Cache Monitoring Technology) supports monitoring of
705+
// the last-level cache (LLC) occupancy for the container.
706+
EnableCMT bool `json:"enableCMT,omitempty"`
707+
708+
// EnableMBM is the flag to indicate if the Intel RDT MBM is enabled. MBM (Memory Bandwidth Monitoring) supports monitoring of
709+
// total and local memory bandwidth for the container.
710+
EnableMBM bool `json:"enableMBM,omitempty"`
702711
}
703712

704713
// ZOS contains platform-specific configuration for z/OS based containers.

0 commit comments

Comments
 (0)