]> xenbits.xensource.com Git - people/liuw/libxenctrl-split/qemu-xen.git/commitdiff
xen: use xendevicemodel_mark_memory_region_dirty
authorIan Campbell <ian.campbell@citrix.com>
Fri, 29 Jan 2016 16:28:35 +0000 (16:28 +0000)
committerIan Campbell <ian.campbell@citrix.com>
Thu, 11 Feb 2016 16:16:44 +0000 (16:16 +0000)
Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
configure
include/hw/xen/xen_common.h
xen-hvm.c

index 4908dab9bd8974406ffaae79351d954337638f48..b5d9219df3a01a5f8bf4732184541525fe697928 100755 (executable)
--- a/configure
+++ b/configure
@@ -2184,6 +2184,7 @@ int main(void) {
   xendevicemodel_set_pci_intx_level(dm, 0, 0, 0, 0, 0);
   xendevicemodel_populate_ram(dm, 0, 0);
   xendevicemodel_create_ioreq_server(dm, 1, NULL);
+  xendevicemodel_mark_memory_region_dirty(dm, 0, 0);
   return 0;
 }
 EOF
index 86749467ae4fa19ffd3cd885e40c28916f9a827b..58c479e3884a0773024acfd0ab36eb18be6399b9 100644 (file)
@@ -152,6 +152,9 @@ static inline int xendevicemodel_populate_ram(xendevicemodel_handle *h,
 #define xendevicemodel_inject_msi(h, a, d) \
     xc_hvm_inject_msi(h, xen_domid, a, d)
 
+#define xendevicemodel_mark_memory_region_dirty(h, s, n) \
+    xc_hvm_modified_memory(h, xen_domid, s, n)
+
 #if CONFIG_XEN_CTRL_INTERFACE_VERSION >= 450
 
 #define xendevicemodel_create_ioreq_server(h, b, i) \
index 91fb3e3ae49710fd5850c152b062796318e4f66b..a6807a0a1b24899e630a60d54333cd58a9c07809 100644 (file)
--- a/xen-hvm.c
+++ b/xen-hvm.c
@@ -1399,7 +1399,7 @@ void xen_modified_memory(ram_addr_t start, ram_addr_t length)
         start_pfn = start >> TARGET_PAGE_BITS;
         nb_pages = ((start + length + TARGET_PAGE_SIZE - 1) >> TARGET_PAGE_BITS)
             - start_pfn;
-        rc = xc_hvm_modified_memory(xen_xc, xen_domid, start_pfn, nb_pages);
+        rc = xendevicemodel_mark_memory_region_dirty(xen_dm, start_pfn, nb_pages);
         if (rc) {
             fprintf(stderr,
                     "%s failed for "RAM_ADDR_FMT" ("RAM_ADDR_FMT"): %i, %s\n",