Olaf Hering
ee2be8156e
This change reverses the task of xenpaging. Before this change a fixed number of pages was paged out. With this change the guest will not have access to more than the given number of pages at the same time. The xenpaging= config option is replaced by actmem= A new xm mem-swap-target is added. The xenpaging binary is moved to /usr/lib/xen/bin/ xenpaging.HVMCOPY_gfn_paged_out.patch xenpaging.XEN_PAGING_DIR.patch xenpaging.add_evict_pages.patch xenpaging.bitmap_clear.patch xenpaging.cmdline-interface.patch xenpaging.encapsulate_domain_info.patch xenpaging.file_op-return-code.patch xenpaging.guest-memusage.patch xenpaging.install-to-libexec.patch xenpaging.low_target_policy_nomru.patch xenpaging.main-loop-exit-handling.patch xenpaging.misleading-comment.patch xenpaging.page_in-munmap-size.patch xenpaging.print-gfn.patch xenpaging.record-numer-paged-out-pages.patch xenpaging.reset-uncomsumed.patch xenpaging.stale-comments.patch xenpaging.target-tot_pages.patch xenpaging.use-PERROR.patch xenpaging.watch-target-tot_pages.patch xenpaging.watch_event-DPRINTF.patch xenpaging.xc_interface_open-comment.patch - xen.spec: update filelist package /usr/lib*/xen with wildcard to pickup new files remove duplicate /usr/sbin/xen-list from filelist OBS-URL: https://build.opensuse.org/package/show/Virtualization/xen?expand=0&rev=157
96 lines
3.2 KiB
Diff
96 lines
3.2 KiB
Diff
# HG changeset patch
|
|
# Parent 9c7e82499e983ad11b13dd41d2fa5f12072adecf
|
|
xenpaging: print gfn in failure case
|
|
|
|
Signed-off-by: Olaf Hering <olaf@aepfle.de>
|
|
|
|
---
|
|
tools/xenpaging/xenpaging.c | 18 +++++++++---------
|
|
1 file changed, 9 insertions(+), 9 deletions(-)
|
|
|
|
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
|
|
@@ -444,7 +444,7 @@ static int xenpaging_evict_page(xenpagin
|
|
PROT_READ | PROT_WRITE, &gfn, 1);
|
|
if ( page == NULL )
|
|
{
|
|
- PERROR("Error mapping page");
|
|
+ PERROR("Error mapping page %lx", victim->gfn);
|
|
goto out;
|
|
}
|
|
|
|
@@ -452,7 +452,7 @@ static int xenpaging_evict_page(xenpagin
|
|
ret = write_page(fd, page, i);
|
|
if ( ret != 0 )
|
|
{
|
|
- PERROR("Error copying page");
|
|
+ PERROR("Error copying page %lx", victim->gfn);
|
|
munmap(page, PAGE_SIZE);
|
|
goto out;
|
|
}
|
|
@@ -464,7 +464,7 @@ static int xenpaging_evict_page(xenpagin
|
|
victim->gfn);
|
|
if ( ret != 0 )
|
|
{
|
|
- PERROR("Error evicting page");
|
|
+ PERROR("Error evicting page %lx", victim->gfn);
|
|
goto out;
|
|
}
|
|
|
|
@@ -520,7 +520,7 @@ static int xenpaging_populate_page(xenpa
|
|
sleep(1);
|
|
continue;
|
|
}
|
|
- PERROR("Error preparing for page in");
|
|
+ PERROR("Error preparing %"PRI_xen_pfn" for page-in", gfn);
|
|
goto out_map;
|
|
}
|
|
}
|
|
@@ -532,7 +532,7 @@ static int xenpaging_populate_page(xenpa
|
|
PROT_READ | PROT_WRITE, &gfn, 1);
|
|
if ( page == NULL )
|
|
{
|
|
- PERROR("Error mapping page: page is null");
|
|
+ PERROR("Error mapping page %"PRI_xen_pfn": page is null", gfn);
|
|
goto out_map;
|
|
}
|
|
|
|
@@ -540,7 +540,7 @@ static int xenpaging_populate_page(xenpa
|
|
ret = read_page(fd, page, i);
|
|
if ( ret != 0 )
|
|
{
|
|
- PERROR("Error reading page");
|
|
+ PERROR("Error reading page %"PRI_xen_pfn"", gfn);
|
|
goto out;
|
|
}
|
|
|
|
@@ -710,7 +710,7 @@ int main(int argc, char *argv[])
|
|
rc = xenpaging_populate_page(paging, req.gfn, fd, i);
|
|
if ( rc != 0 )
|
|
{
|
|
- PERROR("Error populating page");
|
|
+ PERROR("Error populating page %"PRIx64"", req.gfn);
|
|
goto out;
|
|
}
|
|
}
|
|
@@ -723,7 +723,7 @@ int main(int argc, char *argv[])
|
|
rc = xenpaging_resume_page(paging, &rsp, 1);
|
|
if ( rc != 0 )
|
|
{
|
|
- PERROR("Error resuming page");
|
|
+ PERROR("Error resuming page %"PRIx64"", req.gfn);
|
|
goto out;
|
|
}
|
|
|
|
@@ -754,7 +754,7 @@ int main(int argc, char *argv[])
|
|
rc = xenpaging_resume_page(paging, &rsp, 0);
|
|
if ( rc != 0 )
|
|
{
|
|
- PERROR("Error resuming");
|
|
+ PERROR("Error resuming page %"PRIx64"", req.gfn);
|
|
goto out;
|
|
}
|
|
}
|