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

[Xen-changelog] [xen-unstable] xenpaging: Fix 32-bit build after fixed-width type changes.



# HG changeset patch
# User Keir Fraser <keir.fraser@xxxxxxxxxx>
# Date 1277932374 -3600
# Node ID aecf092da7489bd41ffd3e58964535a0d61eb3b4
# Parent  fae04060a4f4e364c5012692b97ae1eeec3a326e
xenpaging: Fix 32-bit build after fixed-width type changes.

Signed-off-by: Keir Fraser <keir.fraser@xxxxxxxxxx>
---
 tools/xenpaging/xenpaging.c |   16 ++++++++++------
 1 files changed, 10 insertions(+), 6 deletions(-)

diff -r fae04060a4f4 -r aecf092da748 tools/xenpaging/xenpaging.c
--- a/tools/xenpaging/xenpaging.c       Wed Jun 30 18:12:43 2010 +0100
+++ b/tools/xenpaging/xenpaging.c       Wed Jun 30 22:12:54 2010 +0100
@@ -375,9 +375,11 @@ int xenpaging_resume_page(xenpaging_t *p
     return ret;
 }
 
-int xenpaging_populate_page(xc_interface *xch, xenpaging_t *paging,
-                            unsigned long *gfn, int fd, int i)
-{
+static int xenpaging_populate_page(
+    xc_interface *xch, xenpaging_t *paging,
+    uint64_t *gfn, int fd, int i)
+{
+    unsigned long _gfn;
     void *page;
     int ret;
 
@@ -392,8 +394,10 @@ int xenpaging_populate_page(xc_interface
 
     /* Map page */
     ret = -EFAULT;
+    _gfn = *gfn;
     page = xc_map_foreign_pages(paging->xc_handle, paging->mem_event.domain_id,
-                                PROT_READ | PROT_WRITE, gfn, 1);
+                                PROT_READ | PROT_WRITE, &_gfn, 1);
+    *gfn = _gfn;
     if ( page == NULL )
     {
         ERROR("Error mapping page: page is null");
@@ -548,7 +552,7 @@ int main(int argc, char *argv[])
     
                 if ( i >= num_pages )
                 {
-                    DPRINTF("Couldn't find page %lx\n", req.gfn);
+                    DPRINTF("Couldn't find page %"PRIx64"\n", req.gfn);
                     goto out;
                 }
                 
@@ -579,7 +583,7 @@ int main(int argc, char *argv[])
             else
             {
                 DPRINTF("page already populated (domain = %d; vcpu = %d;"
-                        " gfn = %lx; paused = %"PRId64")\n",
+                        " gfn = %"PRIx64"; paused = %"PRId64")\n",
                         paging->mem_event.domain_id, req.vcpu_id,
                         req.gfn, req.flags & MEM_EVENT_FLAG_VCPU_PAUSED);
 

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
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®.