aboutsummaryrefslogtreecommitdiffstats
path: root/tools/libxc/xenguest.h
diff options
context:
space:
mode:
authorDario Faggioli <dario.faggioli@citrix.com>2013-09-10 19:54:12 +0200
committerIan Campbell <ian.campbell@citrix.com>2013-09-13 13:10:07 +0100
commit266abb240738bb37ccb28623806273c58523f422 (patch)
treee76529b1acdc3a21ebd82fb5d776a45d8c2ba0bc /tools/libxc/xenguest.h
parentdfdfcdc6f7c51ef7e5d0547120d0ac943ef43c67 (diff)
downloadxen-266abb240738bb37ccb28623806273c58523f422.tar.gz
xen-266abb240738bb37ccb28623806273c58523f422.tar.bz2
xen-266abb240738bb37ccb28623806273c58523f422.zip
libxc: introduce xc_map_domain_meminfo (and xc_unmap_domain_meminfo)
And use it in xc_exchange_page(). This is basically because the following change need something really similar to the set of steps that are here abstracted in these two functions. Despite of the change in the interface and in the signature of some functions, this is pure code motion. No functional changes involved. Signed-off-by: Dario Faggioli <dario.faggioli@citrix.com> Acked-by: Ian Campbell <ian.campbell@citrix.com>
Diffstat (limited to 'tools/libxc/xenguest.h')
-rw-r--r--tools/libxc/xenguest.h17
1 files changed, 17 insertions, 0 deletions
diff --git a/tools/libxc/xenguest.h b/tools/libxc/xenguest.h
index 4714bd2249..c12091f52b 100644
--- a/tools/libxc/xenguest.h
+++ b/tools/libxc/xenguest.h
@@ -276,6 +276,23 @@ int xc_exchange_page(xc_interface *xch, int domid, xen_pfn_t mfn);
/**
+ * Memory related information, such as PFN types, the P2M table,
+ * the guest word width and the guest page table levels.
+ */
+struct xc_domain_meminfo {
+ unsigned int pt_levels;
+ unsigned int guest_width;
+ xen_pfn_t *pfn_type;
+ xen_pfn_t *p2m_table;
+ unsigned long p2m_size;
+};
+
+int xc_map_domain_meminfo(xc_interface *xch, int domid,
+ struct xc_domain_meminfo *minfo);
+
+int xc_unmap_domain_meminfo(xc_interface *xch, struct xc_domain_meminfo *mem);
+
+/**
* This function map m2p table
* @parm xch a handle to an open hypervisor interface
* @parm max_mfn the max pfn