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

Konstantin Khorenko khorenko at virtuozzo.com
Thu Mar 28 11:37:46 MSK 2019


The commit is pushed to "branch-rh7-3.10.0-957.10.1.vz7.85.x-ovz" and will appear at https://src.openvz.org/scm/ovz/vzkernel.git
after rh7-3.10.0-957.10.1.vz7.85.4
------>
commit 85f7a3da6552b7974a8755fe083689fd3c19634d
Author: Pavel Tikhomirov <ptikhomirov at virtuozzo.com>
Date:   Thu Mar 28 11:37:44 2019 +0300

    ve: don't hide cgroup mount root from pseudosuper
    
    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);
 }
 
 /*



More information about the Devel mailing list