Skip to content

Commit e91f77f

Browse files
committed
specs: linux: add intel_rdt cgroup support in specs
Add support for the intel_rdt cgroup resource in Linux-specific runtime configuration to support runtime.json. The intel_rdt cgroup subsystem will be available in Linux 4.6 (or later). Signed-off-by: Xiaochen Shen <[email protected]>
1 parent 6a6ba67 commit e91f77f

File tree

2 files changed

+26
-1
lines changed

2 files changed

+26
-1
lines changed

runtime-config-linux.md

Lines changed: 18 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -167,7 +167,7 @@ The following parameters can be specified:
167167
## Control groups
168168

169169
Also known as cgroups, they are used to restrict resource usage for a container and handle device access.
170-
cgroups provide controls to restrict cpu, memory, IO, pids and network for the container.
170+
cgroups provide controls to restrict cpu, memory, IO, pids, network and intel_rdt for the container.
171171
For more information, see the [kernel cgroups documentation](https://www.kernel.org/doc/Documentation/cgroups/cgroups.txt).
172172

173173
The path to the cgroups can be specified in the Spec via `cgroupsPath`.
@@ -421,6 +421,23 @@ The following paramters can be specified to setup the controller:
421421
}
422422
```
423423

424+
#### Intel_rdt
425+
426+
`intel_rdt` represents the cgroup subsystem `intel_rdt`.
427+
For more information, see [the intel_rdt cgroup man page](https://lkml.org/lkml/2015/12/17/574).
428+
429+
The following paramters can be specified to setup the controller:
430+
431+
* **`l3Cbm`** *(uint64, optional)* - specifies L3 cache capacity bitmask (CBM) in the cgroup
432+
433+
###### Example
434+
435+
```json
436+
"intel_rdt": {
437+
"l3Cbm": 4080
438+
}
439+
```
440+
424441
## Sysctl
425442

426443
sysctl allows kernel parameters to be modified at runtime for the container.

runtime_config_linux.go

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -198,6 +198,12 @@ type Network struct {
198198
Priorities []InterfacePriority `json:"priorities"`
199199
}
200200

201+
// IntelRdt for Linux cgroup 'intel_rdt' resource management
202+
type IntelRdt struct {
203+
// L3 cache capacity bitmask (CBM) for container
204+
L3Cbm *uint64 `json:"l3Cbm,omitempty"`
205+
}
206+
201207
// Resources has container runtime resource constraints
202208
type Resources struct {
203209
// DisableOOMKiller disables the OOM killer for out of memory conditions
@@ -216,6 +222,8 @@ type Resources struct {
216222
HugepageLimits []HugepageLimit `json:"hugepageLimits,omitempty"`
217223
// Network restriction configuration
218224
Network *Network `json:"network,omitempty"`
225+
// IntelRdt restriction configuration
226+
IntelRdt *IntelRdt `json:"intelRdt,omitempty"`
219227
}
220228

221229
// Device represents the information on a Linux special device file

0 commit comments

Comments
 (0)