]> xenbits.xensource.com Git - people/iwj/xen.git/commitdiff
xl: export 'outstanding_pages' value from xcinfo
authorKonrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Fri, 1 Mar 2013 21:49:42 +0000 (16:49 -0500)
committerIan Jackson <Ian.Jackson@eu.citrix.com>
Tue, 16 Apr 2013 15:21:50 +0000 (16:21 +0100)
This patch provides the value of the currently outstanding pages
claimed for a specific domain. This is a value that influences
the global outstanding claims value (See patch: "xl: 'xl info'
print outstanding claims if enabled") returned via
xc_domain_get_outstanding_pages hypercall. This domain value
decrements as the memory is populated for the guest and
eventually reaches zero.

With this patch it is possible to utilize this field.

Acked-by: Ian Campbell <ian.campbell@citrix.com>
[v2: s/unclaimed/outstanding/ per Tim's suggestion]
[v3: Don't use SXP printout file per Ian's suggestion]
Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Acked-by: Ian Jackson <ian.jackson@eu.citrix.com>
tools/libxl/libxl.c
tools/libxl/libxl_types.idl

index 230b9544d6a65e3ac8630e10255b7e3fe3810cca..8b0e415044d749dc2e1932cc1181af4144e71bfd 100644 (file)
@@ -528,6 +528,7 @@ static void xcinfo2xlinfo(const xc_domaininfo_t *xcinfo,
     else
         xlinfo->shutdown_reason  = ~0;
 
+    xlinfo->outstanding_memkb = PAGE_TO_MEMKB(xcinfo->outstanding_pages);
     xlinfo->current_memkb = PAGE_TO_MEMKB(xcinfo->tot_pages);
     xlinfo->shared_memkb = PAGE_TO_MEMKB(xcinfo->shr_pages);
     xlinfo->paged_memkb = PAGE_TO_MEMKB(xcinfo->paged_pages);
index 4d8f7cd18e752c47e1d1b47e96d13f53e074b4d0..fcb1ecd356111ab7c1f7f7d7fd8b66338694b562 100644 (file)
@@ -196,6 +196,7 @@ libxl_dominfo = Struct("dominfo",[
     # Otherwise set to a value guaranteed not to clash with any valid
     # LIBXL_SHUTDOWN_REASON_* constant.
     ("shutdown_reason", libxl_shutdown_reason),
+    ("outstanding_memkb",  MemKB),
     ("current_memkb",   MemKB),
     ("shared_memkb", MemKB),
     ("paged_memkb", MemKB),