agent/taskresource/cgroup/control/cgroup_controller_linux.go
func (c *control) Remove(cgroupPath string) error {
	seelog.Debugf("Removing cgroup %s", cgroupPath)

	controller, err := c.Load(cgroups.V1, cgroups.StaticPath(cgroupPath))
	if err != nil {
		return errors.Wrapf(err, "cgroup remove: unable to obtain controller")
	}

	// Delete cgroup
	err = controller.Delete()
	if err != nil {
		return errors.Wrapf(err, "cgroup remove: unable to delete cgroup")
	}
	return nil
}
func (c *control) Remove(cgroupPath string) error {
	seelog.Debugf("Removing cgroup %s", cgroupPath)

	controller, err := c.Load(cgroups.V1, cgroups.StaticPath(cgroupPath))
	if err != nil {
		return errors.Wrapf(err, "cgroup remove: unable to obtain controller")
	}

	// Delete cgroup
	err = controller.Delete()
	if err != nil {
		return errors.Wrapf(err, "cgroup remove: unable to delete cgroup")
	}
	return nil
}
// Remove is used to delete the cgroup