Re: [PATCH 04/12] qemuDomainObjWait: Add documentation

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 6/13/24 17:11, Peter Krempa wrote:
> Document why this function exists and meaning of return values.
> 
> Signed-off-by: Peter Krempa <pkrempa@xxxxxxxxxx>
> ---
>  src/qemu/qemu_domain.c | 12 ++++++++++++
>  1 file changed, 12 insertions(+)
> 
> diff --git a/src/qemu/qemu_domain.c b/src/qemu/qemu_domain.c
> index 9bbad887e0..8fe1b1924d 100644
> --- a/src/qemu/qemu_domain.c
> +++ b/src/qemu/qemu_domain.c
> @@ -12368,6 +12368,18 @@ qemuDomainRemoveLogs(virQEMUDriver *driver,
>  }
> 
> 
> +/**
> + * qemuDomainObjWait:
> + * @vm: domain object
> + *
> + * Wait for a signal on the main domain condition. Take into account internal
> + * qemu state in addition to what virDomainObjWait checks. Code in the qemu
> + * driver must use this function exclusively instead of virDomainObjWait.
> + *
> + * Returns:
> + *  - 0 on successful wait AND VM is guaranteed to be running
> + *  - -1 on failure to wait or VM was terminated while waiting

Nitpick, drop those leading '-' symbols. And possibly add a comma/full
stop at EOLs.

> + */
>  int
>  qemuDomainObjWait(virDomainObj *vm)
>  {

Michal



[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]

  Powered by Linux