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

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



# HG changeset patch
# User Keir Fraser <keir.fraser@xxxxxxxxxx>
# Date 1277932480 -3600
# Node ID 67caec4b162d250c5b2e4c957994b88c22f94e00
# Parent  9687dcf4d32890bff9f44dfd24a2108b3d3eb8a0
xenpaging: Fix 32-bit build after fixed-width type changes.

Signed-off-by: Keir Fraser <keir.fraser@xxxxxxxxxx>
xen-unstable changeset:   21701:aecf092da748
xen-unstable date:        Wed Jun 30 22:12:54 2010 +0100
---
 tools/xenpaging/xenpaging.c |   14 +++++++++-----
 1 files changed, 9 insertions(+), 5 deletions(-)

diff -r 9687dcf4d328 -r 67caec4b162d tools/xenpaging/xenpaging.c
--- a/tools/xenpaging/xenpaging.c       Wed Jun 30 18:24:55 2010 +0100
+++ b/tools/xenpaging/xenpaging.c       Wed Jun 30 22:14:40 2010 +0100
@@ -373,8 +373,10 @@ int xenpaging_resume_page(xenpaging_t *p
     return ret;
 }
 
-int xenpaging_populate_page(xenpaging_t *paging, unsigned long *gfn, int fd, 
int i)
-{
+static int xenpaging_populate_page(
+    xenpaging_t *paging, uint64_t *gfn, int fd, int i)
+{
+    unsigned long _gfn;
     void *page;
     int ret;
 
@@ -389,8 +391,10 @@ int xenpaging_populate_page(xenpaging_t 
 
     /* 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");
@@ -544,7 +548,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;
                 }
                 
@@ -575,7 +579,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®.