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] [MINI-OS] Add evtchn_bind_interdomain to

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [xen-unstable] [MINI-OS] Add evtchn_bind_interdomain to mini-os, allowing clients to
From: Xen patchbot-unstable <patchbot-unstable@xxxxxxxxxxxxxxxxxxx>
Date: Fri, 28 Jul 2006 21:50:48 +0000
Delivery-date: Fri, 28 Jul 2006 14:53:33 -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 sos22@xxxxxxxxxxxxxxxxxxxx
# Node ID cbfced5fcdb348f23c8727305230b638b16c92dd
# Parent  97ffb7856239a937f391583e881fae695c86fb68
[MINI-OS] Add evtchn_bind_interdomain to mini-os, allowing clients to
bind to interdomain event channels.

Signed-off-by: John D. Ramsdell <ramsdell@xxxxxxxxx>
Signed-off-by: Steven Smith <sos22@xxxxxxxxx>
---
 extras/mini-os/events.c         |   20 ++++++++++++++++++++
 extras/mini-os/include/events.h |    3 +++
 2 files changed, 23 insertions(+)

diff -r 97ffb7856239 -r cbfced5fcdb3 extras/mini-os/events.c
--- a/extras/mini-os/events.c   Fri Jul 28 14:03:54 2006 +0100
+++ b/extras/mini-os/events.c   Fri Jul 28 14:05:02 2006 +0100
@@ -161,3 +161,23 @@ int evtchn_alloc_unbound(domid_t pal, ev
     *port = bind_evtchn(op.u.alloc_unbound.port, handler, data);
     return err;
 }
+
+/* Connect to a port so as to allow the exchange of notifications with
+   the pal. Returns the result of the hypervisor call. */
+
+int evtchn_bind_interdomain(domid_t pal, evtchn_port_t remote_port,
+                           evtchn_handler_t handler, void *data,
+                           evtchn_port_t *local_port)
+{
+    evtchn_op_t op;
+    op.cmd = EVTCHNOP_bind_interdomain;
+    op.u.bind_interdomain.remote_dom = pal;
+    op.u.bind_interdomain.remote_port = remote_port;
+    int err = HYPERVISOR_event_channel_op(&op);
+    if (err)
+               return err;
+       evtchn_port_t port = op.u.bind_interdomain.local_port;
+    clear_evtchn(port);              /* Without, handler gets invoked now! */
+    *local_port = bind_evtchn(port, handler, data);
+    return err;
+}
diff -r 97ffb7856239 -r cbfced5fcdb3 extras/mini-os/include/events.h
--- a/extras/mini-os/include/events.h   Fri Jul 28 14:03:54 2006 +0100
+++ b/extras/mini-os/include/events.h   Fri Jul 28 14:05:02 2006 +0100
@@ -33,6 +33,9 @@ void init_events(void);
 void init_events(void);
 int evtchn_alloc_unbound(domid_t pal, evtchn_handler_t handler,
                                                 void *data, evtchn_port_t 
*port);
+int evtchn_bind_interdomain(domid_t pal, evtchn_port_t remote_port,
+                                                       evtchn_handler_t 
handler, void *data,
+                                                       evtchn_port_t 
*local_port);
 
 static inline int notify_remote_via_evtchn(evtchn_port_t port)
 {

_______________________________________________
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] [MINI-OS] Add evtchn_bind_interdomain to mini-os, allowing clients to, Xen patchbot-unstable <=