From 6baf97ef2c7416f3d81bdc6cf20f121b62c8fd4f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A1n=20Tomko?= Date: Wed, 26 Feb 2020 12:45:02 +0100 Subject: [PATCH] qemu: pass virDomainObjPtr to qemuExtDevicesSetupCgroup MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Ján Tomko Reviewed-by: Peter Krempa Tested-by: Andrea Bolognani --- src/qemu/qemu_cgroup.c | 2 +- src/qemu/qemu_extdevice.c | 3 ++- src/qemu/qemu_extdevice.h | 2 +- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/src/qemu/qemu_cgroup.c b/src/qemu/qemu_cgroup.c index d550d4f58a..c0e30f6152 100644 --- a/src/qemu/qemu_cgroup.c +++ b/src/qemu/qemu_cgroup.c @@ -1165,7 +1165,7 @@ qemuSetupCgroupForExtDevices(virDomainObjPtr vm, false, &cgroup_temp) < 0) goto cleanup; - ret = qemuExtDevicesSetupCgroup(driver, vm->def, cgroup_temp); + ret = qemuExtDevicesSetupCgroup(driver, vm, cgroup_temp); cleanup: virCgroupFree(&cgroup_temp); diff --git a/src/qemu/qemu_extdevice.c b/src/qemu/qemu_extdevice.c index 7f3bb104d9..bb73787b8d 100644 --- a/src/qemu/qemu_extdevice.c +++ b/src/qemu/qemu_extdevice.c @@ -236,9 +236,10 @@ qemuExtDevicesHasDevice(virDomainDefPtr def) int qemuExtDevicesSetupCgroup(virQEMUDriverPtr driver, - virDomainDefPtr def, + virDomainObjPtr vm, virCgroupPtr cgroup) { + virDomainDefPtr def = vm->def; size_t i; for (i = 0; i < def->nvideos; i++) { diff --git a/src/qemu/qemu_extdevice.h b/src/qemu/qemu_extdevice.h index df29968e16..49373a15a1 100644 --- a/src/qemu/qemu_extdevice.h +++ b/src/qemu/qemu_extdevice.h @@ -58,5 +58,5 @@ void qemuExtDevicesStop(virQEMUDriverPtr driver, bool qemuExtDevicesHasDevice(virDomainDefPtr def); int qemuExtDevicesSetupCgroup(virQEMUDriverPtr driver, - virDomainDefPtr def, + virDomainObjPtr vm, virCgroupPtr cgroup);