[libvirt] [PATCH 04/11] libxl: use job functions in libxlDomain{Suspend, Resume}
Michal Privoznik
mprivozn at redhat.com
Tue Feb 11 14:36:04 UTC 2014
On 07.02.2014 04:53, Jim Fehlig wrote:
> These operations aren't necessarily time consuming, but need to
> wait in the queue of modify jobs.
>
> Signed-off-by: Jim Fehlig <jfehlig at suse.com>
> ---
> src/libxl/libxl_driver.c | 24 ++++++++++++++++++------
> 1 file changed, 18 insertions(+), 6 deletions(-)
>
> diff --git a/src/libxl/libxl_driver.c b/src/libxl/libxl_driver.c
> index 4f333bd..caabb44 100644
> --- a/src/libxl/libxl_driver.c
> +++ b/src/libxl/libxl_driver.c
> @@ -1381,10 +1384,13 @@ libxlDomainSuspend(virDomainPtr dom)
> }
>
> if (virDomainSaveStatus(driver->xmlopt, cfg->stateDir, vm) < 0)
> - goto cleanup;
> + goto endjob;
>
> ret = 0;
>
> +endjob:
> + libxlDomainObjEndJob(driver, vm);
> +
> cleanup:
> if (vm)
> virObjectUnlock(vm);
> @@ -1434,10 +1443,13 @@ libxlDomainResume(virDomainPtr dom)
> }
>
> if (virDomainSaveStatus(driver->xmlopt, cfg->stateDir, vm) < 0)
> - goto cleanup;
> + goto endjob;
>
> ret = 0;
>
> +endjob:
> + libxlDomainObjEndJob(driver, vm);
> +
> cleanup:
> if (vm)
> virObjectUnlock(vm);
>
conditional ACK because of EndJob.
Michal
More information about the libvir-list
mailing list