libct/cg: support SCHED_IDLE for runc cgroupfs#3377
Merged
Conversation
d06fe5a to
f9ca48b
Compare
482bccd to
fa7fb14
Compare
Contributor
Author
|
@kolyshkin PTAL |
c918a6c to
b108c38
Compare
kolyshkin
reviewed
May 11, 2022
kolyshkin
reviewed
May 11, 2022
Comment on lines
+18
to
+22
| if r.CpuIdle != nil { | ||
| if err := cgroups.WriteFile(dirPath, "cpu.idle", strconv.FormatInt(*r.CpuIdle, 10)); err != nil { | ||
| return err | ||
| } | ||
| } |
Contributor
There was a problem hiding this comment.
You can move this below to after if !isCpuSet(r).
kolyshkin
reviewed
May 11, 2022
| // MEM to use | ||
| CpusetMems string `json:"cpuset_mems"` | ||
|
|
||
| //nolint:revive |
Contributor
There was a problem hiding this comment.
Maybe instead of ignoring revive warning, call it CPUIdle (hopefully we'll rename the rest of Cpu* fields at some point).
kolyshkin
reviewed
May 11, 2022
| if r.CPU.Quota != nil { | ||
| c.Resources.CpuQuota = *r.CPU.Quota | ||
| } | ||
|
|
kolyshkin
requested changes
May 11, 2022
Contributor
kolyshkin
left a comment
There was a problem hiding this comment.
A few nits, plus can you please make the runtime-spec bump a separate commit (for clarity)?
Contributor
|
Rebased to fix CI |
Contributor
Author
|
@kolyshkin Can I ask you to review it again? |
Member
|
Looks good but needs rebase |
Member
|
@wineway Could you rebase? |
Signed-off-by: wineway <wangyuweihx@gmail.com>
Contributor
Author
sorry, I missed last comment; rebased |
AkihiroSuda
approved these changes
Jan 31, 2023
Merged
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
runtime-spec: opencontainers/runtime-spec#1136