aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorIan Jackson <ian.jackson@eu.citrix.com>2011-01-27 14:59:04 +0000
committerIan Jackson <ian.jackson@eu.citrix.com>2011-01-27 14:59:04 +0000
commit3bbbb0c96c03814cb208f6bf9167c95a94f0bbcb (patch)
tree021b69f9078e477e0fcf32586c8583f1baf06546
parent92585dd6a9557b7d4842260cdb2d2a4da0d5f854 (diff)
downloadxen-3bbbb0c96c03814cb208f6bf9167c95a94f0bbcb.tar.gz
xen-3bbbb0c96c03814cb208f6bf9167c95a94f0bbcb.tar.bz2
xen-3bbbb0c96c03814cb208f6bf9167c95a94f0bbcb.zip
libxc: provide XENCTRL_HAS_XC_INTERFACE feature test macro
This makes it easier for out-of-tree callers to tell which version of the libxc interface this version of xenctrl.h provides. Signed-off-by: Ian Jackson <ian.jackson@eu.citrix.com> Acked-by: Ian Campbell <Ian.Campbell@eu.citrix.com> Committed-by: Ian Jackson <ian.jackson@eu.citrix.com>
-rw-r--r--tools/libxc/xenctrl.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/tools/libxc/xenctrl.h b/tools/libxc/xenctrl.h
index 00c6f4425e..971daf02bc 100644
--- a/tools/libxc/xenctrl.h
+++ b/tools/libxc/xenctrl.h
@@ -88,6 +88,16 @@
#endif
+#define XENCTRL_HAS_XC_INTERFACE 1
+/* In Xen 4.0 and earlier, xc_interface_open and xc_evtchn_open would
+ * both return ints being the file descriptor. In 4.1 and later, they
+ * return an xc_interface* and xc_evtchn*, respectively - ie, a
+ * pointer to an opaque struct. This #define is provided in 4.1 and
+ * later, allowing out-of-tree callers to more easily distinguish
+ * between, and be compatible with, both versions.
+ */
+
+
/*
* GENERAL
*