From: Vincent Hanquez Subject: [PATCH 07/11] add useful xc flags in the xl_dominfo structure Date: Tue, 29 Dec 2009 18:06:55 +0000 Message-ID: <1262110019-31072-8-git-send-email-vincent.hanquez@eu.citrix.com> References: <1262110019-31072-1-git-send-email-vincent.hanquez@eu.citrix.com> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="------------1.6.5.6" Return-path: In-Reply-To: <1262110019-31072-1-git-send-email-vincent.hanquez@eu.citrix.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: xen-devel@lists.xensource.com Cc: Vincent Hanquez List-Id: xen-devel@lists.xenproject.org --------------1.6.5.6 Content-Type: text/plain; charset="UTF-8"; format=fixed Content-Transfer-Encoding: quoted-printable Signed-off-by: Vincent Hanquez --- tools/libxl/libxl.c | 8 ++++++++ tools/libxl/libxl.h | 3 +++ 2 files changed, 11 insertions(+), 0 deletions(-) --------------1.6.5.6 Content-Type: text/x-patch; name="0007-add-useful-xc-flags-in-the-xl_dominfo-structure.patch" Content-Disposition: attachment; filename="0007-add-useful-xc-flags-in-the-xl_dominfo-structure.patch" Content-Transfer-Encoding: quoted-printable diff --git a/tools/libxl/libxl.c b/tools/libxl/libxl.c index 5a8e155..4af95b2 100644 --- a/tools/libxl/libxl.c +++ b/tools/libxl/libxl.c @@ -304,6 +304,14 @@ redo: } memcpy(&(ptr[index].uuid), info[i].handle, sizeof(xen_domain_han= dle_t)); ptr[index].domid =3D info[i].domain; + + if (info[i].flags & XEN_DOMINF_dying) + ptr[index].dying =3D 1; + else if (info[i].flags & XEN_DOMINF_paused) + ptr[index].paused =3D 1; + else if (info[i].flags & XEN_DOMINF_blocked || info[i].flags & X= EN_DOMINF_running) + ptr[index].running =3D 1; + first_domain =3D info[i].domain + 1; index++; } diff --git a/tools/libxl/libxl.h b/tools/libxl/libxl.h index 2d82829..3d2843c 100644 --- a/tools/libxl/libxl.h +++ b/tools/libxl/libxl.h @@ -28,6 +28,9 @@ typedef void (*libxl_log_callback)(void *userdata, int = loglevel, const char *fil struct libxl_dominfo { xen_uuid_t uuid; uint32_t domid; + uint8_t dying:1; + uint8_t paused:1; + uint8_t running:1; }; =20 struct libxl_ctx { --------------1.6.5.6 Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel --------------1.6.5.6--