2012-01-05 20:41:54 +01:00
|
|
|
xenpaging: mmap gfn to evict in readonly mode
|
|
|
|
|
|
|
|
nominate/evict will not modify the page so there is no need to map the page rw.
|
|
|
|
|
|
|
|
---
|
|
|
|
tools/xenpaging/xenpaging.c | 3 +--
|
|
|
|
1 file changed, 1 insertion(+), 2 deletions(-)
|
|
|
|
|
2012-06-11 16:07:46 +02:00
|
|
|
Index: xen-4.1.2-testing/tools/xenpaging/xenpaging.c
|
|
|
|
===================================================================
|
|
|
|
--- xen-4.1.2-testing.orig/tools/xenpaging/xenpaging.c
|
|
|
|
+++ xen-4.1.2-testing/tools/xenpaging/xenpaging.c
|
2012-01-05 20:41:54 +01:00
|
|
|
@@ -575,8 +575,7 @@ static int xenpaging_evict_page(xenpagin
|
|
|
|
|
|
|
|
/* Map page to get a handle */
|
|
|
|
gfn = victim->gfn;
|
|
|
|
- page = xc_map_foreign_pages(xch, paging->mem_event.domain_id,
|
|
|
|
- PROT_READ | PROT_WRITE, &gfn, 1);
|
|
|
|
+ page = xc_map_foreign_pages(xch, paging->mem_event.domain_id, PROT_READ, &gfn, 1);
|
|
|
|
if ( page == NULL )
|
|
|
|
{
|
|
|
|
if ( errno == EINVAL )
|