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

[Xen-devel] [PATCH] notify_via_evtchn returning int

To: "Ian Pratt" <m+Ian.Pratt@xxxxxxxxxxxx>, xen-devel@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-devel] [PATCH] notify_via_evtchn returning int
From: Stefan Berger <stefanb@xxxxxxxxxx>
Date: Fri, 15 Apr 2005 14:20:25 -0400
Delivery-date: Fri, 15 Apr 2005 18:20:26 +0000
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <A95E2296287EAD4EB592B5DEEFCE0E9D1E3BC1@xxxxxxxxxxxxxxxxxxxxxxxxxxx>
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
Below is the patch that returns an 'int' from the notify_via_evtchn() 
call.

Signed-off-by: Stefan Berger <stefanb@xxxxxxxxxx>

--- 
/xen/tmp/xeno-unstable.bk/linux-2.6.11-xen-sparse/include/asm-xen/evtchn.h 
         2005-03-31 16:17:04.000000000 -0500
+++ linux-2.6.11-xen-sparse/include/asm-xen/evtchn.h 2005-04-15 
13:19:14.358768869 -0400
@@ -80,12 +80,12 @@
     synch_clear_bit(port, &s->evtchn_pending[0]);
 }
 
-static inline void notify_via_evtchn(int port)
+static inline int notify_via_evtchn(int port)
 {
     evtchn_op_t op;
     op.cmd = EVTCHNOP_send;
     op.u.send.local_port = port;
-    (void)HYPERVISOR_event_channel_op(&op);
+    return HYPERVISOR_event_channel_op(&op);
 }
 
 /*

xen-devel-bounces@xxxxxxxxxxxxxxxxxxx wrote on 04/15/2005 01:12:44 PM:

> >   The function 
> > include/asm-xen/evtchn.h:notify_via_evtchn(int) currently has 
> > a 'void' as return, however, there are useful error values 
> > coming back from the Hypervisor call. Would it be possible to 
> > have this value return an 'int' and the result of the 
> > Hypervisor call? Thanks.
> 
> Yep, EINVAL is a possibility. Could you work up a patch?
> 
> Thanks,
> Ian 
> 
> _______________________________________________
> Xen-devel mailing list
> Xen-devel@xxxxxxxxxxxxxxxxxxx
> http://lists.xensource.com/xen-devel


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

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