The `if' statement considered return value 0 from libxl_domain_info an error, while 0 actually means success.
Signed-off-by: Wei Liu <wei.l...@citrix.com> Cc: Ian Campbell <ian.campb...@citrix.com> Cc: Ian Jackson <ian.jack...@eu.citrix.com> --- This is a bug fix for PSR feature. This feature was added recently and it's not an regression. However, it would be good to have it working correctly since the beginning, and the fix is straightforward, which should be of very low risk. --- tools/libxl/xl_cmdimpl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/libxl/xl_cmdimpl.c b/tools/libxl/xl_cmdimpl.c index 3c9f146..9afef3f 100644 --- a/tools/libxl/xl_cmdimpl.c +++ b/tools/libxl/xl_cmdimpl.c @@ -7908,7 +7908,7 @@ static int psr_cmt_show_cache_occupancy(uint32_t domid) /* Each domain */ if (domid != INVALID_DOMID) { libxl_dominfo dominfo; - if (!libxl_domain_info(ctx, &dominfo, domid)) { + if (libxl_domain_info(ctx, &dominfo, domid)) { fprintf(stderr, "Failed to get domain info for %d\n", domid); return -1; } -- 1.7.10.4 _______________________________________________ Xen-devel mailing list Xen-devel@lists.xen.org http://lists.xen.org/xen-devel