aboutsummaryrefslogtreecommitdiffstats
path: root/tools/xenstore/xenstored_domain.c
diff options
context:
space:
mode:
authorkaf24@firebug.cl.cam.ac.uk <kaf24@firebug.cl.cam.ac.uk>2005-12-01 15:22:22 +0100
committerkaf24@firebug.cl.cam.ac.uk <kaf24@firebug.cl.cam.ac.uk>2005-12-01 15:22:22 +0100
commit96428d33d9b6f28ce02902eae1a480b1d8f0e713 (patch)
tree2309ca46a0c07d0d9d84881b437d5e23ed8911fc /tools/xenstore/xenstored_domain.c
parent23f0fe07cd3c89f9bf913c9da173e4c0b64bb8b7 (diff)
downloadxen-96428d33d9b6f28ce02902eae1a480b1d8f0e713.tar.gz
xen-96428d33d9b6f28ce02902eae1a480b1d8f0e713.tar.bz2
xen-96428d33d9b6f28ce02902eae1a480b1d8f0e713.zip
Define explicit evtchn_port_t type (32 bits) and plumb up
to user space thru /dev/xen/evtchn. Signed-off-by: Keir Fraser <keir@xensource.com>
Diffstat (limited to 'tools/xenstore/xenstored_domain.c')
-rw-r--r--tools/xenstore/xenstored_domain.c13
1 files changed, 7 insertions, 6 deletions
diff --git a/tools/xenstore/xenstored_domain.c b/tools/xenstore/xenstored_domain.c
index d252469617..47683558e4 100644
--- a/tools/xenstore/xenstored_domain.c
+++ b/tools/xenstore/xenstored_domain.c
@@ -41,7 +41,7 @@
#include <xen/linux/evtchn.h>
static int *xc_handle;
-static int virq_port;
+static evtchn_port_t virq_port;
int eventchn_fd = -1;
@@ -53,11 +53,11 @@ struct domain
unsigned int domid;
/* Event channel port */
- uint16_t port;
+ evtchn_port_t port;
/* The remote end of the event channel, used only to validate
repeated domain introductions. */
- uint16_t remote_port;
+ evtchn_port_t remote_port;
/* The mfn associated with the event channel, used only to validate
repeated domain introductions. */
@@ -224,7 +224,7 @@ static void domain_cleanup(void)
/* We scan all domains rather than use the information given here. */
void handle_event(void)
{
- uint16_t port;
+ evtchn_port_t port;
if (read(eventchn_fd, &port, sizeof(port)) != sizeof(port))
barf_perror("Failed to read from event fd");
@@ -314,7 +314,7 @@ void do_introduce(struct connection *conn, struct buffered_data *in)
char *vec[3];
unsigned int domid;
unsigned long mfn;
- uint16_t port;
+ evtchn_port_t port;
if (get_strings(in, vec, ARRAY_SIZE(vec)) < ARRAY_SIZE(vec)) {
send_error(conn, EINVAL);
@@ -460,7 +460,8 @@ void restore_existing_connections(void)
static int dom0_init(void)
{
- int rc, fd, port;
+ int rc, fd;
+ evtchn_port_t port;
unsigned long mfn;
char str[20];
struct domain *dom0;