Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Intel RDT support #20150

Merged
merged 6 commits into from
Sep 28, 2023
Merged

Add Intel RDT support #20150

merged 6 commits into from
Sep 28, 2023

Conversation

wpross
Copy link
Contributor

@wpross wpross commented Sep 26, 2023

This PR closes #19922

Support for assigning a container to a Class Of Service (COS) based on --rdt-class=COS is added. The COS represents a part of the cache based on the Cache Allocation Technology (CAT) feature that is part of Intel's Resource Director Technology (Intel RDT) feature set. By assigning a container to a COS, all PID's of the container have only access to the cache space defined for this COS.

The COS has to be pre-configured based on the resctrl kernel driver. This is only possible if the HW supports the CAT feature which can be checked based on the presence of the cat_l2 and cat_l3 flags in /proc/cpuinfo.

So far, Intel RDT support is only integrated into runc and not in crun yet.

Does this PR introduce a user-facing change?

yes

A new option `--rdt-class=COS` has been added to the `create` and `run` commands that enables assigning a container to a Class Of Service (COS). The COS has to be pre-configured based on a pseudo-filesystem created by the *resctrl* kernel driver that enables interacting with the Intel RDT CAT feature.

@packit-as-a-service
Copy link

Ephemeral COPR build failed. @containers/packit-build please check.

pkg/specgenutil/specgen.go Outdated Show resolved Hide resolved
@wpross wpross force-pushed the add-rdt branch 3 times, most recently from f87a160 to 4d7363c Compare September 26, 2023 18:46
@mheon
Copy link
Member

mheon commented Sep 27, 2023

Code LGTM

@mheon
Copy link
Member

mheon commented Sep 27, 2023

Can you rebase? I think the system test failure is fixed upstream

wpross and others added 6 commits September 27, 2023 16:44
Add --rdt-class=COS to the create and run command to enable the
assignment of a container to a Class of Service (COS). The COS
represents a part of the cache based on the Cache Allocation Technology
(CAT) feature that is part of Intel's Resource Director Technology
(Intel RDT) feature set. By assigning a container to a COS, all PID's of
the container have only access to the cache space defined for this COS.
The COS has to be pre-configured based on the resctrl kernel driver.
cat_l2 and cat_l3 flags in /proc/cpuinfo represent CAT support for cache
level 2 and 3 respectively.

Signed-off-by: Wolfgang Pross <[email protected]>
Signed-off-by: Wolfgang Pross <[email protected]>
@TomSweeneyRedHat
Copy link
Member

LGTM
once the test are happy. I'll rerun them momentarily.

Copy link
Collaborator

@flouthoc flouthoc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM
/lgtm
/approve

@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label Sep 28, 2023
@openshift-ci
Copy link
Contributor

openshift-ci bot commented Sep 28, 2023

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: flouthoc, wpross

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-ci openshift-ci bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Sep 28, 2023
@openshift-merge-robot openshift-merge-robot merged commit 36f8e78 into containers:main Sep 28, 2023
97 checks passed
@wpross
Copy link
Contributor Author

wpross commented Sep 28, 2023

Thanks @mheon, @TomSweeneyRedHat & @flouthoc for the reviews!

@wpross wpross deleted the add-rdt branch October 2, 2023 13:21
@giuseppe
Copy link
Member

I've opened a PR to add support for Intel RDT to crun: containers/crun#1323

@github-actions github-actions bot added the locked - please file new issue/PR Assist humans wanting to comment on an old issue or PR with locked comments. label Jan 10, 2024
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jan 10, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. lgtm Indicates that a PR is ready to be merged. locked - please file new issue/PR Assist humans wanting to comment on an old issue or PR with locked comments. release-note
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add Intel RDT support
6 participants