[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-changelog] [xen-unstable] xenpaging: mmap guest pages read-only



# HG changeset patch
# User Olaf Hering <olaf@xxxxxxxxx>
# Date 1329754298 0
# Node ID 4173658d1af13ff2fe0f496bb6026307b1ddc167
# Parent  87218bd367befca7d3488ba1cf4feb2b10d5f14e
xenpaging: mmap guest pages read-only

xenpaging does not write to the gfn, so map the gfn to page-out in
read-only mode.

Signed-off-by: Olaf Hering <olaf@xxxxxxxxx>
Signed-off-by: Ian Jackson <ian.jackson@xxxxxxxxxxxxx>
Committed-by: Ian Jackson <ian.jackson@xxxxxxxxxxxxx>
---


diff -r 87218bd367be -r 4173658d1af1 tools/xenpaging/xenpaging.c
--- a/tools/xenpaging/xenpaging.c       Fri Feb 17 12:24:38 2012 +0000
+++ b/tools/xenpaging/xenpaging.c       Mon Feb 20 16:11:38 2012 +0000
@@ -574,7 +574,7 @@
     gfn = victim->gfn;
     ret = -EFAULT;
     page = xc_map_foreign_pages(xch, paging->mem_event.domain_id,
-                                PROT_READ | PROT_WRITE, &gfn, 1);
+                                PROT_READ, &gfn, 1);
     if ( page == NULL )
     {
         PERROR("Error mapping page %lx", victim->gfn);

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.