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] [linux-2.6.18-xen] [IA64] xencomm update for acm interfa

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [linux-2.6.18-xen] [IA64] xencomm update for acm interface change
From: "Xen patchbot-linux-2.6.18-xen" <patchbot-linux-2.6.18-xen@xxxxxxxxxxxxxxxxxxx>
Date: Sat, 16 Jun 2007 05:59:59 -0700
Delivery-date: Sat, 16 Jun 2007 05:58:25 -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 Alex Williamson <alex.williamson@xxxxxx>
# Date 1181685161 21600
# Node ID 1483ef74511b1c9819212aac9f67232a66f71adf
# Parent  a62cfa35d3b504d5ee1acd4a409a6fb3ee45a6bd
[IA64] xencomm update for acm interface change

Changed by c/s 15189:96915ca8d5f2 of xen-unstable.h

Signed-off-by: Isaku Yamahata <yamahata@xxxxxxxxxxxxx>
---
 arch/ia64/xen/xcom_privcmd.c |   57 +++++++++++++++++++++----------------------
 include/asm-ia64/hypercall.h |    6 ++--
 2 files changed, 31 insertions(+), 32 deletions(-)

diff -r a62cfa35d3b5 -r 1483ef74511b arch/ia64/xen/xcom_privcmd.c
--- a/arch/ia64/xen/xcom_privcmd.c      Tue Jun 12 15:48:23 2007 -0600
+++ b/arch/ia64/xen/xcom_privcmd.c      Tue Jun 12 15:52:41 2007 -0600
@@ -338,40 +338,39 @@ static int
 static int
 xencomm_privcmd_acm_op(privcmd_hypercall_t *hypercall)
 {
-       int cmd = hypercall->arg[0];
-       void __user *arg = (void __user *)hypercall->arg[1];
+       void __user *arg = (void __user *)hypercall->arg[0];
+       xen_acmctl_t kern_arg;
        struct xencomm_handle *op_desc;
        struct xencomm_handle *desc = NULL;
        int ret;
 
-       switch (cmd) {
-       case ACMOP_getssid:
-       {
-               struct acm_getssid kern_arg;
-
-               if (copy_from_user(&kern_arg, arg, sizeof (kern_arg)))
+       if (copy_from_user(&kern_arg, arg, sizeof(kern_arg)))
+               return -EFAULT;
+       if (kern_arg.interface_version != ACM_INTERFACE_VERSION)
+               return -ENOSYS;
+       
+       switch (kern_arg.cmd) {
+       case ACMOP_getssid: {
+               op_desc = xencomm_create_inline(&kern_arg);
+
+               ret = xencomm_create(
+                       xen_guest_handle(kern_arg.u.getssid.ssidbuf),
+                       kern_arg.u.getssid.ssidbuf_size, &desc, GFP_KERNEL);
+               if (ret)
+                       return ret;
+
+               set_xen_guest_handle(kern_arg.u.getssid.ssidbuf, (void *)desc);
+
+               ret = xencomm_arch_hypercall_acm_op(op_desc);
+
+               xencomm_free(desc);
+
+               if (copy_to_user(arg, &kern_arg, sizeof(kern_arg)))
                        return -EFAULT;
-
-               op_desc = xencomm_create_inline(&kern_arg);
-
-               ret = xencomm_create(xen_guest_handle(kern_arg.ssidbuf),
-                                    kern_arg.ssidbuf_size, &desc, GFP_KERNEL);
-               if (ret)
-                       return ret;
-
-               set_xen_guest_handle(kern_arg.ssidbuf, (void *)desc);
-
-               ret = xencomm_arch_hypercall_acm_op(cmd, op_desc);
-
-               xencomm_free(desc);
-
-               if (copy_to_user(arg, &kern_arg, sizeof (kern_arg)))
-                       return -EFAULT;
-
-               return ret;
-       }
-       default:
-               printk("%s: unknown acm_op cmd %d\n", __func__, cmd);
+               return ret;
+       }
+       default:
+               printk("%s: unknown acm_op cmd %d\n", __func__, kern_arg.cmd);
                return -ENOSYS;
        }
 
diff -r a62cfa35d3b5 -r 1483ef74511b include/asm-ia64/hypercall.h
--- a/include/asm-ia64/hypercall.h      Tue Jun 12 15:48:23 2007 -0600
+++ b/include/asm-ia64/hypercall.h      Tue Jun 12 15:52:41 2007 -0600
@@ -157,9 +157,9 @@ xencomm_arch_hypercall_event_channel_op(
 }
 
 static inline int
-xencomm_arch_hypercall_acm_op(unsigned int cmd, struct xencomm_handle *arg)
-{
-       return _hypercall2(int, acm_op, cmd, arg);
+xencomm_arch_hypercall_acm_op(struct xencomm_handle *arg)
+{
+       return _hypercall1(int, acm_op, arg);
 }
 
 static inline int

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

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] [linux-2.6.18-xen] [IA64] xencomm update for acm interface change, Xen patchbot-linux-2.6.18-xen <=