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-ppc-devel

[XenPPC] [linux-ppc-2.6] [XEN][POWERPC] HYPERVISOR_memory_op() return va

To: xen-ppc-devel@xxxxxxxxxxxxxxxxxxx
Subject: [XenPPC] [linux-ppc-2.6] [XEN][POWERPC] HYPERVISOR_memory_op() return value now has meaning
From: Xen patchbot-linux-ppc-2.6 <patchbot-linux-ppc-2.6@xxxxxxxxxxxxxxxxxxx>
Date: Wed, 15 Nov 2006 00:44:14 +0000
Delivery-date: Tue, 14 Nov 2006 16:48:17 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-ppc-devel-request@lists.xensource.com?subject=help>
List-id: Xen PPC development <xen-ppc-devel.lists.xensource.com>
List-post: <mailto:xen-ppc-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-ppc-devel>, <mailto:xen-ppc-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-ppc-devel>, <mailto:xen-ppc-devel-request@lists.xensource.com?subject=unsubscribe>
Reply-to: xen-ppc-devel@xxxxxxxxxxxxxxxxxxx
Sender: xen-ppc-devel-bounces@xxxxxxxxxxxxxxxxxxx
# HG changeset patch
# User Jimi Xenidis <jimix@xxxxxxxxxxxxxx>
# Node ID 47cd37e8f8a91bdf10b314cbaa8d5a9088be30fc
# Parent  01f3c63f0343051ce1cc039b4bd38def61eb3def
[XEN][POWERPC] HYPERVISOR_memory_op() return value now has meaning

This patch fixes a "false" failure when calling HYPERVISOR_memory_op()
from user space, where the return value fromt he hcall is expected.

With this fix, the recent bits can can create domains beyond their RMA.

Signed-off-by: Jimi Xenidis <jimix@xxxxxxxxxxxxxx>
---
 arch/powerpc/platforms/xen/hcall.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletion(-)

diff -r 01f3c63f0343 -r 47cd37e8f8a9 arch/powerpc/platforms/xen/hcall.c
--- a/arch/powerpc/platforms/xen/hcall.c        Sat Nov 11 10:25:31 2006 -0500
+++ b/arch/powerpc/platforms/xen/hcall.c        Tue Nov 14 19:33:36 2006 -0500
@@ -520,7 +520,8 @@ static int xenppc_privcmd_memory_op(priv
                           sizeof(xen_memory_reservation_t)))
                return -EFAULT;
 
-       if (!HYPERVISOR_memory_op(cmd, &kern_op)) {
+       ret = HYPERVISOR_memory_op(cmd, &kern_op);
+       if (ret >= 0) {
                if (copy_to_user(user_op, &kern_op,
                                 sizeof(xen_memory_reservation_t)))
                        return -EFAULT;

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

<Prev in Thread] Current Thread [Next in Thread>