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

Re: [XenPPC] [linux-ppc-2.6] [XEN][POWERPC] HYPERVISOR_memory_op() retur

To: xen-ppc-devel@xxxxxxxxxxxxxxxxxxx
Subject: Re: [XenPPC] [linux-ppc-2.6] [XEN][POWERPC] HYPERVISOR_memory_op() return value now has meaning
From: Jimi Xenidis <jimix@xxxxxxxxxxxxxx>
Date: Tue, 14 Nov 2006 19:49:36 -0500
Delivery-date: Tue, 14 Nov 2006 16:49:46 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
In-reply-to: <E1Gk8t1-0007vX-5g@xxxxxxxxxxxxxxxxxxxxx>
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>
References: <E1Gk8t1-0007vX-5g@xxxxxxxxxxxxxxxxxxxxx>
Sender: xen-ppc-devel-bounces@xxxxxxxxxxxxxxxxxxx
Yi noticed that we could not build domains with memory beyond the RMA.
This Linux patch fixes that.
-JX
On Nov 14, 2006, at 7:44 PM, Xen patchbot-linux-ppc-2.6 wrote:

# 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


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

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