On Wed, May 06, 2015 at 11:57:08AM +0300, Cyrill Gorcunov wrote: > Here we rip off all the virtualization code we introduced into kernel to > behave close to rhel6. > > Because we're trying a new concept (bindmounting from the node) it is > no longer needed. > > Now some details: > > - drop cgroup_show_path -- we don't hide VEID in /proc/self/cgroup output, > it doesn't break criu so no need to carry it, same applies to changes > in cgroup_path; > > - because we drop virtualization of systemd -- disable creation of new > hierarchies in container: we don't support it, neither we need it. The > primary reason why we allowed new hierarchies in container was that > CRIU has been running restore procedure inside VE but now we initiate > restore from VE0, so we can safely disable new hierarchies; > > - in cgroup_addrm_files go back to former RHEL7 code; if we need something > special here it must be reviewed carefully and separately; > > - no need to hide /proc/cgroups in VE, there is no sensible info present. > > v2: > > - take into account commits 38f039db6e023ac14517219ad6f674633c4e99ca > and c2ac6df22b20389ae2d0af49c436b00ff3243e89 removing cgroup_is_disposable, > cgroup_kernel_destroy, ve::ve_cgroup_head. > > - drop GRPP_WEAK, CGRP_SELF_DESTRUCTION and CGRP_VE_TOP_CGROUP_VIRTUAL flags > which implies the cgroups no longer auto-cleaned up but user-space tool > (read vzctl and friends) should handle cgroups removal > > - because we're moving to native cgroups code we don't virtualize release > agent anymore > > - still cgroup::cgroup_ve member is needed because we're using it > all over the code
Where do we use it? I think you're mixing it up with the cgroup_ve() macro, which has nothing to do with the ->cgroup_ve cgroup struct member. > > v3: > > - move back ve_offline, we need to free ve id > > Signed-off-by: Cyrill Gorcunov <[email protected]> > CC: Vladimir Davydov <[email protected]> > CC: Konstantin Khorenko <[email protected]> > CC: Pavel Emelyanov <[email protected]> > CC: Andrey Vagin <[email protected]> > --- > include/linux/cgroup.h | 15 --- > include/linux/ve.h | 1 > kernel/bc/beancounter.c | 11 -- > kernel/cgroup.c | 214 > ++++++------------------------------------------ > kernel/ve/ve.c | 9 -- > kernel/ve/vecalls.c | 6 - > 6 files changed, 39 insertions(+), 217 deletions(-) > [...] > Index: linux-pcs7.git/kernel/cgroup.c > =================================================================== > --- linux-pcs7.git.orig/kernel/cgroup.c > +++ linux-pcs7.git/kernel/cgroup.c > @@ -256,18 +256,11 @@ bool cgroup_is_descendant(struct cgroup > } > EXPORT_SYMBOL_GPL(cgroup_is_descendant); > > -static int cgroup_is_disposable(const struct cgroup *cgrp) > -{ > - return (cgrp->flags & ((1 << CGRP_NOTIFY_ON_RELEASE) | > - (1 << CGRP_SELF_DESTRUCTION))) > 0; > -} > - > static int cgroup_is_releasable(const struct cgroup *cgrp) > { > const int bits = > (1 << CGRP_RELEASABLE) | > - (1 << CGRP_NOTIFY_ON_RELEASE) | > - (1 << CGRP_SELF_DESTRUCTION); > + (1 << CGRP_NOTIFY_ON_RELEASE); > return (cgrp->flags & bits) > (1 << CGRP_RELEASABLE); Before commit 38f039db6e023ac14517219ad6f674633c4e99ca we had - return (cgrp->flags & bits) == bits; here. Fix please. > } > [...] > @@ -5774,7 +5621,6 @@ EXPORT_SYMBOL(cgroup_kernel_close); > > void cgroup_kernel_destroy(struct cgroup *cgrp) We don't use this function anymore. Remove it please. > { > - set_bit(CGRP_SELF_DESTRUCTION, &cgrp->flags); > set_bit(CGRP_RELEASABLE, &cgrp->flags); > check_for_release(cgrp); > } _______________________________________________ Devel mailing list [email protected] https://lists.openvz.org/mailman/listinfo/devel
