@@ -4237,6 +4266,19 @@ void cgroup_mark_ve_roots(struct ve_struct *ve)
        mutex_unlock(&cgroup_mutex);
  }
+void cgroup_unmark_ve_roots(struct ve_struct *ve)
+{
+       struct cgroup *cgrp;
+       struct cgroupfs_root *root;
+
+       mutex_lock(&cgroup_mutex);
+       for_each_active_root(root) {
+               cgrp = css_cgroup_from_root(ve->root_css_set, root);

Maybe we can use this new helper in cgroup_mark_ve_roots too for consistency (maybe in separate patch), what do you think?

+               clear_bit(CGRP_VE_ROOT, &cgrp->flags);
+       }
+       mutex_unlock(&cgroup_mutex);
+}
+
  struct cgroup *cgroup_get_ve_root(struct cgroup *cgrp)
  {
        struct cgroup *ve_root = NULL;

--
Best regards, Tikhomirov Pavel
Software Developer, Virtuozzo.
_______________________________________________
Devel mailing list
[email protected]
https://lists.openvz.org/mailman/listinfo/devel

Reply via email to