aboutsummaryrefslogtreecommitdiff
path: root/hw/xen_common.h
diff options
context:
space:
mode:
authorAnthony PERARD <anthony.perard@citrix.com>2011-05-24 14:34:20 +0100
committerAlexander Graf <agraf@suse.de>2011-06-19 04:40:04 +0200
commitb87de24e6c568d40d4f231b10e1707aed1ebe92e (patch)
treed9c3e6e0e4e52917a7e45026b46153f60021635d /hw/xen_common.h
parenteb47d7c5d96060040931c42773ee07e61e547af9 (diff)
xen: Add xc_domain_add_to_physmap to xen_interface.
This function will be used to support sync dirty bitmap. This come with a check against every Xen release, and special implementation for Xen version that doesn't have this specific call. This function will not be usable with Xen 3.3 because the behavior is different. Signed-off-by: Anthony PERARD <anthony.perard@citrix.com> Signed-off-by: Alexander Graf <agraf@suse.de>
Diffstat (limited to 'hw/xen_common.h')
-rw-r--r--hw/xen_common.h14
1 files changed, 14 insertions, 0 deletions
diff --git a/hw/xen_common.h b/hw/xen_common.h
index a1958a0af1..2c79af64d0 100644
--- a/hw/xen_common.h
+++ b/hw/xen_common.h
@@ -71,6 +71,20 @@ static inline int xc_domain_populate_physmap_exact
(xc_handle, domid, nr_extents, extent_order, mem_flags, extent_start);
}
+static inline int xc_domain_add_to_physmap(int xc_handle, uint32_t domid,
+ unsigned int space, unsigned long idx,
+ xen_pfn_t gpfn)
+{
+ struct xen_add_to_physmap xatp = {
+ .domid = domid,
+ .space = space,
+ .idx = idx,
+ .gpfn = gpfn,
+ };
+
+ return xc_memory_op(xc_handle, XENMEM_add_to_physmap, &xatp);
+}
+
/* Xen 4.1 */
#else