aboutsummaryrefslogtreecommitdiffstats
path: root/tools/libxc/xc_netbsd.c
diff options
context:
space:
mode:
authorKeir Fraser <keir.fraser@citrix.com>2008-06-10 13:49:02 +0100
committerKeir Fraser <keir.fraser@citrix.com>2008-06-10 13:49:02 +0100
commitdeb36502454d30eff815e09a0ade1c732366ff4c (patch)
tree8f36f6b491b8e3f91e2fdb4a15a79bb0c086b1e6 /tools/libxc/xc_netbsd.c
parentc30c55b1bc1a586494b1dbd010ccad1ae43548a6 (diff)
downloadxen-deb36502454d30eff815e09a0ade1c732366ff4c.tar.gz
xen-deb36502454d30eff815e09a0ade1c732366ff4c.tar.bz2
xen-deb36502454d30eff815e09a0ade1c732366ff4c.zip
libxc: Update for NetBSD
returns hypercall return value when ioctl was successful. Signed-off-by: Christoph Egger <Christoph.Egger@amd.com>
Diffstat (limited to 'tools/libxc/xc_netbsd.c')
-rw-r--r--tools/libxc/xc_netbsd.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/tools/libxc/xc_netbsd.c b/tools/libxc/xc_netbsd.c
index 81c86d1064..036f64879c 100644
--- a/tools/libxc/xc_netbsd.c
+++ b/tools/libxc/xc_netbsd.c
@@ -142,9 +142,13 @@ static int do_privcmd(int xc_handle, unsigned int cmd, unsigned long data)
int do_xen_hypercall(int xc_handle, privcmd_hypercall_t *hypercall)
{
- return do_privcmd(xc_handle,
+ int error = do_privcmd(xc_handle,
IOCTL_PRIVCMD_HYPERCALL,
(unsigned long)hypercall);
+ if (error)
+ return error;
+ else
+ return (hypercall->retval);
}
#define EVTCHN_DEV_NAME "/dev/xenevt"