]> xenbits.xensource.com Git - people/pauldu/xen.git/commitdiff
libxl: add a 'disable_fifo_evtchn' flag to libxl_domain_build_info ...
authorPaul Durrant <pdurrant@amazon.com>
Tue, 24 Nov 2020 15:18:41 +0000 (15:18 +0000)
committerPaul Durrant <pdurrant@amazon.com>
Tue, 24 Nov 2020 18:00:59 +0000 (18:00 +0000)
...to control setting the domain create flag XEN_DOMCTL_CDF_disable_fifo.

Signed-off-by: Paul Durrant <pdurrant@amazon.com>
Signed-off-by: Eslam Elnikety <elnikety@amazon.com>
---
Cc: Ian Jackson <iwj@xenproject.org>
Cc: Wei Liu <wl@xen.org>
Cc: Anthony PERARD <anthony.perard@citrix.com>
v4:
 - New in v4

tools/include/libxl.h
tools/libs/light/libxl_create.c
tools/libs/light/libxl_types.idl

index 1ea5b4f446e8f3447a9f223caed6b92b10d0cdb4..fe0aad632c081a03270fbd477e6ce0ec561d8047 100644 (file)
  */
 #define LIBXL_HAVE_DISK_SAFE_REMOVE 1
 
+/*
+ * LIBXL_HAVE_BUILDINFO_DISABLE_EVTCHN_FIFO indicates that
+ * libxl_domain_build_info has a disable_evtchn_fifo (boolean) field
+ * to determine whether the EVTCHNOPs to initialize and manipulate FIFO
+ * event channels are exposed to the guest.
+ */
+#define LIBXL_HAVE_BUILDINFO_DISABLE_EVTCHN_FIFO 1
+
 /*
  * libxl ABI compatibility
  *
index 321a13e519b5b71fb684bd6d196d5cd684c72c67..abbbd91442c00b70214a873275cea2fd681d35fb 100644 (file)
@@ -263,6 +263,8 @@ int libxl__domain_build_info_setdefault(libxl__gc *gc,
     if (!b_info->event_channels)
         b_info->event_channels = 1023;
 
+    libxl_defbool_setdefault(&b_info->disable_evtchn_fifo, false);
+
     libxl__arch_domain_build_info_setdefault(gc, b_info);
     libxl_defbool_setdefault(&b_info->dm_restrict, false);
 
@@ -609,6 +611,9 @@ int libxl__domain_make(libxl__gc *gc, libxl_domain_config *d_config,
             .max_maptrack_frames = b_info->max_maptrack_frames,
         };
 
+        if (libxl_defbool_val(b_info->disable_evtchn_fifo))
+            create.flags |= XEN_DOMCTL_CDF_disable_fifo;
+
         if (info->type != LIBXL_DOMAIN_TYPE_PV) {
             create.flags |= XEN_DOMCTL_CDF_hvm;
 
index 9d3f05f3997829b1e637f5d610b26a8276e948c1..fa3f6ec3425ea815dfbe26ca986b1ae4d32de1f2 100644 (file)
@@ -541,6 +541,7 @@ libxl_domain_build_info = Struct("domain_build_info",[
     ("iomem",            Array(libxl_iomem_range, "num_iomem")),
     ("claim_mode",          libxl_defbool),
     ("event_channels",   uint32),
+    ("disable_evtchn_fifo",libxl_defbool),
     ("kernel",           string),
     ("cmdline",          string),
     ("ramdisk",          string),