[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-changelog] [xen master] public/xen.h: add a definition for a 'valid domid' mask

commit 69ad573c2bbbce84d09bce988e7adc3cdafccc06
Author:     Paul Durrant <pdurrant@xxxxxxxxxx>
AuthorDate: Wed Feb 19 08:53:31 2020 +0000
Commit:     Paul Durrant <pdurrant@xxxxxxxxxx>
CommitDate: Mon Feb 24 17:17:35 2020 +0000

    public/xen.h: add a definition for a 'valid domid' mask
    A subsequent patch will modify libxl to allow selection of a random domid
    value when creating domains. Valid values are limited to a width of 15 bits,
    so add an appropriate mask definition to the public header.
    NOTE: It is reasonable for this mask definition to be in a Xen public header
          rather than in, say, a libxenctrl header since it relates to the
          validity of a value passed to XEN_DOMCTL_createdomain. This new
          definition is placed in xen.h rather than domctl.h only to co-locate
          it with other domid-related defitions.
    Signed-off-by: Paul Durrant <pdurrant@xxxxxxxxxx>
    Reviewed-by: Ian Jackson <ian.jackson@xxxxxxxxxxxxx>
    Acked-by: Julien Grall <julien@xxxxxxx>
 xen/include/public/xen.h | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/xen/include/public/xen.h b/xen/include/public/xen.h
index d2198dffad..75b1619d0d 100644
--- a/xen/include/public/xen.h
+++ b/xen/include/public/xen.h
@@ -614,6 +614,9 @@ DEFINE_XEN_GUEST_HANDLE(mmuext_op_t);
 /* Idle domain. */
 #define DOMID_IDLE           xen_mk_uint(0x7FFF)
+/* Mask for valid domain id values */
+#define DOMID_MASK           xen_mk_uint(0x7FFF)
 #ifndef __ASSEMBLY__
 typedef uint16_t domid_t;
generated by git-patchbot for /home/xen/git/xen.git#master

Xen-changelog mailing list



Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.