-
Notifications
You must be signed in to change notification settings - Fork 5.2k
Description
Describe the bug
After upgrading to a recent kernel on a Raspberry Pi 5, the memory cgroup functionality has stopped working.
Looking at the non-working configuration (kernel 6.12.34+rpt-rpi-2712
), you can see the active command line parameters passed to the linux kernel look like:
root@k8s-master-3:~# uname -a
Linux k8s-master-3 6.12.34+rpt-rpi-2712 #1 SMP PREEMPT Debian 1:6.12.34-1+rpt1~bookworm (2025-06-26) aarch64 GNU/Linux
root@k8s-master-3:~# cat /proc/cmdline
reboot=w coherent_pool=1M 8250.nr_uarts=1 pci=pcie_bus_safe cgroup_disable=memory numa_policy=interleave nvme.max_host_mem_size_mb=0 numa=fake=8 system_heap.max_order=0 smsc95xx.macaddr=2C:CF:67:FB:89:3C vc_mem.mem_base=0x3fc00000 vc_mem.mem_size=0x40000000 cgroup_memory=1 cgroup_enable=memory console=ttyAMA10,115200 console=tty1 root=PARTUUID=4d8097e2-02 rootfstype=ext4 fsck.repair=yes rootwait
And /proc/cgroups shows no evidence of memory cgroups being active;
root@k8s-master-3:~# cat /proc/cgroups
#subsys_name hierarchy num_cgroups enabled
cpuset 0 70 1
cpu 0 70 1
cpuacct 0 70 1
blkio 0 70 1
devices 0 70 1
freezer 0 70 1
net_cls 0 70 1
perf_event 0 70 1
net_prio 0 70 1
pids 0 70 1
But looking at an otherwise identical Raspberry Pi 5 which has an older linux kernel (6.6.74+rpt-rpi-2712
), we see the command line and /proc/cgroups output showing that memory cgroups are availble:
root@k8s-master-1:~# uname -a
Linux k8s-master-1 6.6.74+rpt-rpi-2712 #1 SMP PREEMPT Debian 1:6.6.74-1+rpt1 (2025-01-27) aarch64 GNU/Linux
root@k8s-master-1:~# cat /proc/cmdline
reboot=w coherent_pool=1M 8250.nr_uarts=1 pci=pcie_bus_safe cgroup_disable=memory numa_policy=interleave numa=fake=8 system_heap.max_order=0 smsc95xx.macaddr=2C:CF:67:CF:25:FD vc_mem.mem_base=0x3fc00000 vc_mem.mem_size=0x40000000 cgroup_memory=1 cgroup_enable=memory console=ttyAMA10,115200 console=tty1 root=PARTUUID=612e095f-02 rootfstype=ext4 fsck.repair=yes rootwait
/proc/cgroups:
root@k8s-master-1:~# cat /proc/cgroups
#subsys_name hierarchy num_cgroups enabled
cpuset 0 123 1
cpu 0 123 1
cpuacct 0 123 1
blkio 0 123 1
memory 0 123 1
devices 0 123 1
freezer 0 123 1
net_cls 0 123 1
perf_event 0 123 1
net_prio 0 123 1
pids 0 123 1
Steps to reproduce the behaviour
Enable memory cgroups by adding cgroup_memory=1 cgroup_enable=memory
to /boot/firmware/cmdline.txt. Install/upgrade to linux 6.12.34+rpt-rpi-2712
, reboot and see how /proc/cgroups doesn't list memory cgroups as enabled.
Device (s)
Raspberry Pi CM5
System
https://gist.github.com/joelddiaz/d4b75825c9e3f0493ac67cc49d0481b4
Logs
No response
Additional context
Maybe related to this commit...: 86099de