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

[Xen-changelog] Fix PAE overflow in xc_linux_build.



# HG changeset patch
# User kaf24@xxxxxxxxxxxxxxxxxxxx
# Node ID 1fd8bd3591183c55d234c2588679358aec0109ba
# Parent  0fd84f16810364e0963106e16dd0d5ee6c17ed69
Fix PAE overflow in xc_linux_build.
Signed-off-by: srparish@xxxxxxxxxx

diff -r 0fd84f168103 -r 1fd8bd359118 tools/libxc/xc_linux_build.c
--- a/tools/libxc/xc_linux_build.c      Wed Oct 12 08:29:52 2005
+++ b/tools/libxc/xc_linux_build.c      Wed Oct 12 08:31:53 2005
@@ -500,11 +500,11 @@
            _p(dsi.v_start), _p(v_end));
     printf(" ENTRY ADDRESS: %p\n", _p(dsi.v_kernentry));
 
-    if ( (v_end - dsi.v_start) > (nr_pages * PAGE_SIZE) )
-    {
-        PERROR("Initial guest OS requires too much space\n"
+    if ( ((v_end - dsi.v_start)>>PAGE_SHIFT) > nr_pages )
+    {
+        printf("Initial guest OS requires too much space\n"
                "(%luMB is greater than %luMB limit)\n",
-               (v_end-dsi.v_start)>>20, (nr_pages<<PAGE_SHIFT)>>20);
+               (v_end-dsi.v_start)>>20, nr_pages>>(20-PAGE_SHIFT));
         goto error_out;
     }
 

_______________________________________________
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®.