[libvirt] [PATCH v2] libxl: libxl_get_max_cpus returning a libxl error from 4.4 onward

Martin Kletzander mkletzan at redhat.com
Wed Dec 18 16:40:42 UTC 2013


On Wed, Dec 18, 2013 at 03:39:12PM +0100, Dario Faggioli wrote:
> Starting from commit 2e82c18c in Xen (will be included in Xen 4.4)
> both libxl_get_max_cpus() and libxl_get_max_ndoes() start returning

s/ndoes/nodes/

> a proper libxl error code, in case of failure. This patch fixes
> this in the libxl driver.
>
> Note that, although it is now basically impossible for them to return
> 0, that would, theoretically, still be wrong. Also, checking that the
> returned value is '<= 0' makes the code correct for both Xen 4.4 and
> Xen 4.3 (and 4.2), and that is why we go for it (rather than
> just '< 0').
>
> Signed-off-by: Dario Faggioli <dario.faggioli at citrix.com>
> Cc: Jim Fehlig <jfehlig at suse.com>
> Cc: Ian Jackson <Ian.Jackson at eu.citrix.com>
> Cc: Martin Kletzander <mkletzan at redhat.com>
> ---
> Changes from v1:
>  * taking care of libxl_get_max_nodes() too
> ---
>  src/libxl/libxl_driver.c |   15 +++++++++++----
>  1 file changed, 11 insertions(+), 4 deletions(-)
>

ACK, fixed & pushed.

Thanks,
Martin
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 836 bytes
Desc: Digital signature
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20131218/aee11241/attachment-0001.sig>


More information about the libvir-list mailing list