RDKMVE-2571 Add cgroup v2 support in RDKE - #396
Conversation
There was a problem hiding this comment.
🟡 Changes recommended
The cmdline edit is not idempotent and can repeatedly append duplicate kernel parameters on task re-runs, which should be prevented before merging.
Once you've addressed the issues Copilot identified, you can request another Copilot review.
Pull request overview
This PR updates the Raspberry Pi boot cmdline.txt augmentation to enable systemd’s unified (cgroup v2) hierarchy when the DOBBY_CONTAINERS distro feature is enabled, aligning the platform’s boot parameters with cgroup v2 usage.
Changes:
- Appends
systemd.unified_cgroup_hierarchy=1to the kernel command line alongside existing cgroup memory parameters underDOBBY_CONTAINERS.
File summaries
| File | Description |
|---|---|
| recipes-bsp/bootfiles/rpi-cmdline.bbappend | Extends the cmdline append logic to force systemd to use unified cgroup hierarchy (cgroup v2). |
Review details
- Files reviewed: 1/1 changed files
- Comments generated: 1
- Review effort level: Lite
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Updated the implementation to be idempotent. The kernel parameters are now appended only when they are not already present in cmdline.txt, preventing duplication when do_compile is re-executed
There was a problem hiding this comment.
🟡 Changes recommended
The new grep check uses regex matching, which can mis-detect dotted parameters (e.g., systemd.unified_cgroup_hierarchy=1) and skip required cmdline updates.
Once you've addressed the issues Copilot identified, you can request another Copilot review.
Review details
- Files reviewed: 1/1 changed files
- Comments generated: 2
- Review effort level: Lite
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
There was a problem hiding this comment.
🟢 Approval recommended
The change is small and targeted, and the only noted issue is a minor shell-quoting robustness improvement.
Review details
Suppressed comments (1)
recipes-bsp/bootfiles/rpi-cmdline.bbappend:6
CMDLINE_FILEis unquoted in the firstsedinvocation, while later commands quote it. Unquoted shell variables can undergo word-splitting/globbing (e.g., ifWORKDIRcontains spaces or[/*), which can make the task fail or operate on the wrong files; quoting here makes the edit consistent and robust.
CMDLINE_FILE="${WORKDIR}/cmdline.txt"
sed -i 's/[[:space:]]*$//' ${CMDLINE_FILE}
- Files reviewed: 1/1 changed files
- Comments generated: 0 new
- Review effort level: Lite
Update rdkv.cfg for
|
Please trigger build verification and if it passes; merge. |
There was a problem hiding this comment.
🟡 Changes recommended
Retaining cgroup v1 alongside cgroup v2 is needed to avoid breaking legacy consumers.
Get a fresh assessment by requesting another Copilot review.
Review details
- Files reviewed: 2/2 changed files
- Comments generated: 1
- Review effort level: Lite
Update on rpi-cmdline.bbappend for cgroupv2 change