[Devel] [PATCH VZ10 9/9] ve/cgroup-v2: Don't hide default cgroup when ve controller is enabled on it
Pavel Tikhomirov
ptikhomirov at virtuozzo.com
Fri Dec 5 07:50:09 MSK 2025
Else default hierarchy is hidden in container and that prevents systemd
from booting.
https://virtuozzo.atlassian.net/browse/VSTOR-104639
Signed-off-by: Pavel Tikhomirov <ptikhomirov at virtuozzo.com>
Feature: ve: ve generic structures
---
kernel/cgroup/cgroup.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/kernel/cgroup/cgroup.c b/kernel/cgroup/cgroup.c
index d6a762398ea5..7befa430f2f8 100644
--- a/kernel/cgroup/cgroup.c
+++ b/kernel/cgroup/cgroup.c
@@ -6912,7 +6912,10 @@ void cgroup_path_from_kernfs_id(u64 id, char *buf, size_t buflen)
int ve_hide_cgroups(struct cgroup_root *root)
{
struct ve_struct *ve = get_exec_env();
- unsigned long hidden_mask = (1UL << ve_cgrp_id);
+ unsigned long hidden_mask = 0;
+
+ if (!cgroup_subsys_on_dfl(ve_cgrp_subsys))
+ hidden_mask = (1UL << ve_cgrp_id);
/*
* Hide ve cgroup in CT for docker, still showing it to pseudosuper
--
2.52.0
More information about the Devel
mailing list