1 /******************************************************************************
2 * version.h
3 *
4 * Xen version, type, and compile information.
5 *
6 * Permission is hereby granted, free of charge, to any person obtaining a copy
7 * of this software and associated documentation files (the "Software"), to
8 * deal in the Software without restriction, including without limitation the
9 * rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
10 * sell copies of the Software, and to permit persons to whom the Software is
11 * furnished to do so, subject to the following conditions:
12 *
13 * The above copyright notice and this permission notice shall be included in
14 * all copies or substantial portions of the Software.
15 *
16 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
19 * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
20 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
21 * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
22 * DEALINGS IN THE SOFTWARE.
23 *
24 * Copyright (c) 2005, Nguyen Anh Quynh <aquynh@gmail.com>
25 * Copyright (c) 2005, Keir Fraser <keir@xensource.com>
26 */
27
28 #ifndef __XEN_PUBLIC_VERSION_H__
29 #define __XEN_PUBLIC_VERSION_H__
30
31 #include "xen.h"
32
33 /* NB. All ops return zero on success, except XENVER_{version,pagesize}
34 * XENVER_{version,pagesize,build_id} */
35
36 /* arg == NULL; returns major:minor (16:16). */
37 #define XENVER_version 0
38
39 /* arg == xen_extraversion_t. */
40 #define XENVER_extraversion 1
41 typedef char xen_extraversion_t[16];
42 #define XEN_EXTRAVERSION_LEN (sizeof(xen_extraversion_t))
43
44 /* arg == xen_compile_info_t. */
45 #define XENVER_compile_info 2
46 struct xen_compile_info {
47 char compiler[64];
48 char compile_by[16];
49 char compile_domain[32];
50 char compile_date[32];
51 };
52 typedef struct xen_compile_info xen_compile_info_t;
53
54 #define XENVER_capabilities 3
55 typedef char xen_capabilities_info_t[1024];
56 #define XEN_CAPABILITIES_INFO_LEN (sizeof(xen_capabilities_info_t))
57
58 #define XENVER_changeset 4
59 typedef char xen_changeset_info_t[64];
60 #define XEN_CHANGESET_INFO_LEN (sizeof(xen_changeset_info_t))
61
62 #define XENVER_platform_parameters 5
63 struct xen_platform_parameters {
64 xen_ulong_t virt_start;
65 };
66 typedef struct xen_platform_parameters xen_platform_parameters_t;
67
68 #define XENVER_get_features 6
69 struct xen_feature_info {
70 unsigned int submap_idx; /* IN: which 32-bit submap to return */
71 uint32_t submap; /* OUT: 32-bit submap */
72 };
73 typedef struct xen_feature_info xen_feature_info_t;
74
75 /* Declares the features reported by XENVER_get_features. */
76 #include "features.h"
77
78 /* arg == NULL; returns host memory page size. */
79 #define XENVER_pagesize 7
80
81 /* arg == xen_domain_handle_t.
82 *
83 * The toolstack fills it out for guest consumption. It is intended to hold
84 * the UUID of the guest.
85 */
86 #define XENVER_guest_handle 8
87
88 #define XENVER_commandline 9
89 typedef char xen_commandline_t[1024];
90
91 /*
92 * Return value is the number of bytes written, or XEN_Exx on error.
93 * Calling with empty parameter returns the size of build_id.
94 */
95 #define XENVER_build_id 10
96 struct xen_build_id {
97 uint32_t len; /* IN: size of buf[]. */
98 unsigned char buf[XEN_FLEX_ARRAY_DIM];
99 /* OUT: Variable length buffer with build_id. */
100 };
101 typedef struct xen_build_id xen_build_id_t;
102
103 #endif /* __XEN_PUBLIC_VERSION_H__ */
104
105 /*
106 * Local variables:
107 * mode: C
108 * c-file-style: "BSD"
109 * c-basic-offset: 4
110 * tab-width: 4
111 * indent-tabs-mode: nil
112 * End:
113 */
Cache object: d796c0e82254436e6d7f699b6463e8c3
|