WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-changelog

[Xen-changelog] [xen-unstable] 32-on-64: Fix error handling for XENMEM_d

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [xen-unstable] 32-on-64: Fix error handling for XENMEM_decrease_reservation.
From: Xen patchbot-unstable <patchbot-unstable@xxxxxxxxxxxxxxxxxxx>
Date: Fri, 13 Jun 2008 14:10:37 -0700
Delivery-date: Fri, 13 Jun 2008 14:11:40 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-changelog-request@lists.xensource.com?subject=help>
List-id: BK change log <xen-changelog.lists.xensource.com>
List-post: <mailto:xen-changelog@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=unsubscribe>
Reply-to: xen-devel@xxxxxxxxxxxxxxxxxxx
Sender: xen-changelog-bounces@xxxxxxxxxxxxxxxxxxx
# HG changeset patch
# User Keir Fraser <keir.fraser@xxxxxxxxxx>
# Date 1213361248 -3600
# Node ID 12ae02c09d1e9f0cd7153f256618dcc544420d54
# Parent  7eab5d8788a6becb07d56a8ffa12b3675a21f4bb
32-on-64: Fix error handling for XENMEM_decrease_reservation.
Signed-off-by: Keir Fraser <keir.fraser@xxxxxxxxxx>
---
 xen/common/compat/memory.c |   11 ++++++-----
 1 files changed, 6 insertions(+), 5 deletions(-)

diff -r 7eab5d8788a6 -r 12ae02c09d1e xen/common/compat/memory.c
--- a/xen/common/compat/memory.c        Fri Jun 13 11:39:42 2008 +0100
+++ b/xen/common/compat/memory.c        Fri Jun 13 13:47:28 2008 +0100
@@ -250,7 +250,7 @@ int compat_memory_op(unsigned int cmd, X
         case XENMEM_decrease_reservation:
         case XENMEM_populate_physmap:
             end_extent = split >= 0 ? rc : cmd >> MEMOP_EXTENT_SHIFT;
-            if ( op != XENMEM_decrease_reservation &&
+            if ( (op != XENMEM_decrease_reservation) &&
                  !guest_handle_is_null(nat.rsrv->extent_start) )
             {
                 for ( ; start_extent < end_extent; ++start_extent )
@@ -276,13 +276,14 @@ int compat_memory_op(unsigned int cmd, X
                         break;
                     }
                 }
-
-                /* Bail if there was an error. */
-                if ( (split >= 0) && (end_extent != nat.rsrv->nr_extents) )
-                    split = 0;
             }
             else
+            {
                 start_extent = end_extent;
+            }
+            /* Bail if there was an error. */
+            if ( (split >= 0) && (end_extent != nat.rsrv->nr_extents) )
+                split = 0;
             break;
 
         case XENMEM_exchange:

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] [xen-unstable] 32-on-64: Fix error handling for XENMEM_decrease_reservation., Xen patchbot-unstable <=