[Devel] [PATCH RH7] ve: don't hide cgroup mount root from pseudosuper

Pavel Tikhomirov ptikhomirov at virtuozzo.com
Tue Mar 26 13:15:34 MSK 2019


Will need it to check mouninfo persists at the late restore, where the
root task is inside ve.

https://jira.sw.ru/browse/PSBM-86686
Signed-off-by: Pavel Tikhomirov <ptikhomirov at virtuozzo.com>
---
 kernel/cgroup.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/kernel/cgroup.c b/kernel/cgroup.c
index d35e2ac150a3..9ca8af9f73d9 100644
--- a/kernel/cgroup.c
+++ b/kernel/cgroup.c
@@ -1862,7 +1862,9 @@ EXPORT_SYMBOL_GPL(cgroup_path);
 
 int cgroup_path_ve(const struct cgroup *cgrp, char *buf, int buflen)
 {
-	return __cgroup_path(cgrp, buf, buflen, !ve_is_super(get_exec_env()));
+	struct ve_struct *ve = get_exec_env();
+
+	return __cgroup_path(cgrp, buf, buflen, !ve_is_super(ve) && !ve->is_pseudosuper);
 }
 
 /*
-- 
2.20.1



More information about the Devel mailing list