1 /* AUTOMATICALLY GENERATED, DO NOT MODIFY */
2 
3 /*
4  * schema-defined QAPI types
5  *
6  * Copyright IBM, Corp. 2011
7  *
8  * Authors:
9  *  Anthony Liguori   <aliguori@us.ibm.com>
10  *
11  * This work is licensed under the terms of the GNU LGPL, version 2.1 or later.
12  * See the COPYING.LIB file in the top-level directory.
13  *
14  */
15 
16 #ifndef QAPI_TYPES_H
17 #define QAPI_TYPES_H
18 
19 #include "unicorn/platform.h"
20 
21 
22 #ifndef QAPI_TYPES_BUILTIN_STRUCT_DECL_H
23 #define QAPI_TYPES_BUILTIN_STRUCT_DECL_H
24 
25 
26 typedef struct strList
27 {
28     union {
29         char *value;
30         uint64_t padding;
31     };
32     struct strList *next;
33 } strList;
34 
35 typedef struct intList
36 {
37     union {
38         int64_t value;
39         uint64_t padding;
40     };
41     struct intList *next;
42 } intList;
43 
44 typedef struct numberList
45 {
46     union {
47         double value;
48         uint64_t padding;
49     };
50     struct numberList *next;
51 } numberList;
52 
53 typedef struct boolList
54 {
55     union {
56         bool value;
57         uint64_t padding;
58     };
59     struct boolList *next;
60 } boolList;
61 
62 typedef struct int8List
63 {
64     union {
65         int8_t value;
66         uint64_t padding;
67     };
68     struct int8List *next;
69 } int8List;
70 
71 typedef struct int16List
72 {
73     union {
74         int16_t value;
75         uint64_t padding;
76     };
77     struct int16List *next;
78 } int16List;
79 
80 typedef struct int32List
81 {
82     union {
83         int32_t value;
84         uint64_t padding;
85     };
86     struct int32List *next;
87 } int32List;
88 
89 typedef struct int64List
90 {
91     union {
92         int64_t value;
93         uint64_t padding;
94     };
95     struct int64List *next;
96 } int64List;
97 
98 typedef struct uint8List
99 {
100     union {
101         uint8_t value;
102         uint64_t padding;
103     };
104     struct uint8List *next;
105 } uint8List;
106 
107 typedef struct uint16List
108 {
109     union {
110         uint16_t value;
111         uint64_t padding;
112     };
113     struct uint16List *next;
114 } uint16List;
115 
116 typedef struct uint32List
117 {
118     union {
119         uint32_t value;
120         uint64_t padding;
121     };
122     struct uint32List *next;
123 } uint32List;
124 
125 typedef struct uint64List
126 {
127     union {
128         uint64_t value;
129         uint64_t padding;
130     };
131     struct uint64List *next;
132 } uint64List;
133 
134 #endif /* QAPI_TYPES_BUILTIN_STRUCT_DECL_H */
135 
136 
137 extern const char *ErrorClass_lookup[];
138 typedef enum ErrorClass
139 {
140     ERROR_CLASS_GENERIC_ERROR = 0,
141     ERROR_CLASS_COMMAND_NOT_FOUND = 1,
142     ERROR_CLASS_DEVICE_ENCRYPTED = 2,
143     ERROR_CLASS_DEVICE_NOT_ACTIVE = 3,
144     ERROR_CLASS_DEVICE_NOT_FOUND = 4,
145     ERROR_CLASS_KVM_MISSING_CAP = 5,
146     ERROR_CLASS_MAX = 6,
147 } ErrorClass;
148 
149 typedef struct ErrorClassList
150 {
151     union {
152         ErrorClass value;
153         uint64_t padding;
154     };
155     struct ErrorClassList *next;
156 } ErrorClassList;
157 
158 extern const char *X86CPURegister32_lookup[];
159 typedef enum X86CPURegister32
160 {
161     X86_CPU_REGISTER32_EAX = 0,
162     X86_CPU_REGISTER32_EBX = 1,
163     X86_CPU_REGISTER32_ECX = 2,
164     X86_CPU_REGISTER32_EDX = 3,
165     X86_CPU_REGISTER32_ESP = 4,
166     X86_CPU_REGISTER32_EBP = 5,
167     X86_CPU_REGISTER32_ESI = 6,
168     X86_CPU_REGISTER32_EDI = 7,
169     X86_CPU_REGISTER32_MAX = 8,
170 } X86CPURegister32;
171 
172 typedef struct X86CPURegister32List
173 {
174     union {
175         X86CPURegister32 value;
176         uint64_t padding;
177     };
178     struct X86CPURegister32List *next;
179 } X86CPURegister32List;
180 
181 
182 typedef struct X86CPUFeatureWordInfo X86CPUFeatureWordInfo;
183 
184 typedef struct X86CPUFeatureWordInfoList
185 {
186     union {
187         X86CPUFeatureWordInfo *value;
188         uint64_t padding;
189     };
190     struct X86CPUFeatureWordInfoList *next;
191 } X86CPUFeatureWordInfoList;
192 
193 #ifndef QAPI_TYPES_BUILTIN_CLEANUP_DECL_H
194 #define QAPI_TYPES_BUILTIN_CLEANUP_DECL_H
195 
196 void qapi_free_strList(strList *obj);
197 void qapi_free_intList(intList *obj);
198 void qapi_free_numberList(numberList *obj);
199 void qapi_free_boolList(boolList *obj);
200 void qapi_free_int8List(int8List *obj);
201 void qapi_free_int16List(int16List *obj);
202 void qapi_free_int32List(int32List *obj);
203 void qapi_free_int64List(int64List *obj);
204 void qapi_free_uint8List(uint8List *obj);
205 void qapi_free_uint16List(uint16List *obj);
206 void qapi_free_uint32List(uint32List *obj);
207 void qapi_free_uint64List(uint64List *obj);
208 
209 #endif /* QAPI_TYPES_BUILTIN_CLEANUP_DECL_H */
210 
211 
212 void qapi_free_ErrorClassList(ErrorClassList *obj);
213 
214 void qapi_free_X86CPURegister32List(X86CPURegister32List *obj);
215 
216 struct X86CPUFeatureWordInfo
217 {
218     int64_t cpuid_input_eax;
219     bool has_cpuid_input_ecx;
220     int64_t cpuid_input_ecx;
221     X86CPURegister32 cpuid_register;
222     int64_t features;
223 };
224 
225 void qapi_free_X86CPUFeatureWordInfoList(X86CPUFeatureWordInfoList *obj);
226 void qapi_free_X86CPUFeatureWordInfo(X86CPUFeatureWordInfo *obj);
227 
228 #endif
229