[libvirt PATCH v5 1/7] qemu, hypervisor: refactor some cgroup mgmt methods