1#[repr(C)]
8#[derive(Copy, Clone, Debug, Default, Eq, Hash, Ord, PartialEq, PartialOrd)]
9pub struct __BindgenBitfieldUnit<Storage> {
10 storage: Storage,
11}
12impl<Storage> __BindgenBitfieldUnit<Storage> {
13 #[inline]
14 pub const fn new(storage: Storage) -> Self {
15 Self { storage }
16 }
17}
18impl<Storage> __BindgenBitfieldUnit<Storage>
19where
20 Storage: AsRef<[u8]> + AsMut<[u8]>,
21{
22 #[inline]
23 pub fn get_bit(&self, index: usize) -> bool {
24 debug_assert!(index / 8 < self.storage.as_ref().len());
25 let byte_index = index / 8;
26 let byte = self.storage.as_ref()[byte_index];
27 let bit_index = if cfg!(target_endian = "big") {
28 7 - (index % 8)
29 } else {
30 index % 8
31 };
32 let mask = 1 << bit_index;
33 byte & mask == mask
34 }
35 #[inline]
36 pub fn set_bit(&mut self, index: usize, val: bool) {
37 debug_assert!(index / 8 < self.storage.as_ref().len());
38 let byte_index = index / 8;
39 let byte = &mut self.storage.as_mut()[byte_index];
40 let bit_index = if cfg!(target_endian = "big") {
41 7 - (index % 8)
42 } else {
43 index % 8
44 };
45 let mask = 1 << bit_index;
46 if val {
47 *byte |= mask;
48 } else {
49 *byte &= !mask;
50 }
51 }
52 #[inline]
53 pub fn get(&self, bit_offset: usize, bit_width: u8) -> u64 {
54 debug_assert!(bit_width <= 64);
55 debug_assert!(bit_offset / 8 < self.storage.as_ref().len());
56 debug_assert!((bit_offset + (bit_width as usize)) / 8 <= self.storage.as_ref().len());
57 let mut val = 0;
58 for i in 0..(bit_width as usize) {
59 if self.get_bit(i + bit_offset) {
60 let index = if cfg!(target_endian = "big") {
61 bit_width as usize - 1 - i
62 } else {
63 i
64 };
65 val |= 1 << index;
66 }
67 }
68 val
69 }
70 #[inline]
71 pub fn set(&mut self, bit_offset: usize, bit_width: u8, val: u64) {
72 debug_assert!(bit_width <= 64);
73 debug_assert!(bit_offset / 8 < self.storage.as_ref().len());
74 debug_assert!((bit_offset + (bit_width as usize)) / 8 <= self.storage.as_ref().len());
75 for i in 0..(bit_width as usize) {
76 let mask = 1 << i;
77 let val_bit_is_set = val & mask == mask;
78 let index = if cfg!(target_endian = "big") {
79 bit_width as usize - 1 - i
80 } else {
81 i
82 };
83 self.set_bit(index + bit_offset, val_bit_is_set);
84 }
85 }
86}
87#[repr(C)]
88#[derive(Default)]
89pub struct __IncompleteArrayField<T>(::std::marker::PhantomData<T>, [T; 0]);
90impl<T> __IncompleteArrayField<T> {
91 #[inline]
92 pub const fn new() -> Self {
93 __IncompleteArrayField(::std::marker::PhantomData, [])
94 }
95 #[inline]
96 pub fn as_ptr(&self) -> *const T {
97 self as *const _ as *const T
98 }
99 #[inline]
100 pub fn as_mut_ptr(&mut self) -> *mut T {
101 self as *mut _ as *mut T
102 }
103 #[inline]
104 pub unsafe fn as_slice(&self, len: usize) -> &[T] {
105 ::std::slice::from_raw_parts(self.as_ptr(), len)
106 }
107 #[inline]
108 pub unsafe fn as_mut_slice(&mut self, len: usize) -> &mut [T] {
109 ::std::slice::from_raw_parts_mut(self.as_mut_ptr(), len)
110 }
111}
112impl<T> ::std::fmt::Debug for __IncompleteArrayField<T> {
113 fn fmt(&self, fmt: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
114 fmt.write_str("__IncompleteArrayField")
115 }
116}
117pub const __BITS_PER_LONG: u32 = 64;
118pub const __FD_SETSIZE: u32 = 1024;
119pub const HVGDK_MINI_H_VERSION: u32 = 25294;
120pub const HV_STATUS_SUCCESS: u32 = 0;
121pub const HV_STATUS_INVALID_HYPERCALL_CODE: u32 = 2;
122pub const HV_STATUS_INVALID_HYPERCALL_INPUT: u32 = 3;
123pub const HV_STATUS_INVALID_ALIGNMENT: u32 = 4;
124pub const HV_STATUS_INVALID_PARAMETER: u32 = 5;
125pub const HV_STATUS_ACCESS_DENIED: u32 = 6;
126pub const HV_STATUS_INVALID_PARTITION_STATE: u32 = 7;
127pub const HV_STATUS_OPERATION_DENIED: u32 = 8;
128pub const HV_STATUS_UNKNOWN_PROPERTY: u32 = 9;
129pub const HV_STATUS_PROPERTY_VALUE_OUT_OF_RANGE: u32 = 10;
130pub const HV_STATUS_INSUFFICIENT_MEMORY: u32 = 11;
131pub const HV_STATUS_INVALID_PARTITION_ID: u32 = 13;
132pub const HV_STATUS_INVALID_VP_INDEX: u32 = 14;
133pub const HV_STATUS_NOT_FOUND: u32 = 16;
134pub const HV_STATUS_INVALID_PORT_ID: u32 = 17;
135pub const HV_STATUS_INVALID_CONNECTION_ID: u32 = 18;
136pub const HV_STATUS_INSUFFICIENT_BUFFERS: u32 = 19;
137pub const HV_STATUS_NOT_ACKNOWLEDGED: u32 = 20;
138pub const HV_STATUS_INVALID_VP_STATE: u32 = 21;
139pub const HV_STATUS_NO_RESOURCES: u32 = 29;
140pub const HV_STATUS_PROCESSOR_FEATURE_NOT_SUPPORTED: u32 = 32;
141pub const HV_STATUS_INVALID_LP_INDEX: u32 = 65;
142pub const HV_STATUS_INVALID_REGISTER_VALUE: u32 = 80;
143pub const HV_STATUS_OPERATION_FAILED: u32 = 113;
144pub const HV_STATUS_TIME_OUT: u32 = 120;
145pub const HV_STATUS_CALL_PENDING: u32 = 121;
146pub const HV_STATUS_VTL_ALREADY_ENABLED: u32 = 134;
147pub const HV_HYP_PAGE_SHIFT: u32 = 12;
148pub const HV_HYP_PAGE_SIZE: u32 = 4096;
149pub const HV_HYP_PAGE_MASK: i32 = -4096;
150pub const HV_HYP_LARGE_PAGE_SHIFT: u32 = 21;
151pub const HV_X64_MSR_GUEST_OS_ID: u32 = 1073741824;
152pub const HV_X64_MSR_HYPERCALL: u32 = 1073741825;
153pub const HV_X64_MSR_VP_INDEX: u32 = 1073741826;
154pub const HV_X64_MSR_RESET: u32 = 1073741827;
155pub const HV_X64_MSR_VP_RUNTIME: u32 = 1073741840;
156pub const HV_X64_MSR_TIME_REF_COUNT: u32 = 1073741856;
157pub const HV_X64_MSR_REFERENCE_TSC: u32 = 1073741857;
158pub const HV_X64_MSR_TSC_FREQUENCY: u32 = 1073741858;
159pub const HV_X64_MSR_APIC_FREQUENCY: u32 = 1073741859;
160pub const HV_X64_MSR_EOI: u32 = 1073741936;
161pub const HV_X64_MSR_ICR: u32 = 1073741937;
162pub const HV_X64_MSR_TPR: u32 = 1073741938;
163pub const HV_X64_MSR_VP_ASSIST_PAGE: u32 = 1073741939;
164pub const HV_X64_MSR_VP_ASSIST_PAGE_ENABLE: u32 = 1;
165pub const HV_X64_MSR_VP_ASSIST_PAGE_ADDRESS_SHIFT: u32 = 12;
166pub const HV_X64_MSR_VP_ASSIST_PAGE_ADDRESS_MASK: i32 = -4096;
167pub const HV_X64_MSR_SCONTROL: u32 = 1073741952;
168pub const HV_X64_MSR_SVERSION: u32 = 1073741953;
169pub const HV_X64_MSR_SIEFP: u32 = 1073741954;
170pub const HV_X64_MSR_SIMP: u32 = 1073741955;
171pub const HV_X64_MSR_EOM: u32 = 1073741956;
172pub const HV_X64_MSR_SIRBP: u32 = 1073741957;
173pub const HV_X64_MSR_SINT0: u32 = 1073741968;
174pub const HV_X64_MSR_SINT1: u32 = 1073741969;
175pub const HV_X64_MSR_SINT2: u32 = 1073741970;
176pub const HV_X64_MSR_SINT3: u32 = 1073741971;
177pub const HV_X64_MSR_SINT4: u32 = 1073741972;
178pub const HV_X64_MSR_SINT5: u32 = 1073741973;
179pub const HV_X64_MSR_SINT6: u32 = 1073741974;
180pub const HV_X64_MSR_SINT7: u32 = 1073741975;
181pub const HV_X64_MSR_SINT8: u32 = 1073741976;
182pub const HV_X64_MSR_SINT9: u32 = 1073741977;
183pub const HV_X64_MSR_SINT10: u32 = 1073741978;
184pub const HV_X64_MSR_SINT11: u32 = 1073741979;
185pub const HV_X64_MSR_SINT12: u32 = 1073741980;
186pub const HV_X64_MSR_SINT13: u32 = 1073741981;
187pub const HV_X64_MSR_SINT14: u32 = 1073741982;
188pub const HV_X64_MSR_SINT15: u32 = 1073741983;
189pub const HV_X64_MSR_NESTED_SCONTROL: u32 = 1073746048;
190pub const HV_X64_MSR_NESTED_SVERSION: u32 = 1073746049;
191pub const HV_X64_MSR_NESTED_SIEFP: u32 = 1073746050;
192pub const HV_X64_MSR_NESTED_SIMP: u32 = 1073746051;
193pub const HV_X64_MSR_NESTED_EOM: u32 = 1073746052;
194pub const HV_X64_MSR_NESTED_SINT0: u32 = 1073746064;
195pub const HV_X64_MSR_STIMER0_CONFIG: u32 = 1073742000;
196pub const HV_X64_MSR_STIMER0_COUNT: u32 = 1073742001;
197pub const HV_X64_MSR_STIMER1_CONFIG: u32 = 1073742002;
198pub const HV_X64_MSR_STIMER1_COUNT: u32 = 1073742003;
199pub const HV_X64_MSR_STIMER2_CONFIG: u32 = 1073742004;
200pub const HV_X64_MSR_STIMER2_COUNT: u32 = 1073742005;
201pub const HV_X64_MSR_STIMER3_CONFIG: u32 = 1073742006;
202pub const HV_X64_MSR_STIMER3_COUNT: u32 = 1073742007;
203pub const HV_X64_MSR_GUEST_IDLE: u32 = 1073742064;
204pub const HV_X64_MSR_CRASH_P0: u32 = 1073742080;
205pub const HV_X64_MSR_CRASH_P1: u32 = 1073742081;
206pub const HV_X64_MSR_CRASH_P2: u32 = 1073742082;
207pub const HV_X64_MSR_CRASH_P3: u32 = 1073742083;
208pub const HV_X64_MSR_CRASH_P4: u32 = 1073742084;
209pub const HV_X64_MSR_CRASH_CTL: u32 = 1073742085;
210pub const HV_MAXIMUM_PROCESSORS: u32 = 2048;
211pub const HV_MAX_VP_INDEX: u32 = 2047;
212pub const HVCALL_GET_PARTITION_PROPERTY: u32 = 68;
213pub const HVCALL_SET_PARTITION_PROPERTY: u32 = 69;
214pub const HVCALL_INSTALL_INTERCEPT: u32 = 77;
215pub const HVCALL_CREATE_VP: u32 = 78;
216pub const HVCALL_DELETE_VP: u32 = 79;
217pub const HVCALL_GET_VP_REGISTERS: u32 = 80;
218pub const HVCALL_SET_VP_REGISTERS: u32 = 81;
219pub const HVCALL_TRANSLATE_VIRTUAL_ADDRESS: u32 = 82;
220pub const HVCALL_READ_GPA: u32 = 83;
221pub const HVCALL_WRITE_GPA: u32 = 84;
222pub const HVCALL_CLEAR_VIRTUAL_INTERRUPT: u32 = 86;
223pub const HVCALL_REGISTER_INTERCEPT_RESULT: u32 = 145;
224pub const HVCALL_ASSERT_VIRTUAL_INTERRUPT: u32 = 148;
225pub const HVCALL_SIGNAL_EVENT_DIRECT: u32 = 192;
226pub const HVCALL_POST_MESSAGE_DIRECT: u32 = 193;
227pub const HVCALL_IMPORT_ISOLATED_PAGES: u32 = 239;
228pub const HVCALL_COMPLETE_ISOLATED_IMPORT: u32 = 241;
229pub const HVCALL_ISSUE_SNP_PSP_GUEST_REQUEST: u32 = 242;
230pub const HVCALL_GET_VP_CPUID_VALUES: u32 = 244;
231pub const HV_INTERRUPT_VECTOR_NONE: u32 = 4294967295;
232pub const HV_SYNIC_STIMER_COUNT: u32 = 4;
233pub const HV_MESSAGE_SIZE: u32 = 256;
234pub const HV_MESSAGE_PAYLOAD_BYTE_COUNT: u32 = 240;
235pub const HV_MESSAGE_PAYLOAD_QWORD_COUNT: u32 = 30;
236pub const HV_INTERCEPT_ACCESS_MASK_NONE: u32 = 0;
237pub const HV_INTERCEPT_ACCESS_MASK_READ: u32 = 1;
238pub const HV_INTERCEPT_ACCESS_MASK_WRITE: u32 = 2;
239pub const HV_INTERCEPT_ACCESS_MASK_EXECUTE: u32 = 4;
240pub const HV_INTERCEPT_ACCESS_READ: u32 = 0;
241pub const HV_INTERCEPT_ACCESS_WRITE: u32 = 1;
242pub const HV_INTERCEPT_ACCESS_EXECUTE: u32 = 2;
243pub const HVGDK_H_VERSION: u32 = 25125;
244pub const HVHVK_MINI_VERSION: u32 = 25294;
245pub const HV_GENERIC_SET_SHIFT: u32 = 6;
246pub const HV_GENERIC_SET_MASK: u32 = 63;
247pub const HV_MAP_GPA_PERMISSIONS_NONE: u32 = 0;
248pub const HV_MAP_GPA_READABLE: u32 = 1;
249pub const HV_MAP_GPA_WRITABLE: u32 = 2;
250pub const HV_MAP_GPA_KERNEL_EXECUTABLE: u32 = 4;
251pub const HV_MAP_GPA_USER_EXECUTABLE: u32 = 8;
252pub const HV_MAP_GPA_EXECUTABLE: u32 = 12;
253pub const HV_MAP_GPA_PERMISSIONS_MASK: u32 = 15;
254pub const HV_MAP_GPA_ADJUSTABLE: u32 = 32768;
255pub const HV_MAP_GPA_NO_ACCESS: u32 = 65536;
256pub const HV_MAP_GPA_NOT_CACHED: u32 = 2097152;
257pub const HV_MAP_GPA_LARGE_PAGE: u32 = 2147483648;
258pub const HV_PFN_RNG_PAGEBITS: u32 = 24;
259pub const HVHDK_H_VERSION: u32 = 25212;
260pub const HV_X64_REGISTER_CLASS_GENERAL: u32 = 0;
261pub const HV_X64_REGISTER_CLASS_IP: u32 = 1;
262pub const HV_X64_REGISTER_CLASS_XMM: u32 = 2;
263pub const HV_X64_REGISTER_CLASS_SEGMENT: u32 = 3;
264pub const HV_X64_REGISTER_CLASS_FLAGS: u32 = 4;
265pub const HV_VP_REGISTER_PAGE_VERSION_1: u32 = 1;
266pub const HV_VP_REGISTER_PAGE_MAX_VECTOR_COUNT: u32 = 7;
267pub const HV_PARTITION_SYNTHETIC_PROCESSOR_FEATURES_BANKS: u32 = 1;
268pub const HV_TRANSLATE_GVA_VALIDATE_READ: u32 = 1;
269pub const HV_TRANSLATE_GVA_VALIDATE_WRITE: u32 = 2;
270pub const HV_TRANSLATE_GVA_VALIDATE_EXECUTE: u32 = 4;
271pub const HV_TRANSLATE_GVA_PRIVILEGE_EXEMPT: u32 = 8;
272pub const HV_TRANSLATE_GVA_SET_PAGE_TABLE_BITS: u32 = 16;
273pub const HV_TRANSLATE_GVA_TLB_FLUSH_INHIBIT: u32 = 32;
274pub const HV_TRANSLATE_GVA_SUPERVISOR_ACCESS: u32 = 64;
275pub const HV_TRANSLATE_GVA_USER_ACCESS: u32 = 128;
276pub const HV_TRANSLATE_GVA_ENFORCE_SMAP: u32 = 256;
277pub const HV_TRANSLATE_GVA_OVERRIDE_SMAP: u32 = 512;
278pub const HV_TRANSLATE_GVA_SHADOW_STACK: u32 = 1024;
279pub const HV_HYPERCALL_INTERCEPT_MAX_XMM_REGISTERS: u32 = 6;
280pub const HV_UNSUPPORTED_FEATURE_INTERCEPT: u32 = 1;
281pub const HV_UNSUPPORTED_FEATURE_TASK_SWITCH_TSS: u32 = 2;
282pub const HV_X64_PENDING_INTERRUPT: u32 = 0;
283pub const HV_X64_PENDING_NMI: u32 = 2;
284pub const HV_X64_PENDING_EXCEPTION: u32 = 3;
285pub const HV_GPA_ATTRIBUTE_INTERCEPT_MAX_RANGES: u32 = 29;
286pub const HV_PSP_CPUID_LEAF_COUNT_MAX: u32 = 64;
287pub const HV_READ_WRITE_GPA_MAX_SIZE: u32 = 16;
288pub const MSHV_IOCTL: u32 = 184;
289pub const MSHV_VP_MAX_REGISTERS: u32 = 128;
290pub const MSHV_RUN_VP_BUF_SZ: u32 = 256;
291pub const MSHV_CREATE_DEVICE_TEST: u32 = 1;
292pub const MSHV_DEV_VFIO_FILE: u32 = 1;
293pub const MSHV_DEV_VFIO_FILE_ADD: u32 = 1;
294pub const MSHV_DEV_VFIO_FILE_DEL: u32 = 2;
295pub const MSHV_DIAG_IOCTL: u32 = 185;
296pub const MSHV_TRACE_IOCTL: u32 = 186;
297pub type bool_ = bool;
298pub type __s8 = ::std::os::raw::c_schar;
299pub type __u8 = ::std::os::raw::c_uchar;
300pub type __s16 = ::std::os::raw::c_short;
301pub type __u16 = ::std::os::raw::c_ushort;
302pub type __s32 = ::std::os::raw::c_int;
303pub type __u32 = ::std::os::raw::c_uint;
304pub type __s64 = ::std::os::raw::c_longlong;
305pub type __u64 = ::std::os::raw::c_ulonglong;
306#[repr(C)]
307#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
308pub struct __kernel_fd_set {
309 pub fds_bits: [::std::os::raw::c_ulong; 16usize],
310}
311#[test]
312fn bindgen_test_layout___kernel_fd_set() {
313 const UNINIT: ::std::mem::MaybeUninit<__kernel_fd_set> = ::std::mem::MaybeUninit::uninit();
314 let ptr = UNINIT.as_ptr();
315 assert_eq!(
316 ::std::mem::size_of::<__kernel_fd_set>(),
317 128usize,
318 concat!("Size of: ", stringify!(__kernel_fd_set))
319 );
320 assert_eq!(
321 ::std::mem::align_of::<__kernel_fd_set>(),
322 8usize,
323 concat!("Alignment of ", stringify!(__kernel_fd_set))
324 );
325 assert_eq!(
326 unsafe { ::std::ptr::addr_of!((*ptr).fds_bits) as usize - ptr as usize },
327 0usize,
328 concat!(
329 "Offset of field: ",
330 stringify!(__kernel_fd_set),
331 "::",
332 stringify!(fds_bits)
333 )
334 );
335}
336pub type __kernel_sighandler_t =
337 ::std::option::Option<unsafe extern "C" fn(arg1: ::std::os::raw::c_int)>;
338pub type __kernel_key_t = ::std::os::raw::c_int;
339pub type __kernel_mqd_t = ::std::os::raw::c_int;
340pub type __kernel_old_uid_t = ::std::os::raw::c_ushort;
341pub type __kernel_old_gid_t = ::std::os::raw::c_ushort;
342pub type __kernel_old_dev_t = ::std::os::raw::c_ulong;
343pub type __kernel_long_t = ::std::os::raw::c_long;
344pub type __kernel_ulong_t = ::std::os::raw::c_ulong;
345pub type __kernel_ino_t = __kernel_ulong_t;
346pub type __kernel_mode_t = ::std::os::raw::c_uint;
347pub type __kernel_pid_t = ::std::os::raw::c_int;
348pub type __kernel_ipc_pid_t = ::std::os::raw::c_int;
349pub type __kernel_uid_t = ::std::os::raw::c_uint;
350pub type __kernel_gid_t = ::std::os::raw::c_uint;
351pub type __kernel_suseconds_t = __kernel_long_t;
352pub type __kernel_daddr_t = ::std::os::raw::c_int;
353pub type __kernel_uid32_t = ::std::os::raw::c_uint;
354pub type __kernel_gid32_t = ::std::os::raw::c_uint;
355pub type __kernel_size_t = __kernel_ulong_t;
356pub type __kernel_ssize_t = __kernel_long_t;
357pub type __kernel_ptrdiff_t = __kernel_long_t;
358#[repr(C)]
359#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
360pub struct __kernel_fsid_t {
361 pub val: [::std::os::raw::c_int; 2usize],
362}
363#[test]
364fn bindgen_test_layout___kernel_fsid_t() {
365 const UNINIT: ::std::mem::MaybeUninit<__kernel_fsid_t> = ::std::mem::MaybeUninit::uninit();
366 let ptr = UNINIT.as_ptr();
367 assert_eq!(
368 ::std::mem::size_of::<__kernel_fsid_t>(),
369 8usize,
370 concat!("Size of: ", stringify!(__kernel_fsid_t))
371 );
372 assert_eq!(
373 ::std::mem::align_of::<__kernel_fsid_t>(),
374 4usize,
375 concat!("Alignment of ", stringify!(__kernel_fsid_t))
376 );
377 assert_eq!(
378 unsafe { ::std::ptr::addr_of!((*ptr).val) as usize - ptr as usize },
379 0usize,
380 concat!(
381 "Offset of field: ",
382 stringify!(__kernel_fsid_t),
383 "::",
384 stringify!(val)
385 )
386 );
387}
388pub type __kernel_off_t = __kernel_long_t;
389pub type __kernel_loff_t = ::std::os::raw::c_longlong;
390pub type __kernel_old_time_t = __kernel_long_t;
391pub type __kernel_time_t = __kernel_long_t;
392pub type __kernel_time64_t = ::std::os::raw::c_longlong;
393pub type __kernel_clock_t = __kernel_long_t;
394pub type __kernel_timer_t = ::std::os::raw::c_int;
395pub type __kernel_clockid_t = ::std::os::raw::c_int;
396pub type __kernel_caddr_t = *mut ::std::os::raw::c_char;
397pub type __kernel_uid16_t = ::std::os::raw::c_ushort;
398pub type __kernel_gid16_t = ::std::os::raw::c_ushort;
399pub type __s128 = i128;
400pub type __u128 = u128;
401pub type __le16 = __u16;
402pub type __be16 = __u16;
403pub type __le32 = __u32;
404pub type __be32 = __u32;
405pub type __le64 = __u64;
406pub type __be64 = __u64;
407pub type __sum16 = __u16;
408pub type __wsum = __u32;
409pub type __poll_t = ::std::os::raw::c_uint;
410pub type hv_nano100_time_t = __u64;
411#[repr(C, packed)]
412#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
413pub struct hv_u128 {
414 pub low_part: __u64,
415 pub high_part: __u64,
416}
417#[test]
418fn bindgen_test_layout_hv_u128() {
419 const UNINIT: ::std::mem::MaybeUninit<hv_u128> = ::std::mem::MaybeUninit::uninit();
420 let ptr = UNINIT.as_ptr();
421 assert_eq!(
422 ::std::mem::size_of::<hv_u128>(),
423 16usize,
424 concat!("Size of: ", stringify!(hv_u128))
425 );
426 assert_eq!(
427 ::std::mem::align_of::<hv_u128>(),
428 1usize,
429 concat!("Alignment of ", stringify!(hv_u128))
430 );
431 assert_eq!(
432 unsafe { ::std::ptr::addr_of!((*ptr).low_part) as usize - ptr as usize },
433 0usize,
434 concat!(
435 "Offset of field: ",
436 stringify!(hv_u128),
437 "::",
438 stringify!(low_part)
439 )
440 );
441 assert_eq!(
442 unsafe { ::std::ptr::addr_of!((*ptr).high_part) as usize - ptr as usize },
443 8usize,
444 concat!(
445 "Offset of field: ",
446 stringify!(hv_u128),
447 "::",
448 stringify!(high_part)
449 )
450 );
451}
452#[repr(C)]
453#[derive(Copy, Clone)]
454pub union hv_gpa_page_range {
455 pub address_space: __u64,
456 pub page: hv_gpa_page_range__bindgen_ty_1,
457 pub __bindgen_anon_1: hv_gpa_page_range__bindgen_ty_2,
458}
459#[repr(C)]
460#[repr(align(8))]
461#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
462pub struct hv_gpa_page_range__bindgen_ty_1 {
463 pub _bitfield_align_1: [u64; 0],
464 pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>,
465}
466#[test]
467fn bindgen_test_layout_hv_gpa_page_range__bindgen_ty_1() {
468 assert_eq!(
469 ::std::mem::size_of::<hv_gpa_page_range__bindgen_ty_1>(),
470 8usize,
471 concat!("Size of: ", stringify!(hv_gpa_page_range__bindgen_ty_1))
472 );
473 assert_eq!(
474 ::std::mem::align_of::<hv_gpa_page_range__bindgen_ty_1>(),
475 8usize,
476 concat!("Alignment of ", stringify!(hv_gpa_page_range__bindgen_ty_1))
477 );
478}
479impl hv_gpa_page_range__bindgen_ty_1 {
480 #[inline]
481 pub fn additional_pages(&self) -> __u64 {
482 unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 11u8) as u64) }
483 }
484 #[inline]
485 pub fn set_additional_pages(&mut self, val: __u64) {
486 unsafe {
487 let val: u64 = ::std::mem::transmute(val);
488 self._bitfield_1.set(0usize, 11u8, val as u64)
489 }
490 }
491 #[inline]
492 pub fn largepage(&self) -> __u64 {
493 unsafe { ::std::mem::transmute(self._bitfield_1.get(11usize, 1u8) as u64) }
494 }
495 #[inline]
496 pub fn set_largepage(&mut self, val: __u64) {
497 unsafe {
498 let val: u64 = ::std::mem::transmute(val);
499 self._bitfield_1.set(11usize, 1u8, val as u64)
500 }
501 }
502 #[inline]
503 pub fn basepfn(&self) -> __u64 {
504 unsafe { ::std::mem::transmute(self._bitfield_1.get(12usize, 52u8) as u64) }
505 }
506 #[inline]
507 pub fn set_basepfn(&mut self, val: __u64) {
508 unsafe {
509 let val: u64 = ::std::mem::transmute(val);
510 self._bitfield_1.set(12usize, 52u8, val as u64)
511 }
512 }
513 #[inline]
514 pub fn new_bitfield_1(
515 additional_pages: __u64,
516 largepage: __u64,
517 basepfn: __u64,
518 ) -> __BindgenBitfieldUnit<[u8; 8usize]> {
519 let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 8usize]> = Default::default();
520 __bindgen_bitfield_unit.set(0usize, 11u8, {
521 let additional_pages: u64 = unsafe { ::std::mem::transmute(additional_pages) };
522 additional_pages as u64
523 });
524 __bindgen_bitfield_unit.set(11usize, 1u8, {
525 let largepage: u64 = unsafe { ::std::mem::transmute(largepage) };
526 largepage as u64
527 });
528 __bindgen_bitfield_unit.set(12usize, 52u8, {
529 let basepfn: u64 = unsafe { ::std::mem::transmute(basepfn) };
530 basepfn as u64
531 });
532 __bindgen_bitfield_unit
533 }
534}
535#[repr(C)]
536#[repr(align(8))]
537#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
538pub struct hv_gpa_page_range__bindgen_ty_2 {
539 pub _bitfield_align_1: [u64; 0],
540 pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>,
541}
542#[test]
543fn bindgen_test_layout_hv_gpa_page_range__bindgen_ty_2() {
544 assert_eq!(
545 ::std::mem::size_of::<hv_gpa_page_range__bindgen_ty_2>(),
546 8usize,
547 concat!("Size of: ", stringify!(hv_gpa_page_range__bindgen_ty_2))
548 );
549 assert_eq!(
550 ::std::mem::align_of::<hv_gpa_page_range__bindgen_ty_2>(),
551 8usize,
552 concat!("Alignment of ", stringify!(hv_gpa_page_range__bindgen_ty_2))
553 );
554}
555impl hv_gpa_page_range__bindgen_ty_2 {
556 #[inline]
557 pub fn reserved(&self) -> __u64 {
558 unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 12u8) as u64) }
559 }
560 #[inline]
561 pub fn set_reserved(&mut self, val: __u64) {
562 unsafe {
563 let val: u64 = ::std::mem::transmute(val);
564 self._bitfield_1.set(0usize, 12u8, val as u64)
565 }
566 }
567 #[inline]
568 pub fn page_size(&self) -> __u64 {
569 unsafe { ::std::mem::transmute(self._bitfield_1.get(12usize, 1u8) as u64) }
570 }
571 #[inline]
572 pub fn set_page_size(&mut self, val: __u64) {
573 unsafe {
574 let val: u64 = ::std::mem::transmute(val);
575 self._bitfield_1.set(12usize, 1u8, val as u64)
576 }
577 }
578 #[inline]
579 pub fn reserved1(&self) -> __u64 {
580 unsafe { ::std::mem::transmute(self._bitfield_1.get(13usize, 8u8) as u64) }
581 }
582 #[inline]
583 pub fn set_reserved1(&mut self, val: __u64) {
584 unsafe {
585 let val: u64 = ::std::mem::transmute(val);
586 self._bitfield_1.set(13usize, 8u8, val as u64)
587 }
588 }
589 #[inline]
590 pub fn base_large_pfn(&self) -> __u64 {
591 unsafe { ::std::mem::transmute(self._bitfield_1.get(21usize, 43u8) as u64) }
592 }
593 #[inline]
594 pub fn set_base_large_pfn(&mut self, val: __u64) {
595 unsafe {
596 let val: u64 = ::std::mem::transmute(val);
597 self._bitfield_1.set(21usize, 43u8, val as u64)
598 }
599 }
600 #[inline]
601 pub fn new_bitfield_1(
602 reserved: __u64,
603 page_size: __u64,
604 reserved1: __u64,
605 base_large_pfn: __u64,
606 ) -> __BindgenBitfieldUnit<[u8; 8usize]> {
607 let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 8usize]> = Default::default();
608 __bindgen_bitfield_unit.set(0usize, 12u8, {
609 let reserved: u64 = unsafe { ::std::mem::transmute(reserved) };
610 reserved as u64
611 });
612 __bindgen_bitfield_unit.set(12usize, 1u8, {
613 let page_size: u64 = unsafe { ::std::mem::transmute(page_size) };
614 page_size as u64
615 });
616 __bindgen_bitfield_unit.set(13usize, 8u8, {
617 let reserved1: u64 = unsafe { ::std::mem::transmute(reserved1) };
618 reserved1 as u64
619 });
620 __bindgen_bitfield_unit.set(21usize, 43u8, {
621 let base_large_pfn: u64 = unsafe { ::std::mem::transmute(base_large_pfn) };
622 base_large_pfn as u64
623 });
624 __bindgen_bitfield_unit
625 }
626}
627#[test]
628fn bindgen_test_layout_hv_gpa_page_range() {
629 const UNINIT: ::std::mem::MaybeUninit<hv_gpa_page_range> = ::std::mem::MaybeUninit::uninit();
630 let ptr = UNINIT.as_ptr();
631 assert_eq!(
632 ::std::mem::size_of::<hv_gpa_page_range>(),
633 8usize,
634 concat!("Size of: ", stringify!(hv_gpa_page_range))
635 );
636 assert_eq!(
637 ::std::mem::align_of::<hv_gpa_page_range>(),
638 8usize,
639 concat!("Alignment of ", stringify!(hv_gpa_page_range))
640 );
641 assert_eq!(
642 unsafe { ::std::ptr::addr_of!((*ptr).address_space) as usize - ptr as usize },
643 0usize,
644 concat!(
645 "Offset of field: ",
646 stringify!(hv_gpa_page_range),
647 "::",
648 stringify!(address_space)
649 )
650 );
651 assert_eq!(
652 unsafe { ::std::ptr::addr_of!((*ptr).page) as usize - ptr as usize },
653 0usize,
654 concat!(
655 "Offset of field: ",
656 stringify!(hv_gpa_page_range),
657 "::",
658 stringify!(page)
659 )
660 );
661}
662impl Default for hv_gpa_page_range {
663 fn default() -> Self {
664 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
665 unsafe {
666 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
667 s.assume_init()
668 }
669 }
670}
671pub const hv_interrupt_type_HV_X64_INTERRUPT_TYPE_FIXED: hv_interrupt_type = 0;
672pub const hv_interrupt_type_HV_X64_INTERRUPT_TYPE_LOWESTPRIORITY: hv_interrupt_type = 1;
673pub const hv_interrupt_type_HV_X64_INTERRUPT_TYPE_SMI: hv_interrupt_type = 2;
674pub const hv_interrupt_type_HV_X64_INTERRUPT_TYPE_REMOTEREAD: hv_interrupt_type = 3;
675pub const hv_interrupt_type_HV_X64_INTERRUPT_TYPE_NMI: hv_interrupt_type = 4;
676pub const hv_interrupt_type_HV_X64_INTERRUPT_TYPE_INIT: hv_interrupt_type = 5;
677pub const hv_interrupt_type_HV_X64_INTERRUPT_TYPE_SIPI: hv_interrupt_type = 6;
678pub const hv_interrupt_type_HV_X64_INTERRUPT_TYPE_EXTINT: hv_interrupt_type = 7;
679pub const hv_interrupt_type_HV_X64_INTERRUPT_TYPE_LOCALINT0: hv_interrupt_type = 8;
680pub const hv_interrupt_type_HV_X64_INTERRUPT_TYPE_LOCALINT1: hv_interrupt_type = 9;
681pub const hv_interrupt_type_HV_X64_INTERRUPT_TYPE_MAXIMUM: hv_interrupt_type = 10;
682pub type hv_interrupt_type = ::std::os::raw::c_uint;
683#[repr(C)]
684#[derive(Copy, Clone)]
685pub union hv_x64_xsave_xfem_register {
686 pub as_uint64: __u64,
687 pub __bindgen_anon_1: hv_x64_xsave_xfem_register__bindgen_ty_1,
688 pub __bindgen_anon_2: hv_x64_xsave_xfem_register__bindgen_ty_2,
689}
690#[repr(C, packed)]
691#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
692pub struct hv_x64_xsave_xfem_register__bindgen_ty_1 {
693 pub low_uint32: __u32,
694 pub high_uint32: __u32,
695}
696#[test]
697fn bindgen_test_layout_hv_x64_xsave_xfem_register__bindgen_ty_1() {
698 const UNINIT: ::std::mem::MaybeUninit<hv_x64_xsave_xfem_register__bindgen_ty_1> =
699 ::std::mem::MaybeUninit::uninit();
700 let ptr = UNINIT.as_ptr();
701 assert_eq!(
702 ::std::mem::size_of::<hv_x64_xsave_xfem_register__bindgen_ty_1>(),
703 8usize,
704 concat!(
705 "Size of: ",
706 stringify!(hv_x64_xsave_xfem_register__bindgen_ty_1)
707 )
708 );
709 assert_eq!(
710 ::std::mem::align_of::<hv_x64_xsave_xfem_register__bindgen_ty_1>(),
711 1usize,
712 concat!(
713 "Alignment of ",
714 stringify!(hv_x64_xsave_xfem_register__bindgen_ty_1)
715 )
716 );
717 assert_eq!(
718 unsafe { ::std::ptr::addr_of!((*ptr).low_uint32) as usize - ptr as usize },
719 0usize,
720 concat!(
721 "Offset of field: ",
722 stringify!(hv_x64_xsave_xfem_register__bindgen_ty_1),
723 "::",
724 stringify!(low_uint32)
725 )
726 );
727 assert_eq!(
728 unsafe { ::std::ptr::addr_of!((*ptr).high_uint32) as usize - ptr as usize },
729 4usize,
730 concat!(
731 "Offset of field: ",
732 stringify!(hv_x64_xsave_xfem_register__bindgen_ty_1),
733 "::",
734 stringify!(high_uint32)
735 )
736 );
737}
738#[repr(C, packed)]
739#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
740pub struct hv_x64_xsave_xfem_register__bindgen_ty_2 {
741 pub _bitfield_align_1: [u8; 0],
742 pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>,
743}
744#[test]
745fn bindgen_test_layout_hv_x64_xsave_xfem_register__bindgen_ty_2() {
746 assert_eq!(
747 ::std::mem::size_of::<hv_x64_xsave_xfem_register__bindgen_ty_2>(),
748 8usize,
749 concat!(
750 "Size of: ",
751 stringify!(hv_x64_xsave_xfem_register__bindgen_ty_2)
752 )
753 );
754 assert_eq!(
755 ::std::mem::align_of::<hv_x64_xsave_xfem_register__bindgen_ty_2>(),
756 1usize,
757 concat!(
758 "Alignment of ",
759 stringify!(hv_x64_xsave_xfem_register__bindgen_ty_2)
760 )
761 );
762}
763impl hv_x64_xsave_xfem_register__bindgen_ty_2 {
764 #[inline]
765 pub fn legacy_x87(&self) -> __u64 {
766 unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 1u8) as u64) }
767 }
768 #[inline]
769 pub fn set_legacy_x87(&mut self, val: __u64) {
770 unsafe {
771 let val: u64 = ::std::mem::transmute(val);
772 self._bitfield_1.set(0usize, 1u8, val as u64)
773 }
774 }
775 #[inline]
776 pub fn legacy_sse(&self) -> __u64 {
777 unsafe { ::std::mem::transmute(self._bitfield_1.get(1usize, 1u8) as u64) }
778 }
779 #[inline]
780 pub fn set_legacy_sse(&mut self, val: __u64) {
781 unsafe {
782 let val: u64 = ::std::mem::transmute(val);
783 self._bitfield_1.set(1usize, 1u8, val as u64)
784 }
785 }
786 #[inline]
787 pub fn avx(&self) -> __u64 {
788 unsafe { ::std::mem::transmute(self._bitfield_1.get(2usize, 1u8) as u64) }
789 }
790 #[inline]
791 pub fn set_avx(&mut self, val: __u64) {
792 unsafe {
793 let val: u64 = ::std::mem::transmute(val);
794 self._bitfield_1.set(2usize, 1u8, val as u64)
795 }
796 }
797 #[inline]
798 pub fn mpx_bndreg(&self) -> __u64 {
799 unsafe { ::std::mem::transmute(self._bitfield_1.get(3usize, 1u8) as u64) }
800 }
801 #[inline]
802 pub fn set_mpx_bndreg(&mut self, val: __u64) {
803 unsafe {
804 let val: u64 = ::std::mem::transmute(val);
805 self._bitfield_1.set(3usize, 1u8, val as u64)
806 }
807 }
808 #[inline]
809 pub fn mpx_bndcsr(&self) -> __u64 {
810 unsafe { ::std::mem::transmute(self._bitfield_1.get(4usize, 1u8) as u64) }
811 }
812 #[inline]
813 pub fn set_mpx_bndcsr(&mut self, val: __u64) {
814 unsafe {
815 let val: u64 = ::std::mem::transmute(val);
816 self._bitfield_1.set(4usize, 1u8, val as u64)
817 }
818 }
819 #[inline]
820 pub fn avx_512_op_mask(&self) -> __u64 {
821 unsafe { ::std::mem::transmute(self._bitfield_1.get(5usize, 1u8) as u64) }
822 }
823 #[inline]
824 pub fn set_avx_512_op_mask(&mut self, val: __u64) {
825 unsafe {
826 let val: u64 = ::std::mem::transmute(val);
827 self._bitfield_1.set(5usize, 1u8, val as u64)
828 }
829 }
830 #[inline]
831 pub fn avx_512_zmmhi(&self) -> __u64 {
832 unsafe { ::std::mem::transmute(self._bitfield_1.get(6usize, 1u8) as u64) }
833 }
834 #[inline]
835 pub fn set_avx_512_zmmhi(&mut self, val: __u64) {
836 unsafe {
837 let val: u64 = ::std::mem::transmute(val);
838 self._bitfield_1.set(6usize, 1u8, val as u64)
839 }
840 }
841 #[inline]
842 pub fn avx_512_zmm16_31(&self) -> __u64 {
843 unsafe { ::std::mem::transmute(self._bitfield_1.get(7usize, 1u8) as u64) }
844 }
845 #[inline]
846 pub fn set_avx_512_zmm16_31(&mut self, val: __u64) {
847 unsafe {
848 let val: u64 = ::std::mem::transmute(val);
849 self._bitfield_1.set(7usize, 1u8, val as u64)
850 }
851 }
852 #[inline]
853 pub fn rsvd8_9(&self) -> __u64 {
854 unsafe { ::std::mem::transmute(self._bitfield_1.get(8usize, 2u8) as u64) }
855 }
856 #[inline]
857 pub fn set_rsvd8_9(&mut self, val: __u64) {
858 unsafe {
859 let val: u64 = ::std::mem::transmute(val);
860 self._bitfield_1.set(8usize, 2u8, val as u64)
861 }
862 }
863 #[inline]
864 pub fn pasid(&self) -> __u64 {
865 unsafe { ::std::mem::transmute(self._bitfield_1.get(10usize, 1u8) as u64) }
866 }
867 #[inline]
868 pub fn set_pasid(&mut self, val: __u64) {
869 unsafe {
870 let val: u64 = ::std::mem::transmute(val);
871 self._bitfield_1.set(10usize, 1u8, val as u64)
872 }
873 }
874 #[inline]
875 pub fn cet_u(&self) -> __u64 {
876 unsafe { ::std::mem::transmute(self._bitfield_1.get(11usize, 1u8) as u64) }
877 }
878 #[inline]
879 pub fn set_cet_u(&mut self, val: __u64) {
880 unsafe {
881 let val: u64 = ::std::mem::transmute(val);
882 self._bitfield_1.set(11usize, 1u8, val as u64)
883 }
884 }
885 #[inline]
886 pub fn cet_s(&self) -> __u64 {
887 unsafe { ::std::mem::transmute(self._bitfield_1.get(12usize, 1u8) as u64) }
888 }
889 #[inline]
890 pub fn set_cet_s(&mut self, val: __u64) {
891 unsafe {
892 let val: u64 = ::std::mem::transmute(val);
893 self._bitfield_1.set(12usize, 1u8, val as u64)
894 }
895 }
896 #[inline]
897 pub fn rsvd13_16(&self) -> __u64 {
898 unsafe { ::std::mem::transmute(self._bitfield_1.get(13usize, 4u8) as u64) }
899 }
900 #[inline]
901 pub fn set_rsvd13_16(&mut self, val: __u64) {
902 unsafe {
903 let val: u64 = ::std::mem::transmute(val);
904 self._bitfield_1.set(13usize, 4u8, val as u64)
905 }
906 }
907 #[inline]
908 pub fn xtile_cfg(&self) -> __u64 {
909 unsafe { ::std::mem::transmute(self._bitfield_1.get(17usize, 1u8) as u64) }
910 }
911 #[inline]
912 pub fn set_xtile_cfg(&mut self, val: __u64) {
913 unsafe {
914 let val: u64 = ::std::mem::transmute(val);
915 self._bitfield_1.set(17usize, 1u8, val as u64)
916 }
917 }
918 #[inline]
919 pub fn xtile_data(&self) -> __u64 {
920 unsafe { ::std::mem::transmute(self._bitfield_1.get(18usize, 1u8) as u64) }
921 }
922 #[inline]
923 pub fn set_xtile_data(&mut self, val: __u64) {
924 unsafe {
925 let val: u64 = ::std::mem::transmute(val);
926 self._bitfield_1.set(18usize, 1u8, val as u64)
927 }
928 }
929 #[inline]
930 pub fn rsvd19_63(&self) -> __u64 {
931 unsafe { ::std::mem::transmute(self._bitfield_1.get(19usize, 45u8) as u64) }
932 }
933 #[inline]
934 pub fn set_rsvd19_63(&mut self, val: __u64) {
935 unsafe {
936 let val: u64 = ::std::mem::transmute(val);
937 self._bitfield_1.set(19usize, 45u8, val as u64)
938 }
939 }
940 #[inline]
941 pub fn new_bitfield_1(
942 legacy_x87: __u64,
943 legacy_sse: __u64,
944 avx: __u64,
945 mpx_bndreg: __u64,
946 mpx_bndcsr: __u64,
947 avx_512_op_mask: __u64,
948 avx_512_zmmhi: __u64,
949 avx_512_zmm16_31: __u64,
950 rsvd8_9: __u64,
951 pasid: __u64,
952 cet_u: __u64,
953 cet_s: __u64,
954 rsvd13_16: __u64,
955 xtile_cfg: __u64,
956 xtile_data: __u64,
957 rsvd19_63: __u64,
958 ) -> __BindgenBitfieldUnit<[u8; 8usize]> {
959 let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 8usize]> = Default::default();
960 __bindgen_bitfield_unit.set(0usize, 1u8, {
961 let legacy_x87: u64 = unsafe { ::std::mem::transmute(legacy_x87) };
962 legacy_x87 as u64
963 });
964 __bindgen_bitfield_unit.set(1usize, 1u8, {
965 let legacy_sse: u64 = unsafe { ::std::mem::transmute(legacy_sse) };
966 legacy_sse as u64
967 });
968 __bindgen_bitfield_unit.set(2usize, 1u8, {
969 let avx: u64 = unsafe { ::std::mem::transmute(avx) };
970 avx as u64
971 });
972 __bindgen_bitfield_unit.set(3usize, 1u8, {
973 let mpx_bndreg: u64 = unsafe { ::std::mem::transmute(mpx_bndreg) };
974 mpx_bndreg as u64
975 });
976 __bindgen_bitfield_unit.set(4usize, 1u8, {
977 let mpx_bndcsr: u64 = unsafe { ::std::mem::transmute(mpx_bndcsr) };
978 mpx_bndcsr as u64
979 });
980 __bindgen_bitfield_unit.set(5usize, 1u8, {
981 let avx_512_op_mask: u64 = unsafe { ::std::mem::transmute(avx_512_op_mask) };
982 avx_512_op_mask as u64
983 });
984 __bindgen_bitfield_unit.set(6usize, 1u8, {
985 let avx_512_zmmhi: u64 = unsafe { ::std::mem::transmute(avx_512_zmmhi) };
986 avx_512_zmmhi as u64
987 });
988 __bindgen_bitfield_unit.set(7usize, 1u8, {
989 let avx_512_zmm16_31: u64 = unsafe { ::std::mem::transmute(avx_512_zmm16_31) };
990 avx_512_zmm16_31 as u64
991 });
992 __bindgen_bitfield_unit.set(8usize, 2u8, {
993 let rsvd8_9: u64 = unsafe { ::std::mem::transmute(rsvd8_9) };
994 rsvd8_9 as u64
995 });
996 __bindgen_bitfield_unit.set(10usize, 1u8, {
997 let pasid: u64 = unsafe { ::std::mem::transmute(pasid) };
998 pasid as u64
999 });
1000 __bindgen_bitfield_unit.set(11usize, 1u8, {
1001 let cet_u: u64 = unsafe { ::std::mem::transmute(cet_u) };
1002 cet_u as u64
1003 });
1004 __bindgen_bitfield_unit.set(12usize, 1u8, {
1005 let cet_s: u64 = unsafe { ::std::mem::transmute(cet_s) };
1006 cet_s as u64
1007 });
1008 __bindgen_bitfield_unit.set(13usize, 4u8, {
1009 let rsvd13_16: u64 = unsafe { ::std::mem::transmute(rsvd13_16) };
1010 rsvd13_16 as u64
1011 });
1012 __bindgen_bitfield_unit.set(17usize, 1u8, {
1013 let xtile_cfg: u64 = unsafe { ::std::mem::transmute(xtile_cfg) };
1014 xtile_cfg as u64
1015 });
1016 __bindgen_bitfield_unit.set(18usize, 1u8, {
1017 let xtile_data: u64 = unsafe { ::std::mem::transmute(xtile_data) };
1018 xtile_data as u64
1019 });
1020 __bindgen_bitfield_unit.set(19usize, 45u8, {
1021 let rsvd19_63: u64 = unsafe { ::std::mem::transmute(rsvd19_63) };
1022 rsvd19_63 as u64
1023 });
1024 __bindgen_bitfield_unit
1025 }
1026}
1027#[test]
1028fn bindgen_test_layout_hv_x64_xsave_xfem_register() {
1029 const UNINIT: ::std::mem::MaybeUninit<hv_x64_xsave_xfem_register> =
1030 ::std::mem::MaybeUninit::uninit();
1031 let ptr = UNINIT.as_ptr();
1032 assert_eq!(
1033 ::std::mem::size_of::<hv_x64_xsave_xfem_register>(),
1034 8usize,
1035 concat!("Size of: ", stringify!(hv_x64_xsave_xfem_register))
1036 );
1037 assert_eq!(
1038 ::std::mem::align_of::<hv_x64_xsave_xfem_register>(),
1039 8usize,
1040 concat!("Alignment of ", stringify!(hv_x64_xsave_xfem_register))
1041 );
1042 assert_eq!(
1043 unsafe { ::std::ptr::addr_of!((*ptr).as_uint64) as usize - ptr as usize },
1044 0usize,
1045 concat!(
1046 "Offset of field: ",
1047 stringify!(hv_x64_xsave_xfem_register),
1048 "::",
1049 stringify!(as_uint64)
1050 )
1051 );
1052}
1053impl Default for hv_x64_xsave_xfem_register {
1054 fn default() -> Self {
1055 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
1056 unsafe {
1057 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
1058 s.assume_init()
1059 }
1060 }
1061}
1062#[repr(C)]
1063#[derive(Copy, Clone)]
1064pub union hv_stimer_config {
1065 pub as_uint64: __u64,
1066 pub __bindgen_anon_1: hv_stimer_config__bindgen_ty_1,
1067}
1068#[repr(C, packed)]
1069#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
1070pub struct hv_stimer_config__bindgen_ty_1 {
1071 pub _bitfield_align_1: [u8; 0],
1072 pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>,
1073}
1074#[test]
1075fn bindgen_test_layout_hv_stimer_config__bindgen_ty_1() {
1076 assert_eq!(
1077 ::std::mem::size_of::<hv_stimer_config__bindgen_ty_1>(),
1078 8usize,
1079 concat!("Size of: ", stringify!(hv_stimer_config__bindgen_ty_1))
1080 );
1081 assert_eq!(
1082 ::std::mem::align_of::<hv_stimer_config__bindgen_ty_1>(),
1083 1usize,
1084 concat!("Alignment of ", stringify!(hv_stimer_config__bindgen_ty_1))
1085 );
1086}
1087impl hv_stimer_config__bindgen_ty_1 {
1088 #[inline]
1089 pub fn enable(&self) -> __u64 {
1090 unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 1u8) as u64) }
1091 }
1092 #[inline]
1093 pub fn set_enable(&mut self, val: __u64) {
1094 unsafe {
1095 let val: u64 = ::std::mem::transmute(val);
1096 self._bitfield_1.set(0usize, 1u8, val as u64)
1097 }
1098 }
1099 #[inline]
1100 pub fn periodic(&self) -> __u64 {
1101 unsafe { ::std::mem::transmute(self._bitfield_1.get(1usize, 1u8) as u64) }
1102 }
1103 #[inline]
1104 pub fn set_periodic(&mut self, val: __u64) {
1105 unsafe {
1106 let val: u64 = ::std::mem::transmute(val);
1107 self._bitfield_1.set(1usize, 1u8, val as u64)
1108 }
1109 }
1110 #[inline]
1111 pub fn lazy(&self) -> __u64 {
1112 unsafe { ::std::mem::transmute(self._bitfield_1.get(2usize, 1u8) as u64) }
1113 }
1114 #[inline]
1115 pub fn set_lazy(&mut self, val: __u64) {
1116 unsafe {
1117 let val: u64 = ::std::mem::transmute(val);
1118 self._bitfield_1.set(2usize, 1u8, val as u64)
1119 }
1120 }
1121 #[inline]
1122 pub fn auto_enable(&self) -> __u64 {
1123 unsafe { ::std::mem::transmute(self._bitfield_1.get(3usize, 1u8) as u64) }
1124 }
1125 #[inline]
1126 pub fn set_auto_enable(&mut self, val: __u64) {
1127 unsafe {
1128 let val: u64 = ::std::mem::transmute(val);
1129 self._bitfield_1.set(3usize, 1u8, val as u64)
1130 }
1131 }
1132 #[inline]
1133 pub fn apic_vector(&self) -> __u64 {
1134 unsafe { ::std::mem::transmute(self._bitfield_1.get(4usize, 8u8) as u64) }
1135 }
1136 #[inline]
1137 pub fn set_apic_vector(&mut self, val: __u64) {
1138 unsafe {
1139 let val: u64 = ::std::mem::transmute(val);
1140 self._bitfield_1.set(4usize, 8u8, val as u64)
1141 }
1142 }
1143 #[inline]
1144 pub fn direct_mode(&self) -> __u64 {
1145 unsafe { ::std::mem::transmute(self._bitfield_1.get(12usize, 1u8) as u64) }
1146 }
1147 #[inline]
1148 pub fn set_direct_mode(&mut self, val: __u64) {
1149 unsafe {
1150 let val: u64 = ::std::mem::transmute(val);
1151 self._bitfield_1.set(12usize, 1u8, val as u64)
1152 }
1153 }
1154 #[inline]
1155 pub fn reserved_z0(&self) -> __u64 {
1156 unsafe { ::std::mem::transmute(self._bitfield_1.get(13usize, 3u8) as u64) }
1157 }
1158 #[inline]
1159 pub fn set_reserved_z0(&mut self, val: __u64) {
1160 unsafe {
1161 let val: u64 = ::std::mem::transmute(val);
1162 self._bitfield_1.set(13usize, 3u8, val as u64)
1163 }
1164 }
1165 #[inline]
1166 pub fn sintx(&self) -> __u64 {
1167 unsafe { ::std::mem::transmute(self._bitfield_1.get(16usize, 4u8) as u64) }
1168 }
1169 #[inline]
1170 pub fn set_sintx(&mut self, val: __u64) {
1171 unsafe {
1172 let val: u64 = ::std::mem::transmute(val);
1173 self._bitfield_1.set(16usize, 4u8, val as u64)
1174 }
1175 }
1176 #[inline]
1177 pub fn reserved_z1(&self) -> __u64 {
1178 unsafe { ::std::mem::transmute(self._bitfield_1.get(20usize, 44u8) as u64) }
1179 }
1180 #[inline]
1181 pub fn set_reserved_z1(&mut self, val: __u64) {
1182 unsafe {
1183 let val: u64 = ::std::mem::transmute(val);
1184 self._bitfield_1.set(20usize, 44u8, val as u64)
1185 }
1186 }
1187 #[inline]
1188 pub fn new_bitfield_1(
1189 enable: __u64,
1190 periodic: __u64,
1191 lazy: __u64,
1192 auto_enable: __u64,
1193 apic_vector: __u64,
1194 direct_mode: __u64,
1195 reserved_z0: __u64,
1196 sintx: __u64,
1197 reserved_z1: __u64,
1198 ) -> __BindgenBitfieldUnit<[u8; 8usize]> {
1199 let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 8usize]> = Default::default();
1200 __bindgen_bitfield_unit.set(0usize, 1u8, {
1201 let enable: u64 = unsafe { ::std::mem::transmute(enable) };
1202 enable as u64
1203 });
1204 __bindgen_bitfield_unit.set(1usize, 1u8, {
1205 let periodic: u64 = unsafe { ::std::mem::transmute(periodic) };
1206 periodic as u64
1207 });
1208 __bindgen_bitfield_unit.set(2usize, 1u8, {
1209 let lazy: u64 = unsafe { ::std::mem::transmute(lazy) };
1210 lazy as u64
1211 });
1212 __bindgen_bitfield_unit.set(3usize, 1u8, {
1213 let auto_enable: u64 = unsafe { ::std::mem::transmute(auto_enable) };
1214 auto_enable as u64
1215 });
1216 __bindgen_bitfield_unit.set(4usize, 8u8, {
1217 let apic_vector: u64 = unsafe { ::std::mem::transmute(apic_vector) };
1218 apic_vector as u64
1219 });
1220 __bindgen_bitfield_unit.set(12usize, 1u8, {
1221 let direct_mode: u64 = unsafe { ::std::mem::transmute(direct_mode) };
1222 direct_mode as u64
1223 });
1224 __bindgen_bitfield_unit.set(13usize, 3u8, {
1225 let reserved_z0: u64 = unsafe { ::std::mem::transmute(reserved_z0) };
1226 reserved_z0 as u64
1227 });
1228 __bindgen_bitfield_unit.set(16usize, 4u8, {
1229 let sintx: u64 = unsafe { ::std::mem::transmute(sintx) };
1230 sintx as u64
1231 });
1232 __bindgen_bitfield_unit.set(20usize, 44u8, {
1233 let reserved_z1: u64 = unsafe { ::std::mem::transmute(reserved_z1) };
1234 reserved_z1 as u64
1235 });
1236 __bindgen_bitfield_unit
1237 }
1238}
1239#[test]
1240fn bindgen_test_layout_hv_stimer_config() {
1241 const UNINIT: ::std::mem::MaybeUninit<hv_stimer_config> = ::std::mem::MaybeUninit::uninit();
1242 let ptr = UNINIT.as_ptr();
1243 assert_eq!(
1244 ::std::mem::size_of::<hv_stimer_config>(),
1245 8usize,
1246 concat!("Size of: ", stringify!(hv_stimer_config))
1247 );
1248 assert_eq!(
1249 ::std::mem::align_of::<hv_stimer_config>(),
1250 8usize,
1251 concat!("Alignment of ", stringify!(hv_stimer_config))
1252 );
1253 assert_eq!(
1254 unsafe { ::std::ptr::addr_of!((*ptr).as_uint64) as usize - ptr as usize },
1255 0usize,
1256 concat!(
1257 "Offset of field: ",
1258 stringify!(hv_stimer_config),
1259 "::",
1260 stringify!(as_uint64)
1261 )
1262 );
1263}
1264impl Default for hv_stimer_config {
1265 fn default() -> Self {
1266 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
1267 unsafe {
1268 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
1269 s.assume_init()
1270 }
1271 }
1272}
1273#[repr(C)]
1274#[derive(Copy, Clone)]
1275pub union hv_port_id {
1276 pub as__u32: __u32,
1277 pub u: hv_port_id__bindgen_ty_1,
1278}
1279#[repr(C, packed)]
1280#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
1281pub struct hv_port_id__bindgen_ty_1 {
1282 pub _bitfield_align_1: [u8; 0],
1283 pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize]>,
1284}
1285#[test]
1286fn bindgen_test_layout_hv_port_id__bindgen_ty_1() {
1287 assert_eq!(
1288 ::std::mem::size_of::<hv_port_id__bindgen_ty_1>(),
1289 4usize,
1290 concat!("Size of: ", stringify!(hv_port_id__bindgen_ty_1))
1291 );
1292 assert_eq!(
1293 ::std::mem::align_of::<hv_port_id__bindgen_ty_1>(),
1294 1usize,
1295 concat!("Alignment of ", stringify!(hv_port_id__bindgen_ty_1))
1296 );
1297}
1298impl hv_port_id__bindgen_ty_1 {
1299 #[inline]
1300 pub fn id(&self) -> __u32 {
1301 unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 24u8) as u32) }
1302 }
1303 #[inline]
1304 pub fn set_id(&mut self, val: __u32) {
1305 unsafe {
1306 let val: u32 = ::std::mem::transmute(val);
1307 self._bitfield_1.set(0usize, 24u8, val as u64)
1308 }
1309 }
1310 #[inline]
1311 pub fn reserved(&self) -> __u32 {
1312 unsafe { ::std::mem::transmute(self._bitfield_1.get(24usize, 8u8) as u32) }
1313 }
1314 #[inline]
1315 pub fn set_reserved(&mut self, val: __u32) {
1316 unsafe {
1317 let val: u32 = ::std::mem::transmute(val);
1318 self._bitfield_1.set(24usize, 8u8, val as u64)
1319 }
1320 }
1321 #[inline]
1322 pub fn new_bitfield_1(id: __u32, reserved: __u32) -> __BindgenBitfieldUnit<[u8; 4usize]> {
1323 let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 4usize]> = Default::default();
1324 __bindgen_bitfield_unit.set(0usize, 24u8, {
1325 let id: u32 = unsafe { ::std::mem::transmute(id) };
1326 id as u64
1327 });
1328 __bindgen_bitfield_unit.set(24usize, 8u8, {
1329 let reserved: u32 = unsafe { ::std::mem::transmute(reserved) };
1330 reserved as u64
1331 });
1332 __bindgen_bitfield_unit
1333 }
1334}
1335#[test]
1336fn bindgen_test_layout_hv_port_id() {
1337 const UNINIT: ::std::mem::MaybeUninit<hv_port_id> = ::std::mem::MaybeUninit::uninit();
1338 let ptr = UNINIT.as_ptr();
1339 assert_eq!(
1340 ::std::mem::size_of::<hv_port_id>(),
1341 4usize,
1342 concat!("Size of: ", stringify!(hv_port_id))
1343 );
1344 assert_eq!(
1345 ::std::mem::align_of::<hv_port_id>(),
1346 4usize,
1347 concat!("Alignment of ", stringify!(hv_port_id))
1348 );
1349 assert_eq!(
1350 unsafe { ::std::ptr::addr_of!((*ptr).as__u32) as usize - ptr as usize },
1351 0usize,
1352 concat!(
1353 "Offset of field: ",
1354 stringify!(hv_port_id),
1355 "::",
1356 stringify!(as__u32)
1357 )
1358 );
1359 assert_eq!(
1360 unsafe { ::std::ptr::addr_of!((*ptr).u) as usize - ptr as usize },
1361 0usize,
1362 concat!(
1363 "Offset of field: ",
1364 stringify!(hv_port_id),
1365 "::",
1366 stringify!(u)
1367 )
1368 );
1369}
1370impl Default for hv_port_id {
1371 fn default() -> Self {
1372 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
1373 unsafe {
1374 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
1375 s.assume_init()
1376 }
1377 }
1378}
1379pub const hv_message_type_HVMSG_NONE: hv_message_type = 0;
1380pub const hv_message_type_HVMSG_UNMAPPED_GPA: hv_message_type = 2147483648;
1381pub const hv_message_type_HVMSG_GPA_INTERCEPT: hv_message_type = 2147483649;
1382pub const hv_message_type_HVMSG_UNACCEPTED_GPA: hv_message_type = 2147483651;
1383pub const hv_message_type_HVMSG_GPA_ATTRIBUTE_INTERCEPT: hv_message_type = 2147483652;
1384pub const hv_message_type_HVMSG_TIMER_EXPIRED: hv_message_type = 2147483664;
1385pub const hv_message_type_HVMSG_INVALID_VP_REGISTER_VALUE: hv_message_type = 2147483680;
1386pub const hv_message_type_HVMSG_UNRECOVERABLE_EXCEPTION: hv_message_type = 2147483681;
1387pub const hv_message_type_HVMSG_UNSUPPORTED_FEATURE: hv_message_type = 2147483682;
1388pub const hv_message_type_HVMSG_OPAQUE_INTERCEPT: hv_message_type = 2147483711;
1389pub const hv_message_type_HVMSG_EVENTLOG_BUFFERCOMPLETE: hv_message_type = 2147483712;
1390pub const hv_message_type_HVMSG_HYPERCALL_INTERCEPT: hv_message_type = 2147483728;
1391pub const hv_message_type_HVMSG_SYNIC_EVENT_INTERCEPT: hv_message_type = 2147483744;
1392pub const hv_message_type_HVMSG_SYNIC_SINT_INTERCEPT: hv_message_type = 2147483745;
1393pub const hv_message_type_HVMSG_SYNIC_SINT_DELIVERABLE: hv_message_type = 2147483746;
1394pub const hv_message_type_HVMSG_ASYNC_CALL_COMPLETION: hv_message_type = 2147483760;
1395pub const hv_message_type_HVMSG_SCHEDULER_VP_SIGNAL_BITSET: hv_message_type = 2147483904;
1396pub const hv_message_type_HVMSG_SCHEDULER_VP_SIGNAL_PAIR: hv_message_type = 2147483905;
1397pub const hv_message_type_HVMSG_X64_IO_PORT_INTERCEPT: hv_message_type = 2147549184;
1398pub const hv_message_type_HVMSG_X64_MSR_INTERCEPT: hv_message_type = 2147549185;
1399pub const hv_message_type_HVMSG_X64_CPUID_INTERCEPT: hv_message_type = 2147549186;
1400pub const hv_message_type_HVMSG_X64_EXCEPTION_INTERCEPT: hv_message_type = 2147549187;
1401pub const hv_message_type_HVMSG_X64_APIC_EOI: hv_message_type = 2147549188;
1402pub const hv_message_type_HVMSG_X64_LEGACY_FP_ERROR: hv_message_type = 2147549189;
1403pub const hv_message_type_HVMSG_X64_IOMMU_PRQ: hv_message_type = 2147549190;
1404pub const hv_message_type_HVMSG_X64_HALT: hv_message_type = 2147549191;
1405pub const hv_message_type_HVMSG_X64_INTERRUPTION_DELIVERABLE: hv_message_type = 2147549192;
1406pub const hv_message_type_HVMSG_X64_SIPI_INTERCEPT: hv_message_type = 2147549193;
1407pub const hv_message_type_HVMSG_X64_SEV_VMGEXIT_INTERCEPT: hv_message_type = 2147549203;
1408pub type hv_message_type = ::std::os::raw::c_uint;
1409#[repr(C)]
1410#[derive(Copy, Clone)]
1411pub union hv_message_flags {
1412 pub asu8: __u8,
1413 pub __bindgen_anon_1: hv_message_flags__bindgen_ty_1,
1414}
1415#[repr(C, packed)]
1416#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
1417pub struct hv_message_flags__bindgen_ty_1 {
1418 pub _bitfield_align_1: [u8; 0],
1419 pub _bitfield_1: __BindgenBitfieldUnit<[u8; 1usize]>,
1420}
1421#[test]
1422fn bindgen_test_layout_hv_message_flags__bindgen_ty_1() {
1423 assert_eq!(
1424 ::std::mem::size_of::<hv_message_flags__bindgen_ty_1>(),
1425 1usize,
1426 concat!("Size of: ", stringify!(hv_message_flags__bindgen_ty_1))
1427 );
1428 assert_eq!(
1429 ::std::mem::align_of::<hv_message_flags__bindgen_ty_1>(),
1430 1usize,
1431 concat!("Alignment of ", stringify!(hv_message_flags__bindgen_ty_1))
1432 );
1433}
1434impl hv_message_flags__bindgen_ty_1 {
1435 #[inline]
1436 pub fn msg_pending(&self) -> __u8 {
1437 unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 1u8) as u8) }
1438 }
1439 #[inline]
1440 pub fn set_msg_pending(&mut self, val: __u8) {
1441 unsafe {
1442 let val: u8 = ::std::mem::transmute(val);
1443 self._bitfield_1.set(0usize, 1u8, val as u64)
1444 }
1445 }
1446 #[inline]
1447 pub fn reserved(&self) -> __u8 {
1448 unsafe { ::std::mem::transmute(self._bitfield_1.get(1usize, 7u8) as u8) }
1449 }
1450 #[inline]
1451 pub fn set_reserved(&mut self, val: __u8) {
1452 unsafe {
1453 let val: u8 = ::std::mem::transmute(val);
1454 self._bitfield_1.set(1usize, 7u8, val as u64)
1455 }
1456 }
1457 #[inline]
1458 pub fn new_bitfield_1(
1459 msg_pending: __u8,
1460 reserved: __u8,
1461 ) -> __BindgenBitfieldUnit<[u8; 1usize]> {
1462 let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 1usize]> = Default::default();
1463 __bindgen_bitfield_unit.set(0usize, 1u8, {
1464 let msg_pending: u8 = unsafe { ::std::mem::transmute(msg_pending) };
1465 msg_pending as u64
1466 });
1467 __bindgen_bitfield_unit.set(1usize, 7u8, {
1468 let reserved: u8 = unsafe { ::std::mem::transmute(reserved) };
1469 reserved as u64
1470 });
1471 __bindgen_bitfield_unit
1472 }
1473}
1474#[test]
1475fn bindgen_test_layout_hv_message_flags() {
1476 const UNINIT: ::std::mem::MaybeUninit<hv_message_flags> = ::std::mem::MaybeUninit::uninit();
1477 let ptr = UNINIT.as_ptr();
1478 assert_eq!(
1479 ::std::mem::size_of::<hv_message_flags>(),
1480 1usize,
1481 concat!("Size of: ", stringify!(hv_message_flags))
1482 );
1483 assert_eq!(
1484 ::std::mem::align_of::<hv_message_flags>(),
1485 1usize,
1486 concat!("Alignment of ", stringify!(hv_message_flags))
1487 );
1488 assert_eq!(
1489 unsafe { ::std::ptr::addr_of!((*ptr).asu8) as usize - ptr as usize },
1490 0usize,
1491 concat!(
1492 "Offset of field: ",
1493 stringify!(hv_message_flags),
1494 "::",
1495 stringify!(asu8)
1496 )
1497 );
1498}
1499impl Default for hv_message_flags {
1500 fn default() -> Self {
1501 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
1502 unsafe {
1503 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
1504 s.assume_init()
1505 }
1506 }
1507}
1508#[repr(C, packed)]
1509#[derive(Copy, Clone)]
1510pub struct hv_message_header {
1511 pub message_type: __u32,
1512 pub payload_size: __u8,
1513 pub message_flags: hv_message_flags,
1514 pub reserved: [__u8; 2usize],
1515 pub __bindgen_anon_1: hv_message_header__bindgen_ty_1,
1516}
1517#[repr(C)]
1518#[derive(Copy, Clone)]
1519pub union hv_message_header__bindgen_ty_1 {
1520 pub sender: __u64,
1521 pub port: hv_port_id,
1522}
1523#[test]
1524fn bindgen_test_layout_hv_message_header__bindgen_ty_1() {
1525 const UNINIT: ::std::mem::MaybeUninit<hv_message_header__bindgen_ty_1> =
1526 ::std::mem::MaybeUninit::uninit();
1527 let ptr = UNINIT.as_ptr();
1528 assert_eq!(
1529 ::std::mem::size_of::<hv_message_header__bindgen_ty_1>(),
1530 8usize,
1531 concat!("Size of: ", stringify!(hv_message_header__bindgen_ty_1))
1532 );
1533 assert_eq!(
1534 ::std::mem::align_of::<hv_message_header__bindgen_ty_1>(),
1535 8usize,
1536 concat!("Alignment of ", stringify!(hv_message_header__bindgen_ty_1))
1537 );
1538 assert_eq!(
1539 unsafe { ::std::ptr::addr_of!((*ptr).sender) as usize - ptr as usize },
1540 0usize,
1541 concat!(
1542 "Offset of field: ",
1543 stringify!(hv_message_header__bindgen_ty_1),
1544 "::",
1545 stringify!(sender)
1546 )
1547 );
1548 assert_eq!(
1549 unsafe { ::std::ptr::addr_of!((*ptr).port) as usize - ptr as usize },
1550 0usize,
1551 concat!(
1552 "Offset of field: ",
1553 stringify!(hv_message_header__bindgen_ty_1),
1554 "::",
1555 stringify!(port)
1556 )
1557 );
1558}
1559impl Default for hv_message_header__bindgen_ty_1 {
1560 fn default() -> Self {
1561 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
1562 unsafe {
1563 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
1564 s.assume_init()
1565 }
1566 }
1567}
1568#[test]
1569fn bindgen_test_layout_hv_message_header() {
1570 const UNINIT: ::std::mem::MaybeUninit<hv_message_header> = ::std::mem::MaybeUninit::uninit();
1571 let ptr = UNINIT.as_ptr();
1572 assert_eq!(
1573 ::std::mem::size_of::<hv_message_header>(),
1574 16usize,
1575 concat!("Size of: ", stringify!(hv_message_header))
1576 );
1577 assert_eq!(
1578 ::std::mem::align_of::<hv_message_header>(),
1579 1usize,
1580 concat!("Alignment of ", stringify!(hv_message_header))
1581 );
1582 assert_eq!(
1583 unsafe { ::std::ptr::addr_of!((*ptr).message_type) as usize - ptr as usize },
1584 0usize,
1585 concat!(
1586 "Offset of field: ",
1587 stringify!(hv_message_header),
1588 "::",
1589 stringify!(message_type)
1590 )
1591 );
1592 assert_eq!(
1593 unsafe { ::std::ptr::addr_of!((*ptr).payload_size) as usize - ptr as usize },
1594 4usize,
1595 concat!(
1596 "Offset of field: ",
1597 stringify!(hv_message_header),
1598 "::",
1599 stringify!(payload_size)
1600 )
1601 );
1602 assert_eq!(
1603 unsafe { ::std::ptr::addr_of!((*ptr).message_flags) as usize - ptr as usize },
1604 5usize,
1605 concat!(
1606 "Offset of field: ",
1607 stringify!(hv_message_header),
1608 "::",
1609 stringify!(message_flags)
1610 )
1611 );
1612 assert_eq!(
1613 unsafe { ::std::ptr::addr_of!((*ptr).reserved) as usize - ptr as usize },
1614 6usize,
1615 concat!(
1616 "Offset of field: ",
1617 stringify!(hv_message_header),
1618 "::",
1619 stringify!(reserved)
1620 )
1621 );
1622}
1623impl Default for hv_message_header {
1624 fn default() -> Self {
1625 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
1626 unsafe {
1627 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
1628 s.assume_init()
1629 }
1630 }
1631}
1632#[repr(C, packed)]
1633#[derive(Copy, Clone)]
1634pub struct hv_message {
1635 pub header: hv_message_header,
1636 pub u: hv_message__bindgen_ty_1,
1637}
1638#[repr(C)]
1639#[derive(Copy, Clone)]
1640pub union hv_message__bindgen_ty_1 {
1641 pub payload: [__u64; 30usize],
1642}
1643#[test]
1644fn bindgen_test_layout_hv_message__bindgen_ty_1() {
1645 const UNINIT: ::std::mem::MaybeUninit<hv_message__bindgen_ty_1> =
1646 ::std::mem::MaybeUninit::uninit();
1647 let ptr = UNINIT.as_ptr();
1648 assert_eq!(
1649 ::std::mem::size_of::<hv_message__bindgen_ty_1>(),
1650 240usize,
1651 concat!("Size of: ", stringify!(hv_message__bindgen_ty_1))
1652 );
1653 assert_eq!(
1654 ::std::mem::align_of::<hv_message__bindgen_ty_1>(),
1655 8usize,
1656 concat!("Alignment of ", stringify!(hv_message__bindgen_ty_1))
1657 );
1658 assert_eq!(
1659 unsafe { ::std::ptr::addr_of!((*ptr).payload) as usize - ptr as usize },
1660 0usize,
1661 concat!(
1662 "Offset of field: ",
1663 stringify!(hv_message__bindgen_ty_1),
1664 "::",
1665 stringify!(payload)
1666 )
1667 );
1668}
1669impl Default for hv_message__bindgen_ty_1 {
1670 fn default() -> Self {
1671 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
1672 unsafe {
1673 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
1674 s.assume_init()
1675 }
1676 }
1677}
1678#[test]
1679fn bindgen_test_layout_hv_message() {
1680 const UNINIT: ::std::mem::MaybeUninit<hv_message> = ::std::mem::MaybeUninit::uninit();
1681 let ptr = UNINIT.as_ptr();
1682 assert_eq!(
1683 ::std::mem::size_of::<hv_message>(),
1684 256usize,
1685 concat!("Size of: ", stringify!(hv_message))
1686 );
1687 assert_eq!(
1688 ::std::mem::align_of::<hv_message>(),
1689 1usize,
1690 concat!("Alignment of ", stringify!(hv_message))
1691 );
1692 assert_eq!(
1693 unsafe { ::std::ptr::addr_of!((*ptr).header) as usize - ptr as usize },
1694 0usize,
1695 concat!(
1696 "Offset of field: ",
1697 stringify!(hv_message),
1698 "::",
1699 stringify!(header)
1700 )
1701 );
1702 assert_eq!(
1703 unsafe { ::std::ptr::addr_of!((*ptr).u) as usize - ptr as usize },
1704 16usize,
1705 concat!(
1706 "Offset of field: ",
1707 stringify!(hv_message),
1708 "::",
1709 stringify!(u)
1710 )
1711 );
1712}
1713impl Default for hv_message {
1714 fn default() -> Self {
1715 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
1716 unsafe {
1717 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
1718 s.assume_init()
1719 }
1720 }
1721}
1722#[repr(C, packed)]
1723#[derive(Copy, Clone)]
1724pub struct hv_x64_segment_register {
1725 pub base: __u64,
1726 pub limit: __u32,
1727 pub selector: __u16,
1728 pub __bindgen_anon_1: hv_x64_segment_register__bindgen_ty_1,
1729}
1730#[repr(C)]
1731#[derive(Copy, Clone)]
1732pub union hv_x64_segment_register__bindgen_ty_1 {
1733 pub __bindgen_anon_1: hv_x64_segment_register__bindgen_ty_1__bindgen_ty_1,
1734 pub attributes: __u16,
1735}
1736#[repr(C, packed)]
1737#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
1738pub struct hv_x64_segment_register__bindgen_ty_1__bindgen_ty_1 {
1739 pub _bitfield_align_1: [u8; 0],
1740 pub _bitfield_1: __BindgenBitfieldUnit<[u8; 2usize]>,
1741}
1742#[test]
1743fn bindgen_test_layout_hv_x64_segment_register__bindgen_ty_1__bindgen_ty_1() {
1744 assert_eq!(
1745 ::std::mem::size_of::<hv_x64_segment_register__bindgen_ty_1__bindgen_ty_1>(),
1746 2usize,
1747 concat!(
1748 "Size of: ",
1749 stringify!(hv_x64_segment_register__bindgen_ty_1__bindgen_ty_1)
1750 )
1751 );
1752 assert_eq!(
1753 ::std::mem::align_of::<hv_x64_segment_register__bindgen_ty_1__bindgen_ty_1>(),
1754 1usize,
1755 concat!(
1756 "Alignment of ",
1757 stringify!(hv_x64_segment_register__bindgen_ty_1__bindgen_ty_1)
1758 )
1759 );
1760}
1761impl hv_x64_segment_register__bindgen_ty_1__bindgen_ty_1 {
1762 #[inline]
1763 pub fn segment_type(&self) -> __u16 {
1764 unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 4u8) as u16) }
1765 }
1766 #[inline]
1767 pub fn set_segment_type(&mut self, val: __u16) {
1768 unsafe {
1769 let val: u16 = ::std::mem::transmute(val);
1770 self._bitfield_1.set(0usize, 4u8, val as u64)
1771 }
1772 }
1773 #[inline]
1774 pub fn non_system_segment(&self) -> __u16 {
1775 unsafe { ::std::mem::transmute(self._bitfield_1.get(4usize, 1u8) as u16) }
1776 }
1777 #[inline]
1778 pub fn set_non_system_segment(&mut self, val: __u16) {
1779 unsafe {
1780 let val: u16 = ::std::mem::transmute(val);
1781 self._bitfield_1.set(4usize, 1u8, val as u64)
1782 }
1783 }
1784 #[inline]
1785 pub fn descriptor_privilege_level(&self) -> __u16 {
1786 unsafe { ::std::mem::transmute(self._bitfield_1.get(5usize, 2u8) as u16) }
1787 }
1788 #[inline]
1789 pub fn set_descriptor_privilege_level(&mut self, val: __u16) {
1790 unsafe {
1791 let val: u16 = ::std::mem::transmute(val);
1792 self._bitfield_1.set(5usize, 2u8, val as u64)
1793 }
1794 }
1795 #[inline]
1796 pub fn present(&self) -> __u16 {
1797 unsafe { ::std::mem::transmute(self._bitfield_1.get(7usize, 1u8) as u16) }
1798 }
1799 #[inline]
1800 pub fn set_present(&mut self, val: __u16) {
1801 unsafe {
1802 let val: u16 = ::std::mem::transmute(val);
1803 self._bitfield_1.set(7usize, 1u8, val as u64)
1804 }
1805 }
1806 #[inline]
1807 pub fn reserved(&self) -> __u16 {
1808 unsafe { ::std::mem::transmute(self._bitfield_1.get(8usize, 4u8) as u16) }
1809 }
1810 #[inline]
1811 pub fn set_reserved(&mut self, val: __u16) {
1812 unsafe {
1813 let val: u16 = ::std::mem::transmute(val);
1814 self._bitfield_1.set(8usize, 4u8, val as u64)
1815 }
1816 }
1817 #[inline]
1818 pub fn available(&self) -> __u16 {
1819 unsafe { ::std::mem::transmute(self._bitfield_1.get(12usize, 1u8) as u16) }
1820 }
1821 #[inline]
1822 pub fn set_available(&mut self, val: __u16) {
1823 unsafe {
1824 let val: u16 = ::std::mem::transmute(val);
1825 self._bitfield_1.set(12usize, 1u8, val as u64)
1826 }
1827 }
1828 #[inline]
1829 pub fn _long(&self) -> __u16 {
1830 unsafe { ::std::mem::transmute(self._bitfield_1.get(13usize, 1u8) as u16) }
1831 }
1832 #[inline]
1833 pub fn set__long(&mut self, val: __u16) {
1834 unsafe {
1835 let val: u16 = ::std::mem::transmute(val);
1836 self._bitfield_1.set(13usize, 1u8, val as u64)
1837 }
1838 }
1839 #[inline]
1840 pub fn _default(&self) -> __u16 {
1841 unsafe { ::std::mem::transmute(self._bitfield_1.get(14usize, 1u8) as u16) }
1842 }
1843 #[inline]
1844 pub fn set__default(&mut self, val: __u16) {
1845 unsafe {
1846 let val: u16 = ::std::mem::transmute(val);
1847 self._bitfield_1.set(14usize, 1u8, val as u64)
1848 }
1849 }
1850 #[inline]
1851 pub fn granularity(&self) -> __u16 {
1852 unsafe { ::std::mem::transmute(self._bitfield_1.get(15usize, 1u8) as u16) }
1853 }
1854 #[inline]
1855 pub fn set_granularity(&mut self, val: __u16) {
1856 unsafe {
1857 let val: u16 = ::std::mem::transmute(val);
1858 self._bitfield_1.set(15usize, 1u8, val as u64)
1859 }
1860 }
1861 #[inline]
1862 pub fn new_bitfield_1(
1863 segment_type: __u16,
1864 non_system_segment: __u16,
1865 descriptor_privilege_level: __u16,
1866 present: __u16,
1867 reserved: __u16,
1868 available: __u16,
1869 _long: __u16,
1870 _default: __u16,
1871 granularity: __u16,
1872 ) -> __BindgenBitfieldUnit<[u8; 2usize]> {
1873 let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 2usize]> = Default::default();
1874 __bindgen_bitfield_unit.set(0usize, 4u8, {
1875 let segment_type: u16 = unsafe { ::std::mem::transmute(segment_type) };
1876 segment_type as u64
1877 });
1878 __bindgen_bitfield_unit.set(4usize, 1u8, {
1879 let non_system_segment: u16 = unsafe { ::std::mem::transmute(non_system_segment) };
1880 non_system_segment as u64
1881 });
1882 __bindgen_bitfield_unit.set(5usize, 2u8, {
1883 let descriptor_privilege_level: u16 =
1884 unsafe { ::std::mem::transmute(descriptor_privilege_level) };
1885 descriptor_privilege_level as u64
1886 });
1887 __bindgen_bitfield_unit.set(7usize, 1u8, {
1888 let present: u16 = unsafe { ::std::mem::transmute(present) };
1889 present as u64
1890 });
1891 __bindgen_bitfield_unit.set(8usize, 4u8, {
1892 let reserved: u16 = unsafe { ::std::mem::transmute(reserved) };
1893 reserved as u64
1894 });
1895 __bindgen_bitfield_unit.set(12usize, 1u8, {
1896 let available: u16 = unsafe { ::std::mem::transmute(available) };
1897 available as u64
1898 });
1899 __bindgen_bitfield_unit.set(13usize, 1u8, {
1900 let _long: u16 = unsafe { ::std::mem::transmute(_long) };
1901 _long as u64
1902 });
1903 __bindgen_bitfield_unit.set(14usize, 1u8, {
1904 let _default: u16 = unsafe { ::std::mem::transmute(_default) };
1905 _default as u64
1906 });
1907 __bindgen_bitfield_unit.set(15usize, 1u8, {
1908 let granularity: u16 = unsafe { ::std::mem::transmute(granularity) };
1909 granularity as u64
1910 });
1911 __bindgen_bitfield_unit
1912 }
1913}
1914#[test]
1915fn bindgen_test_layout_hv_x64_segment_register__bindgen_ty_1() {
1916 const UNINIT: ::std::mem::MaybeUninit<hv_x64_segment_register__bindgen_ty_1> =
1917 ::std::mem::MaybeUninit::uninit();
1918 let ptr = UNINIT.as_ptr();
1919 assert_eq!(
1920 ::std::mem::size_of::<hv_x64_segment_register__bindgen_ty_1>(),
1921 2usize,
1922 concat!(
1923 "Size of: ",
1924 stringify!(hv_x64_segment_register__bindgen_ty_1)
1925 )
1926 );
1927 assert_eq!(
1928 ::std::mem::align_of::<hv_x64_segment_register__bindgen_ty_1>(),
1929 2usize,
1930 concat!(
1931 "Alignment of ",
1932 stringify!(hv_x64_segment_register__bindgen_ty_1)
1933 )
1934 );
1935 assert_eq!(
1936 unsafe { ::std::ptr::addr_of!((*ptr).attributes) as usize - ptr as usize },
1937 0usize,
1938 concat!(
1939 "Offset of field: ",
1940 stringify!(hv_x64_segment_register__bindgen_ty_1),
1941 "::",
1942 stringify!(attributes)
1943 )
1944 );
1945}
1946impl Default for hv_x64_segment_register__bindgen_ty_1 {
1947 fn default() -> Self {
1948 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
1949 unsafe {
1950 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
1951 s.assume_init()
1952 }
1953 }
1954}
1955#[test]
1956fn bindgen_test_layout_hv_x64_segment_register() {
1957 const UNINIT: ::std::mem::MaybeUninit<hv_x64_segment_register> =
1958 ::std::mem::MaybeUninit::uninit();
1959 let ptr = UNINIT.as_ptr();
1960 assert_eq!(
1961 ::std::mem::size_of::<hv_x64_segment_register>(),
1962 16usize,
1963 concat!("Size of: ", stringify!(hv_x64_segment_register))
1964 );
1965 assert_eq!(
1966 ::std::mem::align_of::<hv_x64_segment_register>(),
1967 1usize,
1968 concat!("Alignment of ", stringify!(hv_x64_segment_register))
1969 );
1970 assert_eq!(
1971 unsafe { ::std::ptr::addr_of!((*ptr).base) as usize - ptr as usize },
1972 0usize,
1973 concat!(
1974 "Offset of field: ",
1975 stringify!(hv_x64_segment_register),
1976 "::",
1977 stringify!(base)
1978 )
1979 );
1980 assert_eq!(
1981 unsafe { ::std::ptr::addr_of!((*ptr).limit) as usize - ptr as usize },
1982 8usize,
1983 concat!(
1984 "Offset of field: ",
1985 stringify!(hv_x64_segment_register),
1986 "::",
1987 stringify!(limit)
1988 )
1989 );
1990 assert_eq!(
1991 unsafe { ::std::ptr::addr_of!((*ptr).selector) as usize - ptr as usize },
1992 12usize,
1993 concat!(
1994 "Offset of field: ",
1995 stringify!(hv_x64_segment_register),
1996 "::",
1997 stringify!(selector)
1998 )
1999 );
2000}
2001impl Default for hv_x64_segment_register {
2002 fn default() -> Self {
2003 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
2004 unsafe {
2005 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
2006 s.assume_init()
2007 }
2008 }
2009}
2010#[repr(C, packed)]
2011#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
2012pub struct hv_x64_table_register {
2013 pub pad: [__u16; 3usize],
2014 pub limit: __u16,
2015 pub base: __u64,
2016}
2017#[test]
2018fn bindgen_test_layout_hv_x64_table_register() {
2019 const UNINIT: ::std::mem::MaybeUninit<hv_x64_table_register> =
2020 ::std::mem::MaybeUninit::uninit();
2021 let ptr = UNINIT.as_ptr();
2022 assert_eq!(
2023 ::std::mem::size_of::<hv_x64_table_register>(),
2024 16usize,
2025 concat!("Size of: ", stringify!(hv_x64_table_register))
2026 );
2027 assert_eq!(
2028 ::std::mem::align_of::<hv_x64_table_register>(),
2029 1usize,
2030 concat!("Alignment of ", stringify!(hv_x64_table_register))
2031 );
2032 assert_eq!(
2033 unsafe { ::std::ptr::addr_of!((*ptr).pad) as usize - ptr as usize },
2034 0usize,
2035 concat!(
2036 "Offset of field: ",
2037 stringify!(hv_x64_table_register),
2038 "::",
2039 stringify!(pad)
2040 )
2041 );
2042 assert_eq!(
2043 unsafe { ::std::ptr::addr_of!((*ptr).limit) as usize - ptr as usize },
2044 6usize,
2045 concat!(
2046 "Offset of field: ",
2047 stringify!(hv_x64_table_register),
2048 "::",
2049 stringify!(limit)
2050 )
2051 );
2052 assert_eq!(
2053 unsafe { ::std::ptr::addr_of!((*ptr).base) as usize - ptr as usize },
2054 8usize,
2055 concat!(
2056 "Offset of field: ",
2057 stringify!(hv_x64_table_register),
2058 "::",
2059 stringify!(base)
2060 )
2061 );
2062}
2063#[repr(C, packed)]
2064#[derive(Copy, Clone)]
2065pub union hv_x64_fp_control_status_register {
2066 pub as_uint128: hv_u128,
2067 pub __bindgen_anon_1: hv_x64_fp_control_status_register__bindgen_ty_1,
2068}
2069#[repr(C, packed)]
2070#[derive(Copy, Clone)]
2071pub struct hv_x64_fp_control_status_register__bindgen_ty_1 {
2072 pub fp_control: __u16,
2073 pub fp_status: __u16,
2074 pub fp_tag: __u8,
2075 pub reserved: __u8,
2076 pub last_fp_op: __u16,
2077 pub __bindgen_anon_1: hv_x64_fp_control_status_register__bindgen_ty_1__bindgen_ty_1,
2078}
2079#[repr(C)]
2080#[derive(Copy, Clone)]
2081pub union hv_x64_fp_control_status_register__bindgen_ty_1__bindgen_ty_1 {
2082 pub last_fp_rip: __u64,
2083 pub __bindgen_anon_1:
2084 hv_x64_fp_control_status_register__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1,
2085}
2086#[repr(C, packed)]
2087#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
2088pub struct hv_x64_fp_control_status_register__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1 {
2089 pub last_fp_eip: __u32,
2090 pub last_fp_cs: __u16,
2091 pub padding: __u16,
2092}
2093#[test]
2094fn bindgen_test_layout_hv_x64_fp_control_status_register__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1()
2095{
2096 const UNINIT: ::std::mem::MaybeUninit<
2097 hv_x64_fp_control_status_register__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1,
2098 > = ::std::mem::MaybeUninit::uninit();
2099 let ptr = UNINIT.as_ptr();
2100 assert_eq!(
2101 ::std::mem::size_of::<
2102 hv_x64_fp_control_status_register__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1,
2103 >(),
2104 8usize,
2105 concat!(
2106 "Size of: ",
2107 stringify!(hv_x64_fp_control_status_register__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1)
2108 )
2109 );
2110 assert_eq!(
2111 ::std::mem::align_of::<
2112 hv_x64_fp_control_status_register__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1,
2113 >(),
2114 1usize,
2115 concat!(
2116 "Alignment of ",
2117 stringify!(hv_x64_fp_control_status_register__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1)
2118 )
2119 );
2120 assert_eq!(
2121 unsafe { ::std::ptr::addr_of!((*ptr).last_fp_eip) as usize - ptr as usize },
2122 0usize,
2123 concat!(
2124 "Offset of field: ",
2125 stringify!(hv_x64_fp_control_status_register__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1),
2126 "::",
2127 stringify!(last_fp_eip)
2128 )
2129 );
2130 assert_eq!(
2131 unsafe { ::std::ptr::addr_of!((*ptr).last_fp_cs) as usize - ptr as usize },
2132 4usize,
2133 concat!(
2134 "Offset of field: ",
2135 stringify!(hv_x64_fp_control_status_register__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1),
2136 "::",
2137 stringify!(last_fp_cs)
2138 )
2139 );
2140 assert_eq!(
2141 unsafe { ::std::ptr::addr_of!((*ptr).padding) as usize - ptr as usize },
2142 6usize,
2143 concat!(
2144 "Offset of field: ",
2145 stringify!(hv_x64_fp_control_status_register__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1),
2146 "::",
2147 stringify!(padding)
2148 )
2149 );
2150}
2151#[test]
2152fn bindgen_test_layout_hv_x64_fp_control_status_register__bindgen_ty_1__bindgen_ty_1() {
2153 const UNINIT: ::std::mem::MaybeUninit<
2154 hv_x64_fp_control_status_register__bindgen_ty_1__bindgen_ty_1,
2155 > = ::std::mem::MaybeUninit::uninit();
2156 let ptr = UNINIT.as_ptr();
2157 assert_eq!(
2158 ::std::mem::size_of::<hv_x64_fp_control_status_register__bindgen_ty_1__bindgen_ty_1>(),
2159 8usize,
2160 concat!(
2161 "Size of: ",
2162 stringify!(hv_x64_fp_control_status_register__bindgen_ty_1__bindgen_ty_1)
2163 )
2164 );
2165 assert_eq!(
2166 ::std::mem::align_of::<hv_x64_fp_control_status_register__bindgen_ty_1__bindgen_ty_1>(),
2167 8usize,
2168 concat!(
2169 "Alignment of ",
2170 stringify!(hv_x64_fp_control_status_register__bindgen_ty_1__bindgen_ty_1)
2171 )
2172 );
2173 assert_eq!(
2174 unsafe { ::std::ptr::addr_of!((*ptr).last_fp_rip) as usize - ptr as usize },
2175 0usize,
2176 concat!(
2177 "Offset of field: ",
2178 stringify!(hv_x64_fp_control_status_register__bindgen_ty_1__bindgen_ty_1),
2179 "::",
2180 stringify!(last_fp_rip)
2181 )
2182 );
2183}
2184impl Default for hv_x64_fp_control_status_register__bindgen_ty_1__bindgen_ty_1 {
2185 fn default() -> Self {
2186 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
2187 unsafe {
2188 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
2189 s.assume_init()
2190 }
2191 }
2192}
2193#[test]
2194fn bindgen_test_layout_hv_x64_fp_control_status_register__bindgen_ty_1() {
2195 const UNINIT: ::std::mem::MaybeUninit<hv_x64_fp_control_status_register__bindgen_ty_1> =
2196 ::std::mem::MaybeUninit::uninit();
2197 let ptr = UNINIT.as_ptr();
2198 assert_eq!(
2199 ::std::mem::size_of::<hv_x64_fp_control_status_register__bindgen_ty_1>(),
2200 16usize,
2201 concat!(
2202 "Size of: ",
2203 stringify!(hv_x64_fp_control_status_register__bindgen_ty_1)
2204 )
2205 );
2206 assert_eq!(
2207 ::std::mem::align_of::<hv_x64_fp_control_status_register__bindgen_ty_1>(),
2208 1usize,
2209 concat!(
2210 "Alignment of ",
2211 stringify!(hv_x64_fp_control_status_register__bindgen_ty_1)
2212 )
2213 );
2214 assert_eq!(
2215 unsafe { ::std::ptr::addr_of!((*ptr).fp_control) as usize - ptr as usize },
2216 0usize,
2217 concat!(
2218 "Offset of field: ",
2219 stringify!(hv_x64_fp_control_status_register__bindgen_ty_1),
2220 "::",
2221 stringify!(fp_control)
2222 )
2223 );
2224 assert_eq!(
2225 unsafe { ::std::ptr::addr_of!((*ptr).fp_status) as usize - ptr as usize },
2226 2usize,
2227 concat!(
2228 "Offset of field: ",
2229 stringify!(hv_x64_fp_control_status_register__bindgen_ty_1),
2230 "::",
2231 stringify!(fp_status)
2232 )
2233 );
2234 assert_eq!(
2235 unsafe { ::std::ptr::addr_of!((*ptr).fp_tag) as usize - ptr as usize },
2236 4usize,
2237 concat!(
2238 "Offset of field: ",
2239 stringify!(hv_x64_fp_control_status_register__bindgen_ty_1),
2240 "::",
2241 stringify!(fp_tag)
2242 )
2243 );
2244 assert_eq!(
2245 unsafe { ::std::ptr::addr_of!((*ptr).reserved) as usize - ptr as usize },
2246 5usize,
2247 concat!(
2248 "Offset of field: ",
2249 stringify!(hv_x64_fp_control_status_register__bindgen_ty_1),
2250 "::",
2251 stringify!(reserved)
2252 )
2253 );
2254 assert_eq!(
2255 unsafe { ::std::ptr::addr_of!((*ptr).last_fp_op) as usize - ptr as usize },
2256 6usize,
2257 concat!(
2258 "Offset of field: ",
2259 stringify!(hv_x64_fp_control_status_register__bindgen_ty_1),
2260 "::",
2261 stringify!(last_fp_op)
2262 )
2263 );
2264}
2265impl Default for hv_x64_fp_control_status_register__bindgen_ty_1 {
2266 fn default() -> Self {
2267 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
2268 unsafe {
2269 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
2270 s.assume_init()
2271 }
2272 }
2273}
2274#[test]
2275fn bindgen_test_layout_hv_x64_fp_control_status_register() {
2276 const UNINIT: ::std::mem::MaybeUninit<hv_x64_fp_control_status_register> =
2277 ::std::mem::MaybeUninit::uninit();
2278 let ptr = UNINIT.as_ptr();
2279 assert_eq!(
2280 ::std::mem::size_of::<hv_x64_fp_control_status_register>(),
2281 16usize,
2282 concat!("Size of: ", stringify!(hv_x64_fp_control_status_register))
2283 );
2284 assert_eq!(
2285 ::std::mem::align_of::<hv_x64_fp_control_status_register>(),
2286 1usize,
2287 concat!(
2288 "Alignment of ",
2289 stringify!(hv_x64_fp_control_status_register)
2290 )
2291 );
2292 assert_eq!(
2293 unsafe { ::std::ptr::addr_of!((*ptr).as_uint128) as usize - ptr as usize },
2294 0usize,
2295 concat!(
2296 "Offset of field: ",
2297 stringify!(hv_x64_fp_control_status_register),
2298 "::",
2299 stringify!(as_uint128)
2300 )
2301 );
2302}
2303impl Default for hv_x64_fp_control_status_register {
2304 fn default() -> Self {
2305 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
2306 unsafe {
2307 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
2308 s.assume_init()
2309 }
2310 }
2311}
2312#[repr(C, packed)]
2313#[derive(Copy, Clone)]
2314pub union hv_x64_xmm_control_status_register {
2315 pub as_uint128: hv_u128,
2316 pub __bindgen_anon_1: hv_x64_xmm_control_status_register__bindgen_ty_1,
2317}
2318#[repr(C, packed)]
2319#[derive(Copy, Clone)]
2320pub struct hv_x64_xmm_control_status_register__bindgen_ty_1 {
2321 pub __bindgen_anon_1: hv_x64_xmm_control_status_register__bindgen_ty_1__bindgen_ty_1,
2322 pub xmm_status_control: __u32,
2323 pub xmm_status_control_mask: __u32,
2324}
2325#[repr(C)]
2326#[derive(Copy, Clone)]
2327pub union hv_x64_xmm_control_status_register__bindgen_ty_1__bindgen_ty_1 {
2328 pub last_fp_rdp: __u64,
2329 pub __bindgen_anon_1:
2330 hv_x64_xmm_control_status_register__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1,
2331}
2332#[repr(C, packed)]
2333#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
2334pub struct hv_x64_xmm_control_status_register__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1 {
2335 pub last_fp_dp: __u32,
2336 pub last_fp_ds: __u16,
2337 pub padding: __u16,
2338}
2339#[test]
2340fn bindgen_test_layout_hv_x64_xmm_control_status_register__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1(
2341) {
2342 const UNINIT: ::std::mem::MaybeUninit<
2343 hv_x64_xmm_control_status_register__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1,
2344 > = ::std::mem::MaybeUninit::uninit();
2345 let ptr = UNINIT.as_ptr();
2346 assert_eq!(
2347 ::std::mem::size_of::<
2348 hv_x64_xmm_control_status_register__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1,
2349 >(),
2350 8usize,
2351 concat!(
2352 "Size of: ",
2353 stringify!(
2354 hv_x64_xmm_control_status_register__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1
2355 )
2356 )
2357 );
2358 assert_eq!(
2359 ::std::mem::align_of::<
2360 hv_x64_xmm_control_status_register__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1,
2361 >(),
2362 1usize,
2363 concat!(
2364 "Alignment of ",
2365 stringify!(
2366 hv_x64_xmm_control_status_register__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1
2367 )
2368 )
2369 );
2370 assert_eq!(
2371 unsafe { ::std::ptr::addr_of!((*ptr).last_fp_dp) as usize - ptr as usize },
2372 0usize,
2373 concat!(
2374 "Offset of field: ",
2375 stringify!(
2376 hv_x64_xmm_control_status_register__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1
2377 ),
2378 "::",
2379 stringify!(last_fp_dp)
2380 )
2381 );
2382 assert_eq!(
2383 unsafe { ::std::ptr::addr_of!((*ptr).last_fp_ds) as usize - ptr as usize },
2384 4usize,
2385 concat!(
2386 "Offset of field: ",
2387 stringify!(
2388 hv_x64_xmm_control_status_register__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1
2389 ),
2390 "::",
2391 stringify!(last_fp_ds)
2392 )
2393 );
2394 assert_eq!(
2395 unsafe { ::std::ptr::addr_of!((*ptr).padding) as usize - ptr as usize },
2396 6usize,
2397 concat!(
2398 "Offset of field: ",
2399 stringify!(
2400 hv_x64_xmm_control_status_register__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1
2401 ),
2402 "::",
2403 stringify!(padding)
2404 )
2405 );
2406}
2407#[test]
2408fn bindgen_test_layout_hv_x64_xmm_control_status_register__bindgen_ty_1__bindgen_ty_1() {
2409 const UNINIT: ::std::mem::MaybeUninit<
2410 hv_x64_xmm_control_status_register__bindgen_ty_1__bindgen_ty_1,
2411 > = ::std::mem::MaybeUninit::uninit();
2412 let ptr = UNINIT.as_ptr();
2413 assert_eq!(
2414 ::std::mem::size_of::<hv_x64_xmm_control_status_register__bindgen_ty_1__bindgen_ty_1>(),
2415 8usize,
2416 concat!(
2417 "Size of: ",
2418 stringify!(hv_x64_xmm_control_status_register__bindgen_ty_1__bindgen_ty_1)
2419 )
2420 );
2421 assert_eq!(
2422 ::std::mem::align_of::<hv_x64_xmm_control_status_register__bindgen_ty_1__bindgen_ty_1>(),
2423 8usize,
2424 concat!(
2425 "Alignment of ",
2426 stringify!(hv_x64_xmm_control_status_register__bindgen_ty_1__bindgen_ty_1)
2427 )
2428 );
2429 assert_eq!(
2430 unsafe { ::std::ptr::addr_of!((*ptr).last_fp_rdp) as usize - ptr as usize },
2431 0usize,
2432 concat!(
2433 "Offset of field: ",
2434 stringify!(hv_x64_xmm_control_status_register__bindgen_ty_1__bindgen_ty_1),
2435 "::",
2436 stringify!(last_fp_rdp)
2437 )
2438 );
2439}
2440impl Default for hv_x64_xmm_control_status_register__bindgen_ty_1__bindgen_ty_1 {
2441 fn default() -> Self {
2442 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
2443 unsafe {
2444 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
2445 s.assume_init()
2446 }
2447 }
2448}
2449#[test]
2450fn bindgen_test_layout_hv_x64_xmm_control_status_register__bindgen_ty_1() {
2451 const UNINIT: ::std::mem::MaybeUninit<hv_x64_xmm_control_status_register__bindgen_ty_1> =
2452 ::std::mem::MaybeUninit::uninit();
2453 let ptr = UNINIT.as_ptr();
2454 assert_eq!(
2455 ::std::mem::size_of::<hv_x64_xmm_control_status_register__bindgen_ty_1>(),
2456 16usize,
2457 concat!(
2458 "Size of: ",
2459 stringify!(hv_x64_xmm_control_status_register__bindgen_ty_1)
2460 )
2461 );
2462 assert_eq!(
2463 ::std::mem::align_of::<hv_x64_xmm_control_status_register__bindgen_ty_1>(),
2464 1usize,
2465 concat!(
2466 "Alignment of ",
2467 stringify!(hv_x64_xmm_control_status_register__bindgen_ty_1)
2468 )
2469 );
2470 assert_eq!(
2471 unsafe { ::std::ptr::addr_of!((*ptr).xmm_status_control) as usize - ptr as usize },
2472 8usize,
2473 concat!(
2474 "Offset of field: ",
2475 stringify!(hv_x64_xmm_control_status_register__bindgen_ty_1),
2476 "::",
2477 stringify!(xmm_status_control)
2478 )
2479 );
2480 assert_eq!(
2481 unsafe { ::std::ptr::addr_of!((*ptr).xmm_status_control_mask) as usize - ptr as usize },
2482 12usize,
2483 concat!(
2484 "Offset of field: ",
2485 stringify!(hv_x64_xmm_control_status_register__bindgen_ty_1),
2486 "::",
2487 stringify!(xmm_status_control_mask)
2488 )
2489 );
2490}
2491impl Default for hv_x64_xmm_control_status_register__bindgen_ty_1 {
2492 fn default() -> Self {
2493 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
2494 unsafe {
2495 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
2496 s.assume_init()
2497 }
2498 }
2499}
2500#[test]
2501fn bindgen_test_layout_hv_x64_xmm_control_status_register() {
2502 const UNINIT: ::std::mem::MaybeUninit<hv_x64_xmm_control_status_register> =
2503 ::std::mem::MaybeUninit::uninit();
2504 let ptr = UNINIT.as_ptr();
2505 assert_eq!(
2506 ::std::mem::size_of::<hv_x64_xmm_control_status_register>(),
2507 16usize,
2508 concat!("Size of: ", stringify!(hv_x64_xmm_control_status_register))
2509 );
2510 assert_eq!(
2511 ::std::mem::align_of::<hv_x64_xmm_control_status_register>(),
2512 1usize,
2513 concat!(
2514 "Alignment of ",
2515 stringify!(hv_x64_xmm_control_status_register)
2516 )
2517 );
2518 assert_eq!(
2519 unsafe { ::std::ptr::addr_of!((*ptr).as_uint128) as usize - ptr as usize },
2520 0usize,
2521 concat!(
2522 "Offset of field: ",
2523 stringify!(hv_x64_xmm_control_status_register),
2524 "::",
2525 stringify!(as_uint128)
2526 )
2527 );
2528}
2529impl Default for hv_x64_xmm_control_status_register {
2530 fn default() -> Self {
2531 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
2532 unsafe {
2533 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
2534 s.assume_init()
2535 }
2536 }
2537}
2538#[repr(C, packed)]
2539#[derive(Copy, Clone)]
2540pub union hv_x64_fp_register {
2541 pub as_uint128: hv_u128,
2542 pub __bindgen_anon_1: hv_x64_fp_register__bindgen_ty_1,
2543}
2544#[repr(C, packed)]
2545#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
2546pub struct hv_x64_fp_register__bindgen_ty_1 {
2547 pub mantissa: __u64,
2548 pub _bitfield_align_1: [u8; 0],
2549 pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>,
2550}
2551#[test]
2552fn bindgen_test_layout_hv_x64_fp_register__bindgen_ty_1() {
2553 const UNINIT: ::std::mem::MaybeUninit<hv_x64_fp_register__bindgen_ty_1> =
2554 ::std::mem::MaybeUninit::uninit();
2555 let ptr = UNINIT.as_ptr();
2556 assert_eq!(
2557 ::std::mem::size_of::<hv_x64_fp_register__bindgen_ty_1>(),
2558 16usize,
2559 concat!("Size of: ", stringify!(hv_x64_fp_register__bindgen_ty_1))
2560 );
2561 assert_eq!(
2562 ::std::mem::align_of::<hv_x64_fp_register__bindgen_ty_1>(),
2563 1usize,
2564 concat!(
2565 "Alignment of ",
2566 stringify!(hv_x64_fp_register__bindgen_ty_1)
2567 )
2568 );
2569 assert_eq!(
2570 unsafe { ::std::ptr::addr_of!((*ptr).mantissa) as usize - ptr as usize },
2571 0usize,
2572 concat!(
2573 "Offset of field: ",
2574 stringify!(hv_x64_fp_register__bindgen_ty_1),
2575 "::",
2576 stringify!(mantissa)
2577 )
2578 );
2579}
2580impl hv_x64_fp_register__bindgen_ty_1 {
2581 #[inline]
2582 pub fn biased_exponent(&self) -> __u64 {
2583 unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 15u8) as u64) }
2584 }
2585 #[inline]
2586 pub fn set_biased_exponent(&mut self, val: __u64) {
2587 unsafe {
2588 let val: u64 = ::std::mem::transmute(val);
2589 self._bitfield_1.set(0usize, 15u8, val as u64)
2590 }
2591 }
2592 #[inline]
2593 pub fn sign(&self) -> __u64 {
2594 unsafe { ::std::mem::transmute(self._bitfield_1.get(15usize, 1u8) as u64) }
2595 }
2596 #[inline]
2597 pub fn set_sign(&mut self, val: __u64) {
2598 unsafe {
2599 let val: u64 = ::std::mem::transmute(val);
2600 self._bitfield_1.set(15usize, 1u8, val as u64)
2601 }
2602 }
2603 #[inline]
2604 pub fn reserved(&self) -> __u64 {
2605 unsafe { ::std::mem::transmute(self._bitfield_1.get(16usize, 48u8) as u64) }
2606 }
2607 #[inline]
2608 pub fn set_reserved(&mut self, val: __u64) {
2609 unsafe {
2610 let val: u64 = ::std::mem::transmute(val);
2611 self._bitfield_1.set(16usize, 48u8, val as u64)
2612 }
2613 }
2614 #[inline]
2615 pub fn new_bitfield_1(
2616 biased_exponent: __u64,
2617 sign: __u64,
2618 reserved: __u64,
2619 ) -> __BindgenBitfieldUnit<[u8; 8usize]> {
2620 let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 8usize]> = Default::default();
2621 __bindgen_bitfield_unit.set(0usize, 15u8, {
2622 let biased_exponent: u64 = unsafe { ::std::mem::transmute(biased_exponent) };
2623 biased_exponent as u64
2624 });
2625 __bindgen_bitfield_unit.set(15usize, 1u8, {
2626 let sign: u64 = unsafe { ::std::mem::transmute(sign) };
2627 sign as u64
2628 });
2629 __bindgen_bitfield_unit.set(16usize, 48u8, {
2630 let reserved: u64 = unsafe { ::std::mem::transmute(reserved) };
2631 reserved as u64
2632 });
2633 __bindgen_bitfield_unit
2634 }
2635}
2636#[test]
2637fn bindgen_test_layout_hv_x64_fp_register() {
2638 const UNINIT: ::std::mem::MaybeUninit<hv_x64_fp_register> = ::std::mem::MaybeUninit::uninit();
2639 let ptr = UNINIT.as_ptr();
2640 assert_eq!(
2641 ::std::mem::size_of::<hv_x64_fp_register>(),
2642 16usize,
2643 concat!("Size of: ", stringify!(hv_x64_fp_register))
2644 );
2645 assert_eq!(
2646 ::std::mem::align_of::<hv_x64_fp_register>(),
2647 1usize,
2648 concat!("Alignment of ", stringify!(hv_x64_fp_register))
2649 );
2650 assert_eq!(
2651 unsafe { ::std::ptr::addr_of!((*ptr).as_uint128) as usize - ptr as usize },
2652 0usize,
2653 concat!(
2654 "Offset of field: ",
2655 stringify!(hv_x64_fp_register),
2656 "::",
2657 stringify!(as_uint128)
2658 )
2659 );
2660}
2661impl Default for hv_x64_fp_register {
2662 fn default() -> Self {
2663 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
2664 unsafe {
2665 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
2666 s.assume_init()
2667 }
2668 }
2669}
2670#[repr(C)]
2671#[derive(Copy, Clone)]
2672pub union hv_x64_msr_npiep_config_contents {
2673 pub as_uint64: __u64,
2674 pub __bindgen_anon_1: hv_x64_msr_npiep_config_contents__bindgen_ty_1,
2675}
2676#[repr(C, packed)]
2677#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
2678pub struct hv_x64_msr_npiep_config_contents__bindgen_ty_1 {
2679 pub _bitfield_align_1: [u8; 0],
2680 pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>,
2681}
2682#[test]
2683fn bindgen_test_layout_hv_x64_msr_npiep_config_contents__bindgen_ty_1() {
2684 assert_eq!(
2685 ::std::mem::size_of::<hv_x64_msr_npiep_config_contents__bindgen_ty_1>(),
2686 8usize,
2687 concat!(
2688 "Size of: ",
2689 stringify!(hv_x64_msr_npiep_config_contents__bindgen_ty_1)
2690 )
2691 );
2692 assert_eq!(
2693 ::std::mem::align_of::<hv_x64_msr_npiep_config_contents__bindgen_ty_1>(),
2694 1usize,
2695 concat!(
2696 "Alignment of ",
2697 stringify!(hv_x64_msr_npiep_config_contents__bindgen_ty_1)
2698 )
2699 );
2700}
2701impl hv_x64_msr_npiep_config_contents__bindgen_ty_1 {
2702 #[inline]
2703 pub fn prevents_gdt(&self) -> __u64 {
2704 unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 1u8) as u64) }
2705 }
2706 #[inline]
2707 pub fn set_prevents_gdt(&mut self, val: __u64) {
2708 unsafe {
2709 let val: u64 = ::std::mem::transmute(val);
2710 self._bitfield_1.set(0usize, 1u8, val as u64)
2711 }
2712 }
2713 #[inline]
2714 pub fn prevents_idt(&self) -> __u64 {
2715 unsafe { ::std::mem::transmute(self._bitfield_1.get(1usize, 1u8) as u64) }
2716 }
2717 #[inline]
2718 pub fn set_prevents_idt(&mut self, val: __u64) {
2719 unsafe {
2720 let val: u64 = ::std::mem::transmute(val);
2721 self._bitfield_1.set(1usize, 1u8, val as u64)
2722 }
2723 }
2724 #[inline]
2725 pub fn prevents_ldt(&self) -> __u64 {
2726 unsafe { ::std::mem::transmute(self._bitfield_1.get(2usize, 1u8) as u64) }
2727 }
2728 #[inline]
2729 pub fn set_prevents_ldt(&mut self, val: __u64) {
2730 unsafe {
2731 let val: u64 = ::std::mem::transmute(val);
2732 self._bitfield_1.set(2usize, 1u8, val as u64)
2733 }
2734 }
2735 #[inline]
2736 pub fn prevents_tr(&self) -> __u64 {
2737 unsafe { ::std::mem::transmute(self._bitfield_1.get(3usize, 1u8) as u64) }
2738 }
2739 #[inline]
2740 pub fn set_prevents_tr(&mut self, val: __u64) {
2741 unsafe {
2742 let val: u64 = ::std::mem::transmute(val);
2743 self._bitfield_1.set(3usize, 1u8, val as u64)
2744 }
2745 }
2746 #[inline]
2747 pub fn reserved(&self) -> __u64 {
2748 unsafe { ::std::mem::transmute(self._bitfield_1.get(4usize, 60u8) as u64) }
2749 }
2750 #[inline]
2751 pub fn set_reserved(&mut self, val: __u64) {
2752 unsafe {
2753 let val: u64 = ::std::mem::transmute(val);
2754 self._bitfield_1.set(4usize, 60u8, val as u64)
2755 }
2756 }
2757 #[inline]
2758 pub fn new_bitfield_1(
2759 prevents_gdt: __u64,
2760 prevents_idt: __u64,
2761 prevents_ldt: __u64,
2762 prevents_tr: __u64,
2763 reserved: __u64,
2764 ) -> __BindgenBitfieldUnit<[u8; 8usize]> {
2765 let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 8usize]> = Default::default();
2766 __bindgen_bitfield_unit.set(0usize, 1u8, {
2767 let prevents_gdt: u64 = unsafe { ::std::mem::transmute(prevents_gdt) };
2768 prevents_gdt as u64
2769 });
2770 __bindgen_bitfield_unit.set(1usize, 1u8, {
2771 let prevents_idt: u64 = unsafe { ::std::mem::transmute(prevents_idt) };
2772 prevents_idt as u64
2773 });
2774 __bindgen_bitfield_unit.set(2usize, 1u8, {
2775 let prevents_ldt: u64 = unsafe { ::std::mem::transmute(prevents_ldt) };
2776 prevents_ldt as u64
2777 });
2778 __bindgen_bitfield_unit.set(3usize, 1u8, {
2779 let prevents_tr: u64 = unsafe { ::std::mem::transmute(prevents_tr) };
2780 prevents_tr as u64
2781 });
2782 __bindgen_bitfield_unit.set(4usize, 60u8, {
2783 let reserved: u64 = unsafe { ::std::mem::transmute(reserved) };
2784 reserved as u64
2785 });
2786 __bindgen_bitfield_unit
2787 }
2788}
2789#[test]
2790fn bindgen_test_layout_hv_x64_msr_npiep_config_contents() {
2791 const UNINIT: ::std::mem::MaybeUninit<hv_x64_msr_npiep_config_contents> =
2792 ::std::mem::MaybeUninit::uninit();
2793 let ptr = UNINIT.as_ptr();
2794 assert_eq!(
2795 ::std::mem::size_of::<hv_x64_msr_npiep_config_contents>(),
2796 8usize,
2797 concat!("Size of: ", stringify!(hv_x64_msr_npiep_config_contents))
2798 );
2799 assert_eq!(
2800 ::std::mem::align_of::<hv_x64_msr_npiep_config_contents>(),
2801 8usize,
2802 concat!(
2803 "Alignment of ",
2804 stringify!(hv_x64_msr_npiep_config_contents)
2805 )
2806 );
2807 assert_eq!(
2808 unsafe { ::std::ptr::addr_of!((*ptr).as_uint64) as usize - ptr as usize },
2809 0usize,
2810 concat!(
2811 "Offset of field: ",
2812 stringify!(hv_x64_msr_npiep_config_contents),
2813 "::",
2814 stringify!(as_uint64)
2815 )
2816 );
2817}
2818impl Default for hv_x64_msr_npiep_config_contents {
2819 fn default() -> Self {
2820 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
2821 unsafe {
2822 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
2823 s.assume_init()
2824 }
2825 }
2826}
2827#[repr(C, packed)]
2828#[derive(Copy, Clone)]
2829pub union hv_input_vtl {
2830 pub as_uint8: __u8,
2831 pub __bindgen_anon_1: hv_input_vtl__bindgen_ty_1,
2832}
2833#[repr(C, packed)]
2834#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
2835pub struct hv_input_vtl__bindgen_ty_1 {
2836 pub _bitfield_align_1: [u8; 0],
2837 pub _bitfield_1: __BindgenBitfieldUnit<[u8; 1usize]>,
2838}
2839#[test]
2840fn bindgen_test_layout_hv_input_vtl__bindgen_ty_1() {
2841 assert_eq!(
2842 ::std::mem::size_of::<hv_input_vtl__bindgen_ty_1>(),
2843 1usize,
2844 concat!("Size of: ", stringify!(hv_input_vtl__bindgen_ty_1))
2845 );
2846 assert_eq!(
2847 ::std::mem::align_of::<hv_input_vtl__bindgen_ty_1>(),
2848 1usize,
2849 concat!("Alignment of ", stringify!(hv_input_vtl__bindgen_ty_1))
2850 );
2851}
2852impl hv_input_vtl__bindgen_ty_1 {
2853 #[inline]
2854 pub fn target_vtl(&self) -> __u8 {
2855 unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 4u8) as u8) }
2856 }
2857 #[inline]
2858 pub fn set_target_vtl(&mut self, val: __u8) {
2859 unsafe {
2860 let val: u8 = ::std::mem::transmute(val);
2861 self._bitfield_1.set(0usize, 4u8, val as u64)
2862 }
2863 }
2864 #[inline]
2865 pub fn use_target_vtl(&self) -> __u8 {
2866 unsafe { ::std::mem::transmute(self._bitfield_1.get(4usize, 1u8) as u8) }
2867 }
2868 #[inline]
2869 pub fn set_use_target_vtl(&mut self, val: __u8) {
2870 unsafe {
2871 let val: u8 = ::std::mem::transmute(val);
2872 self._bitfield_1.set(4usize, 1u8, val as u64)
2873 }
2874 }
2875 #[inline]
2876 pub fn reserved_z(&self) -> __u8 {
2877 unsafe { ::std::mem::transmute(self._bitfield_1.get(5usize, 3u8) as u8) }
2878 }
2879 #[inline]
2880 pub fn set_reserved_z(&mut self, val: __u8) {
2881 unsafe {
2882 let val: u8 = ::std::mem::transmute(val);
2883 self._bitfield_1.set(5usize, 3u8, val as u64)
2884 }
2885 }
2886 #[inline]
2887 pub fn new_bitfield_1(
2888 target_vtl: __u8,
2889 use_target_vtl: __u8,
2890 reserved_z: __u8,
2891 ) -> __BindgenBitfieldUnit<[u8; 1usize]> {
2892 let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 1usize]> = Default::default();
2893 __bindgen_bitfield_unit.set(0usize, 4u8, {
2894 let target_vtl: u8 = unsafe { ::std::mem::transmute(target_vtl) };
2895 target_vtl as u64
2896 });
2897 __bindgen_bitfield_unit.set(4usize, 1u8, {
2898 let use_target_vtl: u8 = unsafe { ::std::mem::transmute(use_target_vtl) };
2899 use_target_vtl as u64
2900 });
2901 __bindgen_bitfield_unit.set(5usize, 3u8, {
2902 let reserved_z: u8 = unsafe { ::std::mem::transmute(reserved_z) };
2903 reserved_z as u64
2904 });
2905 __bindgen_bitfield_unit
2906 }
2907}
2908#[test]
2909fn bindgen_test_layout_hv_input_vtl() {
2910 const UNINIT: ::std::mem::MaybeUninit<hv_input_vtl> = ::std::mem::MaybeUninit::uninit();
2911 let ptr = UNINIT.as_ptr();
2912 assert_eq!(
2913 ::std::mem::size_of::<hv_input_vtl>(),
2914 1usize,
2915 concat!("Size of: ", stringify!(hv_input_vtl))
2916 );
2917 assert_eq!(
2918 ::std::mem::align_of::<hv_input_vtl>(),
2919 1usize,
2920 concat!("Alignment of ", stringify!(hv_input_vtl))
2921 );
2922 assert_eq!(
2923 unsafe { ::std::ptr::addr_of!((*ptr).as_uint8) as usize - ptr as usize },
2924 0usize,
2925 concat!(
2926 "Offset of field: ",
2927 stringify!(hv_input_vtl),
2928 "::",
2929 stringify!(as_uint8)
2930 )
2931 );
2932}
2933impl Default for hv_input_vtl {
2934 fn default() -> Self {
2935 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
2936 unsafe {
2937 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
2938 s.assume_init()
2939 }
2940 }
2941}
2942#[repr(C)]
2943#[derive(Copy, Clone)]
2944pub union hv_register_vsm_partition_config {
2945 pub as_u64: __u64,
2946 pub __bindgen_anon_1: hv_register_vsm_partition_config__bindgen_ty_1,
2947}
2948#[repr(C)]
2949#[repr(align(8))]
2950#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
2951pub struct hv_register_vsm_partition_config__bindgen_ty_1 {
2952 pub _bitfield_align_1: [u64; 0],
2953 pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>,
2954}
2955#[test]
2956fn bindgen_test_layout_hv_register_vsm_partition_config__bindgen_ty_1() {
2957 assert_eq!(
2958 ::std::mem::size_of::<hv_register_vsm_partition_config__bindgen_ty_1>(),
2959 8usize,
2960 concat!(
2961 "Size of: ",
2962 stringify!(hv_register_vsm_partition_config__bindgen_ty_1)
2963 )
2964 );
2965 assert_eq!(
2966 ::std::mem::align_of::<hv_register_vsm_partition_config__bindgen_ty_1>(),
2967 8usize,
2968 concat!(
2969 "Alignment of ",
2970 stringify!(hv_register_vsm_partition_config__bindgen_ty_1)
2971 )
2972 );
2973}
2974impl hv_register_vsm_partition_config__bindgen_ty_1 {
2975 #[inline]
2976 pub fn enable_vtl_protection(&self) -> __u64 {
2977 unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 1u8) as u64) }
2978 }
2979 #[inline]
2980 pub fn set_enable_vtl_protection(&mut self, val: __u64) {
2981 unsafe {
2982 let val: u64 = ::std::mem::transmute(val);
2983 self._bitfield_1.set(0usize, 1u8, val as u64)
2984 }
2985 }
2986 #[inline]
2987 pub fn default_vtl_protection_mask(&self) -> __u64 {
2988 unsafe { ::std::mem::transmute(self._bitfield_1.get(1usize, 4u8) as u64) }
2989 }
2990 #[inline]
2991 pub fn set_default_vtl_protection_mask(&mut self, val: __u64) {
2992 unsafe {
2993 let val: u64 = ::std::mem::transmute(val);
2994 self._bitfield_1.set(1usize, 4u8, val as u64)
2995 }
2996 }
2997 #[inline]
2998 pub fn zero_memory_on_reset(&self) -> __u64 {
2999 unsafe { ::std::mem::transmute(self._bitfield_1.get(5usize, 1u8) as u64) }
3000 }
3001 #[inline]
3002 pub fn set_zero_memory_on_reset(&mut self, val: __u64) {
3003 unsafe {
3004 let val: u64 = ::std::mem::transmute(val);
3005 self._bitfield_1.set(5usize, 1u8, val as u64)
3006 }
3007 }
3008 #[inline]
3009 pub fn deny_lower_vtl_startup(&self) -> __u64 {
3010 unsafe { ::std::mem::transmute(self._bitfield_1.get(6usize, 1u8) as u64) }
3011 }
3012 #[inline]
3013 pub fn set_deny_lower_vtl_startup(&mut self, val: __u64) {
3014 unsafe {
3015 let val: u64 = ::std::mem::transmute(val);
3016 self._bitfield_1.set(6usize, 1u8, val as u64)
3017 }
3018 }
3019 #[inline]
3020 pub fn intercept_acceptance(&self) -> __u64 {
3021 unsafe { ::std::mem::transmute(self._bitfield_1.get(7usize, 1u8) as u64) }
3022 }
3023 #[inline]
3024 pub fn set_intercept_acceptance(&mut self, val: __u64) {
3025 unsafe {
3026 let val: u64 = ::std::mem::transmute(val);
3027 self._bitfield_1.set(7usize, 1u8, val as u64)
3028 }
3029 }
3030 #[inline]
3031 pub fn intercept_enable_vtl_protection(&self) -> __u64 {
3032 unsafe { ::std::mem::transmute(self._bitfield_1.get(8usize, 1u8) as u64) }
3033 }
3034 #[inline]
3035 pub fn set_intercept_enable_vtl_protection(&mut self, val: __u64) {
3036 unsafe {
3037 let val: u64 = ::std::mem::transmute(val);
3038 self._bitfield_1.set(8usize, 1u8, val as u64)
3039 }
3040 }
3041 #[inline]
3042 pub fn intercept_vp_startup(&self) -> __u64 {
3043 unsafe { ::std::mem::transmute(self._bitfield_1.get(9usize, 1u8) as u64) }
3044 }
3045 #[inline]
3046 pub fn set_intercept_vp_startup(&mut self, val: __u64) {
3047 unsafe {
3048 let val: u64 = ::std::mem::transmute(val);
3049 self._bitfield_1.set(9usize, 1u8, val as u64)
3050 }
3051 }
3052 #[inline]
3053 pub fn intercept_cpuid_unimplemented(&self) -> __u64 {
3054 unsafe { ::std::mem::transmute(self._bitfield_1.get(10usize, 1u8) as u64) }
3055 }
3056 #[inline]
3057 pub fn set_intercept_cpuid_unimplemented(&mut self, val: __u64) {
3058 unsafe {
3059 let val: u64 = ::std::mem::transmute(val);
3060 self._bitfield_1.set(10usize, 1u8, val as u64)
3061 }
3062 }
3063 #[inline]
3064 pub fn intercept_unrecoverable_exception(&self) -> __u64 {
3065 unsafe { ::std::mem::transmute(self._bitfield_1.get(11usize, 1u8) as u64) }
3066 }
3067 #[inline]
3068 pub fn set_intercept_unrecoverable_exception(&mut self, val: __u64) {
3069 unsafe {
3070 let val: u64 = ::std::mem::transmute(val);
3071 self._bitfield_1.set(11usize, 1u8, val as u64)
3072 }
3073 }
3074 #[inline]
3075 pub fn intercept_page(&self) -> __u64 {
3076 unsafe { ::std::mem::transmute(self._bitfield_1.get(12usize, 1u8) as u64) }
3077 }
3078 #[inline]
3079 pub fn set_intercept_page(&mut self, val: __u64) {
3080 unsafe {
3081 let val: u64 = ::std::mem::transmute(val);
3082 self._bitfield_1.set(12usize, 1u8, val as u64)
3083 }
3084 }
3085 #[inline]
3086 pub fn intercept_restore_partition_time(&self) -> __u64 {
3087 unsafe { ::std::mem::transmute(self._bitfield_1.get(13usize, 1u8) as u64) }
3088 }
3089 #[inline]
3090 pub fn set_intercept_restore_partition_time(&mut self, val: __u64) {
3091 unsafe {
3092 let val: u64 = ::std::mem::transmute(val);
3093 self._bitfield_1.set(13usize, 1u8, val as u64)
3094 }
3095 }
3096 #[inline]
3097 pub fn intercept_not_present(&self) -> __u64 {
3098 unsafe { ::std::mem::transmute(self._bitfield_1.get(14usize, 1u8) as u64) }
3099 }
3100 #[inline]
3101 pub fn set_intercept_not_present(&mut self, val: __u64) {
3102 unsafe {
3103 let val: u64 = ::std::mem::transmute(val);
3104 self._bitfield_1.set(14usize, 1u8, val as u64)
3105 }
3106 }
3107 #[inline]
3108 pub fn mbz(&self) -> __u64 {
3109 unsafe { ::std::mem::transmute(self._bitfield_1.get(15usize, 49u8) as u64) }
3110 }
3111 #[inline]
3112 pub fn set_mbz(&mut self, val: __u64) {
3113 unsafe {
3114 let val: u64 = ::std::mem::transmute(val);
3115 self._bitfield_1.set(15usize, 49u8, val as u64)
3116 }
3117 }
3118 #[inline]
3119 pub fn new_bitfield_1(
3120 enable_vtl_protection: __u64,
3121 default_vtl_protection_mask: __u64,
3122 zero_memory_on_reset: __u64,
3123 deny_lower_vtl_startup: __u64,
3124 intercept_acceptance: __u64,
3125 intercept_enable_vtl_protection: __u64,
3126 intercept_vp_startup: __u64,
3127 intercept_cpuid_unimplemented: __u64,
3128 intercept_unrecoverable_exception: __u64,
3129 intercept_page: __u64,
3130 intercept_restore_partition_time: __u64,
3131 intercept_not_present: __u64,
3132 mbz: __u64,
3133 ) -> __BindgenBitfieldUnit<[u8; 8usize]> {
3134 let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 8usize]> = Default::default();
3135 __bindgen_bitfield_unit.set(0usize, 1u8, {
3136 let enable_vtl_protection: u64 =
3137 unsafe { ::std::mem::transmute(enable_vtl_protection) };
3138 enable_vtl_protection as u64
3139 });
3140 __bindgen_bitfield_unit.set(1usize, 4u8, {
3141 let default_vtl_protection_mask: u64 =
3142 unsafe { ::std::mem::transmute(default_vtl_protection_mask) };
3143 default_vtl_protection_mask as u64
3144 });
3145 __bindgen_bitfield_unit.set(5usize, 1u8, {
3146 let zero_memory_on_reset: u64 = unsafe { ::std::mem::transmute(zero_memory_on_reset) };
3147 zero_memory_on_reset as u64
3148 });
3149 __bindgen_bitfield_unit.set(6usize, 1u8, {
3150 let deny_lower_vtl_startup: u64 =
3151 unsafe { ::std::mem::transmute(deny_lower_vtl_startup) };
3152 deny_lower_vtl_startup as u64
3153 });
3154 __bindgen_bitfield_unit.set(7usize, 1u8, {
3155 let intercept_acceptance: u64 = unsafe { ::std::mem::transmute(intercept_acceptance) };
3156 intercept_acceptance as u64
3157 });
3158 __bindgen_bitfield_unit.set(8usize, 1u8, {
3159 let intercept_enable_vtl_protection: u64 =
3160 unsafe { ::std::mem::transmute(intercept_enable_vtl_protection) };
3161 intercept_enable_vtl_protection as u64
3162 });
3163 __bindgen_bitfield_unit.set(9usize, 1u8, {
3164 let intercept_vp_startup: u64 = unsafe { ::std::mem::transmute(intercept_vp_startup) };
3165 intercept_vp_startup as u64
3166 });
3167 __bindgen_bitfield_unit.set(10usize, 1u8, {
3168 let intercept_cpuid_unimplemented: u64 =
3169 unsafe { ::std::mem::transmute(intercept_cpuid_unimplemented) };
3170 intercept_cpuid_unimplemented as u64
3171 });
3172 __bindgen_bitfield_unit.set(11usize, 1u8, {
3173 let intercept_unrecoverable_exception: u64 =
3174 unsafe { ::std::mem::transmute(intercept_unrecoverable_exception) };
3175 intercept_unrecoverable_exception as u64
3176 });
3177 __bindgen_bitfield_unit.set(12usize, 1u8, {
3178 let intercept_page: u64 = unsafe { ::std::mem::transmute(intercept_page) };
3179 intercept_page as u64
3180 });
3181 __bindgen_bitfield_unit.set(13usize, 1u8, {
3182 let intercept_restore_partition_time: u64 =
3183 unsafe { ::std::mem::transmute(intercept_restore_partition_time) };
3184 intercept_restore_partition_time as u64
3185 });
3186 __bindgen_bitfield_unit.set(14usize, 1u8, {
3187 let intercept_not_present: u64 =
3188 unsafe { ::std::mem::transmute(intercept_not_present) };
3189 intercept_not_present as u64
3190 });
3191 __bindgen_bitfield_unit.set(15usize, 49u8, {
3192 let mbz: u64 = unsafe { ::std::mem::transmute(mbz) };
3193 mbz as u64
3194 });
3195 __bindgen_bitfield_unit
3196 }
3197}
3198#[test]
3199fn bindgen_test_layout_hv_register_vsm_partition_config() {
3200 const UNINIT: ::std::mem::MaybeUninit<hv_register_vsm_partition_config> =
3201 ::std::mem::MaybeUninit::uninit();
3202 let ptr = UNINIT.as_ptr();
3203 assert_eq!(
3204 ::std::mem::size_of::<hv_register_vsm_partition_config>(),
3205 8usize,
3206 concat!("Size of: ", stringify!(hv_register_vsm_partition_config))
3207 );
3208 assert_eq!(
3209 ::std::mem::align_of::<hv_register_vsm_partition_config>(),
3210 8usize,
3211 concat!(
3212 "Alignment of ",
3213 stringify!(hv_register_vsm_partition_config)
3214 )
3215 );
3216 assert_eq!(
3217 unsafe { ::std::ptr::addr_of!((*ptr).as_u64) as usize - ptr as usize },
3218 0usize,
3219 concat!(
3220 "Offset of field: ",
3221 stringify!(hv_register_vsm_partition_config),
3222 "::",
3223 stringify!(as_u64)
3224 )
3225 );
3226}
3227impl Default for hv_register_vsm_partition_config {
3228 fn default() -> Self {
3229 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
3230 unsafe {
3231 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
3232 s.assume_init()
3233 }
3234 }
3235}
3236pub const hv_register_name_HV_REGISTER_EXPLICIT_SUSPEND: hv_register_name = 0;
3237pub const hv_register_name_HV_REGISTER_INTERCEPT_SUSPEND: hv_register_name = 1;
3238pub const hv_register_name_HV_REGISTER_INSTRUCTION_EMULATION_HINTS: hv_register_name = 2;
3239pub const hv_register_name_HV_REGISTER_DISPATCH_SUSPEND: hv_register_name = 3;
3240pub const hv_register_name_HV_REGISTER_INTERNAL_ACTIVITY_STATE: hv_register_name = 4;
3241pub const hv_register_name_HV_REGISTER_HYPERVISOR_VERSION: hv_register_name = 256;
3242pub const hv_register_name_HV_REGISTER_PRIVILEGES_AND_FEATURES_INFO: hv_register_name = 512;
3243pub const hv_register_name_HV_REGISTER_FEATURES_INFO: hv_register_name = 513;
3244pub const hv_register_name_HV_REGISTER_IMPLEMENTATION_LIMITS_INFO: hv_register_name = 514;
3245pub const hv_register_name_HV_REGISTER_HARDWARE_FEATURES_INFO: hv_register_name = 515;
3246pub const hv_register_name_HV_REGISTER_CPU_MANAGEMENT_FEATURES_INFO: hv_register_name = 516;
3247pub const hv_register_name_HV_REGISTER_SVM_FEATURES_INFO: hv_register_name = 517;
3248pub const hv_register_name_HV_REGISTER_SKIP_LEVEL_FEATURES_INFO: hv_register_name = 518;
3249pub const hv_register_name_HV_REGISTER_NESTED_VIRT_FEATURES_INFO: hv_register_name = 519;
3250pub const hv_register_name_HV_REGISTER_IPT_FEATURES_INFO: hv_register_name = 520;
3251pub const hv_register_name_HV_REGISTER_GUEST_CRASH_P0: hv_register_name = 528;
3252pub const hv_register_name_HV_REGISTER_GUEST_CRASH_P1: hv_register_name = 529;
3253pub const hv_register_name_HV_REGISTER_GUEST_CRASH_P2: hv_register_name = 530;
3254pub const hv_register_name_HV_REGISTER_GUEST_CRASH_P3: hv_register_name = 531;
3255pub const hv_register_name_HV_REGISTER_GUEST_CRASH_P4: hv_register_name = 532;
3256pub const hv_register_name_HV_REGISTER_GUEST_CRASH_CTL: hv_register_name = 533;
3257pub const hv_register_name_HV_REGISTER_POWER_STATE_CONFIG_C1: hv_register_name = 544;
3258pub const hv_register_name_HV_REGISTER_POWER_STATE_TRIGGER_C1: hv_register_name = 545;
3259pub const hv_register_name_HV_REGISTER_POWER_STATE_CONFIG_C2: hv_register_name = 546;
3260pub const hv_register_name_HV_REGISTER_POWER_STATE_TRIGGER_C2: hv_register_name = 547;
3261pub const hv_register_name_HV_REGISTER_POWER_STATE_CONFIG_C3: hv_register_name = 548;
3262pub const hv_register_name_HV_REGISTER_POWER_STATE_TRIGGER_C3: hv_register_name = 549;
3263pub const hv_register_name_HV_REGISTER_PROCESSOR_CLOCK_FREQUENCY: hv_register_name = 576;
3264pub const hv_register_name_HV_REGISTER_INTERRUPT_CLOCK_FREQUENCY: hv_register_name = 577;
3265pub const hv_register_name_HV_REGISTER_GUEST_IDLE: hv_register_name = 592;
3266pub const hv_register_name_HV_REGISTER_DEBUG_DEVICE_OPTIONS: hv_register_name = 608;
3267pub const hv_register_name_HV_REGISTER_MEMORY_ZEROING_CONTROL: hv_register_name = 624;
3268pub const hv_register_name_HV_REGISTER_PENDING_EVENT0: hv_register_name = 65540;
3269pub const hv_register_name_HV_REGISTER_PENDING_EVENT1: hv_register_name = 65541;
3270pub const hv_register_name_HV_REGISTER_DELIVERABILITY_NOTIFICATIONS: hv_register_name = 65542;
3271pub const hv_register_name_HV_REGISTER_VP_RUNTIME: hv_register_name = 589824;
3272pub const hv_register_name_HV_REGISTER_GUEST_OS_ID: hv_register_name = 589826;
3273pub const hv_register_name_HV_REGISTER_VP_INDEX: hv_register_name = 589827;
3274pub const hv_register_name_HV_REGISTER_TIME_REF_COUNT: hv_register_name = 589828;
3275pub const hv_register_name_HV_REGISTER_CPU_MANAGEMENT_VERSION: hv_register_name = 589831;
3276pub const hv_register_name_HV_REGISTER_VP_ASSIST_PAGE: hv_register_name = 589843;
3277pub const hv_register_name_HV_REGISTER_VP_ROOT_SIGNAL_COUNT: hv_register_name = 589844;
3278pub const hv_register_name_HV_REGISTER_REFERENCE_TSC: hv_register_name = 589847;
3279pub const hv_register_name_HV_REGISTER_STATS_PARTITION_RETAIL: hv_register_name = 589856;
3280pub const hv_register_name_HV_REGISTER_STATS_PARTITION_INTERNAL: hv_register_name = 589857;
3281pub const hv_register_name_HV_REGISTER_STATS_VP_RETAIL: hv_register_name = 589858;
3282pub const hv_register_name_HV_REGISTER_STATS_VP_INTERNAL: hv_register_name = 589859;
3283pub const hv_register_name_HV_REGISTER_NESTED_VP_INDEX: hv_register_name = 593923;
3284pub const hv_register_name_HV_REGISTER_SINT0: hv_register_name = 655360;
3285pub const hv_register_name_HV_REGISTER_SINT1: hv_register_name = 655361;
3286pub const hv_register_name_HV_REGISTER_SINT2: hv_register_name = 655362;
3287pub const hv_register_name_HV_REGISTER_SINT3: hv_register_name = 655363;
3288pub const hv_register_name_HV_REGISTER_SINT4: hv_register_name = 655364;
3289pub const hv_register_name_HV_REGISTER_SINT5: hv_register_name = 655365;
3290pub const hv_register_name_HV_REGISTER_SINT6: hv_register_name = 655366;
3291pub const hv_register_name_HV_REGISTER_SINT7: hv_register_name = 655367;
3292pub const hv_register_name_HV_REGISTER_SINT8: hv_register_name = 655368;
3293pub const hv_register_name_HV_REGISTER_SINT9: hv_register_name = 655369;
3294pub const hv_register_name_HV_REGISTER_SINT10: hv_register_name = 655370;
3295pub const hv_register_name_HV_REGISTER_SINT11: hv_register_name = 655371;
3296pub const hv_register_name_HV_REGISTER_SINT12: hv_register_name = 655372;
3297pub const hv_register_name_HV_REGISTER_SINT13: hv_register_name = 655373;
3298pub const hv_register_name_HV_REGISTER_SINT14: hv_register_name = 655374;
3299pub const hv_register_name_HV_REGISTER_SINT15: hv_register_name = 655375;
3300pub const hv_register_name_HV_REGISTER_SCONTROL: hv_register_name = 655376;
3301pub const hv_register_name_HV_REGISTER_SVERSION: hv_register_name = 655377;
3302pub const hv_register_name_HV_REGISTER_SIEFP: hv_register_name = 655378;
3303pub const hv_register_name_HV_REGISTER_SIMP: hv_register_name = 655379;
3304pub const hv_register_name_HV_REGISTER_EOM: hv_register_name = 655380;
3305pub const hv_register_name_HV_REGISTER_SIRBP: hv_register_name = 655381;
3306pub const hv_register_name_HV_REGISTER_NESTED_SINT0: hv_register_name = 659456;
3307pub const hv_register_name_HV_REGISTER_NESTED_SINT1: hv_register_name = 659457;
3308pub const hv_register_name_HV_REGISTER_NESTED_SINT2: hv_register_name = 659458;
3309pub const hv_register_name_HV_REGISTER_NESTED_SINT3: hv_register_name = 659459;
3310pub const hv_register_name_HV_REGISTER_NESTED_SINT4: hv_register_name = 659460;
3311pub const hv_register_name_HV_REGISTER_NESTED_SINT5: hv_register_name = 659461;
3312pub const hv_register_name_HV_REGISTER_NESTED_SINT6: hv_register_name = 659462;
3313pub const hv_register_name_HV_REGISTER_NESTED_SINT7: hv_register_name = 659463;
3314pub const hv_register_name_HV_REGISTER_NESTED_SINT8: hv_register_name = 659464;
3315pub const hv_register_name_HV_REGISTER_NESTED_SINT9: hv_register_name = 659465;
3316pub const hv_register_name_HV_REGISTER_NESTED_SINT10: hv_register_name = 659466;
3317pub const hv_register_name_HV_REGISTER_NESTED_SINT11: hv_register_name = 659467;
3318pub const hv_register_name_HV_REGISTER_NESTED_SINT12: hv_register_name = 659468;
3319pub const hv_register_name_HV_REGISTER_NESTED_SINT13: hv_register_name = 659469;
3320pub const hv_register_name_HV_REGISTER_NESTED_SINT14: hv_register_name = 659470;
3321pub const hv_register_name_HV_REGISTER_NESTED_SINT15: hv_register_name = 659471;
3322pub const hv_register_name_HV_REGISTER_NESTED_SCONTROL: hv_register_name = 659472;
3323pub const hv_register_name_HV_REGISTER_NESTED_SVERSION: hv_register_name = 659473;
3324pub const hv_register_name_HV_REGISTER_NESTED_SIFP: hv_register_name = 659474;
3325pub const hv_register_name_HV_REGISTER_NESTED_SIPP: hv_register_name = 659475;
3326pub const hv_register_name_HV_REGISTER_NESTED_EOM: hv_register_name = 659476;
3327pub const hv_register_name_HV_REGISTER_NESTED_SIRBP: hv_register_name = 659477;
3328pub const hv_register_name_HV_REGISTER_STIMER0_CONFIG: hv_register_name = 720896;
3329pub const hv_register_name_HV_REGISTER_STIMER0_COUNT: hv_register_name = 720897;
3330pub const hv_register_name_HV_REGISTER_STIMER1_CONFIG: hv_register_name = 720898;
3331pub const hv_register_name_HV_REGISTER_STIMER1_COUNT: hv_register_name = 720899;
3332pub const hv_register_name_HV_REGISTER_STIMER2_CONFIG: hv_register_name = 720900;
3333pub const hv_register_name_HV_REGISTER_STIMER2_COUNT: hv_register_name = 720901;
3334pub const hv_register_name_HV_REGISTER_STIMER3_CONFIG: hv_register_name = 720902;
3335pub const hv_register_name_HV_REGISTER_STIMER3_COUNT: hv_register_name = 720903;
3336pub const hv_register_name_HV_REGISTER_STIME_UNHALTED_TIMER_CONFIG: hv_register_name = 721152;
3337pub const hv_register_name_HV_REGISTER_STIME_UNHALTED_TIMER_COUNT: hv_register_name = 721153;
3338pub const hv_register_name_HV_REGISTER_VSM_CODE_PAGE_OFFSETS: hv_register_name = 851970;
3339pub const hv_register_name_HV_REGISTER_VSM_VP_STATUS: hv_register_name = 851971;
3340pub const hv_register_name_HV_REGISTER_VSM_PARTITION_STATUS: hv_register_name = 851972;
3341pub const hv_register_name_HV_REGISTER_VSM_VINA: hv_register_name = 851973;
3342pub const hv_register_name_HV_REGISTER_VSM_CAPABILITIES: hv_register_name = 851974;
3343pub const hv_register_name_HV_REGISTER_VSM_PARTITION_CONFIG: hv_register_name = 851975;
3344pub const hv_register_name_HV_REGISTER_VSM_VP_SECURE_CONFIG_VTL0: hv_register_name = 851984;
3345pub const hv_register_name_HV_REGISTER_VSM_VP_SECURE_CONFIG_VTL1: hv_register_name = 851985;
3346pub const hv_register_name_HV_REGISTER_VSM_VP_SECURE_CONFIG_VTL2: hv_register_name = 851986;
3347pub const hv_register_name_HV_REGISTER_VSM_VP_SECURE_CONFIG_VTL3: hv_register_name = 851987;
3348pub const hv_register_name_HV_REGISTER_VSM_VP_SECURE_CONFIG_VTL4: hv_register_name = 851988;
3349pub const hv_register_name_HV_REGISTER_VSM_VP_SECURE_CONFIG_VTL5: hv_register_name = 851989;
3350pub const hv_register_name_HV_REGISTER_VSM_VP_SECURE_CONFIG_VTL6: hv_register_name = 851990;
3351pub const hv_register_name_HV_REGISTER_VSM_VP_SECURE_CONFIG_VTL7: hv_register_name = 851991;
3352pub const hv_register_name_HV_REGISTER_VSM_VP_SECURE_CONFIG_VTL8: hv_register_name = 851992;
3353pub const hv_register_name_HV_REGISTER_VSM_VP_SECURE_CONFIG_VTL9: hv_register_name = 851993;
3354pub const hv_register_name_HV_REGISTER_VSM_VP_SECURE_CONFIG_VTL10: hv_register_name = 851994;
3355pub const hv_register_name_HV_REGISTER_VSM_VP_SECURE_CONFIG_VTL11: hv_register_name = 851995;
3356pub const hv_register_name_HV_REGISTER_VSM_VP_SECURE_CONFIG_VTL12: hv_register_name = 851996;
3357pub const hv_register_name_HV_REGISTER_VSM_VP_SECURE_CONFIG_VTL13: hv_register_name = 851997;
3358pub const hv_register_name_HV_REGISTER_VSM_VP_SECURE_CONFIG_VTL14: hv_register_name = 851998;
3359pub const hv_register_name_HV_REGISTER_VSM_VP_WAIT_FOR_TLB_LOCK: hv_register_name = 852000;
3360pub const hv_register_name_HV_REGISTER_ISOLATION_CAPABILITIES: hv_register_name = 852224;
3361pub const hv_register_name_HV_REGISTER_PENDING_INTERRUPTION: hv_register_name = 65538;
3362pub const hv_register_name_HV_REGISTER_INTERRUPT_STATE: hv_register_name = 65539;
3363pub const hv_register_name_HV_X64_REGISTER_DELIVERABILITY_NOTIFICATIONS: hv_register_name = 65542;
3364pub const hv_register_name_HV_X64_REGISTER_PENDING_DEBUG_EXCEPTION: hv_register_name = 65543;
3365pub const hv_register_name_HV_X64_REGISTER_RAX: hv_register_name = 131072;
3366pub const hv_register_name_HV_X64_REGISTER_RCX: hv_register_name = 131073;
3367pub const hv_register_name_HV_X64_REGISTER_RDX: hv_register_name = 131074;
3368pub const hv_register_name_HV_X64_REGISTER_RBX: hv_register_name = 131075;
3369pub const hv_register_name_HV_X64_REGISTER_RSP: hv_register_name = 131076;
3370pub const hv_register_name_HV_X64_REGISTER_RBP: hv_register_name = 131077;
3371pub const hv_register_name_HV_X64_REGISTER_RSI: hv_register_name = 131078;
3372pub const hv_register_name_HV_X64_REGISTER_RDI: hv_register_name = 131079;
3373pub const hv_register_name_HV_X64_REGISTER_R8: hv_register_name = 131080;
3374pub const hv_register_name_HV_X64_REGISTER_R9: hv_register_name = 131081;
3375pub const hv_register_name_HV_X64_REGISTER_R10: hv_register_name = 131082;
3376pub const hv_register_name_HV_X64_REGISTER_R11: hv_register_name = 131083;
3377pub const hv_register_name_HV_X64_REGISTER_R12: hv_register_name = 131084;
3378pub const hv_register_name_HV_X64_REGISTER_R13: hv_register_name = 131085;
3379pub const hv_register_name_HV_X64_REGISTER_R14: hv_register_name = 131086;
3380pub const hv_register_name_HV_X64_REGISTER_R15: hv_register_name = 131087;
3381pub const hv_register_name_HV_X64_REGISTER_RIP: hv_register_name = 131088;
3382pub const hv_register_name_HV_X64_REGISTER_RFLAGS: hv_register_name = 131089;
3383pub const hv_register_name_HV_X64_REGISTER_XMM0: hv_register_name = 196608;
3384pub const hv_register_name_HV_X64_REGISTER_XMM1: hv_register_name = 196609;
3385pub const hv_register_name_HV_X64_REGISTER_XMM2: hv_register_name = 196610;
3386pub const hv_register_name_HV_X64_REGISTER_XMM3: hv_register_name = 196611;
3387pub const hv_register_name_HV_X64_REGISTER_XMM4: hv_register_name = 196612;
3388pub const hv_register_name_HV_X64_REGISTER_XMM5: hv_register_name = 196613;
3389pub const hv_register_name_HV_X64_REGISTER_XMM6: hv_register_name = 196614;
3390pub const hv_register_name_HV_X64_REGISTER_XMM7: hv_register_name = 196615;
3391pub const hv_register_name_HV_X64_REGISTER_XMM8: hv_register_name = 196616;
3392pub const hv_register_name_HV_X64_REGISTER_XMM9: hv_register_name = 196617;
3393pub const hv_register_name_HV_X64_REGISTER_XMM10: hv_register_name = 196618;
3394pub const hv_register_name_HV_X64_REGISTER_XMM11: hv_register_name = 196619;
3395pub const hv_register_name_HV_X64_REGISTER_XMM12: hv_register_name = 196620;
3396pub const hv_register_name_HV_X64_REGISTER_XMM13: hv_register_name = 196621;
3397pub const hv_register_name_HV_X64_REGISTER_XMM14: hv_register_name = 196622;
3398pub const hv_register_name_HV_X64_REGISTER_XMM15: hv_register_name = 196623;
3399pub const hv_register_name_HV_X64_REGISTER_FP_MMX0: hv_register_name = 196624;
3400pub const hv_register_name_HV_X64_REGISTER_FP_MMX1: hv_register_name = 196625;
3401pub const hv_register_name_HV_X64_REGISTER_FP_MMX2: hv_register_name = 196626;
3402pub const hv_register_name_HV_X64_REGISTER_FP_MMX3: hv_register_name = 196627;
3403pub const hv_register_name_HV_X64_REGISTER_FP_MMX4: hv_register_name = 196628;
3404pub const hv_register_name_HV_X64_REGISTER_FP_MMX5: hv_register_name = 196629;
3405pub const hv_register_name_HV_X64_REGISTER_FP_MMX6: hv_register_name = 196630;
3406pub const hv_register_name_HV_X64_REGISTER_FP_MMX7: hv_register_name = 196631;
3407pub const hv_register_name_HV_X64_REGISTER_FP_CONTROL_STATUS: hv_register_name = 196632;
3408pub const hv_register_name_HV_X64_REGISTER_XMM_CONTROL_STATUS: hv_register_name = 196633;
3409pub const hv_register_name_HV_X64_REGISTER_CR0: hv_register_name = 262144;
3410pub const hv_register_name_HV_X64_REGISTER_CR2: hv_register_name = 262145;
3411pub const hv_register_name_HV_X64_REGISTER_CR3: hv_register_name = 262146;
3412pub const hv_register_name_HV_X64_REGISTER_CR4: hv_register_name = 262147;
3413pub const hv_register_name_HV_X64_REGISTER_CR8: hv_register_name = 262148;
3414pub const hv_register_name_HV_X64_REGISTER_XFEM: hv_register_name = 262149;
3415pub const hv_register_name_HV_X64_REGISTER_INTERMEDIATE_CR0: hv_register_name = 266240;
3416pub const hv_register_name_HV_X64_REGISTER_INTERMEDIATE_CR4: hv_register_name = 266243;
3417pub const hv_register_name_HV_X64_REGISTER_INTERMEDIATE_CR8: hv_register_name = 266244;
3418pub const hv_register_name_HV_X64_REGISTER_DR0: hv_register_name = 327680;
3419pub const hv_register_name_HV_X64_REGISTER_DR1: hv_register_name = 327681;
3420pub const hv_register_name_HV_X64_REGISTER_DR2: hv_register_name = 327682;
3421pub const hv_register_name_HV_X64_REGISTER_DR3: hv_register_name = 327683;
3422pub const hv_register_name_HV_X64_REGISTER_DR6: hv_register_name = 327684;
3423pub const hv_register_name_HV_X64_REGISTER_DR7: hv_register_name = 327685;
3424pub const hv_register_name_HV_X64_REGISTER_ES: hv_register_name = 393216;
3425pub const hv_register_name_HV_X64_REGISTER_CS: hv_register_name = 393217;
3426pub const hv_register_name_HV_X64_REGISTER_SS: hv_register_name = 393218;
3427pub const hv_register_name_HV_X64_REGISTER_DS: hv_register_name = 393219;
3428pub const hv_register_name_HV_X64_REGISTER_FS: hv_register_name = 393220;
3429pub const hv_register_name_HV_X64_REGISTER_GS: hv_register_name = 393221;
3430pub const hv_register_name_HV_X64_REGISTER_LDTR: hv_register_name = 393222;
3431pub const hv_register_name_HV_X64_REGISTER_TR: hv_register_name = 393223;
3432pub const hv_register_name_HV_X64_REGISTER_IDTR: hv_register_name = 458752;
3433pub const hv_register_name_HV_X64_REGISTER_GDTR: hv_register_name = 458753;
3434pub const hv_register_name_HV_X64_REGISTER_TSC: hv_register_name = 524288;
3435pub const hv_register_name_HV_X64_REGISTER_EFER: hv_register_name = 524289;
3436pub const hv_register_name_HV_X64_REGISTER_KERNEL_GS_BASE: hv_register_name = 524290;
3437pub const hv_register_name_HV_X64_REGISTER_APIC_BASE: hv_register_name = 524291;
3438pub const hv_register_name_HV_X64_REGISTER_PAT: hv_register_name = 524292;
3439pub const hv_register_name_HV_X64_REGISTER_SYSENTER_CS: hv_register_name = 524293;
3440pub const hv_register_name_HV_X64_REGISTER_SYSENTER_EIP: hv_register_name = 524294;
3441pub const hv_register_name_HV_X64_REGISTER_SYSENTER_ESP: hv_register_name = 524295;
3442pub const hv_register_name_HV_X64_REGISTER_STAR: hv_register_name = 524296;
3443pub const hv_register_name_HV_X64_REGISTER_LSTAR: hv_register_name = 524297;
3444pub const hv_register_name_HV_X64_REGISTER_CSTAR: hv_register_name = 524298;
3445pub const hv_register_name_HV_X64_REGISTER_SFMASK: hv_register_name = 524299;
3446pub const hv_register_name_HV_X64_REGISTER_INITIAL_APIC_ID: hv_register_name = 524300;
3447pub const hv_register_name_HV_X64_REGISTER_MSR_MTRR_CAP: hv_register_name = 524301;
3448pub const hv_register_name_HV_X64_REGISTER_MSR_MTRR_DEF_TYPE: hv_register_name = 524302;
3449pub const hv_register_name_HV_X64_REGISTER_MSR_MTRR_PHYS_BASE0: hv_register_name = 524304;
3450pub const hv_register_name_HV_X64_REGISTER_MSR_MTRR_PHYS_BASE1: hv_register_name = 524305;
3451pub const hv_register_name_HV_X64_REGISTER_MSR_MTRR_PHYS_BASE2: hv_register_name = 524306;
3452pub const hv_register_name_HV_X64_REGISTER_MSR_MTRR_PHYS_BASE3: hv_register_name = 524307;
3453pub const hv_register_name_HV_X64_REGISTER_MSR_MTRR_PHYS_BASE4: hv_register_name = 524308;
3454pub const hv_register_name_HV_X64_REGISTER_MSR_MTRR_PHYS_BASE5: hv_register_name = 524309;
3455pub const hv_register_name_HV_X64_REGISTER_MSR_MTRR_PHYS_BASE6: hv_register_name = 524310;
3456pub const hv_register_name_HV_X64_REGISTER_MSR_MTRR_PHYS_BASE7: hv_register_name = 524311;
3457pub const hv_register_name_HV_X64_REGISTER_MSR_MTRR_PHYS_BASE8: hv_register_name = 524312;
3458pub const hv_register_name_HV_X64_REGISTER_MSR_MTRR_PHYS_BASE9: hv_register_name = 524313;
3459pub const hv_register_name_HV_X64_REGISTER_MSR_MTRR_PHYS_BASEA: hv_register_name = 524314;
3460pub const hv_register_name_HV_X64_REGISTER_MSR_MTRR_PHYS_BASEB: hv_register_name = 524315;
3461pub const hv_register_name_HV_X64_REGISTER_MSR_MTRR_PHYS_BASEC: hv_register_name = 524316;
3462pub const hv_register_name_HV_X64_REGISTER_MSR_MTRR_PHYS_BASED: hv_register_name = 524317;
3463pub const hv_register_name_HV_X64_REGISTER_MSR_MTRR_PHYS_BASEE: hv_register_name = 524318;
3464pub const hv_register_name_HV_X64_REGISTER_MSR_MTRR_PHYS_BASEF: hv_register_name = 524319;
3465pub const hv_register_name_HV_X64_REGISTER_MSR_MTRR_PHYS_MASK0: hv_register_name = 524352;
3466pub const hv_register_name_HV_X64_REGISTER_MSR_MTRR_PHYS_MASK1: hv_register_name = 524353;
3467pub const hv_register_name_HV_X64_REGISTER_MSR_MTRR_PHYS_MASK2: hv_register_name = 524354;
3468pub const hv_register_name_HV_X64_REGISTER_MSR_MTRR_PHYS_MASK3: hv_register_name = 524355;
3469pub const hv_register_name_HV_X64_REGISTER_MSR_MTRR_PHYS_MASK4: hv_register_name = 524356;
3470pub const hv_register_name_HV_X64_REGISTER_MSR_MTRR_PHYS_MASK5: hv_register_name = 524357;
3471pub const hv_register_name_HV_X64_REGISTER_MSR_MTRR_PHYS_MASK6: hv_register_name = 524358;
3472pub const hv_register_name_HV_X64_REGISTER_MSR_MTRR_PHYS_MASK7: hv_register_name = 524359;
3473pub const hv_register_name_HV_X64_REGISTER_MSR_MTRR_PHYS_MASK8: hv_register_name = 524360;
3474pub const hv_register_name_HV_X64_REGISTER_MSR_MTRR_PHYS_MASK9: hv_register_name = 524361;
3475pub const hv_register_name_HV_X64_REGISTER_MSR_MTRR_PHYS_MASKA: hv_register_name = 524362;
3476pub const hv_register_name_HV_X64_REGISTER_MSR_MTRR_PHYS_MASKB: hv_register_name = 524363;
3477pub const hv_register_name_HV_X64_REGISTER_MSR_MTRR_PHYS_MASKC: hv_register_name = 524364;
3478pub const hv_register_name_HV_X64_REGISTER_MSR_MTRR_PHYS_MASKD: hv_register_name = 524365;
3479pub const hv_register_name_HV_X64_REGISTER_MSR_MTRR_PHYS_MASKE: hv_register_name = 524366;
3480pub const hv_register_name_HV_X64_REGISTER_MSR_MTRR_PHYS_MASKF: hv_register_name = 524367;
3481pub const hv_register_name_HV_X64_REGISTER_MSR_MTRR_FIX64K00000: hv_register_name = 524400;
3482pub const hv_register_name_HV_X64_REGISTER_MSR_MTRR_FIX16K80000: hv_register_name = 524401;
3483pub const hv_register_name_HV_X64_REGISTER_MSR_MTRR_FIX16KA0000: hv_register_name = 524402;
3484pub const hv_register_name_HV_X64_REGISTER_MSR_MTRR_FIX4KC0000: hv_register_name = 524403;
3485pub const hv_register_name_HV_X64_REGISTER_MSR_MTRR_FIX4KC8000: hv_register_name = 524404;
3486pub const hv_register_name_HV_X64_REGISTER_MSR_MTRR_FIX4KD0000: hv_register_name = 524405;
3487pub const hv_register_name_HV_X64_REGISTER_MSR_MTRR_FIX4KD8000: hv_register_name = 524406;
3488pub const hv_register_name_HV_X64_REGISTER_MSR_MTRR_FIX4KE0000: hv_register_name = 524407;
3489pub const hv_register_name_HV_X64_REGISTER_MSR_MTRR_FIX4KE8000: hv_register_name = 524408;
3490pub const hv_register_name_HV_X64_REGISTER_MSR_MTRR_FIX4KF0000: hv_register_name = 524409;
3491pub const hv_register_name_HV_X64_REGISTER_MSR_MTRR_FIX4KF8000: hv_register_name = 524410;
3492pub const hv_register_name_HV_X64_REGISTER_TSC_AUX: hv_register_name = 524411;
3493pub const hv_register_name_HV_X64_REGISTER_BNDCFGS: hv_register_name = 524412;
3494pub const hv_register_name_HV_X64_REGISTER_DEBUG_CTL: hv_register_name = 524413;
3495pub const hv_register_name_HV_X64_REGISTER_AVAILABLE0008007E: hv_register_name = 524414;
3496pub const hv_register_name_HV_X64_REGISTER_AVAILABLE0008007F: hv_register_name = 524415;
3497pub const hv_register_name_HV_X64_REGISTER_SGX_LAUNCH_CONTROL0: hv_register_name = 524416;
3498pub const hv_register_name_HV_X64_REGISTER_SGX_LAUNCH_CONTROL1: hv_register_name = 524417;
3499pub const hv_register_name_HV_X64_REGISTER_SGX_LAUNCH_CONTROL2: hv_register_name = 524418;
3500pub const hv_register_name_HV_X64_REGISTER_SGX_LAUNCH_CONTROL3: hv_register_name = 524419;
3501pub const hv_register_name_HV_X64_REGISTER_SPEC_CTRL: hv_register_name = 524420;
3502pub const hv_register_name_HV_X64_REGISTER_PRED_CMD: hv_register_name = 524421;
3503pub const hv_register_name_HV_X64_REGISTER_VIRT_SPEC_CTRL: hv_register_name = 524422;
3504pub const hv_register_name_HV_X64_REGISTER_TSC_ADJUST: hv_register_name = 524438;
3505pub const hv_register_name_HV_X64_REGISTER_MSR_IA32_MISC_ENABLE: hv_register_name = 524448;
3506pub const hv_register_name_HV_X64_REGISTER_IA32_FEATURE_CONTROL: hv_register_name = 524449;
3507pub const hv_register_name_HV_X64_REGISTER_IA32_VMX_BASIC: hv_register_name = 524450;
3508pub const hv_register_name_HV_X64_REGISTER_IA32_VMX_PINBASED_CTLS: hv_register_name = 524451;
3509pub const hv_register_name_HV_X64_REGISTER_IA32_VMX_PROCBASED_CTLS: hv_register_name = 524452;
3510pub const hv_register_name_HV_X64_REGISTER_IA32_VMX_EXIT_CTLS: hv_register_name = 524453;
3511pub const hv_register_name_HV_X64_REGISTER_IA32_VMX_ENTRY_CTLS: hv_register_name = 524454;
3512pub const hv_register_name_HV_X64_REGISTER_IA32_VMX_MISC: hv_register_name = 524455;
3513pub const hv_register_name_HV_X64_REGISTER_IA32_VMX_CR0_FIXED0: hv_register_name = 524456;
3514pub const hv_register_name_HV_X64_REGISTER_IA32_VMX_CR0_FIXED1: hv_register_name = 524457;
3515pub const hv_register_name_HV_X64_REGISTER_IA32_VMX_CR4_FIXED0: hv_register_name = 524458;
3516pub const hv_register_name_HV_X64_REGISTER_IA32_VMX_CR4_FIXED1: hv_register_name = 524459;
3517pub const hv_register_name_HV_X64_REGISTER_IA32_VMX_VMCS_ENUM: hv_register_name = 524460;
3518pub const hv_register_name_HV_X64_REGISTER_IA32_VMX_PROCBASED_CTLS2: hv_register_name = 524461;
3519pub const hv_register_name_HV_X64_REGISTER_IA32_VMX_EPT_VPID_CAP: hv_register_name = 524462;
3520pub const hv_register_name_HV_X64_REGISTER_IA32_VMX_TRUE_PINBASED_CTLS: hv_register_name = 524463;
3521pub const hv_register_name_HV_X64_REGISTER_IA32_VMX_TRUE_PROCBASED_CTLS: hv_register_name = 524464;
3522pub const hv_register_name_HV_X64_REGISTER_IA32_VMX_TRUE_EXIT_CTLS: hv_register_name = 524465;
3523pub const hv_register_name_HV_X64_REGISTER_IA32_VMX_TRUE_ENTRY_CTLS: hv_register_name = 524466;
3524pub const hv_register_name_HV_X64_REGISTER_PERF_GLOBAL_CTRL: hv_register_name = 528384;
3525pub const hv_register_name_HV_X64_REGISTER_PERF_GLOBAL_STATUS: hv_register_name = 528385;
3526pub const hv_register_name_HV_X64_REGISTER_PERF_GLOBAL_IN_USE: hv_register_name = 528386;
3527pub const hv_register_name_HV_X64_REGISTER_FIXED_CTR_CTRL: hv_register_name = 528387;
3528pub const hv_register_name_HV_X64_REGISTER_DS_AREA: hv_register_name = 528388;
3529pub const hv_register_name_HV_X64_REGISTER_PEBS_ENABLE: hv_register_name = 528389;
3530pub const hv_register_name_HV_X64_REGISTER_PEBS_LD_LAT: hv_register_name = 528390;
3531pub const hv_register_name_HV_X64_REGISTER_PEBS_FRONTEND: hv_register_name = 528391;
3532pub const hv_register_name_HV_X64_REGISTER_PERF_EVT_SEL0: hv_register_name = 528640;
3533pub const hv_register_name_HV_X64_REGISTER_PMC0: hv_register_name = 528896;
3534pub const hv_register_name_HV_X64_REGISTER_FIXED_CTR0: hv_register_name = 529152;
3535pub const hv_register_name_HV_X64_REGISTER_LBR_TOS: hv_register_name = 532480;
3536pub const hv_register_name_HV_X64_REGISTER_LBR_SELECT: hv_register_name = 532481;
3537pub const hv_register_name_HV_X64_REGISTER_LER_FROM_LIP: hv_register_name = 532482;
3538pub const hv_register_name_HV_X64_REGISTER_LER_TO_LIP: hv_register_name = 532483;
3539pub const hv_register_name_HV_X64_REGISTER_LBR_FROM0: hv_register_name = 532736;
3540pub const hv_register_name_HV_X64_REGISTER_LBR_TO0: hv_register_name = 532992;
3541pub const hv_register_name_HV_X64_REGISTER_LBR_INFO0: hv_register_name = 537344;
3542pub const hv_register_name_HV_X64_REGISTER_RTIT_CTL: hv_register_name = 528392;
3543pub const hv_register_name_HV_X64_REGISTER_RTIT_STATUS: hv_register_name = 528393;
3544pub const hv_register_name_HV_X64_REGISTER_RTIT_OUTPUT_BASE: hv_register_name = 528394;
3545pub const hv_register_name_HV_X64_REGISTER_RTIT_OUTPUT_MASK_PTRS: hv_register_name = 528395;
3546pub const hv_register_name_HV_X64_REGISTER_RTIT_CR3_MATCH: hv_register_name = 528396;
3547pub const hv_register_name_HV_X64_REGISTER_RTIT_ADDR0A: hv_register_name = 529408;
3548pub const hv_register_name_HV_X64_REGISTER_APIC_ID: hv_register_name = 542722;
3549pub const hv_register_name_HV_X64_REGISTER_APIC_VERSION: hv_register_name = 542723;
3550pub const hv_register_name_HV_X64_REGISTER_HYPERCALL: hv_register_name = 589825;
3551pub const hv_register_name_HV_X64_REGISTER_SYNTHETIC_EOI: hv_register_name = 589840;
3552pub const hv_register_name_HV_X64_REGISTER_SYNTHETIC_ICR: hv_register_name = 589841;
3553pub const hv_register_name_HV_X64_REGISTER_SYNTHETIC_TPR: hv_register_name = 589842;
3554pub const hv_register_name_HV_X64_REGISTER_REG_PAGE: hv_register_name = 589852;
3555pub const hv_register_name_HV_X64_REGISTER_GHCB: hv_register_name = 589849;
3556pub const hv_register_name_HV_X64_REGISTER_EMULATED_TIMER_PERIOD: hv_register_name = 589872;
3557pub const hv_register_name_HV_X64_REGISTER_EMULATED_TIMER_CONTROL: hv_register_name = 589873;
3558pub const hv_register_name_HV_X64_REGISTER_PM_TIMER_ASSIST: hv_register_name = 589874;
3559pub const hv_register_name_HV_X64_REGISTER_SEV_CONTROL: hv_register_name = 589888;
3560pub const hv_register_name_HV_X64_REGISTER_SEV_GHCB_GPA: hv_register_name = 589889;
3561pub const hv_register_name_HV_X64_REGISTER_SEV_DOORBELL_GPA: hv_register_name = 589890;
3562pub const hv_register_name_HV_X64_REGISTER_CR_INTERCEPT_CONTROL: hv_register_name = 917504;
3563pub const hv_register_name_HV_X64_REGISTER_CR_INTERCEPT_CR0_MASK: hv_register_name = 917505;
3564pub const hv_register_name_HV_X64_REGISTER_CR_INTERCEPT_CR4_MASK: hv_register_name = 917506;
3565pub const hv_register_name_HV_X64_REGISTER_CR_INTERCEPT_IA32_MISC_ENABLE_MASK: hv_register_name =
3566 917507;
3567pub type hv_register_name = ::std::os::raw::c_uint;
3568#[repr(C)]
3569#[derive(Copy, Clone)]
3570pub union hv_explicit_suspend_register {
3571 pub as_uint64: __u64,
3572 pub __bindgen_anon_1: hv_explicit_suspend_register__bindgen_ty_1,
3573}
3574#[repr(C, packed)]
3575#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
3576pub struct hv_explicit_suspend_register__bindgen_ty_1 {
3577 pub _bitfield_align_1: [u8; 0],
3578 pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>,
3579}
3580#[test]
3581fn bindgen_test_layout_hv_explicit_suspend_register__bindgen_ty_1() {
3582 assert_eq!(
3583 ::std::mem::size_of::<hv_explicit_suspend_register__bindgen_ty_1>(),
3584 8usize,
3585 concat!(
3586 "Size of: ",
3587 stringify!(hv_explicit_suspend_register__bindgen_ty_1)
3588 )
3589 );
3590 assert_eq!(
3591 ::std::mem::align_of::<hv_explicit_suspend_register__bindgen_ty_1>(),
3592 1usize,
3593 concat!(
3594 "Alignment of ",
3595 stringify!(hv_explicit_suspend_register__bindgen_ty_1)
3596 )
3597 );
3598}
3599impl hv_explicit_suspend_register__bindgen_ty_1 {
3600 #[inline]
3601 pub fn suspended(&self) -> __u64 {
3602 unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 1u8) as u64) }
3603 }
3604 #[inline]
3605 pub fn set_suspended(&mut self, val: __u64) {
3606 unsafe {
3607 let val: u64 = ::std::mem::transmute(val);
3608 self._bitfield_1.set(0usize, 1u8, val as u64)
3609 }
3610 }
3611 #[inline]
3612 pub fn reserved(&self) -> __u64 {
3613 unsafe { ::std::mem::transmute(self._bitfield_1.get(1usize, 63u8) as u64) }
3614 }
3615 #[inline]
3616 pub fn set_reserved(&mut self, val: __u64) {
3617 unsafe {
3618 let val: u64 = ::std::mem::transmute(val);
3619 self._bitfield_1.set(1usize, 63u8, val as u64)
3620 }
3621 }
3622 #[inline]
3623 pub fn new_bitfield_1(
3624 suspended: __u64,
3625 reserved: __u64,
3626 ) -> __BindgenBitfieldUnit<[u8; 8usize]> {
3627 let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 8usize]> = Default::default();
3628 __bindgen_bitfield_unit.set(0usize, 1u8, {
3629 let suspended: u64 = unsafe { ::std::mem::transmute(suspended) };
3630 suspended as u64
3631 });
3632 __bindgen_bitfield_unit.set(1usize, 63u8, {
3633 let reserved: u64 = unsafe { ::std::mem::transmute(reserved) };
3634 reserved as u64
3635 });
3636 __bindgen_bitfield_unit
3637 }
3638}
3639#[test]
3640fn bindgen_test_layout_hv_explicit_suspend_register() {
3641 const UNINIT: ::std::mem::MaybeUninit<hv_explicit_suspend_register> =
3642 ::std::mem::MaybeUninit::uninit();
3643 let ptr = UNINIT.as_ptr();
3644 assert_eq!(
3645 ::std::mem::size_of::<hv_explicit_suspend_register>(),
3646 8usize,
3647 concat!("Size of: ", stringify!(hv_explicit_suspend_register))
3648 );
3649 assert_eq!(
3650 ::std::mem::align_of::<hv_explicit_suspend_register>(),
3651 8usize,
3652 concat!("Alignment of ", stringify!(hv_explicit_suspend_register))
3653 );
3654 assert_eq!(
3655 unsafe { ::std::ptr::addr_of!((*ptr).as_uint64) as usize - ptr as usize },
3656 0usize,
3657 concat!(
3658 "Offset of field: ",
3659 stringify!(hv_explicit_suspend_register),
3660 "::",
3661 stringify!(as_uint64)
3662 )
3663 );
3664}
3665impl Default for hv_explicit_suspend_register {
3666 fn default() -> Self {
3667 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
3668 unsafe {
3669 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
3670 s.assume_init()
3671 }
3672 }
3673}
3674#[repr(C)]
3675#[derive(Copy, Clone)]
3676pub union hv_intercept_suspend_register {
3677 pub as_uint64: __u64,
3678 pub __bindgen_anon_1: hv_intercept_suspend_register__bindgen_ty_1,
3679}
3680#[repr(C, packed)]
3681#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
3682pub struct hv_intercept_suspend_register__bindgen_ty_1 {
3683 pub _bitfield_align_1: [u8; 0],
3684 pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>,
3685}
3686#[test]
3687fn bindgen_test_layout_hv_intercept_suspend_register__bindgen_ty_1() {
3688 assert_eq!(
3689 ::std::mem::size_of::<hv_intercept_suspend_register__bindgen_ty_1>(),
3690 8usize,
3691 concat!(
3692 "Size of: ",
3693 stringify!(hv_intercept_suspend_register__bindgen_ty_1)
3694 )
3695 );
3696 assert_eq!(
3697 ::std::mem::align_of::<hv_intercept_suspend_register__bindgen_ty_1>(),
3698 1usize,
3699 concat!(
3700 "Alignment of ",
3701 stringify!(hv_intercept_suspend_register__bindgen_ty_1)
3702 )
3703 );
3704}
3705impl hv_intercept_suspend_register__bindgen_ty_1 {
3706 #[inline]
3707 pub fn suspended(&self) -> __u64 {
3708 unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 1u8) as u64) }
3709 }
3710 #[inline]
3711 pub fn set_suspended(&mut self, val: __u64) {
3712 unsafe {
3713 let val: u64 = ::std::mem::transmute(val);
3714 self._bitfield_1.set(0usize, 1u8, val as u64)
3715 }
3716 }
3717 #[inline]
3718 pub fn reserved(&self) -> __u64 {
3719 unsafe { ::std::mem::transmute(self._bitfield_1.get(1usize, 63u8) as u64) }
3720 }
3721 #[inline]
3722 pub fn set_reserved(&mut self, val: __u64) {
3723 unsafe {
3724 let val: u64 = ::std::mem::transmute(val);
3725 self._bitfield_1.set(1usize, 63u8, val as u64)
3726 }
3727 }
3728 #[inline]
3729 pub fn new_bitfield_1(
3730 suspended: __u64,
3731 reserved: __u64,
3732 ) -> __BindgenBitfieldUnit<[u8; 8usize]> {
3733 let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 8usize]> = Default::default();
3734 __bindgen_bitfield_unit.set(0usize, 1u8, {
3735 let suspended: u64 = unsafe { ::std::mem::transmute(suspended) };
3736 suspended as u64
3737 });
3738 __bindgen_bitfield_unit.set(1usize, 63u8, {
3739 let reserved: u64 = unsafe { ::std::mem::transmute(reserved) };
3740 reserved as u64
3741 });
3742 __bindgen_bitfield_unit
3743 }
3744}
3745#[test]
3746fn bindgen_test_layout_hv_intercept_suspend_register() {
3747 const UNINIT: ::std::mem::MaybeUninit<hv_intercept_suspend_register> =
3748 ::std::mem::MaybeUninit::uninit();
3749 let ptr = UNINIT.as_ptr();
3750 assert_eq!(
3751 ::std::mem::size_of::<hv_intercept_suspend_register>(),
3752 8usize,
3753 concat!("Size of: ", stringify!(hv_intercept_suspend_register))
3754 );
3755 assert_eq!(
3756 ::std::mem::align_of::<hv_intercept_suspend_register>(),
3757 8usize,
3758 concat!("Alignment of ", stringify!(hv_intercept_suspend_register))
3759 );
3760 assert_eq!(
3761 unsafe { ::std::ptr::addr_of!((*ptr).as_uint64) as usize - ptr as usize },
3762 0usize,
3763 concat!(
3764 "Offset of field: ",
3765 stringify!(hv_intercept_suspend_register),
3766 "::",
3767 stringify!(as_uint64)
3768 )
3769 );
3770}
3771impl Default for hv_intercept_suspend_register {
3772 fn default() -> Self {
3773 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
3774 unsafe {
3775 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
3776 s.assume_init()
3777 }
3778 }
3779}
3780#[repr(C)]
3781#[derive(Copy, Clone)]
3782pub union hv_internal_activity_register {
3783 pub as_uint64: __u64,
3784 pub __bindgen_anon_1: hv_internal_activity_register__bindgen_ty_1,
3785}
3786#[repr(C, packed)]
3787#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
3788pub struct hv_internal_activity_register__bindgen_ty_1 {
3789 pub _bitfield_align_1: [u8; 0],
3790 pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>,
3791}
3792#[test]
3793fn bindgen_test_layout_hv_internal_activity_register__bindgen_ty_1() {
3794 assert_eq!(
3795 ::std::mem::size_of::<hv_internal_activity_register__bindgen_ty_1>(),
3796 8usize,
3797 concat!(
3798 "Size of: ",
3799 stringify!(hv_internal_activity_register__bindgen_ty_1)
3800 )
3801 );
3802 assert_eq!(
3803 ::std::mem::align_of::<hv_internal_activity_register__bindgen_ty_1>(),
3804 1usize,
3805 concat!(
3806 "Alignment of ",
3807 stringify!(hv_internal_activity_register__bindgen_ty_1)
3808 )
3809 );
3810}
3811impl hv_internal_activity_register__bindgen_ty_1 {
3812 #[inline]
3813 pub fn startup_suspend(&self) -> __u64 {
3814 unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 1u8) as u64) }
3815 }
3816 #[inline]
3817 pub fn set_startup_suspend(&mut self, val: __u64) {
3818 unsafe {
3819 let val: u64 = ::std::mem::transmute(val);
3820 self._bitfield_1.set(0usize, 1u8, val as u64)
3821 }
3822 }
3823 #[inline]
3824 pub fn halt_suspend(&self) -> __u64 {
3825 unsafe { ::std::mem::transmute(self._bitfield_1.get(1usize, 1u8) as u64) }
3826 }
3827 #[inline]
3828 pub fn set_halt_suspend(&mut self, val: __u64) {
3829 unsafe {
3830 let val: u64 = ::std::mem::transmute(val);
3831 self._bitfield_1.set(1usize, 1u8, val as u64)
3832 }
3833 }
3834 #[inline]
3835 pub fn idle_suspend(&self) -> __u64 {
3836 unsafe { ::std::mem::transmute(self._bitfield_1.get(2usize, 1u8) as u64) }
3837 }
3838 #[inline]
3839 pub fn set_idle_suspend(&mut self, val: __u64) {
3840 unsafe {
3841 let val: u64 = ::std::mem::transmute(val);
3842 self._bitfield_1.set(2usize, 1u8, val as u64)
3843 }
3844 }
3845 #[inline]
3846 pub fn rsvd_z(&self) -> __u64 {
3847 unsafe { ::std::mem::transmute(self._bitfield_1.get(3usize, 61u8) as u64) }
3848 }
3849 #[inline]
3850 pub fn set_rsvd_z(&mut self, val: __u64) {
3851 unsafe {
3852 let val: u64 = ::std::mem::transmute(val);
3853 self._bitfield_1.set(3usize, 61u8, val as u64)
3854 }
3855 }
3856 #[inline]
3857 pub fn new_bitfield_1(
3858 startup_suspend: __u64,
3859 halt_suspend: __u64,
3860 idle_suspend: __u64,
3861 rsvd_z: __u64,
3862 ) -> __BindgenBitfieldUnit<[u8; 8usize]> {
3863 let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 8usize]> = Default::default();
3864 __bindgen_bitfield_unit.set(0usize, 1u8, {
3865 let startup_suspend: u64 = unsafe { ::std::mem::transmute(startup_suspend) };
3866 startup_suspend as u64
3867 });
3868 __bindgen_bitfield_unit.set(1usize, 1u8, {
3869 let halt_suspend: u64 = unsafe { ::std::mem::transmute(halt_suspend) };
3870 halt_suspend as u64
3871 });
3872 __bindgen_bitfield_unit.set(2usize, 1u8, {
3873 let idle_suspend: u64 = unsafe { ::std::mem::transmute(idle_suspend) };
3874 idle_suspend as u64
3875 });
3876 __bindgen_bitfield_unit.set(3usize, 61u8, {
3877 let rsvd_z: u64 = unsafe { ::std::mem::transmute(rsvd_z) };
3878 rsvd_z as u64
3879 });
3880 __bindgen_bitfield_unit
3881 }
3882}
3883#[test]
3884fn bindgen_test_layout_hv_internal_activity_register() {
3885 const UNINIT: ::std::mem::MaybeUninit<hv_internal_activity_register> =
3886 ::std::mem::MaybeUninit::uninit();
3887 let ptr = UNINIT.as_ptr();
3888 assert_eq!(
3889 ::std::mem::size_of::<hv_internal_activity_register>(),
3890 8usize,
3891 concat!("Size of: ", stringify!(hv_internal_activity_register))
3892 );
3893 assert_eq!(
3894 ::std::mem::align_of::<hv_internal_activity_register>(),
3895 8usize,
3896 concat!("Alignment of ", stringify!(hv_internal_activity_register))
3897 );
3898 assert_eq!(
3899 unsafe { ::std::ptr::addr_of!((*ptr).as_uint64) as usize - ptr as usize },
3900 0usize,
3901 concat!(
3902 "Offset of field: ",
3903 stringify!(hv_internal_activity_register),
3904 "::",
3905 stringify!(as_uint64)
3906 )
3907 );
3908}
3909impl Default for hv_internal_activity_register {
3910 fn default() -> Self {
3911 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
3912 unsafe {
3913 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
3914 s.assume_init()
3915 }
3916 }
3917}
3918#[repr(C)]
3919#[derive(Copy, Clone)]
3920pub union hv_x64_interrupt_state_register {
3921 pub as_uint64: __u64,
3922 pub __bindgen_anon_1: hv_x64_interrupt_state_register__bindgen_ty_1,
3923}
3924#[repr(C, packed)]
3925#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
3926pub struct hv_x64_interrupt_state_register__bindgen_ty_1 {
3927 pub _bitfield_align_1: [u8; 0],
3928 pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>,
3929}
3930#[test]
3931fn bindgen_test_layout_hv_x64_interrupt_state_register__bindgen_ty_1() {
3932 assert_eq!(
3933 ::std::mem::size_of::<hv_x64_interrupt_state_register__bindgen_ty_1>(),
3934 8usize,
3935 concat!(
3936 "Size of: ",
3937 stringify!(hv_x64_interrupt_state_register__bindgen_ty_1)
3938 )
3939 );
3940 assert_eq!(
3941 ::std::mem::align_of::<hv_x64_interrupt_state_register__bindgen_ty_1>(),
3942 1usize,
3943 concat!(
3944 "Alignment of ",
3945 stringify!(hv_x64_interrupt_state_register__bindgen_ty_1)
3946 )
3947 );
3948}
3949impl hv_x64_interrupt_state_register__bindgen_ty_1 {
3950 #[inline]
3951 pub fn interrupt_shadow(&self) -> __u64 {
3952 unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 1u8) as u64) }
3953 }
3954 #[inline]
3955 pub fn set_interrupt_shadow(&mut self, val: __u64) {
3956 unsafe {
3957 let val: u64 = ::std::mem::transmute(val);
3958 self._bitfield_1.set(0usize, 1u8, val as u64)
3959 }
3960 }
3961 #[inline]
3962 pub fn nmi_masked(&self) -> __u64 {
3963 unsafe { ::std::mem::transmute(self._bitfield_1.get(1usize, 1u8) as u64) }
3964 }
3965 #[inline]
3966 pub fn set_nmi_masked(&mut self, val: __u64) {
3967 unsafe {
3968 let val: u64 = ::std::mem::transmute(val);
3969 self._bitfield_1.set(1usize, 1u8, val as u64)
3970 }
3971 }
3972 #[inline]
3973 pub fn reserved(&self) -> __u64 {
3974 unsafe { ::std::mem::transmute(self._bitfield_1.get(2usize, 62u8) as u64) }
3975 }
3976 #[inline]
3977 pub fn set_reserved(&mut self, val: __u64) {
3978 unsafe {
3979 let val: u64 = ::std::mem::transmute(val);
3980 self._bitfield_1.set(2usize, 62u8, val as u64)
3981 }
3982 }
3983 #[inline]
3984 pub fn new_bitfield_1(
3985 interrupt_shadow: __u64,
3986 nmi_masked: __u64,
3987 reserved: __u64,
3988 ) -> __BindgenBitfieldUnit<[u8; 8usize]> {
3989 let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 8usize]> = Default::default();
3990 __bindgen_bitfield_unit.set(0usize, 1u8, {
3991 let interrupt_shadow: u64 = unsafe { ::std::mem::transmute(interrupt_shadow) };
3992 interrupt_shadow as u64
3993 });
3994 __bindgen_bitfield_unit.set(1usize, 1u8, {
3995 let nmi_masked: u64 = unsafe { ::std::mem::transmute(nmi_masked) };
3996 nmi_masked as u64
3997 });
3998 __bindgen_bitfield_unit.set(2usize, 62u8, {
3999 let reserved: u64 = unsafe { ::std::mem::transmute(reserved) };
4000 reserved as u64
4001 });
4002 __bindgen_bitfield_unit
4003 }
4004}
4005#[test]
4006fn bindgen_test_layout_hv_x64_interrupt_state_register() {
4007 const UNINIT: ::std::mem::MaybeUninit<hv_x64_interrupt_state_register> =
4008 ::std::mem::MaybeUninit::uninit();
4009 let ptr = UNINIT.as_ptr();
4010 assert_eq!(
4011 ::std::mem::size_of::<hv_x64_interrupt_state_register>(),
4012 8usize,
4013 concat!("Size of: ", stringify!(hv_x64_interrupt_state_register))
4014 );
4015 assert_eq!(
4016 ::std::mem::align_of::<hv_x64_interrupt_state_register>(),
4017 8usize,
4018 concat!("Alignment of ", stringify!(hv_x64_interrupt_state_register))
4019 );
4020 assert_eq!(
4021 unsafe { ::std::ptr::addr_of!((*ptr).as_uint64) as usize - ptr as usize },
4022 0usize,
4023 concat!(
4024 "Offset of field: ",
4025 stringify!(hv_x64_interrupt_state_register),
4026 "::",
4027 stringify!(as_uint64)
4028 )
4029 );
4030}
4031impl Default for hv_x64_interrupt_state_register {
4032 fn default() -> Self {
4033 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
4034 unsafe {
4035 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
4036 s.assume_init()
4037 }
4038 }
4039}
4040#[repr(C)]
4041#[derive(Copy, Clone)]
4042pub union hv_x64_pending_exception_event {
4043 pub as_uint64: [__u64; 2usize],
4044 pub __bindgen_anon_1: hv_x64_pending_exception_event__bindgen_ty_1,
4045}
4046#[repr(C, packed)]
4047#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
4048pub struct hv_x64_pending_exception_event__bindgen_ty_1 {
4049 pub _bitfield_align_1: [u8; 0],
4050 pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize]>,
4051 pub error_code: __u32,
4052 pub exception_parameter: __u64,
4053}
4054#[test]
4055fn bindgen_test_layout_hv_x64_pending_exception_event__bindgen_ty_1() {
4056 const UNINIT: ::std::mem::MaybeUninit<hv_x64_pending_exception_event__bindgen_ty_1> =
4057 ::std::mem::MaybeUninit::uninit();
4058 let ptr = UNINIT.as_ptr();
4059 assert_eq!(
4060 ::std::mem::size_of::<hv_x64_pending_exception_event__bindgen_ty_1>(),
4061 16usize,
4062 concat!(
4063 "Size of: ",
4064 stringify!(hv_x64_pending_exception_event__bindgen_ty_1)
4065 )
4066 );
4067 assert_eq!(
4068 ::std::mem::align_of::<hv_x64_pending_exception_event__bindgen_ty_1>(),
4069 1usize,
4070 concat!(
4071 "Alignment of ",
4072 stringify!(hv_x64_pending_exception_event__bindgen_ty_1)
4073 )
4074 );
4075 assert_eq!(
4076 unsafe { ::std::ptr::addr_of!((*ptr).error_code) as usize - ptr as usize },
4077 4usize,
4078 concat!(
4079 "Offset of field: ",
4080 stringify!(hv_x64_pending_exception_event__bindgen_ty_1),
4081 "::",
4082 stringify!(error_code)
4083 )
4084 );
4085 assert_eq!(
4086 unsafe { ::std::ptr::addr_of!((*ptr).exception_parameter) as usize - ptr as usize },
4087 8usize,
4088 concat!(
4089 "Offset of field: ",
4090 stringify!(hv_x64_pending_exception_event__bindgen_ty_1),
4091 "::",
4092 stringify!(exception_parameter)
4093 )
4094 );
4095}
4096impl hv_x64_pending_exception_event__bindgen_ty_1 {
4097 #[inline]
4098 pub fn event_pending(&self) -> __u32 {
4099 unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 1u8) as u32) }
4100 }
4101 #[inline]
4102 pub fn set_event_pending(&mut self, val: __u32) {
4103 unsafe {
4104 let val: u32 = ::std::mem::transmute(val);
4105 self._bitfield_1.set(0usize, 1u8, val as u64)
4106 }
4107 }
4108 #[inline]
4109 pub fn event_type(&self) -> __u32 {
4110 unsafe { ::std::mem::transmute(self._bitfield_1.get(1usize, 3u8) as u32) }
4111 }
4112 #[inline]
4113 pub fn set_event_type(&mut self, val: __u32) {
4114 unsafe {
4115 let val: u32 = ::std::mem::transmute(val);
4116 self._bitfield_1.set(1usize, 3u8, val as u64)
4117 }
4118 }
4119 #[inline]
4120 pub fn reserved0(&self) -> __u32 {
4121 unsafe { ::std::mem::transmute(self._bitfield_1.get(4usize, 4u8) as u32) }
4122 }
4123 #[inline]
4124 pub fn set_reserved0(&mut self, val: __u32) {
4125 unsafe {
4126 let val: u32 = ::std::mem::transmute(val);
4127 self._bitfield_1.set(4usize, 4u8, val as u64)
4128 }
4129 }
4130 #[inline]
4131 pub fn deliver_error_code(&self) -> __u32 {
4132 unsafe { ::std::mem::transmute(self._bitfield_1.get(8usize, 1u8) as u32) }
4133 }
4134 #[inline]
4135 pub fn set_deliver_error_code(&mut self, val: __u32) {
4136 unsafe {
4137 let val: u32 = ::std::mem::transmute(val);
4138 self._bitfield_1.set(8usize, 1u8, val as u64)
4139 }
4140 }
4141 #[inline]
4142 pub fn reserved1(&self) -> __u32 {
4143 unsafe { ::std::mem::transmute(self._bitfield_1.get(9usize, 7u8) as u32) }
4144 }
4145 #[inline]
4146 pub fn set_reserved1(&mut self, val: __u32) {
4147 unsafe {
4148 let val: u32 = ::std::mem::transmute(val);
4149 self._bitfield_1.set(9usize, 7u8, val as u64)
4150 }
4151 }
4152 #[inline]
4153 pub fn vector(&self) -> __u32 {
4154 unsafe { ::std::mem::transmute(self._bitfield_1.get(16usize, 16u8) as u32) }
4155 }
4156 #[inline]
4157 pub fn set_vector(&mut self, val: __u32) {
4158 unsafe {
4159 let val: u32 = ::std::mem::transmute(val);
4160 self._bitfield_1.set(16usize, 16u8, val as u64)
4161 }
4162 }
4163 #[inline]
4164 pub fn new_bitfield_1(
4165 event_pending: __u32,
4166 event_type: __u32,
4167 reserved0: __u32,
4168 deliver_error_code: __u32,
4169 reserved1: __u32,
4170 vector: __u32,
4171 ) -> __BindgenBitfieldUnit<[u8; 4usize]> {
4172 let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 4usize]> = Default::default();
4173 __bindgen_bitfield_unit.set(0usize, 1u8, {
4174 let event_pending: u32 = unsafe { ::std::mem::transmute(event_pending) };
4175 event_pending as u64
4176 });
4177 __bindgen_bitfield_unit.set(1usize, 3u8, {
4178 let event_type: u32 = unsafe { ::std::mem::transmute(event_type) };
4179 event_type as u64
4180 });
4181 __bindgen_bitfield_unit.set(4usize, 4u8, {
4182 let reserved0: u32 = unsafe { ::std::mem::transmute(reserved0) };
4183 reserved0 as u64
4184 });
4185 __bindgen_bitfield_unit.set(8usize, 1u8, {
4186 let deliver_error_code: u32 = unsafe { ::std::mem::transmute(deliver_error_code) };
4187 deliver_error_code as u64
4188 });
4189 __bindgen_bitfield_unit.set(9usize, 7u8, {
4190 let reserved1: u32 = unsafe { ::std::mem::transmute(reserved1) };
4191 reserved1 as u64
4192 });
4193 __bindgen_bitfield_unit.set(16usize, 16u8, {
4194 let vector: u32 = unsafe { ::std::mem::transmute(vector) };
4195 vector as u64
4196 });
4197 __bindgen_bitfield_unit
4198 }
4199}
4200#[test]
4201fn bindgen_test_layout_hv_x64_pending_exception_event() {
4202 const UNINIT: ::std::mem::MaybeUninit<hv_x64_pending_exception_event> =
4203 ::std::mem::MaybeUninit::uninit();
4204 let ptr = UNINIT.as_ptr();
4205 assert_eq!(
4206 ::std::mem::size_of::<hv_x64_pending_exception_event>(),
4207 16usize,
4208 concat!("Size of: ", stringify!(hv_x64_pending_exception_event))
4209 );
4210 assert_eq!(
4211 ::std::mem::align_of::<hv_x64_pending_exception_event>(),
4212 8usize,
4213 concat!("Alignment of ", stringify!(hv_x64_pending_exception_event))
4214 );
4215 assert_eq!(
4216 unsafe { ::std::ptr::addr_of!((*ptr).as_uint64) as usize - ptr as usize },
4217 0usize,
4218 concat!(
4219 "Offset of field: ",
4220 stringify!(hv_x64_pending_exception_event),
4221 "::",
4222 stringify!(as_uint64)
4223 )
4224 );
4225}
4226impl Default for hv_x64_pending_exception_event {
4227 fn default() -> Self {
4228 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
4229 unsafe {
4230 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
4231 s.assume_init()
4232 }
4233 }
4234}
4235#[repr(C)]
4236#[derive(Copy, Clone)]
4237pub union hv_x64_pending_virtualization_fault_event {
4238 pub as_uint64: [__u64; 2usize],
4239 pub __bindgen_anon_1: hv_x64_pending_virtualization_fault_event__bindgen_ty_1,
4240}
4241#[repr(C, packed)]
4242#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
4243pub struct hv_x64_pending_virtualization_fault_event__bindgen_ty_1 {
4244 pub _bitfield_align_1: [u8; 0],
4245 pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize]>,
4246 pub code: __u32,
4247 pub parameter1: __u64,
4248}
4249#[test]
4250fn bindgen_test_layout_hv_x64_pending_virtualization_fault_event__bindgen_ty_1() {
4251 const UNINIT: ::std::mem::MaybeUninit<hv_x64_pending_virtualization_fault_event__bindgen_ty_1> =
4252 ::std::mem::MaybeUninit::uninit();
4253 let ptr = UNINIT.as_ptr();
4254 assert_eq!(
4255 ::std::mem::size_of::<hv_x64_pending_virtualization_fault_event__bindgen_ty_1>(),
4256 16usize,
4257 concat!(
4258 "Size of: ",
4259 stringify!(hv_x64_pending_virtualization_fault_event__bindgen_ty_1)
4260 )
4261 );
4262 assert_eq!(
4263 ::std::mem::align_of::<hv_x64_pending_virtualization_fault_event__bindgen_ty_1>(),
4264 1usize,
4265 concat!(
4266 "Alignment of ",
4267 stringify!(hv_x64_pending_virtualization_fault_event__bindgen_ty_1)
4268 )
4269 );
4270 assert_eq!(
4271 unsafe { ::std::ptr::addr_of!((*ptr).code) as usize - ptr as usize },
4272 4usize,
4273 concat!(
4274 "Offset of field: ",
4275 stringify!(hv_x64_pending_virtualization_fault_event__bindgen_ty_1),
4276 "::",
4277 stringify!(code)
4278 )
4279 );
4280 assert_eq!(
4281 unsafe { ::std::ptr::addr_of!((*ptr).parameter1) as usize - ptr as usize },
4282 8usize,
4283 concat!(
4284 "Offset of field: ",
4285 stringify!(hv_x64_pending_virtualization_fault_event__bindgen_ty_1),
4286 "::",
4287 stringify!(parameter1)
4288 )
4289 );
4290}
4291impl hv_x64_pending_virtualization_fault_event__bindgen_ty_1 {
4292 #[inline]
4293 pub fn event_pending(&self) -> __u32 {
4294 unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 1u8) as u32) }
4295 }
4296 #[inline]
4297 pub fn set_event_pending(&mut self, val: __u32) {
4298 unsafe {
4299 let val: u32 = ::std::mem::transmute(val);
4300 self._bitfield_1.set(0usize, 1u8, val as u64)
4301 }
4302 }
4303 #[inline]
4304 pub fn event_type(&self) -> __u32 {
4305 unsafe { ::std::mem::transmute(self._bitfield_1.get(1usize, 3u8) as u32) }
4306 }
4307 #[inline]
4308 pub fn set_event_type(&mut self, val: __u32) {
4309 unsafe {
4310 let val: u32 = ::std::mem::transmute(val);
4311 self._bitfield_1.set(1usize, 3u8, val as u64)
4312 }
4313 }
4314 #[inline]
4315 pub fn reserved0(&self) -> __u32 {
4316 unsafe { ::std::mem::transmute(self._bitfield_1.get(4usize, 4u8) as u32) }
4317 }
4318 #[inline]
4319 pub fn set_reserved0(&mut self, val: __u32) {
4320 unsafe {
4321 let val: u32 = ::std::mem::transmute(val);
4322 self._bitfield_1.set(4usize, 4u8, val as u64)
4323 }
4324 }
4325 #[inline]
4326 pub fn reserved1(&self) -> __u32 {
4327 unsafe { ::std::mem::transmute(self._bitfield_1.get(8usize, 8u8) as u32) }
4328 }
4329 #[inline]
4330 pub fn set_reserved1(&mut self, val: __u32) {
4331 unsafe {
4332 let val: u32 = ::std::mem::transmute(val);
4333 self._bitfield_1.set(8usize, 8u8, val as u64)
4334 }
4335 }
4336 #[inline]
4337 pub fn parameter0(&self) -> __u32 {
4338 unsafe { ::std::mem::transmute(self._bitfield_1.get(16usize, 16u8) as u32) }
4339 }
4340 #[inline]
4341 pub fn set_parameter0(&mut self, val: __u32) {
4342 unsafe {
4343 let val: u32 = ::std::mem::transmute(val);
4344 self._bitfield_1.set(16usize, 16u8, val as u64)
4345 }
4346 }
4347 #[inline]
4348 pub fn new_bitfield_1(
4349 event_pending: __u32,
4350 event_type: __u32,
4351 reserved0: __u32,
4352 reserved1: __u32,
4353 parameter0: __u32,
4354 ) -> __BindgenBitfieldUnit<[u8; 4usize]> {
4355 let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 4usize]> = Default::default();
4356 __bindgen_bitfield_unit.set(0usize, 1u8, {
4357 let event_pending: u32 = unsafe { ::std::mem::transmute(event_pending) };
4358 event_pending as u64
4359 });
4360 __bindgen_bitfield_unit.set(1usize, 3u8, {
4361 let event_type: u32 = unsafe { ::std::mem::transmute(event_type) };
4362 event_type as u64
4363 });
4364 __bindgen_bitfield_unit.set(4usize, 4u8, {
4365 let reserved0: u32 = unsafe { ::std::mem::transmute(reserved0) };
4366 reserved0 as u64
4367 });
4368 __bindgen_bitfield_unit.set(8usize, 8u8, {
4369 let reserved1: u32 = unsafe { ::std::mem::transmute(reserved1) };
4370 reserved1 as u64
4371 });
4372 __bindgen_bitfield_unit.set(16usize, 16u8, {
4373 let parameter0: u32 = unsafe { ::std::mem::transmute(parameter0) };
4374 parameter0 as u64
4375 });
4376 __bindgen_bitfield_unit
4377 }
4378}
4379#[test]
4380fn bindgen_test_layout_hv_x64_pending_virtualization_fault_event() {
4381 const UNINIT: ::std::mem::MaybeUninit<hv_x64_pending_virtualization_fault_event> =
4382 ::std::mem::MaybeUninit::uninit();
4383 let ptr = UNINIT.as_ptr();
4384 assert_eq!(
4385 ::std::mem::size_of::<hv_x64_pending_virtualization_fault_event>(),
4386 16usize,
4387 concat!(
4388 "Size of: ",
4389 stringify!(hv_x64_pending_virtualization_fault_event)
4390 )
4391 );
4392 assert_eq!(
4393 ::std::mem::align_of::<hv_x64_pending_virtualization_fault_event>(),
4394 8usize,
4395 concat!(
4396 "Alignment of ",
4397 stringify!(hv_x64_pending_virtualization_fault_event)
4398 )
4399 );
4400 assert_eq!(
4401 unsafe { ::std::ptr::addr_of!((*ptr).as_uint64) as usize - ptr as usize },
4402 0usize,
4403 concat!(
4404 "Offset of field: ",
4405 stringify!(hv_x64_pending_virtualization_fault_event),
4406 "::",
4407 stringify!(as_uint64)
4408 )
4409 );
4410}
4411impl Default for hv_x64_pending_virtualization_fault_event {
4412 fn default() -> Self {
4413 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
4414 unsafe {
4415 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
4416 s.assume_init()
4417 }
4418 }
4419}
4420#[repr(C)]
4421#[derive(Copy, Clone)]
4422pub union hv_x64_pending_interruption_register {
4423 pub as_uint64: __u64,
4424 pub __bindgen_anon_1: hv_x64_pending_interruption_register__bindgen_ty_1,
4425}
4426#[repr(C, packed)]
4427#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
4428pub struct hv_x64_pending_interruption_register__bindgen_ty_1 {
4429 pub _bitfield_align_1: [u8; 0],
4430 pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize]>,
4431 pub error_code: __u32,
4432}
4433#[test]
4434fn bindgen_test_layout_hv_x64_pending_interruption_register__bindgen_ty_1() {
4435 const UNINIT: ::std::mem::MaybeUninit<hv_x64_pending_interruption_register__bindgen_ty_1> =
4436 ::std::mem::MaybeUninit::uninit();
4437 let ptr = UNINIT.as_ptr();
4438 assert_eq!(
4439 ::std::mem::size_of::<hv_x64_pending_interruption_register__bindgen_ty_1>(),
4440 8usize,
4441 concat!(
4442 "Size of: ",
4443 stringify!(hv_x64_pending_interruption_register__bindgen_ty_1)
4444 )
4445 );
4446 assert_eq!(
4447 ::std::mem::align_of::<hv_x64_pending_interruption_register__bindgen_ty_1>(),
4448 1usize,
4449 concat!(
4450 "Alignment of ",
4451 stringify!(hv_x64_pending_interruption_register__bindgen_ty_1)
4452 )
4453 );
4454 assert_eq!(
4455 unsafe { ::std::ptr::addr_of!((*ptr).error_code) as usize - ptr as usize },
4456 4usize,
4457 concat!(
4458 "Offset of field: ",
4459 stringify!(hv_x64_pending_interruption_register__bindgen_ty_1),
4460 "::",
4461 stringify!(error_code)
4462 )
4463 );
4464}
4465impl hv_x64_pending_interruption_register__bindgen_ty_1 {
4466 #[inline]
4467 pub fn interruption_pending(&self) -> __u32 {
4468 unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 1u8) as u32) }
4469 }
4470 #[inline]
4471 pub fn set_interruption_pending(&mut self, val: __u32) {
4472 unsafe {
4473 let val: u32 = ::std::mem::transmute(val);
4474 self._bitfield_1.set(0usize, 1u8, val as u64)
4475 }
4476 }
4477 #[inline]
4478 pub fn interruption_type(&self) -> __u32 {
4479 unsafe { ::std::mem::transmute(self._bitfield_1.get(1usize, 3u8) as u32) }
4480 }
4481 #[inline]
4482 pub fn set_interruption_type(&mut self, val: __u32) {
4483 unsafe {
4484 let val: u32 = ::std::mem::transmute(val);
4485 self._bitfield_1.set(1usize, 3u8, val as u64)
4486 }
4487 }
4488 #[inline]
4489 pub fn deliver_error_code(&self) -> __u32 {
4490 unsafe { ::std::mem::transmute(self._bitfield_1.get(4usize, 1u8) as u32) }
4491 }
4492 #[inline]
4493 pub fn set_deliver_error_code(&mut self, val: __u32) {
4494 unsafe {
4495 let val: u32 = ::std::mem::transmute(val);
4496 self._bitfield_1.set(4usize, 1u8, val as u64)
4497 }
4498 }
4499 #[inline]
4500 pub fn instruction_length(&self) -> __u32 {
4501 unsafe { ::std::mem::transmute(self._bitfield_1.get(5usize, 4u8) as u32) }
4502 }
4503 #[inline]
4504 pub fn set_instruction_length(&mut self, val: __u32) {
4505 unsafe {
4506 let val: u32 = ::std::mem::transmute(val);
4507 self._bitfield_1.set(5usize, 4u8, val as u64)
4508 }
4509 }
4510 #[inline]
4511 pub fn nested_event(&self) -> __u32 {
4512 unsafe { ::std::mem::transmute(self._bitfield_1.get(9usize, 1u8) as u32) }
4513 }
4514 #[inline]
4515 pub fn set_nested_event(&mut self, val: __u32) {
4516 unsafe {
4517 let val: u32 = ::std::mem::transmute(val);
4518 self._bitfield_1.set(9usize, 1u8, val as u64)
4519 }
4520 }
4521 #[inline]
4522 pub fn reserved(&self) -> __u32 {
4523 unsafe { ::std::mem::transmute(self._bitfield_1.get(10usize, 6u8) as u32) }
4524 }
4525 #[inline]
4526 pub fn set_reserved(&mut self, val: __u32) {
4527 unsafe {
4528 let val: u32 = ::std::mem::transmute(val);
4529 self._bitfield_1.set(10usize, 6u8, val as u64)
4530 }
4531 }
4532 #[inline]
4533 pub fn interruption_vector(&self) -> __u32 {
4534 unsafe { ::std::mem::transmute(self._bitfield_1.get(16usize, 16u8) as u32) }
4535 }
4536 #[inline]
4537 pub fn set_interruption_vector(&mut self, val: __u32) {
4538 unsafe {
4539 let val: u32 = ::std::mem::transmute(val);
4540 self._bitfield_1.set(16usize, 16u8, val as u64)
4541 }
4542 }
4543 #[inline]
4544 pub fn new_bitfield_1(
4545 interruption_pending: __u32,
4546 interruption_type: __u32,
4547 deliver_error_code: __u32,
4548 instruction_length: __u32,
4549 nested_event: __u32,
4550 reserved: __u32,
4551 interruption_vector: __u32,
4552 ) -> __BindgenBitfieldUnit<[u8; 4usize]> {
4553 let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 4usize]> = Default::default();
4554 __bindgen_bitfield_unit.set(0usize, 1u8, {
4555 let interruption_pending: u32 = unsafe { ::std::mem::transmute(interruption_pending) };
4556 interruption_pending as u64
4557 });
4558 __bindgen_bitfield_unit.set(1usize, 3u8, {
4559 let interruption_type: u32 = unsafe { ::std::mem::transmute(interruption_type) };
4560 interruption_type as u64
4561 });
4562 __bindgen_bitfield_unit.set(4usize, 1u8, {
4563 let deliver_error_code: u32 = unsafe { ::std::mem::transmute(deliver_error_code) };
4564 deliver_error_code as u64
4565 });
4566 __bindgen_bitfield_unit.set(5usize, 4u8, {
4567 let instruction_length: u32 = unsafe { ::std::mem::transmute(instruction_length) };
4568 instruction_length as u64
4569 });
4570 __bindgen_bitfield_unit.set(9usize, 1u8, {
4571 let nested_event: u32 = unsafe { ::std::mem::transmute(nested_event) };
4572 nested_event as u64
4573 });
4574 __bindgen_bitfield_unit.set(10usize, 6u8, {
4575 let reserved: u32 = unsafe { ::std::mem::transmute(reserved) };
4576 reserved as u64
4577 });
4578 __bindgen_bitfield_unit.set(16usize, 16u8, {
4579 let interruption_vector: u32 = unsafe { ::std::mem::transmute(interruption_vector) };
4580 interruption_vector as u64
4581 });
4582 __bindgen_bitfield_unit
4583 }
4584}
4585#[test]
4586fn bindgen_test_layout_hv_x64_pending_interruption_register() {
4587 const UNINIT: ::std::mem::MaybeUninit<hv_x64_pending_interruption_register> =
4588 ::std::mem::MaybeUninit::uninit();
4589 let ptr = UNINIT.as_ptr();
4590 assert_eq!(
4591 ::std::mem::size_of::<hv_x64_pending_interruption_register>(),
4592 8usize,
4593 concat!(
4594 "Size of: ",
4595 stringify!(hv_x64_pending_interruption_register)
4596 )
4597 );
4598 assert_eq!(
4599 ::std::mem::align_of::<hv_x64_pending_interruption_register>(),
4600 8usize,
4601 concat!(
4602 "Alignment of ",
4603 stringify!(hv_x64_pending_interruption_register)
4604 )
4605 );
4606 assert_eq!(
4607 unsafe { ::std::ptr::addr_of!((*ptr).as_uint64) as usize - ptr as usize },
4608 0usize,
4609 concat!(
4610 "Offset of field: ",
4611 stringify!(hv_x64_pending_interruption_register),
4612 "::",
4613 stringify!(as_uint64)
4614 )
4615 );
4616}
4617impl Default for hv_x64_pending_interruption_register {
4618 fn default() -> Self {
4619 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
4620 unsafe {
4621 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
4622 s.assume_init()
4623 }
4624 }
4625}
4626#[repr(C)]
4627#[derive(Copy, Clone)]
4628pub union hv_x64_register_sev_control {
4629 pub as_uint64: __u64,
4630 pub __bindgen_anon_1: hv_x64_register_sev_control__bindgen_ty_1,
4631}
4632#[repr(C, packed)]
4633#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
4634pub struct hv_x64_register_sev_control__bindgen_ty_1 {
4635 pub _bitfield_align_1: [u8; 0],
4636 pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>,
4637}
4638#[test]
4639fn bindgen_test_layout_hv_x64_register_sev_control__bindgen_ty_1() {
4640 assert_eq!(
4641 ::std::mem::size_of::<hv_x64_register_sev_control__bindgen_ty_1>(),
4642 8usize,
4643 concat!(
4644 "Size of: ",
4645 stringify!(hv_x64_register_sev_control__bindgen_ty_1)
4646 )
4647 );
4648 assert_eq!(
4649 ::std::mem::align_of::<hv_x64_register_sev_control__bindgen_ty_1>(),
4650 1usize,
4651 concat!(
4652 "Alignment of ",
4653 stringify!(hv_x64_register_sev_control__bindgen_ty_1)
4654 )
4655 );
4656}
4657impl hv_x64_register_sev_control__bindgen_ty_1 {
4658 #[inline]
4659 pub fn enable_encrypted_state(&self) -> __u64 {
4660 unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 1u8) as u64) }
4661 }
4662 #[inline]
4663 pub fn set_enable_encrypted_state(&mut self, val: __u64) {
4664 unsafe {
4665 let val: u64 = ::std::mem::transmute(val);
4666 self._bitfield_1.set(0usize, 1u8, val as u64)
4667 }
4668 }
4669 #[inline]
4670 pub fn reserved_z(&self) -> __u64 {
4671 unsafe { ::std::mem::transmute(self._bitfield_1.get(1usize, 11u8) as u64) }
4672 }
4673 #[inline]
4674 pub fn set_reserved_z(&mut self, val: __u64) {
4675 unsafe {
4676 let val: u64 = ::std::mem::transmute(val);
4677 self._bitfield_1.set(1usize, 11u8, val as u64)
4678 }
4679 }
4680 #[inline]
4681 pub fn vmsa_gpa_page_number(&self) -> __u64 {
4682 unsafe { ::std::mem::transmute(self._bitfield_1.get(12usize, 52u8) as u64) }
4683 }
4684 #[inline]
4685 pub fn set_vmsa_gpa_page_number(&mut self, val: __u64) {
4686 unsafe {
4687 let val: u64 = ::std::mem::transmute(val);
4688 self._bitfield_1.set(12usize, 52u8, val as u64)
4689 }
4690 }
4691 #[inline]
4692 pub fn new_bitfield_1(
4693 enable_encrypted_state: __u64,
4694 reserved_z: __u64,
4695 vmsa_gpa_page_number: __u64,
4696 ) -> __BindgenBitfieldUnit<[u8; 8usize]> {
4697 let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 8usize]> = Default::default();
4698 __bindgen_bitfield_unit.set(0usize, 1u8, {
4699 let enable_encrypted_state: u64 =
4700 unsafe { ::std::mem::transmute(enable_encrypted_state) };
4701 enable_encrypted_state as u64
4702 });
4703 __bindgen_bitfield_unit.set(1usize, 11u8, {
4704 let reserved_z: u64 = unsafe { ::std::mem::transmute(reserved_z) };
4705 reserved_z as u64
4706 });
4707 __bindgen_bitfield_unit.set(12usize, 52u8, {
4708 let vmsa_gpa_page_number: u64 = unsafe { ::std::mem::transmute(vmsa_gpa_page_number) };
4709 vmsa_gpa_page_number as u64
4710 });
4711 __bindgen_bitfield_unit
4712 }
4713}
4714#[test]
4715fn bindgen_test_layout_hv_x64_register_sev_control() {
4716 const UNINIT: ::std::mem::MaybeUninit<hv_x64_register_sev_control> =
4717 ::std::mem::MaybeUninit::uninit();
4718 let ptr = UNINIT.as_ptr();
4719 assert_eq!(
4720 ::std::mem::size_of::<hv_x64_register_sev_control>(),
4721 8usize,
4722 concat!("Size of: ", stringify!(hv_x64_register_sev_control))
4723 );
4724 assert_eq!(
4725 ::std::mem::align_of::<hv_x64_register_sev_control>(),
4726 8usize,
4727 concat!("Alignment of ", stringify!(hv_x64_register_sev_control))
4728 );
4729 assert_eq!(
4730 unsafe { ::std::ptr::addr_of!((*ptr).as_uint64) as usize - ptr as usize },
4731 0usize,
4732 concat!(
4733 "Offset of field: ",
4734 stringify!(hv_x64_register_sev_control),
4735 "::",
4736 stringify!(as_uint64)
4737 )
4738 );
4739}
4740impl Default for hv_x64_register_sev_control {
4741 fn default() -> Self {
4742 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
4743 unsafe {
4744 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
4745 s.assume_init()
4746 }
4747 }
4748}
4749#[repr(C)]
4750#[derive(Copy, Clone)]
4751pub union hv_register_value {
4752 pub reg128: hv_u128,
4753 pub reg64: __u64,
4754 pub reg32: __u32,
4755 pub reg16: __u16,
4756 pub reg8: __u8,
4757 pub fp: hv_x64_fp_register,
4758 pub fp_control_status: hv_x64_fp_control_status_register,
4759 pub xmm_control_status: hv_x64_xmm_control_status_register,
4760 pub segment: hv_x64_segment_register,
4761 pub table: hv_x64_table_register,
4762 pub explicit_suspend: hv_explicit_suspend_register,
4763 pub intercept_suspend: hv_intercept_suspend_register,
4764 pub internal_activity: hv_internal_activity_register,
4765 pub interrupt_state: hv_x64_interrupt_state_register,
4766 pub pending_interruption: hv_x64_pending_interruption_register,
4767 pub npiep_config: hv_x64_msr_npiep_config_contents,
4768 pub pending_exception_event: hv_x64_pending_exception_event,
4769 pub pending_virtualization_fault_event: hv_x64_pending_virtualization_fault_event,
4770 pub sev_control: hv_x64_register_sev_control,
4771}
4772#[test]
4773fn bindgen_test_layout_hv_register_value() {
4774 const UNINIT: ::std::mem::MaybeUninit<hv_register_value> = ::std::mem::MaybeUninit::uninit();
4775 let ptr = UNINIT.as_ptr();
4776 assert_eq!(
4777 ::std::mem::size_of::<hv_register_value>(),
4778 16usize,
4779 concat!("Size of: ", stringify!(hv_register_value))
4780 );
4781 assert_eq!(
4782 ::std::mem::align_of::<hv_register_value>(),
4783 8usize,
4784 concat!("Alignment of ", stringify!(hv_register_value))
4785 );
4786 assert_eq!(
4787 unsafe { ::std::ptr::addr_of!((*ptr).reg128) as usize - ptr as usize },
4788 0usize,
4789 concat!(
4790 "Offset of field: ",
4791 stringify!(hv_register_value),
4792 "::",
4793 stringify!(reg128)
4794 )
4795 );
4796 assert_eq!(
4797 unsafe { ::std::ptr::addr_of!((*ptr).reg64) as usize - ptr as usize },
4798 0usize,
4799 concat!(
4800 "Offset of field: ",
4801 stringify!(hv_register_value),
4802 "::",
4803 stringify!(reg64)
4804 )
4805 );
4806 assert_eq!(
4807 unsafe { ::std::ptr::addr_of!((*ptr).reg32) as usize - ptr as usize },
4808 0usize,
4809 concat!(
4810 "Offset of field: ",
4811 stringify!(hv_register_value),
4812 "::",
4813 stringify!(reg32)
4814 )
4815 );
4816 assert_eq!(
4817 unsafe { ::std::ptr::addr_of!((*ptr).reg16) as usize - ptr as usize },
4818 0usize,
4819 concat!(
4820 "Offset of field: ",
4821 stringify!(hv_register_value),
4822 "::",
4823 stringify!(reg16)
4824 )
4825 );
4826 assert_eq!(
4827 unsafe { ::std::ptr::addr_of!((*ptr).reg8) as usize - ptr as usize },
4828 0usize,
4829 concat!(
4830 "Offset of field: ",
4831 stringify!(hv_register_value),
4832 "::",
4833 stringify!(reg8)
4834 )
4835 );
4836 assert_eq!(
4837 unsafe { ::std::ptr::addr_of!((*ptr).fp) as usize - ptr as usize },
4838 0usize,
4839 concat!(
4840 "Offset of field: ",
4841 stringify!(hv_register_value),
4842 "::",
4843 stringify!(fp)
4844 )
4845 );
4846 assert_eq!(
4847 unsafe { ::std::ptr::addr_of!((*ptr).fp_control_status) as usize - ptr as usize },
4848 0usize,
4849 concat!(
4850 "Offset of field: ",
4851 stringify!(hv_register_value),
4852 "::",
4853 stringify!(fp_control_status)
4854 )
4855 );
4856 assert_eq!(
4857 unsafe { ::std::ptr::addr_of!((*ptr).xmm_control_status) as usize - ptr as usize },
4858 0usize,
4859 concat!(
4860 "Offset of field: ",
4861 stringify!(hv_register_value),
4862 "::",
4863 stringify!(xmm_control_status)
4864 )
4865 );
4866 assert_eq!(
4867 unsafe { ::std::ptr::addr_of!((*ptr).segment) as usize - ptr as usize },
4868 0usize,
4869 concat!(
4870 "Offset of field: ",
4871 stringify!(hv_register_value),
4872 "::",
4873 stringify!(segment)
4874 )
4875 );
4876 assert_eq!(
4877 unsafe { ::std::ptr::addr_of!((*ptr).table) as usize - ptr as usize },
4878 0usize,
4879 concat!(
4880 "Offset of field: ",
4881 stringify!(hv_register_value),
4882 "::",
4883 stringify!(table)
4884 )
4885 );
4886 assert_eq!(
4887 unsafe { ::std::ptr::addr_of!((*ptr).explicit_suspend) as usize - ptr as usize },
4888 0usize,
4889 concat!(
4890 "Offset of field: ",
4891 stringify!(hv_register_value),
4892 "::",
4893 stringify!(explicit_suspend)
4894 )
4895 );
4896 assert_eq!(
4897 unsafe { ::std::ptr::addr_of!((*ptr).intercept_suspend) as usize - ptr as usize },
4898 0usize,
4899 concat!(
4900 "Offset of field: ",
4901 stringify!(hv_register_value),
4902 "::",
4903 stringify!(intercept_suspend)
4904 )
4905 );
4906 assert_eq!(
4907 unsafe { ::std::ptr::addr_of!((*ptr).internal_activity) as usize - ptr as usize },
4908 0usize,
4909 concat!(
4910 "Offset of field: ",
4911 stringify!(hv_register_value),
4912 "::",
4913 stringify!(internal_activity)
4914 )
4915 );
4916 assert_eq!(
4917 unsafe { ::std::ptr::addr_of!((*ptr).interrupt_state) as usize - ptr as usize },
4918 0usize,
4919 concat!(
4920 "Offset of field: ",
4921 stringify!(hv_register_value),
4922 "::",
4923 stringify!(interrupt_state)
4924 )
4925 );
4926 assert_eq!(
4927 unsafe { ::std::ptr::addr_of!((*ptr).pending_interruption) as usize - ptr as usize },
4928 0usize,
4929 concat!(
4930 "Offset of field: ",
4931 stringify!(hv_register_value),
4932 "::",
4933 stringify!(pending_interruption)
4934 )
4935 );
4936 assert_eq!(
4937 unsafe { ::std::ptr::addr_of!((*ptr).npiep_config) as usize - ptr as usize },
4938 0usize,
4939 concat!(
4940 "Offset of field: ",
4941 stringify!(hv_register_value),
4942 "::",
4943 stringify!(npiep_config)
4944 )
4945 );
4946 assert_eq!(
4947 unsafe { ::std::ptr::addr_of!((*ptr).pending_exception_event) as usize - ptr as usize },
4948 0usize,
4949 concat!(
4950 "Offset of field: ",
4951 stringify!(hv_register_value),
4952 "::",
4953 stringify!(pending_exception_event)
4954 )
4955 );
4956 assert_eq!(
4957 unsafe {
4958 ::std::ptr::addr_of!((*ptr).pending_virtualization_fault_event) as usize - ptr as usize
4959 },
4960 0usize,
4961 concat!(
4962 "Offset of field: ",
4963 stringify!(hv_register_value),
4964 "::",
4965 stringify!(pending_virtualization_fault_event)
4966 )
4967 );
4968 assert_eq!(
4969 unsafe { ::std::ptr::addr_of!((*ptr).sev_control) as usize - ptr as usize },
4970 0usize,
4971 concat!(
4972 "Offset of field: ",
4973 stringify!(hv_register_value),
4974 "::",
4975 stringify!(sev_control)
4976 )
4977 );
4978}
4979impl Default for hv_register_value {
4980 fn default() -> Self {
4981 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
4982 unsafe {
4983 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
4984 s.assume_init()
4985 }
4986 }
4987}
4988#[repr(C, packed)]
4989#[derive(Copy, Clone)]
4990pub struct hv_register_assoc {
4991 pub name: __u32,
4992 pub reserved1: __u32,
4993 pub reserved2: __u64,
4994 pub value: hv_register_value,
4995}
4996#[test]
4997fn bindgen_test_layout_hv_register_assoc() {
4998 const UNINIT: ::std::mem::MaybeUninit<hv_register_assoc> = ::std::mem::MaybeUninit::uninit();
4999 let ptr = UNINIT.as_ptr();
5000 assert_eq!(
5001 ::std::mem::size_of::<hv_register_assoc>(),
5002 32usize,
5003 concat!("Size of: ", stringify!(hv_register_assoc))
5004 );
5005 assert_eq!(
5006 ::std::mem::align_of::<hv_register_assoc>(),
5007 1usize,
5008 concat!("Alignment of ", stringify!(hv_register_assoc))
5009 );
5010 assert_eq!(
5011 unsafe { ::std::ptr::addr_of!((*ptr).name) as usize - ptr as usize },
5012 0usize,
5013 concat!(
5014 "Offset of field: ",
5015 stringify!(hv_register_assoc),
5016 "::",
5017 stringify!(name)
5018 )
5019 );
5020 assert_eq!(
5021 unsafe { ::std::ptr::addr_of!((*ptr).reserved1) as usize - ptr as usize },
5022 4usize,
5023 concat!(
5024 "Offset of field: ",
5025 stringify!(hv_register_assoc),
5026 "::",
5027 stringify!(reserved1)
5028 )
5029 );
5030 assert_eq!(
5031 unsafe { ::std::ptr::addr_of!((*ptr).reserved2) as usize - ptr as usize },
5032 8usize,
5033 concat!(
5034 "Offset of field: ",
5035 stringify!(hv_register_assoc),
5036 "::",
5037 stringify!(reserved2)
5038 )
5039 );
5040 assert_eq!(
5041 unsafe { ::std::ptr::addr_of!((*ptr).value) as usize - ptr as usize },
5042 16usize,
5043 concat!(
5044 "Offset of field: ",
5045 stringify!(hv_register_assoc),
5046 "::",
5047 stringify!(value)
5048 )
5049 );
5050}
5051impl Default for hv_register_assoc {
5052 fn default() -> Self {
5053 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
5054 unsafe {
5055 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
5056 s.assume_init()
5057 }
5058 }
5059}
5060#[repr(C, packed)]
5061pub struct hv_input_get_vp_registers {
5062 pub partition_id: __u64,
5063 pub vp_index: __u32,
5064 pub input_vtl: hv_input_vtl,
5065 pub rsvd_z8: __u8,
5066 pub rsvd_z16: __u16,
5067 pub names: __IncompleteArrayField<__u32>,
5068}
5069#[test]
5070fn bindgen_test_layout_hv_input_get_vp_registers() {
5071 const UNINIT: ::std::mem::MaybeUninit<hv_input_get_vp_registers> =
5072 ::std::mem::MaybeUninit::uninit();
5073 let ptr = UNINIT.as_ptr();
5074 assert_eq!(
5075 ::std::mem::size_of::<hv_input_get_vp_registers>(),
5076 16usize,
5077 concat!("Size of: ", stringify!(hv_input_get_vp_registers))
5078 );
5079 assert_eq!(
5080 ::std::mem::align_of::<hv_input_get_vp_registers>(),
5081 1usize,
5082 concat!("Alignment of ", stringify!(hv_input_get_vp_registers))
5083 );
5084 assert_eq!(
5085 unsafe { ::std::ptr::addr_of!((*ptr).partition_id) as usize - ptr as usize },
5086 0usize,
5087 concat!(
5088 "Offset of field: ",
5089 stringify!(hv_input_get_vp_registers),
5090 "::",
5091 stringify!(partition_id)
5092 )
5093 );
5094 assert_eq!(
5095 unsafe { ::std::ptr::addr_of!((*ptr).vp_index) as usize - ptr as usize },
5096 8usize,
5097 concat!(
5098 "Offset of field: ",
5099 stringify!(hv_input_get_vp_registers),
5100 "::",
5101 stringify!(vp_index)
5102 )
5103 );
5104 assert_eq!(
5105 unsafe { ::std::ptr::addr_of!((*ptr).input_vtl) as usize - ptr as usize },
5106 12usize,
5107 concat!(
5108 "Offset of field: ",
5109 stringify!(hv_input_get_vp_registers),
5110 "::",
5111 stringify!(input_vtl)
5112 )
5113 );
5114 assert_eq!(
5115 unsafe { ::std::ptr::addr_of!((*ptr).rsvd_z8) as usize - ptr as usize },
5116 13usize,
5117 concat!(
5118 "Offset of field: ",
5119 stringify!(hv_input_get_vp_registers),
5120 "::",
5121 stringify!(rsvd_z8)
5122 )
5123 );
5124 assert_eq!(
5125 unsafe { ::std::ptr::addr_of!((*ptr).rsvd_z16) as usize - ptr as usize },
5126 14usize,
5127 concat!(
5128 "Offset of field: ",
5129 stringify!(hv_input_get_vp_registers),
5130 "::",
5131 stringify!(rsvd_z16)
5132 )
5133 );
5134 assert_eq!(
5135 unsafe { ::std::ptr::addr_of!((*ptr).names) as usize - ptr as usize },
5136 16usize,
5137 concat!(
5138 "Offset of field: ",
5139 stringify!(hv_input_get_vp_registers),
5140 "::",
5141 stringify!(names)
5142 )
5143 );
5144}
5145impl Default for hv_input_get_vp_registers {
5146 fn default() -> Self {
5147 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
5148 unsafe {
5149 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
5150 s.assume_init()
5151 }
5152 }
5153}
5154#[repr(C, packed)]
5155pub struct hv_input_set_vp_registers {
5156 pub partition_id: __u64,
5157 pub vp_index: __u32,
5158 pub input_vtl: hv_input_vtl,
5159 pub rsvd_z8: __u8,
5160 pub rsvd_z16: __u16,
5161 pub elements: __IncompleteArrayField<hv_register_assoc>,
5162}
5163#[test]
5164fn bindgen_test_layout_hv_input_set_vp_registers() {
5165 const UNINIT: ::std::mem::MaybeUninit<hv_input_set_vp_registers> =
5166 ::std::mem::MaybeUninit::uninit();
5167 let ptr = UNINIT.as_ptr();
5168 assert_eq!(
5169 ::std::mem::size_of::<hv_input_set_vp_registers>(),
5170 16usize,
5171 concat!("Size of: ", stringify!(hv_input_set_vp_registers))
5172 );
5173 assert_eq!(
5174 ::std::mem::align_of::<hv_input_set_vp_registers>(),
5175 1usize,
5176 concat!("Alignment of ", stringify!(hv_input_set_vp_registers))
5177 );
5178 assert_eq!(
5179 unsafe { ::std::ptr::addr_of!((*ptr).partition_id) as usize - ptr as usize },
5180 0usize,
5181 concat!(
5182 "Offset of field: ",
5183 stringify!(hv_input_set_vp_registers),
5184 "::",
5185 stringify!(partition_id)
5186 )
5187 );
5188 assert_eq!(
5189 unsafe { ::std::ptr::addr_of!((*ptr).vp_index) as usize - ptr as usize },
5190 8usize,
5191 concat!(
5192 "Offset of field: ",
5193 stringify!(hv_input_set_vp_registers),
5194 "::",
5195 stringify!(vp_index)
5196 )
5197 );
5198 assert_eq!(
5199 unsafe { ::std::ptr::addr_of!((*ptr).input_vtl) as usize - ptr as usize },
5200 12usize,
5201 concat!(
5202 "Offset of field: ",
5203 stringify!(hv_input_set_vp_registers),
5204 "::",
5205 stringify!(input_vtl)
5206 )
5207 );
5208 assert_eq!(
5209 unsafe { ::std::ptr::addr_of!((*ptr).rsvd_z8) as usize - ptr as usize },
5210 13usize,
5211 concat!(
5212 "Offset of field: ",
5213 stringify!(hv_input_set_vp_registers),
5214 "::",
5215 stringify!(rsvd_z8)
5216 )
5217 );
5218 assert_eq!(
5219 unsafe { ::std::ptr::addr_of!((*ptr).rsvd_z16) as usize - ptr as usize },
5220 14usize,
5221 concat!(
5222 "Offset of field: ",
5223 stringify!(hv_input_set_vp_registers),
5224 "::",
5225 stringify!(rsvd_z16)
5226 )
5227 );
5228 assert_eq!(
5229 unsafe { ::std::ptr::addr_of!((*ptr).elements) as usize - ptr as usize },
5230 16usize,
5231 concat!(
5232 "Offset of field: ",
5233 stringify!(hv_input_set_vp_registers),
5234 "::",
5235 stringify!(elements)
5236 )
5237 );
5238}
5239impl Default for hv_input_set_vp_registers {
5240 fn default() -> Self {
5241 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
5242 unsafe {
5243 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
5244 s.assume_init()
5245 }
5246 }
5247}
5248pub const hv_intercept_type_HV_INTERCEPT_TYPE_X64_IO_PORT: hv_intercept_type = 0;
5249pub const hv_intercept_type_HV_INTERCEPT_TYPE_X64_MSR: hv_intercept_type = 1;
5250pub const hv_intercept_type_HV_INTERCEPT_TYPE_X64_CPUID: hv_intercept_type = 2;
5251pub const hv_intercept_type_HV_INTERCEPT_TYPE_EXCEPTION: hv_intercept_type = 3;
5252pub const hv_intercept_type_HV_INTERCEPT_TYPE_RESERVED0: hv_intercept_type = 4;
5253pub const hv_intercept_type_HV_INTERCEPT_TYPE_MMIO: hv_intercept_type = 5;
5254pub const hv_intercept_type_HV_INTERCEPT_TYPE_X64_GLOBAL_CPUID: hv_intercept_type = 6;
5255pub const hv_intercept_type_HV_INTERCEPT_TYPE_X64_APIC_SMI: hv_intercept_type = 7;
5256pub const hv_intercept_type_HV_INTERCEPT_TYPE_HYPERCALL: hv_intercept_type = 8;
5257pub const hv_intercept_type_HV_INTERCEPT_TYPE_X64_APIC_INIT_SIPI: hv_intercept_type = 9;
5258pub const hv_intercept_type_HV_INTERCEPT_MC_UPDATE_PATCH_LEVEL_MSR_READ: hv_intercept_type = 10;
5259pub const hv_intercept_type_HV_INTERCEPT_TYPE_X64_APIC_WRITE: hv_intercept_type = 11;
5260pub const hv_intercept_type_HV_INTERCEPT_TYPE_X64_MSR_INDEX: hv_intercept_type = 12;
5261pub const hv_intercept_type_HV_INTERCEPT_TYPE_MAX: hv_intercept_type = 13;
5262pub const hv_intercept_type_HV_INTERCEPT_TYPE_INVALID: hv_intercept_type = 4294967295;
5263pub type hv_intercept_type = ::std::os::raw::c_uint;
5264#[repr(C)]
5265#[derive(Copy, Clone)]
5266pub union hv_intercept_parameters {
5267 pub as_uint64: __u64,
5268 pub io_port: __u16,
5269 pub cpuid_index: __u32,
5270 pub apic_write_mask: __u32,
5271 pub exception_vector: __u16,
5272 pub msr_index: __u32,
5273}
5274#[test]
5275fn bindgen_test_layout_hv_intercept_parameters() {
5276 const UNINIT: ::std::mem::MaybeUninit<hv_intercept_parameters> =
5277 ::std::mem::MaybeUninit::uninit();
5278 let ptr = UNINIT.as_ptr();
5279 assert_eq!(
5280 ::std::mem::size_of::<hv_intercept_parameters>(),
5281 8usize,
5282 concat!("Size of: ", stringify!(hv_intercept_parameters))
5283 );
5284 assert_eq!(
5285 ::std::mem::align_of::<hv_intercept_parameters>(),
5286 8usize,
5287 concat!("Alignment of ", stringify!(hv_intercept_parameters))
5288 );
5289 assert_eq!(
5290 unsafe { ::std::ptr::addr_of!((*ptr).as_uint64) as usize - ptr as usize },
5291 0usize,
5292 concat!(
5293 "Offset of field: ",
5294 stringify!(hv_intercept_parameters),
5295 "::",
5296 stringify!(as_uint64)
5297 )
5298 );
5299 assert_eq!(
5300 unsafe { ::std::ptr::addr_of!((*ptr).io_port) as usize - ptr as usize },
5301 0usize,
5302 concat!(
5303 "Offset of field: ",
5304 stringify!(hv_intercept_parameters),
5305 "::",
5306 stringify!(io_port)
5307 )
5308 );
5309 assert_eq!(
5310 unsafe { ::std::ptr::addr_of!((*ptr).cpuid_index) as usize - ptr as usize },
5311 0usize,
5312 concat!(
5313 "Offset of field: ",
5314 stringify!(hv_intercept_parameters),
5315 "::",
5316 stringify!(cpuid_index)
5317 )
5318 );
5319 assert_eq!(
5320 unsafe { ::std::ptr::addr_of!((*ptr).apic_write_mask) as usize - ptr as usize },
5321 0usize,
5322 concat!(
5323 "Offset of field: ",
5324 stringify!(hv_intercept_parameters),
5325 "::",
5326 stringify!(apic_write_mask)
5327 )
5328 );
5329 assert_eq!(
5330 unsafe { ::std::ptr::addr_of!((*ptr).exception_vector) as usize - ptr as usize },
5331 0usize,
5332 concat!(
5333 "Offset of field: ",
5334 stringify!(hv_intercept_parameters),
5335 "::",
5336 stringify!(exception_vector)
5337 )
5338 );
5339 assert_eq!(
5340 unsafe { ::std::ptr::addr_of!((*ptr).msr_index) as usize - ptr as usize },
5341 0usize,
5342 concat!(
5343 "Offset of field: ",
5344 stringify!(hv_intercept_parameters),
5345 "::",
5346 stringify!(msr_index)
5347 )
5348 );
5349}
5350impl Default for hv_intercept_parameters {
5351 fn default() -> Self {
5352 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
5353 unsafe {
5354 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
5355 s.assume_init()
5356 }
5357 }
5358}
5359#[repr(C, packed)]
5360#[derive(Copy, Clone)]
5361pub struct hv_input_install_intercept {
5362 pub partition_id: __u64,
5363 pub access_type: __u32,
5364 pub intercept_type: __u32,
5365 pub intercept_parameter: hv_intercept_parameters,
5366}
5367#[test]
5368fn bindgen_test_layout_hv_input_install_intercept() {
5369 const UNINIT: ::std::mem::MaybeUninit<hv_input_install_intercept> =
5370 ::std::mem::MaybeUninit::uninit();
5371 let ptr = UNINIT.as_ptr();
5372 assert_eq!(
5373 ::std::mem::size_of::<hv_input_install_intercept>(),
5374 24usize,
5375 concat!("Size of: ", stringify!(hv_input_install_intercept))
5376 );
5377 assert_eq!(
5378 ::std::mem::align_of::<hv_input_install_intercept>(),
5379 1usize,
5380 concat!("Alignment of ", stringify!(hv_input_install_intercept))
5381 );
5382 assert_eq!(
5383 unsafe { ::std::ptr::addr_of!((*ptr).partition_id) as usize - ptr as usize },
5384 0usize,
5385 concat!(
5386 "Offset of field: ",
5387 stringify!(hv_input_install_intercept),
5388 "::",
5389 stringify!(partition_id)
5390 )
5391 );
5392 assert_eq!(
5393 unsafe { ::std::ptr::addr_of!((*ptr).access_type) as usize - ptr as usize },
5394 8usize,
5395 concat!(
5396 "Offset of field: ",
5397 stringify!(hv_input_install_intercept),
5398 "::",
5399 stringify!(access_type)
5400 )
5401 );
5402 assert_eq!(
5403 unsafe { ::std::ptr::addr_of!((*ptr).intercept_type) as usize - ptr as usize },
5404 12usize,
5405 concat!(
5406 "Offset of field: ",
5407 stringify!(hv_input_install_intercept),
5408 "::",
5409 stringify!(intercept_type)
5410 )
5411 );
5412 assert_eq!(
5413 unsafe { ::std::ptr::addr_of!((*ptr).intercept_parameter) as usize - ptr as usize },
5414 16usize,
5415 concat!(
5416 "Offset of field: ",
5417 stringify!(hv_input_install_intercept),
5418 "::",
5419 stringify!(intercept_parameter)
5420 )
5421 );
5422}
5423impl Default for hv_input_install_intercept {
5424 fn default() -> Self {
5425 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
5426 unsafe {
5427 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
5428 s.assume_init()
5429 }
5430 }
5431}
5432#[repr(C)]
5433#[derive(Copy, Clone)]
5434pub union hv_x64_register_sev_ghcb {
5435 pub as_uint64: __u64,
5436 pub __bindgen_anon_1: hv_x64_register_sev_ghcb__bindgen_ty_1,
5437}
5438#[repr(C, packed)]
5439#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
5440pub struct hv_x64_register_sev_ghcb__bindgen_ty_1 {
5441 pub _bitfield_align_1: [u8; 0],
5442 pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>,
5443}
5444#[test]
5445fn bindgen_test_layout_hv_x64_register_sev_ghcb__bindgen_ty_1() {
5446 assert_eq!(
5447 ::std::mem::size_of::<hv_x64_register_sev_ghcb__bindgen_ty_1>(),
5448 8usize,
5449 concat!(
5450 "Size of: ",
5451 stringify!(hv_x64_register_sev_ghcb__bindgen_ty_1)
5452 )
5453 );
5454 assert_eq!(
5455 ::std::mem::align_of::<hv_x64_register_sev_ghcb__bindgen_ty_1>(),
5456 1usize,
5457 concat!(
5458 "Alignment of ",
5459 stringify!(hv_x64_register_sev_ghcb__bindgen_ty_1)
5460 )
5461 );
5462}
5463impl hv_x64_register_sev_ghcb__bindgen_ty_1 {
5464 #[inline]
5465 pub fn enabled(&self) -> __u64 {
5466 unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 1u8) as u64) }
5467 }
5468 #[inline]
5469 pub fn set_enabled(&mut self, val: __u64) {
5470 unsafe {
5471 let val: u64 = ::std::mem::transmute(val);
5472 self._bitfield_1.set(0usize, 1u8, val as u64)
5473 }
5474 }
5475 #[inline]
5476 pub fn reservedz(&self) -> __u64 {
5477 unsafe { ::std::mem::transmute(self._bitfield_1.get(1usize, 11u8) as u64) }
5478 }
5479 #[inline]
5480 pub fn set_reservedz(&mut self, val: __u64) {
5481 unsafe {
5482 let val: u64 = ::std::mem::transmute(val);
5483 self._bitfield_1.set(1usize, 11u8, val as u64)
5484 }
5485 }
5486 #[inline]
5487 pub fn page_number(&self) -> __u64 {
5488 unsafe { ::std::mem::transmute(self._bitfield_1.get(12usize, 52u8) as u64) }
5489 }
5490 #[inline]
5491 pub fn set_page_number(&mut self, val: __u64) {
5492 unsafe {
5493 let val: u64 = ::std::mem::transmute(val);
5494 self._bitfield_1.set(12usize, 52u8, val as u64)
5495 }
5496 }
5497 #[inline]
5498 pub fn new_bitfield_1(
5499 enabled: __u64,
5500 reservedz: __u64,
5501 page_number: __u64,
5502 ) -> __BindgenBitfieldUnit<[u8; 8usize]> {
5503 let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 8usize]> = Default::default();
5504 __bindgen_bitfield_unit.set(0usize, 1u8, {
5505 let enabled: u64 = unsafe { ::std::mem::transmute(enabled) };
5506 enabled as u64
5507 });
5508 __bindgen_bitfield_unit.set(1usize, 11u8, {
5509 let reservedz: u64 = unsafe { ::std::mem::transmute(reservedz) };
5510 reservedz as u64
5511 });
5512 __bindgen_bitfield_unit.set(12usize, 52u8, {
5513 let page_number: u64 = unsafe { ::std::mem::transmute(page_number) };
5514 page_number as u64
5515 });
5516 __bindgen_bitfield_unit
5517 }
5518}
5519#[test]
5520fn bindgen_test_layout_hv_x64_register_sev_ghcb() {
5521 const UNINIT: ::std::mem::MaybeUninit<hv_x64_register_sev_ghcb> =
5522 ::std::mem::MaybeUninit::uninit();
5523 let ptr = UNINIT.as_ptr();
5524 assert_eq!(
5525 ::std::mem::size_of::<hv_x64_register_sev_ghcb>(),
5526 8usize,
5527 concat!("Size of: ", stringify!(hv_x64_register_sev_ghcb))
5528 );
5529 assert_eq!(
5530 ::std::mem::align_of::<hv_x64_register_sev_ghcb>(),
5531 8usize,
5532 concat!("Alignment of ", stringify!(hv_x64_register_sev_ghcb))
5533 );
5534 assert_eq!(
5535 unsafe { ::std::ptr::addr_of!((*ptr).as_uint64) as usize - ptr as usize },
5536 0usize,
5537 concat!(
5538 "Offset of field: ",
5539 stringify!(hv_x64_register_sev_ghcb),
5540 "::",
5541 stringify!(as_uint64)
5542 )
5543 );
5544}
5545impl Default for hv_x64_register_sev_ghcb {
5546 fn default() -> Self {
5547 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
5548 unsafe {
5549 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
5550 s.assume_init()
5551 }
5552 }
5553}
5554#[repr(C)]
5555#[derive(Copy, Clone)]
5556pub union hv_x64_register_sev_hv_doorbell {
5557 pub as_uint64: __u64,
5558 pub __bindgen_anon_1: hv_x64_register_sev_hv_doorbell__bindgen_ty_1,
5559}
5560#[repr(C, packed)]
5561#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
5562pub struct hv_x64_register_sev_hv_doorbell__bindgen_ty_1 {
5563 pub _bitfield_align_1: [u8; 0],
5564 pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>,
5565}
5566#[test]
5567fn bindgen_test_layout_hv_x64_register_sev_hv_doorbell__bindgen_ty_1() {
5568 assert_eq!(
5569 ::std::mem::size_of::<hv_x64_register_sev_hv_doorbell__bindgen_ty_1>(),
5570 8usize,
5571 concat!(
5572 "Size of: ",
5573 stringify!(hv_x64_register_sev_hv_doorbell__bindgen_ty_1)
5574 )
5575 );
5576 assert_eq!(
5577 ::std::mem::align_of::<hv_x64_register_sev_hv_doorbell__bindgen_ty_1>(),
5578 1usize,
5579 concat!(
5580 "Alignment of ",
5581 stringify!(hv_x64_register_sev_hv_doorbell__bindgen_ty_1)
5582 )
5583 );
5584}
5585impl hv_x64_register_sev_hv_doorbell__bindgen_ty_1 {
5586 #[inline]
5587 pub fn enabled(&self) -> __u64 {
5588 unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 1u8) as u64) }
5589 }
5590 #[inline]
5591 pub fn set_enabled(&mut self, val: __u64) {
5592 unsafe {
5593 let val: u64 = ::std::mem::transmute(val);
5594 self._bitfield_1.set(0usize, 1u8, val as u64)
5595 }
5596 }
5597 #[inline]
5598 pub fn reservedz(&self) -> __u64 {
5599 unsafe { ::std::mem::transmute(self._bitfield_1.get(1usize, 11u8) as u64) }
5600 }
5601 #[inline]
5602 pub fn set_reservedz(&mut self, val: __u64) {
5603 unsafe {
5604 let val: u64 = ::std::mem::transmute(val);
5605 self._bitfield_1.set(1usize, 11u8, val as u64)
5606 }
5607 }
5608 #[inline]
5609 pub fn page_number(&self) -> __u64 {
5610 unsafe { ::std::mem::transmute(self._bitfield_1.get(12usize, 52u8) as u64) }
5611 }
5612 #[inline]
5613 pub fn set_page_number(&mut self, val: __u64) {
5614 unsafe {
5615 let val: u64 = ::std::mem::transmute(val);
5616 self._bitfield_1.set(12usize, 52u8, val as u64)
5617 }
5618 }
5619 #[inline]
5620 pub fn new_bitfield_1(
5621 enabled: __u64,
5622 reservedz: __u64,
5623 page_number: __u64,
5624 ) -> __BindgenBitfieldUnit<[u8; 8usize]> {
5625 let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 8usize]> = Default::default();
5626 __bindgen_bitfield_unit.set(0usize, 1u8, {
5627 let enabled: u64 = unsafe { ::std::mem::transmute(enabled) };
5628 enabled as u64
5629 });
5630 __bindgen_bitfield_unit.set(1usize, 11u8, {
5631 let reservedz: u64 = unsafe { ::std::mem::transmute(reservedz) };
5632 reservedz as u64
5633 });
5634 __bindgen_bitfield_unit.set(12usize, 52u8, {
5635 let page_number: u64 = unsafe { ::std::mem::transmute(page_number) };
5636 page_number as u64
5637 });
5638 __bindgen_bitfield_unit
5639 }
5640}
5641#[test]
5642fn bindgen_test_layout_hv_x64_register_sev_hv_doorbell() {
5643 const UNINIT: ::std::mem::MaybeUninit<hv_x64_register_sev_hv_doorbell> =
5644 ::std::mem::MaybeUninit::uninit();
5645 let ptr = UNINIT.as_ptr();
5646 assert_eq!(
5647 ::std::mem::size_of::<hv_x64_register_sev_hv_doorbell>(),
5648 8usize,
5649 concat!("Size of: ", stringify!(hv_x64_register_sev_hv_doorbell))
5650 );
5651 assert_eq!(
5652 ::std::mem::align_of::<hv_x64_register_sev_hv_doorbell>(),
5653 8usize,
5654 concat!("Alignment of ", stringify!(hv_x64_register_sev_hv_doorbell))
5655 );
5656 assert_eq!(
5657 unsafe { ::std::ptr::addr_of!((*ptr).as_uint64) as usize - ptr as usize },
5658 0usize,
5659 concat!(
5660 "Offset of field: ",
5661 stringify!(hv_x64_register_sev_hv_doorbell),
5662 "::",
5663 stringify!(as_uint64)
5664 )
5665 );
5666}
5667impl Default for hv_x64_register_sev_hv_doorbell {
5668 fn default() -> Self {
5669 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
5670 unsafe {
5671 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
5672 s.assume_init()
5673 }
5674 }
5675}
5676pub const hv_unimplemented_msr_action_HV_UNIMPLEMENTED_MSR_ACTION_FAULT:
5677 hv_unimplemented_msr_action = 0;
5678pub const hv_unimplemented_msr_action_HV_UNIMPLEMENTED_MSR_ACTION_IGNORE_WRITE_READ_ZERO:
5679 hv_unimplemented_msr_action = 1;
5680pub const hv_unimplemented_msr_action_HV_UNIMPLEMENTED_MSR_ACTION_COUNT:
5681 hv_unimplemented_msr_action = 2;
5682pub type hv_unimplemented_msr_action = ::std::os::raw::c_uint;
5683pub const hv_generic_set_format_HV_GENERIC_SET_SPARSE_4K: hv_generic_set_format = 0;
5684pub const hv_generic_set_format_HV_GENERIC_SET_ALL: hv_generic_set_format = 1;
5685pub type hv_generic_set_format = ::std::os::raw::c_uint;
5686pub const hv_partition_property_code_HV_PARTITION_PROPERTY_PRIVILEGE_FLAGS:
5687 hv_partition_property_code = 65536;
5688pub const hv_partition_property_code_HV_PARTITION_PROPERTY_SYNTHETIC_PROC_FEATURES:
5689 hv_partition_property_code = 65537;
5690pub const hv_partition_property_code_HV_PARTITION_PROPERTY_SUSPEND: hv_partition_property_code =
5691 131072;
5692pub const hv_partition_property_code_HV_PARTITION_PROPERTY_CPU_RESERVE: hv_partition_property_code =
5693 131073;
5694pub const hv_partition_property_code_HV_PARTITION_PROPERTY_CPU_CAP: hv_partition_property_code =
5695 131074;
5696pub const hv_partition_property_code_HV_PARTITION_PROPERTY_CPU_WEIGHT: hv_partition_property_code =
5697 131075;
5698pub const hv_partition_property_code_HV_PARTITION_PROPERTY_CPU_GROUP_ID:
5699 hv_partition_property_code = 131076;
5700pub const hv_partition_property_code_HV_PARTITION_PROPERTY_TIME_FREEZE: hv_partition_property_code =
5701 196611;
5702pub const hv_partition_property_code_HV_PARTITION_PROPERTY_REFERENCE_TIME:
5703 hv_partition_property_code = 196613;
5704pub const hv_partition_property_code_HV_PARTITION_PROPERTY_DEBUG_CHANNEL_ID:
5705 hv_partition_property_code = 262144;
5706pub const hv_partition_property_code_HV_PARTITION_PROPERTY_VIRTUAL_TLB_PAGE_COUNT:
5707 hv_partition_property_code = 327680;
5708pub const hv_partition_property_code_HV_PARTITION_PROPERTY_VSM_CONFIG: hv_partition_property_code =
5709 327681;
5710pub const hv_partition_property_code_HV_PARTITION_PROPERTY_ZERO_MEMORY_ON_RESET:
5711 hv_partition_property_code = 327682;
5712pub const hv_partition_property_code_HV_PARTITION_PROPERTY_PROCESSORS_PER_SOCKET:
5713 hv_partition_property_code = 327683;
5714pub const hv_partition_property_code_HV_PARTITION_PROPERTY_NESTED_TLB_SIZE:
5715 hv_partition_property_code = 327684;
5716pub const hv_partition_property_code_HV_PARTITION_PROPERTY_GPA_PAGE_ACCESS_TRACKING:
5717 hv_partition_property_code = 327685;
5718pub const hv_partition_property_code_HV_PARTITION_PROPERTY_VSM_PERMISSIONS_DIRTY_SINCE_LAST_QUERY : hv_partition_property_code = 327686 ;
5719pub const hv_partition_property_code_HV_PARTITION_PROPERTY_SGX_LAUNCH_CONTROL_CONFIG:
5720 hv_partition_property_code = 327687;
5721pub const hv_partition_property_code_HV_PARTITION_PROPERTY_DEFAULT_SGX_LAUNCH_CONTROL0:
5722 hv_partition_property_code = 327688;
5723pub const hv_partition_property_code_HV_PARTITION_PROPERTY_DEFAULT_SGX_LAUNCH_CONTROL1:
5724 hv_partition_property_code = 327689;
5725pub const hv_partition_property_code_HV_PARTITION_PROPERTY_DEFAULT_SGX_LAUNCH_CONTROL2:
5726 hv_partition_property_code = 327690;
5727pub const hv_partition_property_code_HV_PARTITION_PROPERTY_DEFAULT_SGX_LAUNCH_CONTROL3:
5728 hv_partition_property_code = 327691;
5729pub const hv_partition_property_code_HV_PARTITION_PROPERTY_ISOLATION_STATE:
5730 hv_partition_property_code = 327692;
5731pub const hv_partition_property_code_HV_PARTITION_PROPERTY_ISOLATION_CONTROL:
5732 hv_partition_property_code = 327693;
5733pub const hv_partition_property_code_HV_PARTITION_PROPERTY_ALLOCATION_ID:
5734 hv_partition_property_code = 327694;
5735pub const hv_partition_property_code_HV_PARTITION_PROPERTY_MONITORING_ID:
5736 hv_partition_property_code = 327695;
5737pub const hv_partition_property_code_HV_PARTITION_PROPERTY_IMPLEMENTED_PHYSICAL_ADDRESS_BITS:
5738 hv_partition_property_code = 327696;
5739pub const hv_partition_property_code_HV_PARTITION_PROPERTY_NON_ARCHITECTURAL_CORE_SHARING:
5740 hv_partition_property_code = 327697;
5741pub const hv_partition_property_code_HV_PARTITION_PROPERTY_HYPERCALL_DOORBELL_PAGE:
5742 hv_partition_property_code = 327698;
5743pub const hv_partition_property_code_HV_PARTITION_PROPERTY_ISOLATION_POLICY:
5744 hv_partition_property_code = 327700;
5745pub const hv_partition_property_code_HV_PARTITION_PROPERTY_UNIMPLEMENTED_MSR_ACTION:
5746 hv_partition_property_code = 327703;
5747pub const hv_partition_property_code_HV_PARTITION_PROPERTY_SEV_VMGEXIT_OFFLOADS:
5748 hv_partition_property_code = 327714;
5749pub const hv_partition_property_code_HV_PARTITION_PROPERTY_PROCESSOR_VENDOR:
5750 hv_partition_property_code = 393216;
5751pub const hv_partition_property_code_HV_PARTITION_PROPERTY_PROCESSOR_FEATURES_DEPRECATED:
5752 hv_partition_property_code = 393217;
5753pub const hv_partition_property_code_HV_PARTITION_PROPERTY_PROCESSOR_XSAVE_FEATURES:
5754 hv_partition_property_code = 393218;
5755pub const hv_partition_property_code_HV_PARTITION_PROPERTY_PROCESSOR_CL_FLUSH_SIZE:
5756 hv_partition_property_code = 393219;
5757pub const hv_partition_property_code_HV_PARTITION_PROPERTY_ENLIGHTENMENT_MODIFICATIONS:
5758 hv_partition_property_code = 393220;
5759pub const hv_partition_property_code_HV_PARTITION_PROPERTY_COMPATIBILITY_VERSION:
5760 hv_partition_property_code = 393221;
5761pub const hv_partition_property_code_HV_PARTITION_PROPERTY_PHYSICAL_ADDRESS_WIDTH:
5762 hv_partition_property_code = 393222;
5763pub const hv_partition_property_code_HV_PARTITION_PROPERTY_XSAVE_STATES:
5764 hv_partition_property_code = 393223;
5765pub const hv_partition_property_code_HV_PARTITION_PROPERTY_MAX_XSAVE_DATA_SIZE:
5766 hv_partition_property_code = 393224;
5767pub const hv_partition_property_code_HV_PARTITION_PROPERTY_PROCESSOR_CLOCK_FREQUENCY:
5768 hv_partition_property_code = 393225;
5769pub const hv_partition_property_code_HV_PARTITION_PROPERTY_PROCESSOR_FEATURES0:
5770 hv_partition_property_code = 393226;
5771pub const hv_partition_property_code_HV_PARTITION_PROPERTY_PROCESSOR_FEATURES1:
5772 hv_partition_property_code = 393227;
5773pub const hv_partition_property_code_HV_PARTITION_PROPERTY_GUEST_OS_ID: hv_partition_property_code =
5774 458752;
5775pub const hv_partition_property_code_HV_PARTITION_PROPERTY_PROCESSOR_VIRTUALIZATION_FEATURES:
5776 hv_partition_property_code = 524288;
5777pub type hv_partition_property_code = ::std::os::raw::c_uint;
5778#[repr(C)]
5779#[derive(Copy, Clone)]
5780pub union hv_pfn_range {
5781 pub as_uint64: __u64,
5782 pub __bindgen_anon_1: hv_pfn_range__bindgen_ty_1,
5783}
5784#[repr(C, packed)]
5785#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
5786pub struct hv_pfn_range__bindgen_ty_1 {
5787 pub _bitfield_align_1: [u8; 0],
5788 pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>,
5789}
5790#[test]
5791fn bindgen_test_layout_hv_pfn_range__bindgen_ty_1() {
5792 assert_eq!(
5793 ::std::mem::size_of::<hv_pfn_range__bindgen_ty_1>(),
5794 8usize,
5795 concat!("Size of: ", stringify!(hv_pfn_range__bindgen_ty_1))
5796 );
5797 assert_eq!(
5798 ::std::mem::align_of::<hv_pfn_range__bindgen_ty_1>(),
5799 1usize,
5800 concat!("Alignment of ", stringify!(hv_pfn_range__bindgen_ty_1))
5801 );
5802}
5803impl hv_pfn_range__bindgen_ty_1 {
5804 #[inline]
5805 pub fn base_pfn(&self) -> __u64 {
5806 unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 40u8) as u64) }
5807 }
5808 #[inline]
5809 pub fn set_base_pfn(&mut self, val: __u64) {
5810 unsafe {
5811 let val: u64 = ::std::mem::transmute(val);
5812 self._bitfield_1.set(0usize, 40u8, val as u64)
5813 }
5814 }
5815 #[inline]
5816 pub fn add_pfns(&self) -> __u64 {
5817 unsafe { ::std::mem::transmute(self._bitfield_1.get(40usize, 24u8) as u64) }
5818 }
5819 #[inline]
5820 pub fn set_add_pfns(&mut self, val: __u64) {
5821 unsafe {
5822 let val: u64 = ::std::mem::transmute(val);
5823 self._bitfield_1.set(40usize, 24u8, val as u64)
5824 }
5825 }
5826 #[inline]
5827 pub fn new_bitfield_1(base_pfn: __u64, add_pfns: __u64) -> __BindgenBitfieldUnit<[u8; 8usize]> {
5828 let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 8usize]> = Default::default();
5829 __bindgen_bitfield_unit.set(0usize, 40u8, {
5830 let base_pfn: u64 = unsafe { ::std::mem::transmute(base_pfn) };
5831 base_pfn as u64
5832 });
5833 __bindgen_bitfield_unit.set(40usize, 24u8, {
5834 let add_pfns: u64 = unsafe { ::std::mem::transmute(add_pfns) };
5835 add_pfns as u64
5836 });
5837 __bindgen_bitfield_unit
5838 }
5839}
5840#[test]
5841fn bindgen_test_layout_hv_pfn_range() {
5842 const UNINIT: ::std::mem::MaybeUninit<hv_pfn_range> = ::std::mem::MaybeUninit::uninit();
5843 let ptr = UNINIT.as_ptr();
5844 assert_eq!(
5845 ::std::mem::size_of::<hv_pfn_range>(),
5846 8usize,
5847 concat!("Size of: ", stringify!(hv_pfn_range))
5848 );
5849 assert_eq!(
5850 ::std::mem::align_of::<hv_pfn_range>(),
5851 8usize,
5852 concat!("Alignment of ", stringify!(hv_pfn_range))
5853 );
5854 assert_eq!(
5855 unsafe { ::std::ptr::addr_of!((*ptr).as_uint64) as usize - ptr as usize },
5856 0usize,
5857 concat!(
5858 "Offset of field: ",
5859 stringify!(hv_pfn_range),
5860 "::",
5861 stringify!(as_uint64)
5862 )
5863 );
5864}
5865impl Default for hv_pfn_range {
5866 fn default() -> Self {
5867 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
5868 unsafe {
5869 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
5870 s.assume_init()
5871 }
5872 }
5873}
5874#[repr(C)]
5875#[derive(Copy, Clone)]
5876pub union hv_snp_guest_policy {
5877 pub __bindgen_anon_1: hv_snp_guest_policy__bindgen_ty_1,
5878 pub as_uint64: __u64,
5879}
5880#[repr(C, packed)]
5881#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
5882pub struct hv_snp_guest_policy__bindgen_ty_1 {
5883 pub _bitfield_align_1: [u8; 0],
5884 pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>,
5885}
5886#[test]
5887fn bindgen_test_layout_hv_snp_guest_policy__bindgen_ty_1() {
5888 assert_eq!(
5889 ::std::mem::size_of::<hv_snp_guest_policy__bindgen_ty_1>(),
5890 8usize,
5891 concat!("Size of: ", stringify!(hv_snp_guest_policy__bindgen_ty_1))
5892 );
5893 assert_eq!(
5894 ::std::mem::align_of::<hv_snp_guest_policy__bindgen_ty_1>(),
5895 1usize,
5896 concat!(
5897 "Alignment of ",
5898 stringify!(hv_snp_guest_policy__bindgen_ty_1)
5899 )
5900 );
5901}
5902impl hv_snp_guest_policy__bindgen_ty_1 {
5903 #[inline]
5904 pub fn minor_version(&self) -> __u64 {
5905 unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 8u8) as u64) }
5906 }
5907 #[inline]
5908 pub fn set_minor_version(&mut self, val: __u64) {
5909 unsafe {
5910 let val: u64 = ::std::mem::transmute(val);
5911 self._bitfield_1.set(0usize, 8u8, val as u64)
5912 }
5913 }
5914 #[inline]
5915 pub fn major_version(&self) -> __u64 {
5916 unsafe { ::std::mem::transmute(self._bitfield_1.get(8usize, 8u8) as u64) }
5917 }
5918 #[inline]
5919 pub fn set_major_version(&mut self, val: __u64) {
5920 unsafe {
5921 let val: u64 = ::std::mem::transmute(val);
5922 self._bitfield_1.set(8usize, 8u8, val as u64)
5923 }
5924 }
5925 #[inline]
5926 pub fn smt_allowed(&self) -> __u64 {
5927 unsafe { ::std::mem::transmute(self._bitfield_1.get(16usize, 1u8) as u64) }
5928 }
5929 #[inline]
5930 pub fn set_smt_allowed(&mut self, val: __u64) {
5931 unsafe {
5932 let val: u64 = ::std::mem::transmute(val);
5933 self._bitfield_1.set(16usize, 1u8, val as u64)
5934 }
5935 }
5936 #[inline]
5937 pub fn vmpls_required(&self) -> __u64 {
5938 unsafe { ::std::mem::transmute(self._bitfield_1.get(17usize, 1u8) as u64) }
5939 }
5940 #[inline]
5941 pub fn set_vmpls_required(&mut self, val: __u64) {
5942 unsafe {
5943 let val: u64 = ::std::mem::transmute(val);
5944 self._bitfield_1.set(17usize, 1u8, val as u64)
5945 }
5946 }
5947 #[inline]
5948 pub fn migration_agent_allowed(&self) -> __u64 {
5949 unsafe { ::std::mem::transmute(self._bitfield_1.get(18usize, 1u8) as u64) }
5950 }
5951 #[inline]
5952 pub fn set_migration_agent_allowed(&mut self, val: __u64) {
5953 unsafe {
5954 let val: u64 = ::std::mem::transmute(val);
5955 self._bitfield_1.set(18usize, 1u8, val as u64)
5956 }
5957 }
5958 #[inline]
5959 pub fn debug_allowed(&self) -> __u64 {
5960 unsafe { ::std::mem::transmute(self._bitfield_1.get(19usize, 1u8) as u64) }
5961 }
5962 #[inline]
5963 pub fn set_debug_allowed(&mut self, val: __u64) {
5964 unsafe {
5965 let val: u64 = ::std::mem::transmute(val);
5966 self._bitfield_1.set(19usize, 1u8, val as u64)
5967 }
5968 }
5969 #[inline]
5970 pub fn reserved(&self) -> __u64 {
5971 unsafe { ::std::mem::transmute(self._bitfield_1.get(20usize, 44u8) as u64) }
5972 }
5973 #[inline]
5974 pub fn set_reserved(&mut self, val: __u64) {
5975 unsafe {
5976 let val: u64 = ::std::mem::transmute(val);
5977 self._bitfield_1.set(20usize, 44u8, val as u64)
5978 }
5979 }
5980 #[inline]
5981 pub fn new_bitfield_1(
5982 minor_version: __u64,
5983 major_version: __u64,
5984 smt_allowed: __u64,
5985 vmpls_required: __u64,
5986 migration_agent_allowed: __u64,
5987 debug_allowed: __u64,
5988 reserved: __u64,
5989 ) -> __BindgenBitfieldUnit<[u8; 8usize]> {
5990 let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 8usize]> = Default::default();
5991 __bindgen_bitfield_unit.set(0usize, 8u8, {
5992 let minor_version: u64 = unsafe { ::std::mem::transmute(minor_version) };
5993 minor_version as u64
5994 });
5995 __bindgen_bitfield_unit.set(8usize, 8u8, {
5996 let major_version: u64 = unsafe { ::std::mem::transmute(major_version) };
5997 major_version as u64
5998 });
5999 __bindgen_bitfield_unit.set(16usize, 1u8, {
6000 let smt_allowed: u64 = unsafe { ::std::mem::transmute(smt_allowed) };
6001 smt_allowed as u64
6002 });
6003 __bindgen_bitfield_unit.set(17usize, 1u8, {
6004 let vmpls_required: u64 = unsafe { ::std::mem::transmute(vmpls_required) };
6005 vmpls_required as u64
6006 });
6007 __bindgen_bitfield_unit.set(18usize, 1u8, {
6008 let migration_agent_allowed: u64 =
6009 unsafe { ::std::mem::transmute(migration_agent_allowed) };
6010 migration_agent_allowed as u64
6011 });
6012 __bindgen_bitfield_unit.set(19usize, 1u8, {
6013 let debug_allowed: u64 = unsafe { ::std::mem::transmute(debug_allowed) };
6014 debug_allowed as u64
6015 });
6016 __bindgen_bitfield_unit.set(20usize, 44u8, {
6017 let reserved: u64 = unsafe { ::std::mem::transmute(reserved) };
6018 reserved as u64
6019 });
6020 __bindgen_bitfield_unit
6021 }
6022}
6023#[test]
6024fn bindgen_test_layout_hv_snp_guest_policy() {
6025 const UNINIT: ::std::mem::MaybeUninit<hv_snp_guest_policy> = ::std::mem::MaybeUninit::uninit();
6026 let ptr = UNINIT.as_ptr();
6027 assert_eq!(
6028 ::std::mem::size_of::<hv_snp_guest_policy>(),
6029 8usize,
6030 concat!("Size of: ", stringify!(hv_snp_guest_policy))
6031 );
6032 assert_eq!(
6033 ::std::mem::align_of::<hv_snp_guest_policy>(),
6034 8usize,
6035 concat!("Alignment of ", stringify!(hv_snp_guest_policy))
6036 );
6037 assert_eq!(
6038 unsafe { ::std::ptr::addr_of!((*ptr).as_uint64) as usize - ptr as usize },
6039 0usize,
6040 concat!(
6041 "Offset of field: ",
6042 stringify!(hv_snp_guest_policy),
6043 "::",
6044 stringify!(as_uint64)
6045 )
6046 );
6047}
6048impl Default for hv_snp_guest_policy {
6049 fn default() -> Self {
6050 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
6051 unsafe {
6052 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
6053 s.assume_init()
6054 }
6055 }
6056}
6057#[repr(C, packed)]
6058#[derive(Copy, Clone)]
6059pub struct hv_snp_id_block {
6060 pub launch_digest: [__u8; 48usize],
6061 pub family_id: [__u8; 16usize],
6062 pub image_id: [__u8; 16usize],
6063 pub version: __u32,
6064 pub guest_svn: __u32,
6065 pub policy: hv_snp_guest_policy,
6066}
6067#[test]
6068fn bindgen_test_layout_hv_snp_id_block() {
6069 const UNINIT: ::std::mem::MaybeUninit<hv_snp_id_block> = ::std::mem::MaybeUninit::uninit();
6070 let ptr = UNINIT.as_ptr();
6071 assert_eq!(
6072 ::std::mem::size_of::<hv_snp_id_block>(),
6073 96usize,
6074 concat!("Size of: ", stringify!(hv_snp_id_block))
6075 );
6076 assert_eq!(
6077 ::std::mem::align_of::<hv_snp_id_block>(),
6078 1usize,
6079 concat!("Alignment of ", stringify!(hv_snp_id_block))
6080 );
6081 assert_eq!(
6082 unsafe { ::std::ptr::addr_of!((*ptr).launch_digest) as usize - ptr as usize },
6083 0usize,
6084 concat!(
6085 "Offset of field: ",
6086 stringify!(hv_snp_id_block),
6087 "::",
6088 stringify!(launch_digest)
6089 )
6090 );
6091 assert_eq!(
6092 unsafe { ::std::ptr::addr_of!((*ptr).family_id) as usize - ptr as usize },
6093 48usize,
6094 concat!(
6095 "Offset of field: ",
6096 stringify!(hv_snp_id_block),
6097 "::",
6098 stringify!(family_id)
6099 )
6100 );
6101 assert_eq!(
6102 unsafe { ::std::ptr::addr_of!((*ptr).image_id) as usize - ptr as usize },
6103 64usize,
6104 concat!(
6105 "Offset of field: ",
6106 stringify!(hv_snp_id_block),
6107 "::",
6108 stringify!(image_id)
6109 )
6110 );
6111 assert_eq!(
6112 unsafe { ::std::ptr::addr_of!((*ptr).version) as usize - ptr as usize },
6113 80usize,
6114 concat!(
6115 "Offset of field: ",
6116 stringify!(hv_snp_id_block),
6117 "::",
6118 stringify!(version)
6119 )
6120 );
6121 assert_eq!(
6122 unsafe { ::std::ptr::addr_of!((*ptr).guest_svn) as usize - ptr as usize },
6123 84usize,
6124 concat!(
6125 "Offset of field: ",
6126 stringify!(hv_snp_id_block),
6127 "::",
6128 stringify!(guest_svn)
6129 )
6130 );
6131 assert_eq!(
6132 unsafe { ::std::ptr::addr_of!((*ptr).policy) as usize - ptr as usize },
6133 88usize,
6134 concat!(
6135 "Offset of field: ",
6136 stringify!(hv_snp_id_block),
6137 "::",
6138 stringify!(policy)
6139 )
6140 );
6141}
6142impl Default for hv_snp_id_block {
6143 fn default() -> Self {
6144 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
6145 unsafe {
6146 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
6147 s.assume_init()
6148 }
6149 }
6150}
6151#[repr(C, packed)]
6152#[derive(Debug, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
6153pub struct hv_snp_id_auth_info {
6154 pub id_key_algorithm: __u32,
6155 pub auth_key_algorithm: __u32,
6156 pub reserved0: [__u8; 56usize],
6157 pub id_block_signature: [__u8; 512usize],
6158 pub id_key: [__u8; 1028usize],
6159 pub reserved1: [__u8; 60usize],
6160 pub id_key_signature: [__u8; 512usize],
6161 pub author_key: [__u8; 1028usize],
6162}
6163#[test]
6164fn bindgen_test_layout_hv_snp_id_auth_info() {
6165 const UNINIT: ::std::mem::MaybeUninit<hv_snp_id_auth_info> = ::std::mem::MaybeUninit::uninit();
6166 let ptr = UNINIT.as_ptr();
6167 assert_eq!(
6168 ::std::mem::size_of::<hv_snp_id_auth_info>(),
6169 3204usize,
6170 concat!("Size of: ", stringify!(hv_snp_id_auth_info))
6171 );
6172 assert_eq!(
6173 ::std::mem::align_of::<hv_snp_id_auth_info>(),
6174 1usize,
6175 concat!("Alignment of ", stringify!(hv_snp_id_auth_info))
6176 );
6177 assert_eq!(
6178 unsafe { ::std::ptr::addr_of!((*ptr).id_key_algorithm) as usize - ptr as usize },
6179 0usize,
6180 concat!(
6181 "Offset of field: ",
6182 stringify!(hv_snp_id_auth_info),
6183 "::",
6184 stringify!(id_key_algorithm)
6185 )
6186 );
6187 assert_eq!(
6188 unsafe { ::std::ptr::addr_of!((*ptr).auth_key_algorithm) as usize - ptr as usize },
6189 4usize,
6190 concat!(
6191 "Offset of field: ",
6192 stringify!(hv_snp_id_auth_info),
6193 "::",
6194 stringify!(auth_key_algorithm)
6195 )
6196 );
6197 assert_eq!(
6198 unsafe { ::std::ptr::addr_of!((*ptr).reserved0) as usize - ptr as usize },
6199 8usize,
6200 concat!(
6201 "Offset of field: ",
6202 stringify!(hv_snp_id_auth_info),
6203 "::",
6204 stringify!(reserved0)
6205 )
6206 );
6207 assert_eq!(
6208 unsafe { ::std::ptr::addr_of!((*ptr).id_block_signature) as usize - ptr as usize },
6209 64usize,
6210 concat!(
6211 "Offset of field: ",
6212 stringify!(hv_snp_id_auth_info),
6213 "::",
6214 stringify!(id_block_signature)
6215 )
6216 );
6217 assert_eq!(
6218 unsafe { ::std::ptr::addr_of!((*ptr).id_key) as usize - ptr as usize },
6219 576usize,
6220 concat!(
6221 "Offset of field: ",
6222 stringify!(hv_snp_id_auth_info),
6223 "::",
6224 stringify!(id_key)
6225 )
6226 );
6227 assert_eq!(
6228 unsafe { ::std::ptr::addr_of!((*ptr).reserved1) as usize - ptr as usize },
6229 1604usize,
6230 concat!(
6231 "Offset of field: ",
6232 stringify!(hv_snp_id_auth_info),
6233 "::",
6234 stringify!(reserved1)
6235 )
6236 );
6237 assert_eq!(
6238 unsafe { ::std::ptr::addr_of!((*ptr).id_key_signature) as usize - ptr as usize },
6239 1664usize,
6240 concat!(
6241 "Offset of field: ",
6242 stringify!(hv_snp_id_auth_info),
6243 "::",
6244 stringify!(id_key_signature)
6245 )
6246 );
6247 assert_eq!(
6248 unsafe { ::std::ptr::addr_of!((*ptr).author_key) as usize - ptr as usize },
6249 2176usize,
6250 concat!(
6251 "Offset of field: ",
6252 stringify!(hv_snp_id_auth_info),
6253 "::",
6254 stringify!(author_key)
6255 )
6256 );
6257}
6258impl Default for hv_snp_id_auth_info {
6259 fn default() -> Self {
6260 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
6261 unsafe {
6262 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
6263 s.assume_init()
6264 }
6265 }
6266}
6267#[repr(C, packed)]
6268#[derive(Copy, Clone)]
6269pub struct hv_psp_launch_finish_data {
6270 pub id_block: hv_snp_id_block,
6271 pub id_auth_info: hv_snp_id_auth_info,
6272 pub host_data: [__u8; 32usize],
6273 pub id_block_enabled: __u8,
6274 pub author_key_enabled: __u8,
6275}
6276#[test]
6277fn bindgen_test_layout_hv_psp_launch_finish_data() {
6278 const UNINIT: ::std::mem::MaybeUninit<hv_psp_launch_finish_data> =
6279 ::std::mem::MaybeUninit::uninit();
6280 let ptr = UNINIT.as_ptr();
6281 assert_eq!(
6282 ::std::mem::size_of::<hv_psp_launch_finish_data>(),
6283 3334usize,
6284 concat!("Size of: ", stringify!(hv_psp_launch_finish_data))
6285 );
6286 assert_eq!(
6287 ::std::mem::align_of::<hv_psp_launch_finish_data>(),
6288 1usize,
6289 concat!("Alignment of ", stringify!(hv_psp_launch_finish_data))
6290 );
6291 assert_eq!(
6292 unsafe { ::std::ptr::addr_of!((*ptr).id_block) as usize - ptr as usize },
6293 0usize,
6294 concat!(
6295 "Offset of field: ",
6296 stringify!(hv_psp_launch_finish_data),
6297 "::",
6298 stringify!(id_block)
6299 )
6300 );
6301 assert_eq!(
6302 unsafe { ::std::ptr::addr_of!((*ptr).id_auth_info) as usize - ptr as usize },
6303 96usize,
6304 concat!(
6305 "Offset of field: ",
6306 stringify!(hv_psp_launch_finish_data),
6307 "::",
6308 stringify!(id_auth_info)
6309 )
6310 );
6311 assert_eq!(
6312 unsafe { ::std::ptr::addr_of!((*ptr).host_data) as usize - ptr as usize },
6313 3300usize,
6314 concat!(
6315 "Offset of field: ",
6316 stringify!(hv_psp_launch_finish_data),
6317 "::",
6318 stringify!(host_data)
6319 )
6320 );
6321 assert_eq!(
6322 unsafe { ::std::ptr::addr_of!((*ptr).id_block_enabled) as usize - ptr as usize },
6323 3332usize,
6324 concat!(
6325 "Offset of field: ",
6326 stringify!(hv_psp_launch_finish_data),
6327 "::",
6328 stringify!(id_block_enabled)
6329 )
6330 );
6331 assert_eq!(
6332 unsafe { ::std::ptr::addr_of!((*ptr).author_key_enabled) as usize - ptr as usize },
6333 3333usize,
6334 concat!(
6335 "Offset of field: ",
6336 stringify!(hv_psp_launch_finish_data),
6337 "::",
6338 stringify!(author_key_enabled)
6339 )
6340 );
6341}
6342impl Default for hv_psp_launch_finish_data {
6343 fn default() -> Self {
6344 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
6345 unsafe {
6346 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
6347 s.assume_init()
6348 }
6349 }
6350}
6351#[repr(C, packed)]
6352#[derive(Copy, Clone)]
6353pub union hv_partition_complete_isolated_import_data {
6354 pub reserved: __u64,
6355 pub psp_parameters: hv_psp_launch_finish_data,
6356}
6357#[test]
6358fn bindgen_test_layout_hv_partition_complete_isolated_import_data() {
6359 const UNINIT: ::std::mem::MaybeUninit<hv_partition_complete_isolated_import_data> =
6360 ::std::mem::MaybeUninit::uninit();
6361 let ptr = UNINIT.as_ptr();
6362 assert_eq!(
6363 ::std::mem::size_of::<hv_partition_complete_isolated_import_data>(),
6364 3334usize,
6365 concat!(
6366 "Size of: ",
6367 stringify!(hv_partition_complete_isolated_import_data)
6368 )
6369 );
6370 assert_eq!(
6371 ::std::mem::align_of::<hv_partition_complete_isolated_import_data>(),
6372 1usize,
6373 concat!(
6374 "Alignment of ",
6375 stringify!(hv_partition_complete_isolated_import_data)
6376 )
6377 );
6378 assert_eq!(
6379 unsafe { ::std::ptr::addr_of!((*ptr).reserved) as usize - ptr as usize },
6380 0usize,
6381 concat!(
6382 "Offset of field: ",
6383 stringify!(hv_partition_complete_isolated_import_data),
6384 "::",
6385 stringify!(reserved)
6386 )
6387 );
6388 assert_eq!(
6389 unsafe { ::std::ptr::addr_of!((*ptr).psp_parameters) as usize - ptr as usize },
6390 0usize,
6391 concat!(
6392 "Offset of field: ",
6393 stringify!(hv_partition_complete_isolated_import_data),
6394 "::",
6395 stringify!(psp_parameters)
6396 )
6397 );
6398}
6399impl Default for hv_partition_complete_isolated_import_data {
6400 fn default() -> Self {
6401 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
6402 unsafe {
6403 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
6404 s.assume_init()
6405 }
6406 }
6407}
6408#[repr(C, packed)]
6409#[derive(Copy, Clone)]
6410pub struct hv_input_complete_isolated_import {
6411 pub partition_id: __u64,
6412 pub import_data: hv_partition_complete_isolated_import_data,
6413}
6414#[test]
6415fn bindgen_test_layout_hv_input_complete_isolated_import() {
6416 const UNINIT: ::std::mem::MaybeUninit<hv_input_complete_isolated_import> =
6417 ::std::mem::MaybeUninit::uninit();
6418 let ptr = UNINIT.as_ptr();
6419 assert_eq!(
6420 ::std::mem::size_of::<hv_input_complete_isolated_import>(),
6421 3342usize,
6422 concat!("Size of: ", stringify!(hv_input_complete_isolated_import))
6423 );
6424 assert_eq!(
6425 ::std::mem::align_of::<hv_input_complete_isolated_import>(),
6426 1usize,
6427 concat!(
6428 "Alignment of ",
6429 stringify!(hv_input_complete_isolated_import)
6430 )
6431 );
6432 assert_eq!(
6433 unsafe { ::std::ptr::addr_of!((*ptr).partition_id) as usize - ptr as usize },
6434 0usize,
6435 concat!(
6436 "Offset of field: ",
6437 stringify!(hv_input_complete_isolated_import),
6438 "::",
6439 stringify!(partition_id)
6440 )
6441 );
6442 assert_eq!(
6443 unsafe { ::std::ptr::addr_of!((*ptr).import_data) as usize - ptr as usize },
6444 8usize,
6445 concat!(
6446 "Offset of field: ",
6447 stringify!(hv_input_complete_isolated_import),
6448 "::",
6449 stringify!(import_data)
6450 )
6451 );
6452}
6453impl Default for hv_input_complete_isolated_import {
6454 fn default() -> Self {
6455 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
6456 unsafe {
6457 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
6458 s.assume_init()
6459 }
6460 }
6461}
6462#[repr(C, packed)]
6463#[derive(Copy, Clone)]
6464pub union hv_vp_register_page_interrupt_vectors {
6465 pub as_uint64: __u64,
6466 pub __bindgen_anon_1: hv_vp_register_page_interrupt_vectors__bindgen_ty_1,
6467}
6468#[repr(C, packed)]
6469#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
6470pub struct hv_vp_register_page_interrupt_vectors__bindgen_ty_1 {
6471 pub vector_count: __u8,
6472 pub vector: [__u8; 7usize],
6473}
6474#[test]
6475fn bindgen_test_layout_hv_vp_register_page_interrupt_vectors__bindgen_ty_1() {
6476 const UNINIT: ::std::mem::MaybeUninit<hv_vp_register_page_interrupt_vectors__bindgen_ty_1> =
6477 ::std::mem::MaybeUninit::uninit();
6478 let ptr = UNINIT.as_ptr();
6479 assert_eq!(
6480 ::std::mem::size_of::<hv_vp_register_page_interrupt_vectors__bindgen_ty_1>(),
6481 8usize,
6482 concat!(
6483 "Size of: ",
6484 stringify!(hv_vp_register_page_interrupt_vectors__bindgen_ty_1)
6485 )
6486 );
6487 assert_eq!(
6488 ::std::mem::align_of::<hv_vp_register_page_interrupt_vectors__bindgen_ty_1>(),
6489 1usize,
6490 concat!(
6491 "Alignment of ",
6492 stringify!(hv_vp_register_page_interrupt_vectors__bindgen_ty_1)
6493 )
6494 );
6495 assert_eq!(
6496 unsafe { ::std::ptr::addr_of!((*ptr).vector_count) as usize - ptr as usize },
6497 0usize,
6498 concat!(
6499 "Offset of field: ",
6500 stringify!(hv_vp_register_page_interrupt_vectors__bindgen_ty_1),
6501 "::",
6502 stringify!(vector_count)
6503 )
6504 );
6505 assert_eq!(
6506 unsafe { ::std::ptr::addr_of!((*ptr).vector) as usize - ptr as usize },
6507 1usize,
6508 concat!(
6509 "Offset of field: ",
6510 stringify!(hv_vp_register_page_interrupt_vectors__bindgen_ty_1),
6511 "::",
6512 stringify!(vector)
6513 )
6514 );
6515}
6516#[test]
6517fn bindgen_test_layout_hv_vp_register_page_interrupt_vectors() {
6518 const UNINIT: ::std::mem::MaybeUninit<hv_vp_register_page_interrupt_vectors> =
6519 ::std::mem::MaybeUninit::uninit();
6520 let ptr = UNINIT.as_ptr();
6521 assert_eq!(
6522 ::std::mem::size_of::<hv_vp_register_page_interrupt_vectors>(),
6523 8usize,
6524 concat!(
6525 "Size of: ",
6526 stringify!(hv_vp_register_page_interrupt_vectors)
6527 )
6528 );
6529 assert_eq!(
6530 ::std::mem::align_of::<hv_vp_register_page_interrupt_vectors>(),
6531 1usize,
6532 concat!(
6533 "Alignment of ",
6534 stringify!(hv_vp_register_page_interrupt_vectors)
6535 )
6536 );
6537 assert_eq!(
6538 unsafe { ::std::ptr::addr_of!((*ptr).as_uint64) as usize - ptr as usize },
6539 0usize,
6540 concat!(
6541 "Offset of field: ",
6542 stringify!(hv_vp_register_page_interrupt_vectors),
6543 "::",
6544 stringify!(as_uint64)
6545 )
6546 );
6547}
6548impl Default for hv_vp_register_page_interrupt_vectors {
6549 fn default() -> Self {
6550 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
6551 unsafe {
6552 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
6553 s.assume_init()
6554 }
6555 }
6556}
6557#[repr(C, packed)]
6558#[derive(Copy, Clone)]
6559pub struct hv_vp_register_page {
6560 pub version: __u16,
6561 pub isvalid: __u8,
6562 pub rsvdz: __u8,
6563 pub dirty: __u32,
6564 pub __bindgen_anon_1: hv_vp_register_page__bindgen_ty_1,
6565 pub reserved: [__u8; 8usize],
6566 pub __bindgen_anon_2: hv_vp_register_page__bindgen_ty_2,
6567 pub __bindgen_anon_3: hv_vp_register_page__bindgen_ty_3,
6568 pub cr0: __u64,
6569 pub cr3: __u64,
6570 pub cr4: __u64,
6571 pub cr8: __u64,
6572 pub efer: __u64,
6573 pub dr7: __u64,
6574 pub pending_interruption: hv_x64_pending_interruption_register,
6575 pub interrupt_state: hv_x64_interrupt_state_register,
6576 pub instruction_emulation_hints: __u64,
6577 pub xfem: __u64,
6578 pub reserved1: [__u8; 256usize],
6579 pub interrupt_vectors: hv_vp_register_page_interrupt_vectors,
6580}
6581#[repr(C)]
6582#[derive(Copy, Clone)]
6583pub union hv_vp_register_page__bindgen_ty_1 {
6584 pub __bindgen_anon_1: hv_vp_register_page__bindgen_ty_1__bindgen_ty_1,
6585 pub registers: [__u64; 18usize],
6586}
6587#[repr(C, packed)]
6588#[derive(Copy, Clone)]
6589pub struct hv_vp_register_page__bindgen_ty_1__bindgen_ty_1 {
6590 pub __bindgen_anon_1: hv_vp_register_page__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1,
6591 pub rip: __u64,
6592 pub rflags: __u64,
6593}
6594#[repr(C)]
6595#[derive(Copy, Clone)]
6596pub union hv_vp_register_page__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1 {
6597 pub __bindgen_anon_1:
6598 hv_vp_register_page__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1,
6599 pub gp_registers: [__u64; 16usize],
6600}
6601#[repr(C, packed)]
6602#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
6603pub struct hv_vp_register_page__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1 {
6604 pub rax: __u64,
6605 pub rcx: __u64,
6606 pub rdx: __u64,
6607 pub rbx: __u64,
6608 pub rsp: __u64,
6609 pub rbp: __u64,
6610 pub rsi: __u64,
6611 pub rdi: __u64,
6612 pub r8: __u64,
6613 pub r9: __u64,
6614 pub r10: __u64,
6615 pub r11: __u64,
6616 pub r12: __u64,
6617 pub r13: __u64,
6618 pub r14: __u64,
6619 pub r15: __u64,
6620}
6621#[test]
6622fn bindgen_test_layout_hv_vp_register_page__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1()
6623{
6624 const UNINIT: ::std::mem::MaybeUninit<
6625 hv_vp_register_page__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1,
6626 > = ::std::mem::MaybeUninit::uninit();
6627 let ptr = UNINIT.as_ptr();
6628 assert_eq!(
6629 ::std::mem::size_of::<
6630 hv_vp_register_page__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1,
6631 >(),
6632 128usize,
6633 concat!(
6634 "Size of: ",
6635 stringify!(hv_vp_register_page__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1)
6636 )
6637 );
6638 assert_eq!(
6639 ::std::mem::align_of::<
6640 hv_vp_register_page__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1,
6641 >(),
6642 1usize,
6643 concat!(
6644 "Alignment of ",
6645 stringify!(hv_vp_register_page__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1)
6646 )
6647 );
6648 assert_eq!(
6649 unsafe { ::std::ptr::addr_of!((*ptr).rax) as usize - ptr as usize },
6650 0usize,
6651 concat!(
6652 "Offset of field: ",
6653 stringify!(hv_vp_register_page__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1),
6654 "::",
6655 stringify!(rax)
6656 )
6657 );
6658 assert_eq!(
6659 unsafe { ::std::ptr::addr_of!((*ptr).rcx) as usize - ptr as usize },
6660 8usize,
6661 concat!(
6662 "Offset of field: ",
6663 stringify!(hv_vp_register_page__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1),
6664 "::",
6665 stringify!(rcx)
6666 )
6667 );
6668 assert_eq!(
6669 unsafe { ::std::ptr::addr_of!((*ptr).rdx) as usize - ptr as usize },
6670 16usize,
6671 concat!(
6672 "Offset of field: ",
6673 stringify!(hv_vp_register_page__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1),
6674 "::",
6675 stringify!(rdx)
6676 )
6677 );
6678 assert_eq!(
6679 unsafe { ::std::ptr::addr_of!((*ptr).rbx) as usize - ptr as usize },
6680 24usize,
6681 concat!(
6682 "Offset of field: ",
6683 stringify!(hv_vp_register_page__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1),
6684 "::",
6685 stringify!(rbx)
6686 )
6687 );
6688 assert_eq!(
6689 unsafe { ::std::ptr::addr_of!((*ptr).rsp) as usize - ptr as usize },
6690 32usize,
6691 concat!(
6692 "Offset of field: ",
6693 stringify!(hv_vp_register_page__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1),
6694 "::",
6695 stringify!(rsp)
6696 )
6697 );
6698 assert_eq!(
6699 unsafe { ::std::ptr::addr_of!((*ptr).rbp) as usize - ptr as usize },
6700 40usize,
6701 concat!(
6702 "Offset of field: ",
6703 stringify!(hv_vp_register_page__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1),
6704 "::",
6705 stringify!(rbp)
6706 )
6707 );
6708 assert_eq!(
6709 unsafe { ::std::ptr::addr_of!((*ptr).rsi) as usize - ptr as usize },
6710 48usize,
6711 concat!(
6712 "Offset of field: ",
6713 stringify!(hv_vp_register_page__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1),
6714 "::",
6715 stringify!(rsi)
6716 )
6717 );
6718 assert_eq!(
6719 unsafe { ::std::ptr::addr_of!((*ptr).rdi) as usize - ptr as usize },
6720 56usize,
6721 concat!(
6722 "Offset of field: ",
6723 stringify!(hv_vp_register_page__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1),
6724 "::",
6725 stringify!(rdi)
6726 )
6727 );
6728 assert_eq!(
6729 unsafe { ::std::ptr::addr_of!((*ptr).r8) as usize - ptr as usize },
6730 64usize,
6731 concat!(
6732 "Offset of field: ",
6733 stringify!(hv_vp_register_page__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1),
6734 "::",
6735 stringify!(r8)
6736 )
6737 );
6738 assert_eq!(
6739 unsafe { ::std::ptr::addr_of!((*ptr).r9) as usize - ptr as usize },
6740 72usize,
6741 concat!(
6742 "Offset of field: ",
6743 stringify!(hv_vp_register_page__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1),
6744 "::",
6745 stringify!(r9)
6746 )
6747 );
6748 assert_eq!(
6749 unsafe { ::std::ptr::addr_of!((*ptr).r10) as usize - ptr as usize },
6750 80usize,
6751 concat!(
6752 "Offset of field: ",
6753 stringify!(hv_vp_register_page__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1),
6754 "::",
6755 stringify!(r10)
6756 )
6757 );
6758 assert_eq!(
6759 unsafe { ::std::ptr::addr_of!((*ptr).r11) as usize - ptr as usize },
6760 88usize,
6761 concat!(
6762 "Offset of field: ",
6763 stringify!(hv_vp_register_page__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1),
6764 "::",
6765 stringify!(r11)
6766 )
6767 );
6768 assert_eq!(
6769 unsafe { ::std::ptr::addr_of!((*ptr).r12) as usize - ptr as usize },
6770 96usize,
6771 concat!(
6772 "Offset of field: ",
6773 stringify!(hv_vp_register_page__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1),
6774 "::",
6775 stringify!(r12)
6776 )
6777 );
6778 assert_eq!(
6779 unsafe { ::std::ptr::addr_of!((*ptr).r13) as usize - ptr as usize },
6780 104usize,
6781 concat!(
6782 "Offset of field: ",
6783 stringify!(hv_vp_register_page__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1),
6784 "::",
6785 stringify!(r13)
6786 )
6787 );
6788 assert_eq!(
6789 unsafe { ::std::ptr::addr_of!((*ptr).r14) as usize - ptr as usize },
6790 112usize,
6791 concat!(
6792 "Offset of field: ",
6793 stringify!(hv_vp_register_page__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1),
6794 "::",
6795 stringify!(r14)
6796 )
6797 );
6798 assert_eq!(
6799 unsafe { ::std::ptr::addr_of!((*ptr).r15) as usize - ptr as usize },
6800 120usize,
6801 concat!(
6802 "Offset of field: ",
6803 stringify!(hv_vp_register_page__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1),
6804 "::",
6805 stringify!(r15)
6806 )
6807 );
6808}
6809#[test]
6810fn bindgen_test_layout_hv_vp_register_page__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1() {
6811 const UNINIT: ::std::mem::MaybeUninit<
6812 hv_vp_register_page__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1,
6813 > = ::std::mem::MaybeUninit::uninit();
6814 let ptr = UNINIT.as_ptr();
6815 assert_eq!(
6816 ::std::mem::size_of::<hv_vp_register_page__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1>(),
6817 128usize,
6818 concat!(
6819 "Size of: ",
6820 stringify!(hv_vp_register_page__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1)
6821 )
6822 );
6823 assert_eq!(
6824 ::std::mem::align_of::<hv_vp_register_page__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1>(),
6825 8usize,
6826 concat!(
6827 "Alignment of ",
6828 stringify!(hv_vp_register_page__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1)
6829 )
6830 );
6831 assert_eq!(
6832 unsafe { ::std::ptr::addr_of!((*ptr).gp_registers) as usize - ptr as usize },
6833 0usize,
6834 concat!(
6835 "Offset of field: ",
6836 stringify!(hv_vp_register_page__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1),
6837 "::",
6838 stringify!(gp_registers)
6839 )
6840 );
6841}
6842impl Default for hv_vp_register_page__bindgen_ty_1__bindgen_ty_1__bindgen_ty_1 {
6843 fn default() -> Self {
6844 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
6845 unsafe {
6846 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
6847 s.assume_init()
6848 }
6849 }
6850}
6851#[test]
6852fn bindgen_test_layout_hv_vp_register_page__bindgen_ty_1__bindgen_ty_1() {
6853 const UNINIT: ::std::mem::MaybeUninit<hv_vp_register_page__bindgen_ty_1__bindgen_ty_1> =
6854 ::std::mem::MaybeUninit::uninit();
6855 let ptr = UNINIT.as_ptr();
6856 assert_eq!(
6857 ::std::mem::size_of::<hv_vp_register_page__bindgen_ty_1__bindgen_ty_1>(),
6858 144usize,
6859 concat!(
6860 "Size of: ",
6861 stringify!(hv_vp_register_page__bindgen_ty_1__bindgen_ty_1)
6862 )
6863 );
6864 assert_eq!(
6865 ::std::mem::align_of::<hv_vp_register_page__bindgen_ty_1__bindgen_ty_1>(),
6866 1usize,
6867 concat!(
6868 "Alignment of ",
6869 stringify!(hv_vp_register_page__bindgen_ty_1__bindgen_ty_1)
6870 )
6871 );
6872 assert_eq!(
6873 unsafe { ::std::ptr::addr_of!((*ptr).rip) as usize - ptr as usize },
6874 128usize,
6875 concat!(
6876 "Offset of field: ",
6877 stringify!(hv_vp_register_page__bindgen_ty_1__bindgen_ty_1),
6878 "::",
6879 stringify!(rip)
6880 )
6881 );
6882 assert_eq!(
6883 unsafe { ::std::ptr::addr_of!((*ptr).rflags) as usize - ptr as usize },
6884 136usize,
6885 concat!(
6886 "Offset of field: ",
6887 stringify!(hv_vp_register_page__bindgen_ty_1__bindgen_ty_1),
6888 "::",
6889 stringify!(rflags)
6890 )
6891 );
6892}
6893impl Default for hv_vp_register_page__bindgen_ty_1__bindgen_ty_1 {
6894 fn default() -> Self {
6895 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
6896 unsafe {
6897 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
6898 s.assume_init()
6899 }
6900 }
6901}
6902#[test]
6903fn bindgen_test_layout_hv_vp_register_page__bindgen_ty_1() {
6904 const UNINIT: ::std::mem::MaybeUninit<hv_vp_register_page__bindgen_ty_1> =
6905 ::std::mem::MaybeUninit::uninit();
6906 let ptr = UNINIT.as_ptr();
6907 assert_eq!(
6908 ::std::mem::size_of::<hv_vp_register_page__bindgen_ty_1>(),
6909 144usize,
6910 concat!("Size of: ", stringify!(hv_vp_register_page__bindgen_ty_1))
6911 );
6912 assert_eq!(
6913 ::std::mem::align_of::<hv_vp_register_page__bindgen_ty_1>(),
6914 8usize,
6915 concat!(
6916 "Alignment of ",
6917 stringify!(hv_vp_register_page__bindgen_ty_1)
6918 )
6919 );
6920 assert_eq!(
6921 unsafe { ::std::ptr::addr_of!((*ptr).registers) as usize - ptr as usize },
6922 0usize,
6923 concat!(
6924 "Offset of field: ",
6925 stringify!(hv_vp_register_page__bindgen_ty_1),
6926 "::",
6927 stringify!(registers)
6928 )
6929 );
6930}
6931impl Default for hv_vp_register_page__bindgen_ty_1 {
6932 fn default() -> Self {
6933 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
6934 unsafe {
6935 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
6936 s.assume_init()
6937 }
6938 }
6939}
6940#[repr(C)]
6941#[derive(Copy, Clone)]
6942pub union hv_vp_register_page__bindgen_ty_2 {
6943 pub __bindgen_anon_1: hv_vp_register_page__bindgen_ty_2__bindgen_ty_1,
6944 pub xmm_registers: [hv_u128; 6usize],
6945}
6946#[repr(C, packed)]
6947#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
6948pub struct hv_vp_register_page__bindgen_ty_2__bindgen_ty_1 {
6949 pub xmm0: hv_u128,
6950 pub xmm1: hv_u128,
6951 pub xmm2: hv_u128,
6952 pub xmm3: hv_u128,
6953 pub xmm4: hv_u128,
6954 pub xmm5: hv_u128,
6955}
6956#[test]
6957fn bindgen_test_layout_hv_vp_register_page__bindgen_ty_2__bindgen_ty_1() {
6958 const UNINIT: ::std::mem::MaybeUninit<hv_vp_register_page__bindgen_ty_2__bindgen_ty_1> =
6959 ::std::mem::MaybeUninit::uninit();
6960 let ptr = UNINIT.as_ptr();
6961 assert_eq!(
6962 ::std::mem::size_of::<hv_vp_register_page__bindgen_ty_2__bindgen_ty_1>(),
6963 96usize,
6964 concat!(
6965 "Size of: ",
6966 stringify!(hv_vp_register_page__bindgen_ty_2__bindgen_ty_1)
6967 )
6968 );
6969 assert_eq!(
6970 ::std::mem::align_of::<hv_vp_register_page__bindgen_ty_2__bindgen_ty_1>(),
6971 1usize,
6972 concat!(
6973 "Alignment of ",
6974 stringify!(hv_vp_register_page__bindgen_ty_2__bindgen_ty_1)
6975 )
6976 );
6977 assert_eq!(
6978 unsafe { ::std::ptr::addr_of!((*ptr).xmm0) as usize - ptr as usize },
6979 0usize,
6980 concat!(
6981 "Offset of field: ",
6982 stringify!(hv_vp_register_page__bindgen_ty_2__bindgen_ty_1),
6983 "::",
6984 stringify!(xmm0)
6985 )
6986 );
6987 assert_eq!(
6988 unsafe { ::std::ptr::addr_of!((*ptr).xmm1) as usize - ptr as usize },
6989 16usize,
6990 concat!(
6991 "Offset of field: ",
6992 stringify!(hv_vp_register_page__bindgen_ty_2__bindgen_ty_1),
6993 "::",
6994 stringify!(xmm1)
6995 )
6996 );
6997 assert_eq!(
6998 unsafe { ::std::ptr::addr_of!((*ptr).xmm2) as usize - ptr as usize },
6999 32usize,
7000 concat!(
7001 "Offset of field: ",
7002 stringify!(hv_vp_register_page__bindgen_ty_2__bindgen_ty_1),
7003 "::",
7004 stringify!(xmm2)
7005 )
7006 );
7007 assert_eq!(
7008 unsafe { ::std::ptr::addr_of!((*ptr).xmm3) as usize - ptr as usize },
7009 48usize,
7010 concat!(
7011 "Offset of field: ",
7012 stringify!(hv_vp_register_page__bindgen_ty_2__bindgen_ty_1),
7013 "::",
7014 stringify!(xmm3)
7015 )
7016 );
7017 assert_eq!(
7018 unsafe { ::std::ptr::addr_of!((*ptr).xmm4) as usize - ptr as usize },
7019 64usize,
7020 concat!(
7021 "Offset of field: ",
7022 stringify!(hv_vp_register_page__bindgen_ty_2__bindgen_ty_1),
7023 "::",
7024 stringify!(xmm4)
7025 )
7026 );
7027 assert_eq!(
7028 unsafe { ::std::ptr::addr_of!((*ptr).xmm5) as usize - ptr as usize },
7029 80usize,
7030 concat!(
7031 "Offset of field: ",
7032 stringify!(hv_vp_register_page__bindgen_ty_2__bindgen_ty_1),
7033 "::",
7034 stringify!(xmm5)
7035 )
7036 );
7037}
7038#[test]
7039fn bindgen_test_layout_hv_vp_register_page__bindgen_ty_2() {
7040 const UNINIT: ::std::mem::MaybeUninit<hv_vp_register_page__bindgen_ty_2> =
7041 ::std::mem::MaybeUninit::uninit();
7042 let ptr = UNINIT.as_ptr();
7043 assert_eq!(
7044 ::std::mem::size_of::<hv_vp_register_page__bindgen_ty_2>(),
7045 96usize,
7046 concat!("Size of: ", stringify!(hv_vp_register_page__bindgen_ty_2))
7047 );
7048 assert_eq!(
7049 ::std::mem::align_of::<hv_vp_register_page__bindgen_ty_2>(),
7050 1usize,
7051 concat!(
7052 "Alignment of ",
7053 stringify!(hv_vp_register_page__bindgen_ty_2)
7054 )
7055 );
7056 assert_eq!(
7057 unsafe { ::std::ptr::addr_of!((*ptr).xmm_registers) as usize - ptr as usize },
7058 0usize,
7059 concat!(
7060 "Offset of field: ",
7061 stringify!(hv_vp_register_page__bindgen_ty_2),
7062 "::",
7063 stringify!(xmm_registers)
7064 )
7065 );
7066}
7067impl Default for hv_vp_register_page__bindgen_ty_2 {
7068 fn default() -> Self {
7069 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
7070 unsafe {
7071 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
7072 s.assume_init()
7073 }
7074 }
7075}
7076#[repr(C)]
7077#[derive(Copy, Clone)]
7078pub union hv_vp_register_page__bindgen_ty_3 {
7079 pub __bindgen_anon_1: hv_vp_register_page__bindgen_ty_3__bindgen_ty_1,
7080 pub segment_registers: [hv_x64_segment_register; 6usize],
7081}
7082#[repr(C, packed)]
7083#[derive(Copy, Clone)]
7084pub struct hv_vp_register_page__bindgen_ty_3__bindgen_ty_1 {
7085 pub es: hv_x64_segment_register,
7086 pub cs: hv_x64_segment_register,
7087 pub ss: hv_x64_segment_register,
7088 pub ds: hv_x64_segment_register,
7089 pub fs: hv_x64_segment_register,
7090 pub gs: hv_x64_segment_register,
7091}
7092#[test]
7093fn bindgen_test_layout_hv_vp_register_page__bindgen_ty_3__bindgen_ty_1() {
7094 const UNINIT: ::std::mem::MaybeUninit<hv_vp_register_page__bindgen_ty_3__bindgen_ty_1> =
7095 ::std::mem::MaybeUninit::uninit();
7096 let ptr = UNINIT.as_ptr();
7097 assert_eq!(
7098 ::std::mem::size_of::<hv_vp_register_page__bindgen_ty_3__bindgen_ty_1>(),
7099 96usize,
7100 concat!(
7101 "Size of: ",
7102 stringify!(hv_vp_register_page__bindgen_ty_3__bindgen_ty_1)
7103 )
7104 );
7105 assert_eq!(
7106 ::std::mem::align_of::<hv_vp_register_page__bindgen_ty_3__bindgen_ty_1>(),
7107 1usize,
7108 concat!(
7109 "Alignment of ",
7110 stringify!(hv_vp_register_page__bindgen_ty_3__bindgen_ty_1)
7111 )
7112 );
7113 assert_eq!(
7114 unsafe { ::std::ptr::addr_of!((*ptr).es) as usize - ptr as usize },
7115 0usize,
7116 concat!(
7117 "Offset of field: ",
7118 stringify!(hv_vp_register_page__bindgen_ty_3__bindgen_ty_1),
7119 "::",
7120 stringify!(es)
7121 )
7122 );
7123 assert_eq!(
7124 unsafe { ::std::ptr::addr_of!((*ptr).cs) as usize - ptr as usize },
7125 16usize,
7126 concat!(
7127 "Offset of field: ",
7128 stringify!(hv_vp_register_page__bindgen_ty_3__bindgen_ty_1),
7129 "::",
7130 stringify!(cs)
7131 )
7132 );
7133 assert_eq!(
7134 unsafe { ::std::ptr::addr_of!((*ptr).ss) as usize - ptr as usize },
7135 32usize,
7136 concat!(
7137 "Offset of field: ",
7138 stringify!(hv_vp_register_page__bindgen_ty_3__bindgen_ty_1),
7139 "::",
7140 stringify!(ss)
7141 )
7142 );
7143 assert_eq!(
7144 unsafe { ::std::ptr::addr_of!((*ptr).ds) as usize - ptr as usize },
7145 48usize,
7146 concat!(
7147 "Offset of field: ",
7148 stringify!(hv_vp_register_page__bindgen_ty_3__bindgen_ty_1),
7149 "::",
7150 stringify!(ds)
7151 )
7152 );
7153 assert_eq!(
7154 unsafe { ::std::ptr::addr_of!((*ptr).fs) as usize - ptr as usize },
7155 64usize,
7156 concat!(
7157 "Offset of field: ",
7158 stringify!(hv_vp_register_page__bindgen_ty_3__bindgen_ty_1),
7159 "::",
7160 stringify!(fs)
7161 )
7162 );
7163 assert_eq!(
7164 unsafe { ::std::ptr::addr_of!((*ptr).gs) as usize - ptr as usize },
7165 80usize,
7166 concat!(
7167 "Offset of field: ",
7168 stringify!(hv_vp_register_page__bindgen_ty_3__bindgen_ty_1),
7169 "::",
7170 stringify!(gs)
7171 )
7172 );
7173}
7174impl Default for hv_vp_register_page__bindgen_ty_3__bindgen_ty_1 {
7175 fn default() -> Self {
7176 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
7177 unsafe {
7178 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
7179 s.assume_init()
7180 }
7181 }
7182}
7183#[test]
7184fn bindgen_test_layout_hv_vp_register_page__bindgen_ty_3() {
7185 const UNINIT: ::std::mem::MaybeUninit<hv_vp_register_page__bindgen_ty_3> =
7186 ::std::mem::MaybeUninit::uninit();
7187 let ptr = UNINIT.as_ptr();
7188 assert_eq!(
7189 ::std::mem::size_of::<hv_vp_register_page__bindgen_ty_3>(),
7190 96usize,
7191 concat!("Size of: ", stringify!(hv_vp_register_page__bindgen_ty_3))
7192 );
7193 assert_eq!(
7194 ::std::mem::align_of::<hv_vp_register_page__bindgen_ty_3>(),
7195 1usize,
7196 concat!(
7197 "Alignment of ",
7198 stringify!(hv_vp_register_page__bindgen_ty_3)
7199 )
7200 );
7201 assert_eq!(
7202 unsafe { ::std::ptr::addr_of!((*ptr).segment_registers) as usize - ptr as usize },
7203 0usize,
7204 concat!(
7205 "Offset of field: ",
7206 stringify!(hv_vp_register_page__bindgen_ty_3),
7207 "::",
7208 stringify!(segment_registers)
7209 )
7210 );
7211}
7212impl Default for hv_vp_register_page__bindgen_ty_3 {
7213 fn default() -> Self {
7214 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
7215 unsafe {
7216 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
7217 s.assume_init()
7218 }
7219 }
7220}
7221#[test]
7222fn bindgen_test_layout_hv_vp_register_page() {
7223 const UNINIT: ::std::mem::MaybeUninit<hv_vp_register_page> = ::std::mem::MaybeUninit::uninit();
7224 let ptr = UNINIT.as_ptr();
7225 assert_eq!(
7226 ::std::mem::size_of::<hv_vp_register_page>(),
7227 696usize,
7228 concat!("Size of: ", stringify!(hv_vp_register_page))
7229 );
7230 assert_eq!(
7231 ::std::mem::align_of::<hv_vp_register_page>(),
7232 1usize,
7233 concat!("Alignment of ", stringify!(hv_vp_register_page))
7234 );
7235 assert_eq!(
7236 unsafe { ::std::ptr::addr_of!((*ptr).version) as usize - ptr as usize },
7237 0usize,
7238 concat!(
7239 "Offset of field: ",
7240 stringify!(hv_vp_register_page),
7241 "::",
7242 stringify!(version)
7243 )
7244 );
7245 assert_eq!(
7246 unsafe { ::std::ptr::addr_of!((*ptr).isvalid) as usize - ptr as usize },
7247 2usize,
7248 concat!(
7249 "Offset of field: ",
7250 stringify!(hv_vp_register_page),
7251 "::",
7252 stringify!(isvalid)
7253 )
7254 );
7255 assert_eq!(
7256 unsafe { ::std::ptr::addr_of!((*ptr).rsvdz) as usize - ptr as usize },
7257 3usize,
7258 concat!(
7259 "Offset of field: ",
7260 stringify!(hv_vp_register_page),
7261 "::",
7262 stringify!(rsvdz)
7263 )
7264 );
7265 assert_eq!(
7266 unsafe { ::std::ptr::addr_of!((*ptr).dirty) as usize - ptr as usize },
7267 4usize,
7268 concat!(
7269 "Offset of field: ",
7270 stringify!(hv_vp_register_page),
7271 "::",
7272 stringify!(dirty)
7273 )
7274 );
7275 assert_eq!(
7276 unsafe { ::std::ptr::addr_of!((*ptr).reserved) as usize - ptr as usize },
7277 152usize,
7278 concat!(
7279 "Offset of field: ",
7280 stringify!(hv_vp_register_page),
7281 "::",
7282 stringify!(reserved)
7283 )
7284 );
7285 assert_eq!(
7286 unsafe { ::std::ptr::addr_of!((*ptr).cr0) as usize - ptr as usize },
7287 352usize,
7288 concat!(
7289 "Offset of field: ",
7290 stringify!(hv_vp_register_page),
7291 "::",
7292 stringify!(cr0)
7293 )
7294 );
7295 assert_eq!(
7296 unsafe { ::std::ptr::addr_of!((*ptr).cr3) as usize - ptr as usize },
7297 360usize,
7298 concat!(
7299 "Offset of field: ",
7300 stringify!(hv_vp_register_page),
7301 "::",
7302 stringify!(cr3)
7303 )
7304 );
7305 assert_eq!(
7306 unsafe { ::std::ptr::addr_of!((*ptr).cr4) as usize - ptr as usize },
7307 368usize,
7308 concat!(
7309 "Offset of field: ",
7310 stringify!(hv_vp_register_page),
7311 "::",
7312 stringify!(cr4)
7313 )
7314 );
7315 assert_eq!(
7316 unsafe { ::std::ptr::addr_of!((*ptr).cr8) as usize - ptr as usize },
7317 376usize,
7318 concat!(
7319 "Offset of field: ",
7320 stringify!(hv_vp_register_page),
7321 "::",
7322 stringify!(cr8)
7323 )
7324 );
7325 assert_eq!(
7326 unsafe { ::std::ptr::addr_of!((*ptr).efer) as usize - ptr as usize },
7327 384usize,
7328 concat!(
7329 "Offset of field: ",
7330 stringify!(hv_vp_register_page),
7331 "::",
7332 stringify!(efer)
7333 )
7334 );
7335 assert_eq!(
7336 unsafe { ::std::ptr::addr_of!((*ptr).dr7) as usize - ptr as usize },
7337 392usize,
7338 concat!(
7339 "Offset of field: ",
7340 stringify!(hv_vp_register_page),
7341 "::",
7342 stringify!(dr7)
7343 )
7344 );
7345 assert_eq!(
7346 unsafe { ::std::ptr::addr_of!((*ptr).pending_interruption) as usize - ptr as usize },
7347 400usize,
7348 concat!(
7349 "Offset of field: ",
7350 stringify!(hv_vp_register_page),
7351 "::",
7352 stringify!(pending_interruption)
7353 )
7354 );
7355 assert_eq!(
7356 unsafe { ::std::ptr::addr_of!((*ptr).interrupt_state) as usize - ptr as usize },
7357 408usize,
7358 concat!(
7359 "Offset of field: ",
7360 stringify!(hv_vp_register_page),
7361 "::",
7362 stringify!(interrupt_state)
7363 )
7364 );
7365 assert_eq!(
7366 unsafe { ::std::ptr::addr_of!((*ptr).instruction_emulation_hints) as usize - ptr as usize },
7367 416usize,
7368 concat!(
7369 "Offset of field: ",
7370 stringify!(hv_vp_register_page),
7371 "::",
7372 stringify!(instruction_emulation_hints)
7373 )
7374 );
7375 assert_eq!(
7376 unsafe { ::std::ptr::addr_of!((*ptr).xfem) as usize - ptr as usize },
7377 424usize,
7378 concat!(
7379 "Offset of field: ",
7380 stringify!(hv_vp_register_page),
7381 "::",
7382 stringify!(xfem)
7383 )
7384 );
7385 assert_eq!(
7386 unsafe { ::std::ptr::addr_of!((*ptr).reserved1) as usize - ptr as usize },
7387 432usize,
7388 concat!(
7389 "Offset of field: ",
7390 stringify!(hv_vp_register_page),
7391 "::",
7392 stringify!(reserved1)
7393 )
7394 );
7395 assert_eq!(
7396 unsafe { ::std::ptr::addr_of!((*ptr).interrupt_vectors) as usize - ptr as usize },
7397 688usize,
7398 concat!(
7399 "Offset of field: ",
7400 stringify!(hv_vp_register_page),
7401 "::",
7402 stringify!(interrupt_vectors)
7403 )
7404 );
7405}
7406impl Default for hv_vp_register_page {
7407 fn default() -> Self {
7408 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
7409 unsafe {
7410 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
7411 s.assume_init()
7412 }
7413 }
7414}
7415#[repr(C)]
7416#[derive(Copy, Clone)]
7417pub union hv_partition_synthetic_processor_features {
7418 pub as_uint64: [__u64; 1usize],
7419 pub __bindgen_anon_1: hv_partition_synthetic_processor_features__bindgen_ty_1,
7420}
7421#[repr(C, packed)]
7422#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
7423pub struct hv_partition_synthetic_processor_features__bindgen_ty_1 {
7424 pub _bitfield_align_1: [u8; 0],
7425 pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>,
7426}
7427#[test]
7428fn bindgen_test_layout_hv_partition_synthetic_processor_features__bindgen_ty_1() {
7429 assert_eq!(
7430 ::std::mem::size_of::<hv_partition_synthetic_processor_features__bindgen_ty_1>(),
7431 8usize,
7432 concat!(
7433 "Size of: ",
7434 stringify!(hv_partition_synthetic_processor_features__bindgen_ty_1)
7435 )
7436 );
7437 assert_eq!(
7438 ::std::mem::align_of::<hv_partition_synthetic_processor_features__bindgen_ty_1>(),
7439 1usize,
7440 concat!(
7441 "Alignment of ",
7442 stringify!(hv_partition_synthetic_processor_features__bindgen_ty_1)
7443 )
7444 );
7445}
7446impl hv_partition_synthetic_processor_features__bindgen_ty_1 {
7447 #[inline]
7448 pub fn hypervisor_present(&self) -> __u64 {
7449 unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 1u8) as u64) }
7450 }
7451 #[inline]
7452 pub fn set_hypervisor_present(&mut self, val: __u64) {
7453 unsafe {
7454 let val: u64 = ::std::mem::transmute(val);
7455 self._bitfield_1.set(0usize, 1u8, val as u64)
7456 }
7457 }
7458 #[inline]
7459 pub fn hv1(&self) -> __u64 {
7460 unsafe { ::std::mem::transmute(self._bitfield_1.get(1usize, 1u8) as u64) }
7461 }
7462 #[inline]
7463 pub fn set_hv1(&mut self, val: __u64) {
7464 unsafe {
7465 let val: u64 = ::std::mem::transmute(val);
7466 self._bitfield_1.set(1usize, 1u8, val as u64)
7467 }
7468 }
7469 #[inline]
7470 pub fn access_vp_run_time_reg(&self) -> __u64 {
7471 unsafe { ::std::mem::transmute(self._bitfield_1.get(2usize, 1u8) as u64) }
7472 }
7473 #[inline]
7474 pub fn set_access_vp_run_time_reg(&mut self, val: __u64) {
7475 unsafe {
7476 let val: u64 = ::std::mem::transmute(val);
7477 self._bitfield_1.set(2usize, 1u8, val as u64)
7478 }
7479 }
7480 #[inline]
7481 pub fn access_partition_reference_counter(&self) -> __u64 {
7482 unsafe { ::std::mem::transmute(self._bitfield_1.get(3usize, 1u8) as u64) }
7483 }
7484 #[inline]
7485 pub fn set_access_partition_reference_counter(&mut self, val: __u64) {
7486 unsafe {
7487 let val: u64 = ::std::mem::transmute(val);
7488 self._bitfield_1.set(3usize, 1u8, val as u64)
7489 }
7490 }
7491 #[inline]
7492 pub fn access_synic_regs(&self) -> __u64 {
7493 unsafe { ::std::mem::transmute(self._bitfield_1.get(4usize, 1u8) as u64) }
7494 }
7495 #[inline]
7496 pub fn set_access_synic_regs(&mut self, val: __u64) {
7497 unsafe {
7498 let val: u64 = ::std::mem::transmute(val);
7499 self._bitfield_1.set(4usize, 1u8, val as u64)
7500 }
7501 }
7502 #[inline]
7503 pub fn access_synthetic_timer_regs(&self) -> __u64 {
7504 unsafe { ::std::mem::transmute(self._bitfield_1.get(5usize, 1u8) as u64) }
7505 }
7506 #[inline]
7507 pub fn set_access_synthetic_timer_regs(&mut self, val: __u64) {
7508 unsafe {
7509 let val: u64 = ::std::mem::transmute(val);
7510 self._bitfield_1.set(5usize, 1u8, val as u64)
7511 }
7512 }
7513 #[inline]
7514 pub fn access_intr_ctrl_regs(&self) -> __u64 {
7515 unsafe { ::std::mem::transmute(self._bitfield_1.get(6usize, 1u8) as u64) }
7516 }
7517 #[inline]
7518 pub fn set_access_intr_ctrl_regs(&mut self, val: __u64) {
7519 unsafe {
7520 let val: u64 = ::std::mem::transmute(val);
7521 self._bitfield_1.set(6usize, 1u8, val as u64)
7522 }
7523 }
7524 #[inline]
7525 pub fn access_hypercall_regs(&self) -> __u64 {
7526 unsafe { ::std::mem::transmute(self._bitfield_1.get(7usize, 1u8) as u64) }
7527 }
7528 #[inline]
7529 pub fn set_access_hypercall_regs(&mut self, val: __u64) {
7530 unsafe {
7531 let val: u64 = ::std::mem::transmute(val);
7532 self._bitfield_1.set(7usize, 1u8, val as u64)
7533 }
7534 }
7535 #[inline]
7536 pub fn access_vp_index(&self) -> __u64 {
7537 unsafe { ::std::mem::transmute(self._bitfield_1.get(8usize, 1u8) as u64) }
7538 }
7539 #[inline]
7540 pub fn set_access_vp_index(&mut self, val: __u64) {
7541 unsafe {
7542 let val: u64 = ::std::mem::transmute(val);
7543 self._bitfield_1.set(8usize, 1u8, val as u64)
7544 }
7545 }
7546 #[inline]
7547 pub fn access_partition_reference_tsc(&self) -> __u64 {
7548 unsafe { ::std::mem::transmute(self._bitfield_1.get(9usize, 1u8) as u64) }
7549 }
7550 #[inline]
7551 pub fn set_access_partition_reference_tsc(&mut self, val: __u64) {
7552 unsafe {
7553 let val: u64 = ::std::mem::transmute(val);
7554 self._bitfield_1.set(9usize, 1u8, val as u64)
7555 }
7556 }
7557 #[inline]
7558 pub fn access_guest_idle_reg(&self) -> __u64 {
7559 unsafe { ::std::mem::transmute(self._bitfield_1.get(10usize, 1u8) as u64) }
7560 }
7561 #[inline]
7562 pub fn set_access_guest_idle_reg(&mut self, val: __u64) {
7563 unsafe {
7564 let val: u64 = ::std::mem::transmute(val);
7565 self._bitfield_1.set(10usize, 1u8, val as u64)
7566 }
7567 }
7568 #[inline]
7569 pub fn access_frequency_regs(&self) -> __u64 {
7570 unsafe { ::std::mem::transmute(self._bitfield_1.get(11usize, 1u8) as u64) }
7571 }
7572 #[inline]
7573 pub fn set_access_frequency_regs(&mut self, val: __u64) {
7574 unsafe {
7575 let val: u64 = ::std::mem::transmute(val);
7576 self._bitfield_1.set(11usize, 1u8, val as u64)
7577 }
7578 }
7579 #[inline]
7580 pub fn reserved_z12(&self) -> __u64 {
7581 unsafe { ::std::mem::transmute(self._bitfield_1.get(12usize, 1u8) as u64) }
7582 }
7583 #[inline]
7584 pub fn set_reserved_z12(&mut self, val: __u64) {
7585 unsafe {
7586 let val: u64 = ::std::mem::transmute(val);
7587 self._bitfield_1.set(12usize, 1u8, val as u64)
7588 }
7589 }
7590 #[inline]
7591 pub fn reserved_z13(&self) -> __u64 {
7592 unsafe { ::std::mem::transmute(self._bitfield_1.get(13usize, 1u8) as u64) }
7593 }
7594 #[inline]
7595 pub fn set_reserved_z13(&mut self, val: __u64) {
7596 unsafe {
7597 let val: u64 = ::std::mem::transmute(val);
7598 self._bitfield_1.set(13usize, 1u8, val as u64)
7599 }
7600 }
7601 #[inline]
7602 pub fn reserved_z14(&self) -> __u64 {
7603 unsafe { ::std::mem::transmute(self._bitfield_1.get(14usize, 1u8) as u64) }
7604 }
7605 #[inline]
7606 pub fn set_reserved_z14(&mut self, val: __u64) {
7607 unsafe {
7608 let val: u64 = ::std::mem::transmute(val);
7609 self._bitfield_1.set(14usize, 1u8, val as u64)
7610 }
7611 }
7612 #[inline]
7613 pub fn enable_extended_gva_ranges_for_flush_virtual_address_list(&self) -> __u64 {
7614 unsafe { ::std::mem::transmute(self._bitfield_1.get(15usize, 1u8) as u64) }
7615 }
7616 #[inline]
7617 pub fn set_enable_extended_gva_ranges_for_flush_virtual_address_list(&mut self, val: __u64) {
7618 unsafe {
7619 let val: u64 = ::std::mem::transmute(val);
7620 self._bitfield_1.set(15usize, 1u8, val as u64)
7621 }
7622 }
7623 #[inline]
7624 pub fn reserved_z16(&self) -> __u64 {
7625 unsafe { ::std::mem::transmute(self._bitfield_1.get(16usize, 1u8) as u64) }
7626 }
7627 #[inline]
7628 pub fn set_reserved_z16(&mut self, val: __u64) {
7629 unsafe {
7630 let val: u64 = ::std::mem::transmute(val);
7631 self._bitfield_1.set(16usize, 1u8, val as u64)
7632 }
7633 }
7634 #[inline]
7635 pub fn reserved_z17(&self) -> __u64 {
7636 unsafe { ::std::mem::transmute(self._bitfield_1.get(17usize, 1u8) as u64) }
7637 }
7638 #[inline]
7639 pub fn set_reserved_z17(&mut self, val: __u64) {
7640 unsafe {
7641 let val: u64 = ::std::mem::transmute(val);
7642 self._bitfield_1.set(17usize, 1u8, val as u64)
7643 }
7644 }
7645 #[inline]
7646 pub fn fast_hypercall_output(&self) -> __u64 {
7647 unsafe { ::std::mem::transmute(self._bitfield_1.get(18usize, 1u8) as u64) }
7648 }
7649 #[inline]
7650 pub fn set_fast_hypercall_output(&mut self, val: __u64) {
7651 unsafe {
7652 let val: u64 = ::std::mem::transmute(val);
7653 self._bitfield_1.set(18usize, 1u8, val as u64)
7654 }
7655 }
7656 #[inline]
7657 pub fn reserved_z19(&self) -> __u64 {
7658 unsafe { ::std::mem::transmute(self._bitfield_1.get(19usize, 1u8) as u64) }
7659 }
7660 #[inline]
7661 pub fn set_reserved_z19(&mut self, val: __u64) {
7662 unsafe {
7663 let val: u64 = ::std::mem::transmute(val);
7664 self._bitfield_1.set(19usize, 1u8, val as u64)
7665 }
7666 }
7667 #[inline]
7668 pub fn start_virtual_processor(&self) -> __u64 {
7669 unsafe { ::std::mem::transmute(self._bitfield_1.get(20usize, 1u8) as u64) }
7670 }
7671 #[inline]
7672 pub fn set_start_virtual_processor(&mut self, val: __u64) {
7673 unsafe {
7674 let val: u64 = ::std::mem::transmute(val);
7675 self._bitfield_1.set(20usize, 1u8, val as u64)
7676 }
7677 }
7678 #[inline]
7679 pub fn reserved_z21(&self) -> __u64 {
7680 unsafe { ::std::mem::transmute(self._bitfield_1.get(21usize, 1u8) as u64) }
7681 }
7682 #[inline]
7683 pub fn set_reserved_z21(&mut self, val: __u64) {
7684 unsafe {
7685 let val: u64 = ::std::mem::transmute(val);
7686 self._bitfield_1.set(21usize, 1u8, val as u64)
7687 }
7688 }
7689 #[inline]
7690 pub fn direct_synthetic_timers(&self) -> __u64 {
7691 unsafe { ::std::mem::transmute(self._bitfield_1.get(22usize, 1u8) as u64) }
7692 }
7693 #[inline]
7694 pub fn set_direct_synthetic_timers(&mut self, val: __u64) {
7695 unsafe {
7696 let val: u64 = ::std::mem::transmute(val);
7697 self._bitfield_1.set(22usize, 1u8, val as u64)
7698 }
7699 }
7700 #[inline]
7701 pub fn reserved_z23(&self) -> __u64 {
7702 unsafe { ::std::mem::transmute(self._bitfield_1.get(23usize, 1u8) as u64) }
7703 }
7704 #[inline]
7705 pub fn set_reserved_z23(&mut self, val: __u64) {
7706 unsafe {
7707 let val: u64 = ::std::mem::transmute(val);
7708 self._bitfield_1.set(23usize, 1u8, val as u64)
7709 }
7710 }
7711 #[inline]
7712 pub fn extended_processor_masks(&self) -> __u64 {
7713 unsafe { ::std::mem::transmute(self._bitfield_1.get(24usize, 1u8) as u64) }
7714 }
7715 #[inline]
7716 pub fn set_extended_processor_masks(&mut self, val: __u64) {
7717 unsafe {
7718 let val: u64 = ::std::mem::transmute(val);
7719 self._bitfield_1.set(24usize, 1u8, val as u64)
7720 }
7721 }
7722 #[inline]
7723 pub fn tb_flush_hypercalls(&self) -> __u64 {
7724 unsafe { ::std::mem::transmute(self._bitfield_1.get(25usize, 1u8) as u64) }
7725 }
7726 #[inline]
7727 pub fn set_tb_flush_hypercalls(&mut self, val: __u64) {
7728 unsafe {
7729 let val: u64 = ::std::mem::transmute(val);
7730 self._bitfield_1.set(25usize, 1u8, val as u64)
7731 }
7732 }
7733 #[inline]
7734 pub fn synthetic_cluster_ipi(&self) -> __u64 {
7735 unsafe { ::std::mem::transmute(self._bitfield_1.get(26usize, 1u8) as u64) }
7736 }
7737 #[inline]
7738 pub fn set_synthetic_cluster_ipi(&mut self, val: __u64) {
7739 unsafe {
7740 let val: u64 = ::std::mem::transmute(val);
7741 self._bitfield_1.set(26usize, 1u8, val as u64)
7742 }
7743 }
7744 #[inline]
7745 pub fn notify_long_spin_wait(&self) -> __u64 {
7746 unsafe { ::std::mem::transmute(self._bitfield_1.get(27usize, 1u8) as u64) }
7747 }
7748 #[inline]
7749 pub fn set_notify_long_spin_wait(&mut self, val: __u64) {
7750 unsafe {
7751 let val: u64 = ::std::mem::transmute(val);
7752 self._bitfield_1.set(27usize, 1u8, val as u64)
7753 }
7754 }
7755 #[inline]
7756 pub fn query_numa_distance(&self) -> __u64 {
7757 unsafe { ::std::mem::transmute(self._bitfield_1.get(28usize, 1u8) as u64) }
7758 }
7759 #[inline]
7760 pub fn set_query_numa_distance(&mut self, val: __u64) {
7761 unsafe {
7762 let val: u64 = ::std::mem::transmute(val);
7763 self._bitfield_1.set(28usize, 1u8, val as u64)
7764 }
7765 }
7766 #[inline]
7767 pub fn signal_events(&self) -> __u64 {
7768 unsafe { ::std::mem::transmute(self._bitfield_1.get(29usize, 1u8) as u64) }
7769 }
7770 #[inline]
7771 pub fn set_signal_events(&mut self, val: __u64) {
7772 unsafe {
7773 let val: u64 = ::std::mem::transmute(val);
7774 self._bitfield_1.set(29usize, 1u8, val as u64)
7775 }
7776 }
7777 #[inline]
7778 pub fn retarget_device_interrupt(&self) -> __u64 {
7779 unsafe { ::std::mem::transmute(self._bitfield_1.get(30usize, 1u8) as u64) }
7780 }
7781 #[inline]
7782 pub fn set_retarget_device_interrupt(&mut self, val: __u64) {
7783 unsafe {
7784 let val: u64 = ::std::mem::transmute(val);
7785 self._bitfield_1.set(30usize, 1u8, val as u64)
7786 }
7787 }
7788 #[inline]
7789 pub fn restore_time(&self) -> __u64 {
7790 unsafe { ::std::mem::transmute(self._bitfield_1.get(31usize, 1u8) as u64) }
7791 }
7792 #[inline]
7793 pub fn set_restore_time(&mut self, val: __u64) {
7794 unsafe {
7795 let val: u64 = ::std::mem::transmute(val);
7796 self._bitfield_1.set(31usize, 1u8, val as u64)
7797 }
7798 }
7799 #[inline]
7800 pub fn enlightened_vmcs(&self) -> __u64 {
7801 unsafe { ::std::mem::transmute(self._bitfield_1.get(32usize, 1u8) as u64) }
7802 }
7803 #[inline]
7804 pub fn set_enlightened_vmcs(&mut self, val: __u64) {
7805 unsafe {
7806 let val: u64 = ::std::mem::transmute(val);
7807 self._bitfield_1.set(32usize, 1u8, val as u64)
7808 }
7809 }
7810 #[inline]
7811 pub fn reserved(&self) -> __u64 {
7812 unsafe { ::std::mem::transmute(self._bitfield_1.get(33usize, 30u8) as u64) }
7813 }
7814 #[inline]
7815 pub fn set_reserved(&mut self, val: __u64) {
7816 unsafe {
7817 let val: u64 = ::std::mem::transmute(val);
7818 self._bitfield_1.set(33usize, 30u8, val as u64)
7819 }
7820 }
7821 #[inline]
7822 pub fn new_bitfield_1(
7823 hypervisor_present: __u64,
7824 hv1: __u64,
7825 access_vp_run_time_reg: __u64,
7826 access_partition_reference_counter: __u64,
7827 access_synic_regs: __u64,
7828 access_synthetic_timer_regs: __u64,
7829 access_intr_ctrl_regs: __u64,
7830 access_hypercall_regs: __u64,
7831 access_vp_index: __u64,
7832 access_partition_reference_tsc: __u64,
7833 access_guest_idle_reg: __u64,
7834 access_frequency_regs: __u64,
7835 reserved_z12: __u64,
7836 reserved_z13: __u64,
7837 reserved_z14: __u64,
7838 enable_extended_gva_ranges_for_flush_virtual_address_list: __u64,
7839 reserved_z16: __u64,
7840 reserved_z17: __u64,
7841 fast_hypercall_output: __u64,
7842 reserved_z19: __u64,
7843 start_virtual_processor: __u64,
7844 reserved_z21: __u64,
7845 direct_synthetic_timers: __u64,
7846 reserved_z23: __u64,
7847 extended_processor_masks: __u64,
7848 tb_flush_hypercalls: __u64,
7849 synthetic_cluster_ipi: __u64,
7850 notify_long_spin_wait: __u64,
7851 query_numa_distance: __u64,
7852 signal_events: __u64,
7853 retarget_device_interrupt: __u64,
7854 restore_time: __u64,
7855 enlightened_vmcs: __u64,
7856 reserved: __u64,
7857 ) -> __BindgenBitfieldUnit<[u8; 8usize]> {
7858 let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 8usize]> = Default::default();
7859 __bindgen_bitfield_unit.set(0usize, 1u8, {
7860 let hypervisor_present: u64 = unsafe { ::std::mem::transmute(hypervisor_present) };
7861 hypervisor_present as u64
7862 });
7863 __bindgen_bitfield_unit.set(1usize, 1u8, {
7864 let hv1: u64 = unsafe { ::std::mem::transmute(hv1) };
7865 hv1 as u64
7866 });
7867 __bindgen_bitfield_unit.set(2usize, 1u8, {
7868 let access_vp_run_time_reg: u64 =
7869 unsafe { ::std::mem::transmute(access_vp_run_time_reg) };
7870 access_vp_run_time_reg as u64
7871 });
7872 __bindgen_bitfield_unit.set(3usize, 1u8, {
7873 let access_partition_reference_counter: u64 =
7874 unsafe { ::std::mem::transmute(access_partition_reference_counter) };
7875 access_partition_reference_counter as u64
7876 });
7877 __bindgen_bitfield_unit.set(4usize, 1u8, {
7878 let access_synic_regs: u64 = unsafe { ::std::mem::transmute(access_synic_regs) };
7879 access_synic_regs as u64
7880 });
7881 __bindgen_bitfield_unit.set(5usize, 1u8, {
7882 let access_synthetic_timer_regs: u64 =
7883 unsafe { ::std::mem::transmute(access_synthetic_timer_regs) };
7884 access_synthetic_timer_regs as u64
7885 });
7886 __bindgen_bitfield_unit.set(6usize, 1u8, {
7887 let access_intr_ctrl_regs: u64 =
7888 unsafe { ::std::mem::transmute(access_intr_ctrl_regs) };
7889 access_intr_ctrl_regs as u64
7890 });
7891 __bindgen_bitfield_unit.set(7usize, 1u8, {
7892 let access_hypercall_regs: u64 =
7893 unsafe { ::std::mem::transmute(access_hypercall_regs) };
7894 access_hypercall_regs as u64
7895 });
7896 __bindgen_bitfield_unit.set(8usize, 1u8, {
7897 let access_vp_index: u64 = unsafe { ::std::mem::transmute(access_vp_index) };
7898 access_vp_index as u64
7899 });
7900 __bindgen_bitfield_unit.set(9usize, 1u8, {
7901 let access_partition_reference_tsc: u64 =
7902 unsafe { ::std::mem::transmute(access_partition_reference_tsc) };
7903 access_partition_reference_tsc as u64
7904 });
7905 __bindgen_bitfield_unit.set(10usize, 1u8, {
7906 let access_guest_idle_reg: u64 =
7907 unsafe { ::std::mem::transmute(access_guest_idle_reg) };
7908 access_guest_idle_reg as u64
7909 });
7910 __bindgen_bitfield_unit.set(11usize, 1u8, {
7911 let access_frequency_regs: u64 =
7912 unsafe { ::std::mem::transmute(access_frequency_regs) };
7913 access_frequency_regs as u64
7914 });
7915 __bindgen_bitfield_unit.set(12usize, 1u8, {
7916 let reserved_z12: u64 = unsafe { ::std::mem::transmute(reserved_z12) };
7917 reserved_z12 as u64
7918 });
7919 __bindgen_bitfield_unit.set(13usize, 1u8, {
7920 let reserved_z13: u64 = unsafe { ::std::mem::transmute(reserved_z13) };
7921 reserved_z13 as u64
7922 });
7923 __bindgen_bitfield_unit.set(14usize, 1u8, {
7924 let reserved_z14: u64 = unsafe { ::std::mem::transmute(reserved_z14) };
7925 reserved_z14 as u64
7926 });
7927 __bindgen_bitfield_unit.set(15usize, 1u8, {
7928 let enable_extended_gva_ranges_for_flush_virtual_address_list: u64 = unsafe {
7929 ::std::mem::transmute(enable_extended_gva_ranges_for_flush_virtual_address_list)
7930 };
7931 enable_extended_gva_ranges_for_flush_virtual_address_list as u64
7932 });
7933 __bindgen_bitfield_unit.set(16usize, 1u8, {
7934 let reserved_z16: u64 = unsafe { ::std::mem::transmute(reserved_z16) };
7935 reserved_z16 as u64
7936 });
7937 __bindgen_bitfield_unit.set(17usize, 1u8, {
7938 let reserved_z17: u64 = unsafe { ::std::mem::transmute(reserved_z17) };
7939 reserved_z17 as u64
7940 });
7941 __bindgen_bitfield_unit.set(18usize, 1u8, {
7942 let fast_hypercall_output: u64 =
7943 unsafe { ::std::mem::transmute(fast_hypercall_output) };
7944 fast_hypercall_output as u64
7945 });
7946 __bindgen_bitfield_unit.set(19usize, 1u8, {
7947 let reserved_z19: u64 = unsafe { ::std::mem::transmute(reserved_z19) };
7948 reserved_z19 as u64
7949 });
7950 __bindgen_bitfield_unit.set(20usize, 1u8, {
7951 let start_virtual_processor: u64 =
7952 unsafe { ::std::mem::transmute(start_virtual_processor) };
7953 start_virtual_processor as u64
7954 });
7955 __bindgen_bitfield_unit.set(21usize, 1u8, {
7956 let reserved_z21: u64 = unsafe { ::std::mem::transmute(reserved_z21) };
7957 reserved_z21 as u64
7958 });
7959 __bindgen_bitfield_unit.set(22usize, 1u8, {
7960 let direct_synthetic_timers: u64 =
7961 unsafe { ::std::mem::transmute(direct_synthetic_timers) };
7962 direct_synthetic_timers as u64
7963 });
7964 __bindgen_bitfield_unit.set(23usize, 1u8, {
7965 let reserved_z23: u64 = unsafe { ::std::mem::transmute(reserved_z23) };
7966 reserved_z23 as u64
7967 });
7968 __bindgen_bitfield_unit.set(24usize, 1u8, {
7969 let extended_processor_masks: u64 =
7970 unsafe { ::std::mem::transmute(extended_processor_masks) };
7971 extended_processor_masks as u64
7972 });
7973 __bindgen_bitfield_unit.set(25usize, 1u8, {
7974 let tb_flush_hypercalls: u64 = unsafe { ::std::mem::transmute(tb_flush_hypercalls) };
7975 tb_flush_hypercalls as u64
7976 });
7977 __bindgen_bitfield_unit.set(26usize, 1u8, {
7978 let synthetic_cluster_ipi: u64 =
7979 unsafe { ::std::mem::transmute(synthetic_cluster_ipi) };
7980 synthetic_cluster_ipi as u64
7981 });
7982 __bindgen_bitfield_unit.set(27usize, 1u8, {
7983 let notify_long_spin_wait: u64 =
7984 unsafe { ::std::mem::transmute(notify_long_spin_wait) };
7985 notify_long_spin_wait as u64
7986 });
7987 __bindgen_bitfield_unit.set(28usize, 1u8, {
7988 let query_numa_distance: u64 = unsafe { ::std::mem::transmute(query_numa_distance) };
7989 query_numa_distance as u64
7990 });
7991 __bindgen_bitfield_unit.set(29usize, 1u8, {
7992 let signal_events: u64 = unsafe { ::std::mem::transmute(signal_events) };
7993 signal_events as u64
7994 });
7995 __bindgen_bitfield_unit.set(30usize, 1u8, {
7996 let retarget_device_interrupt: u64 =
7997 unsafe { ::std::mem::transmute(retarget_device_interrupt) };
7998 retarget_device_interrupt as u64
7999 });
8000 __bindgen_bitfield_unit.set(31usize, 1u8, {
8001 let restore_time: u64 = unsafe { ::std::mem::transmute(restore_time) };
8002 restore_time as u64
8003 });
8004 __bindgen_bitfield_unit.set(32usize, 1u8, {
8005 let enlightened_vmcs: u64 = unsafe { ::std::mem::transmute(enlightened_vmcs) };
8006 enlightened_vmcs as u64
8007 });
8008 __bindgen_bitfield_unit.set(33usize, 30u8, {
8009 let reserved: u64 = unsafe { ::std::mem::transmute(reserved) };
8010 reserved as u64
8011 });
8012 __bindgen_bitfield_unit
8013 }
8014}
8015#[test]
8016fn bindgen_test_layout_hv_partition_synthetic_processor_features() {
8017 const UNINIT: ::std::mem::MaybeUninit<hv_partition_synthetic_processor_features> =
8018 ::std::mem::MaybeUninit::uninit();
8019 let ptr = UNINIT.as_ptr();
8020 assert_eq!(
8021 ::std::mem::size_of::<hv_partition_synthetic_processor_features>(),
8022 8usize,
8023 concat!(
8024 "Size of: ",
8025 stringify!(hv_partition_synthetic_processor_features)
8026 )
8027 );
8028 assert_eq!(
8029 ::std::mem::align_of::<hv_partition_synthetic_processor_features>(),
8030 8usize,
8031 concat!(
8032 "Alignment of ",
8033 stringify!(hv_partition_synthetic_processor_features)
8034 )
8035 );
8036 assert_eq!(
8037 unsafe { ::std::ptr::addr_of!((*ptr).as_uint64) as usize - ptr as usize },
8038 0usize,
8039 concat!(
8040 "Offset of field: ",
8041 stringify!(hv_partition_synthetic_processor_features),
8042 "::",
8043 stringify!(as_uint64)
8044 )
8045 );
8046}
8047impl Default for hv_partition_synthetic_processor_features {
8048 fn default() -> Self {
8049 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
8050 unsafe {
8051 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
8052 s.assume_init()
8053 }
8054 }
8055}
8056pub const hv_partition_isolation_state_HV_PARTITION_ISOLATION_INVALID:
8057 hv_partition_isolation_state = 0;
8058pub const hv_partition_isolation_state_HV_PARTITION_ISOLATION_INSECURE_CLEAN:
8059 hv_partition_isolation_state = 1;
8060pub const hv_partition_isolation_state_HV_PARTITION_ISOLATION_INSECURE_DIRTY:
8061 hv_partition_isolation_state = 2;
8062pub const hv_partition_isolation_state_HV_PARTITION_ISOLATION_SECURE: hv_partition_isolation_state =
8063 3;
8064pub const hv_partition_isolation_state_HV_PARTITION_ISOLATION_SECURE_DIRTY:
8065 hv_partition_isolation_state = 4;
8066pub const hv_partition_isolation_state_HV_PARTITION_ISOLATION_SECURE_TERMINATING:
8067 hv_partition_isolation_state = 5;
8068pub type hv_partition_isolation_state = ::std::os::raw::c_uint;
8069#[repr(C)]
8070#[derive(Copy, Clone)]
8071pub union hv_partition_isolation_properties {
8072 pub as_uint64: __u64,
8073 pub __bindgen_anon_1: hv_partition_isolation_properties__bindgen_ty_1,
8074}
8075#[repr(C, packed)]
8076#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
8077pub struct hv_partition_isolation_properties__bindgen_ty_1 {
8078 pub _bitfield_align_1: [u8; 0],
8079 pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>,
8080}
8081#[test]
8082fn bindgen_test_layout_hv_partition_isolation_properties__bindgen_ty_1() {
8083 assert_eq!(
8084 ::std::mem::size_of::<hv_partition_isolation_properties__bindgen_ty_1>(),
8085 8usize,
8086 concat!(
8087 "Size of: ",
8088 stringify!(hv_partition_isolation_properties__bindgen_ty_1)
8089 )
8090 );
8091 assert_eq!(
8092 ::std::mem::align_of::<hv_partition_isolation_properties__bindgen_ty_1>(),
8093 1usize,
8094 concat!(
8095 "Alignment of ",
8096 stringify!(hv_partition_isolation_properties__bindgen_ty_1)
8097 )
8098 );
8099}
8100impl hv_partition_isolation_properties__bindgen_ty_1 {
8101 #[inline]
8102 pub fn isolation_type(&self) -> __u64 {
8103 unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 5u8) as u64) }
8104 }
8105 #[inline]
8106 pub fn set_isolation_type(&mut self, val: __u64) {
8107 unsafe {
8108 let val: u64 = ::std::mem::transmute(val);
8109 self._bitfield_1.set(0usize, 5u8, val as u64)
8110 }
8111 }
8112 #[inline]
8113 pub fn isolation_host_type(&self) -> __u64 {
8114 unsafe { ::std::mem::transmute(self._bitfield_1.get(5usize, 2u8) as u64) }
8115 }
8116 #[inline]
8117 pub fn set_isolation_host_type(&mut self, val: __u64) {
8118 unsafe {
8119 let val: u64 = ::std::mem::transmute(val);
8120 self._bitfield_1.set(5usize, 2u8, val as u64)
8121 }
8122 }
8123 #[inline]
8124 pub fn rsvd_z(&self) -> __u64 {
8125 unsafe { ::std::mem::transmute(self._bitfield_1.get(7usize, 5u8) as u64) }
8126 }
8127 #[inline]
8128 pub fn set_rsvd_z(&mut self, val: __u64) {
8129 unsafe {
8130 let val: u64 = ::std::mem::transmute(val);
8131 self._bitfield_1.set(7usize, 5u8, val as u64)
8132 }
8133 }
8134 #[inline]
8135 pub fn shared_gpa_boundary_page_number(&self) -> __u64 {
8136 unsafe { ::std::mem::transmute(self._bitfield_1.get(12usize, 52u8) as u64) }
8137 }
8138 #[inline]
8139 pub fn set_shared_gpa_boundary_page_number(&mut self, val: __u64) {
8140 unsafe {
8141 let val: u64 = ::std::mem::transmute(val);
8142 self._bitfield_1.set(12usize, 52u8, val as u64)
8143 }
8144 }
8145 #[inline]
8146 pub fn new_bitfield_1(
8147 isolation_type: __u64,
8148 isolation_host_type: __u64,
8149 rsvd_z: __u64,
8150 shared_gpa_boundary_page_number: __u64,
8151 ) -> __BindgenBitfieldUnit<[u8; 8usize]> {
8152 let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 8usize]> = Default::default();
8153 __bindgen_bitfield_unit.set(0usize, 5u8, {
8154 let isolation_type: u64 = unsafe { ::std::mem::transmute(isolation_type) };
8155 isolation_type as u64
8156 });
8157 __bindgen_bitfield_unit.set(5usize, 2u8, {
8158 let isolation_host_type: u64 = unsafe { ::std::mem::transmute(isolation_host_type) };
8159 isolation_host_type as u64
8160 });
8161 __bindgen_bitfield_unit.set(7usize, 5u8, {
8162 let rsvd_z: u64 = unsafe { ::std::mem::transmute(rsvd_z) };
8163 rsvd_z as u64
8164 });
8165 __bindgen_bitfield_unit.set(12usize, 52u8, {
8166 let shared_gpa_boundary_page_number: u64 =
8167 unsafe { ::std::mem::transmute(shared_gpa_boundary_page_number) };
8168 shared_gpa_boundary_page_number as u64
8169 });
8170 __bindgen_bitfield_unit
8171 }
8172}
8173#[test]
8174fn bindgen_test_layout_hv_partition_isolation_properties() {
8175 const UNINIT: ::std::mem::MaybeUninit<hv_partition_isolation_properties> =
8176 ::std::mem::MaybeUninit::uninit();
8177 let ptr = UNINIT.as_ptr();
8178 assert_eq!(
8179 ::std::mem::size_of::<hv_partition_isolation_properties>(),
8180 8usize,
8181 concat!("Size of: ", stringify!(hv_partition_isolation_properties))
8182 );
8183 assert_eq!(
8184 ::std::mem::align_of::<hv_partition_isolation_properties>(),
8185 8usize,
8186 concat!(
8187 "Alignment of ",
8188 stringify!(hv_partition_isolation_properties)
8189 )
8190 );
8191 assert_eq!(
8192 unsafe { ::std::ptr::addr_of!((*ptr).as_uint64) as usize - ptr as usize },
8193 0usize,
8194 concat!(
8195 "Offset of field: ",
8196 stringify!(hv_partition_isolation_properties),
8197 "::",
8198 stringify!(as_uint64)
8199 )
8200 );
8201}
8202impl Default for hv_partition_isolation_properties {
8203 fn default() -> Self {
8204 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
8205 unsafe {
8206 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
8207 s.assume_init()
8208 }
8209 }
8210}
8211#[repr(C, packed)]
8212#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
8213pub struct hv_input_get_partition_property {
8214 pub partition_id: __u64,
8215 pub property_code: __u32,
8216 pub padding: __u32,
8217}
8218#[test]
8219fn bindgen_test_layout_hv_input_get_partition_property() {
8220 const UNINIT: ::std::mem::MaybeUninit<hv_input_get_partition_property> =
8221 ::std::mem::MaybeUninit::uninit();
8222 let ptr = UNINIT.as_ptr();
8223 assert_eq!(
8224 ::std::mem::size_of::<hv_input_get_partition_property>(),
8225 16usize,
8226 concat!("Size of: ", stringify!(hv_input_get_partition_property))
8227 );
8228 assert_eq!(
8229 ::std::mem::align_of::<hv_input_get_partition_property>(),
8230 1usize,
8231 concat!("Alignment of ", stringify!(hv_input_get_partition_property))
8232 );
8233 assert_eq!(
8234 unsafe { ::std::ptr::addr_of!((*ptr).partition_id) as usize - ptr as usize },
8235 0usize,
8236 concat!(
8237 "Offset of field: ",
8238 stringify!(hv_input_get_partition_property),
8239 "::",
8240 stringify!(partition_id)
8241 )
8242 );
8243 assert_eq!(
8244 unsafe { ::std::ptr::addr_of!((*ptr).property_code) as usize - ptr as usize },
8245 8usize,
8246 concat!(
8247 "Offset of field: ",
8248 stringify!(hv_input_get_partition_property),
8249 "::",
8250 stringify!(property_code)
8251 )
8252 );
8253 assert_eq!(
8254 unsafe { ::std::ptr::addr_of!((*ptr).padding) as usize - ptr as usize },
8255 12usize,
8256 concat!(
8257 "Offset of field: ",
8258 stringify!(hv_input_get_partition_property),
8259 "::",
8260 stringify!(padding)
8261 )
8262 );
8263}
8264#[repr(C, packed)]
8265#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
8266pub struct hv_output_get_partition_property {
8267 pub property_value: __u64,
8268}
8269#[test]
8270fn bindgen_test_layout_hv_output_get_partition_property() {
8271 const UNINIT: ::std::mem::MaybeUninit<hv_output_get_partition_property> =
8272 ::std::mem::MaybeUninit::uninit();
8273 let ptr = UNINIT.as_ptr();
8274 assert_eq!(
8275 ::std::mem::size_of::<hv_output_get_partition_property>(),
8276 8usize,
8277 concat!("Size of: ", stringify!(hv_output_get_partition_property))
8278 );
8279 assert_eq!(
8280 ::std::mem::align_of::<hv_output_get_partition_property>(),
8281 1usize,
8282 concat!(
8283 "Alignment of ",
8284 stringify!(hv_output_get_partition_property)
8285 )
8286 );
8287 assert_eq!(
8288 unsafe { ::std::ptr::addr_of!((*ptr).property_value) as usize - ptr as usize },
8289 0usize,
8290 concat!(
8291 "Offset of field: ",
8292 stringify!(hv_output_get_partition_property),
8293 "::",
8294 stringify!(property_value)
8295 )
8296 );
8297}
8298#[repr(C, packed)]
8299#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
8300pub struct hv_input_set_partition_property {
8301 pub partition_id: __u64,
8302 pub property_code: __u32,
8303 pub padding: __u32,
8304 pub property_value: __u64,
8305}
8306#[test]
8307fn bindgen_test_layout_hv_input_set_partition_property() {
8308 const UNINIT: ::std::mem::MaybeUninit<hv_input_set_partition_property> =
8309 ::std::mem::MaybeUninit::uninit();
8310 let ptr = UNINIT.as_ptr();
8311 assert_eq!(
8312 ::std::mem::size_of::<hv_input_set_partition_property>(),
8313 24usize,
8314 concat!("Size of: ", stringify!(hv_input_set_partition_property))
8315 );
8316 assert_eq!(
8317 ::std::mem::align_of::<hv_input_set_partition_property>(),
8318 1usize,
8319 concat!("Alignment of ", stringify!(hv_input_set_partition_property))
8320 );
8321 assert_eq!(
8322 unsafe { ::std::ptr::addr_of!((*ptr).partition_id) as usize - ptr as usize },
8323 0usize,
8324 concat!(
8325 "Offset of field: ",
8326 stringify!(hv_input_set_partition_property),
8327 "::",
8328 stringify!(partition_id)
8329 )
8330 );
8331 assert_eq!(
8332 unsafe { ::std::ptr::addr_of!((*ptr).property_code) as usize - ptr as usize },
8333 8usize,
8334 concat!(
8335 "Offset of field: ",
8336 stringify!(hv_input_set_partition_property),
8337 "::",
8338 stringify!(property_code)
8339 )
8340 );
8341 assert_eq!(
8342 unsafe { ::std::ptr::addr_of!((*ptr).padding) as usize - ptr as usize },
8343 12usize,
8344 concat!(
8345 "Offset of field: ",
8346 stringify!(hv_input_set_partition_property),
8347 "::",
8348 stringify!(padding)
8349 )
8350 );
8351 assert_eq!(
8352 unsafe { ::std::ptr::addr_of!((*ptr).property_value) as usize - ptr as usize },
8353 16usize,
8354 concat!(
8355 "Offset of field: ",
8356 stringify!(hv_input_set_partition_property),
8357 "::",
8358 stringify!(property_value)
8359 )
8360 );
8361}
8362#[repr(C, packed)]
8363#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
8364pub struct hv_cpuid_leaf_info {
8365 pub eax: __u32,
8366 pub ecx: __u32,
8367 pub xfem: __u64,
8368 pub xss: __u64,
8369}
8370#[test]
8371fn bindgen_test_layout_hv_cpuid_leaf_info() {
8372 const UNINIT: ::std::mem::MaybeUninit<hv_cpuid_leaf_info> = ::std::mem::MaybeUninit::uninit();
8373 let ptr = UNINIT.as_ptr();
8374 assert_eq!(
8375 ::std::mem::size_of::<hv_cpuid_leaf_info>(),
8376 24usize,
8377 concat!("Size of: ", stringify!(hv_cpuid_leaf_info))
8378 );
8379 assert_eq!(
8380 ::std::mem::align_of::<hv_cpuid_leaf_info>(),
8381 1usize,
8382 concat!("Alignment of ", stringify!(hv_cpuid_leaf_info))
8383 );
8384 assert_eq!(
8385 unsafe { ::std::ptr::addr_of!((*ptr).eax) as usize - ptr as usize },
8386 0usize,
8387 concat!(
8388 "Offset of field: ",
8389 stringify!(hv_cpuid_leaf_info),
8390 "::",
8391 stringify!(eax)
8392 )
8393 );
8394 assert_eq!(
8395 unsafe { ::std::ptr::addr_of!((*ptr).ecx) as usize - ptr as usize },
8396 4usize,
8397 concat!(
8398 "Offset of field: ",
8399 stringify!(hv_cpuid_leaf_info),
8400 "::",
8401 stringify!(ecx)
8402 )
8403 );
8404 assert_eq!(
8405 unsafe { ::std::ptr::addr_of!((*ptr).xfem) as usize - ptr as usize },
8406 8usize,
8407 concat!(
8408 "Offset of field: ",
8409 stringify!(hv_cpuid_leaf_info),
8410 "::",
8411 stringify!(xfem)
8412 )
8413 );
8414 assert_eq!(
8415 unsafe { ::std::ptr::addr_of!((*ptr).xss) as usize - ptr as usize },
8416 16usize,
8417 concat!(
8418 "Offset of field: ",
8419 stringify!(hv_cpuid_leaf_info),
8420 "::",
8421 stringify!(xss)
8422 )
8423 );
8424}
8425#[repr(C, packed)]
8426#[derive(Copy, Clone)]
8427pub union hv_get_vp_cpuid_values_flags {
8428 pub as_uint32: __u32,
8429 pub __bindgen_anon_1: hv_get_vp_cpuid_values_flags__bindgen_ty_1,
8430}
8431#[repr(C, packed)]
8432#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
8433pub struct hv_get_vp_cpuid_values_flags__bindgen_ty_1 {
8434 pub _bitfield_align_1: [u8; 0],
8435 pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize]>,
8436}
8437#[test]
8438fn bindgen_test_layout_hv_get_vp_cpuid_values_flags__bindgen_ty_1() {
8439 assert_eq!(
8440 ::std::mem::size_of::<hv_get_vp_cpuid_values_flags__bindgen_ty_1>(),
8441 4usize,
8442 concat!(
8443 "Size of: ",
8444 stringify!(hv_get_vp_cpuid_values_flags__bindgen_ty_1)
8445 )
8446 );
8447 assert_eq!(
8448 ::std::mem::align_of::<hv_get_vp_cpuid_values_flags__bindgen_ty_1>(),
8449 1usize,
8450 concat!(
8451 "Alignment of ",
8452 stringify!(hv_get_vp_cpuid_values_flags__bindgen_ty_1)
8453 )
8454 );
8455}
8456impl hv_get_vp_cpuid_values_flags__bindgen_ty_1 {
8457 #[inline]
8458 pub fn use_vp_xfem_xss(&self) -> __u32 {
8459 unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 1u8) as u32) }
8460 }
8461 #[inline]
8462 pub fn set_use_vp_xfem_xss(&mut self, val: __u32) {
8463 unsafe {
8464 let val: u32 = ::std::mem::transmute(val);
8465 self._bitfield_1.set(0usize, 1u8, val as u64)
8466 }
8467 }
8468 #[inline]
8469 pub fn apply_registered_values(&self) -> __u32 {
8470 unsafe { ::std::mem::transmute(self._bitfield_1.get(1usize, 1u8) as u32) }
8471 }
8472 #[inline]
8473 pub fn set_apply_registered_values(&mut self, val: __u32) {
8474 unsafe {
8475 let val: u32 = ::std::mem::transmute(val);
8476 self._bitfield_1.set(1usize, 1u8, val as u64)
8477 }
8478 }
8479 #[inline]
8480 pub fn reserved(&self) -> __u32 {
8481 unsafe { ::std::mem::transmute(self._bitfield_1.get(2usize, 30u8) as u32) }
8482 }
8483 #[inline]
8484 pub fn set_reserved(&mut self, val: __u32) {
8485 unsafe {
8486 let val: u32 = ::std::mem::transmute(val);
8487 self._bitfield_1.set(2usize, 30u8, val as u64)
8488 }
8489 }
8490 #[inline]
8491 pub fn new_bitfield_1(
8492 use_vp_xfem_xss: __u32,
8493 apply_registered_values: __u32,
8494 reserved: __u32,
8495 ) -> __BindgenBitfieldUnit<[u8; 4usize]> {
8496 let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 4usize]> = Default::default();
8497 __bindgen_bitfield_unit.set(0usize, 1u8, {
8498 let use_vp_xfem_xss: u32 = unsafe { ::std::mem::transmute(use_vp_xfem_xss) };
8499 use_vp_xfem_xss as u64
8500 });
8501 __bindgen_bitfield_unit.set(1usize, 1u8, {
8502 let apply_registered_values: u32 =
8503 unsafe { ::std::mem::transmute(apply_registered_values) };
8504 apply_registered_values as u64
8505 });
8506 __bindgen_bitfield_unit.set(2usize, 30u8, {
8507 let reserved: u32 = unsafe { ::std::mem::transmute(reserved) };
8508 reserved as u64
8509 });
8510 __bindgen_bitfield_unit
8511 }
8512}
8513#[test]
8514fn bindgen_test_layout_hv_get_vp_cpuid_values_flags() {
8515 const UNINIT: ::std::mem::MaybeUninit<hv_get_vp_cpuid_values_flags> =
8516 ::std::mem::MaybeUninit::uninit();
8517 let ptr = UNINIT.as_ptr();
8518 assert_eq!(
8519 ::std::mem::size_of::<hv_get_vp_cpuid_values_flags>(),
8520 4usize,
8521 concat!("Size of: ", stringify!(hv_get_vp_cpuid_values_flags))
8522 );
8523 assert_eq!(
8524 ::std::mem::align_of::<hv_get_vp_cpuid_values_flags>(),
8525 1usize,
8526 concat!("Alignment of ", stringify!(hv_get_vp_cpuid_values_flags))
8527 );
8528 assert_eq!(
8529 unsafe { ::std::ptr::addr_of!((*ptr).as_uint32) as usize - ptr as usize },
8530 0usize,
8531 concat!(
8532 "Offset of field: ",
8533 stringify!(hv_get_vp_cpuid_values_flags),
8534 "::",
8535 stringify!(as_uint32)
8536 )
8537 );
8538}
8539impl Default for hv_get_vp_cpuid_values_flags {
8540 fn default() -> Self {
8541 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
8542 unsafe {
8543 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
8544 s.assume_init()
8545 }
8546 }
8547}
8548#[repr(C, packed)]
8549pub struct hv_input_get_vp_cpuid_values {
8550 pub partition_id: __u64,
8551 pub vp_index: __u32,
8552 pub flags: hv_get_vp_cpuid_values_flags,
8553 pub reserved: __u32,
8554 pub padding: __u32,
8555 pub cpuid_leaf_info: __IncompleteArrayField<hv_cpuid_leaf_info>,
8556}
8557#[test]
8558fn bindgen_test_layout_hv_input_get_vp_cpuid_values() {
8559 const UNINIT: ::std::mem::MaybeUninit<hv_input_get_vp_cpuid_values> =
8560 ::std::mem::MaybeUninit::uninit();
8561 let ptr = UNINIT.as_ptr();
8562 assert_eq!(
8563 ::std::mem::size_of::<hv_input_get_vp_cpuid_values>(),
8564 24usize,
8565 concat!("Size of: ", stringify!(hv_input_get_vp_cpuid_values))
8566 );
8567 assert_eq!(
8568 ::std::mem::align_of::<hv_input_get_vp_cpuid_values>(),
8569 1usize,
8570 concat!("Alignment of ", stringify!(hv_input_get_vp_cpuid_values))
8571 );
8572 assert_eq!(
8573 unsafe { ::std::ptr::addr_of!((*ptr).partition_id) as usize - ptr as usize },
8574 0usize,
8575 concat!(
8576 "Offset of field: ",
8577 stringify!(hv_input_get_vp_cpuid_values),
8578 "::",
8579 stringify!(partition_id)
8580 )
8581 );
8582 assert_eq!(
8583 unsafe { ::std::ptr::addr_of!((*ptr).vp_index) as usize - ptr as usize },
8584 8usize,
8585 concat!(
8586 "Offset of field: ",
8587 stringify!(hv_input_get_vp_cpuid_values),
8588 "::",
8589 stringify!(vp_index)
8590 )
8591 );
8592 assert_eq!(
8593 unsafe { ::std::ptr::addr_of!((*ptr).flags) as usize - ptr as usize },
8594 12usize,
8595 concat!(
8596 "Offset of field: ",
8597 stringify!(hv_input_get_vp_cpuid_values),
8598 "::",
8599 stringify!(flags)
8600 )
8601 );
8602 assert_eq!(
8603 unsafe { ::std::ptr::addr_of!((*ptr).reserved) as usize - ptr as usize },
8604 16usize,
8605 concat!(
8606 "Offset of field: ",
8607 stringify!(hv_input_get_vp_cpuid_values),
8608 "::",
8609 stringify!(reserved)
8610 )
8611 );
8612 assert_eq!(
8613 unsafe { ::std::ptr::addr_of!((*ptr).padding) as usize - ptr as usize },
8614 20usize,
8615 concat!(
8616 "Offset of field: ",
8617 stringify!(hv_input_get_vp_cpuid_values),
8618 "::",
8619 stringify!(padding)
8620 )
8621 );
8622 assert_eq!(
8623 unsafe { ::std::ptr::addr_of!((*ptr).cpuid_leaf_info) as usize - ptr as usize },
8624 24usize,
8625 concat!(
8626 "Offset of field: ",
8627 stringify!(hv_input_get_vp_cpuid_values),
8628 "::",
8629 stringify!(cpuid_leaf_info)
8630 )
8631 );
8632}
8633impl Default for hv_input_get_vp_cpuid_values {
8634 fn default() -> Self {
8635 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
8636 unsafe {
8637 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
8638 s.assume_init()
8639 }
8640 }
8641}
8642#[repr(C)]
8643#[derive(Copy, Clone)]
8644pub union hv_output_get_vp_cpuid_values {
8645 pub as_uint32: [__u32; 4usize],
8646 pub __bindgen_anon_1: hv_output_get_vp_cpuid_values__bindgen_ty_1,
8647}
8648#[repr(C, packed)]
8649#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
8650pub struct hv_output_get_vp_cpuid_values__bindgen_ty_1 {
8651 pub eax: __u32,
8652 pub ebx: __u32,
8653 pub ecx: __u32,
8654 pub edx: __u32,
8655}
8656#[test]
8657fn bindgen_test_layout_hv_output_get_vp_cpuid_values__bindgen_ty_1() {
8658 const UNINIT: ::std::mem::MaybeUninit<hv_output_get_vp_cpuid_values__bindgen_ty_1> =
8659 ::std::mem::MaybeUninit::uninit();
8660 let ptr = UNINIT.as_ptr();
8661 assert_eq!(
8662 ::std::mem::size_of::<hv_output_get_vp_cpuid_values__bindgen_ty_1>(),
8663 16usize,
8664 concat!(
8665 "Size of: ",
8666 stringify!(hv_output_get_vp_cpuid_values__bindgen_ty_1)
8667 )
8668 );
8669 assert_eq!(
8670 ::std::mem::align_of::<hv_output_get_vp_cpuid_values__bindgen_ty_1>(),
8671 1usize,
8672 concat!(
8673 "Alignment of ",
8674 stringify!(hv_output_get_vp_cpuid_values__bindgen_ty_1)
8675 )
8676 );
8677 assert_eq!(
8678 unsafe { ::std::ptr::addr_of!((*ptr).eax) as usize - ptr as usize },
8679 0usize,
8680 concat!(
8681 "Offset of field: ",
8682 stringify!(hv_output_get_vp_cpuid_values__bindgen_ty_1),
8683 "::",
8684 stringify!(eax)
8685 )
8686 );
8687 assert_eq!(
8688 unsafe { ::std::ptr::addr_of!((*ptr).ebx) as usize - ptr as usize },
8689 4usize,
8690 concat!(
8691 "Offset of field: ",
8692 stringify!(hv_output_get_vp_cpuid_values__bindgen_ty_1),
8693 "::",
8694 stringify!(ebx)
8695 )
8696 );
8697 assert_eq!(
8698 unsafe { ::std::ptr::addr_of!((*ptr).ecx) as usize - ptr as usize },
8699 8usize,
8700 concat!(
8701 "Offset of field: ",
8702 stringify!(hv_output_get_vp_cpuid_values__bindgen_ty_1),
8703 "::",
8704 stringify!(ecx)
8705 )
8706 );
8707 assert_eq!(
8708 unsafe { ::std::ptr::addr_of!((*ptr).edx) as usize - ptr as usize },
8709 12usize,
8710 concat!(
8711 "Offset of field: ",
8712 stringify!(hv_output_get_vp_cpuid_values__bindgen_ty_1),
8713 "::",
8714 stringify!(edx)
8715 )
8716 );
8717}
8718#[test]
8719fn bindgen_test_layout_hv_output_get_vp_cpuid_values() {
8720 const UNINIT: ::std::mem::MaybeUninit<hv_output_get_vp_cpuid_values> =
8721 ::std::mem::MaybeUninit::uninit();
8722 let ptr = UNINIT.as_ptr();
8723 assert_eq!(
8724 ::std::mem::size_of::<hv_output_get_vp_cpuid_values>(),
8725 16usize,
8726 concat!("Size of: ", stringify!(hv_output_get_vp_cpuid_values))
8727 );
8728 assert_eq!(
8729 ::std::mem::align_of::<hv_output_get_vp_cpuid_values>(),
8730 4usize,
8731 concat!("Alignment of ", stringify!(hv_output_get_vp_cpuid_values))
8732 );
8733 assert_eq!(
8734 unsafe { ::std::ptr::addr_of!((*ptr).as_uint32) as usize - ptr as usize },
8735 0usize,
8736 concat!(
8737 "Offset of field: ",
8738 stringify!(hv_output_get_vp_cpuid_values),
8739 "::",
8740 stringify!(as_uint32)
8741 )
8742 );
8743}
8744impl Default for hv_output_get_vp_cpuid_values {
8745 fn default() -> Self {
8746 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
8747 unsafe {
8748 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
8749 s.assume_init()
8750 }
8751 }
8752}
8753pub const hv_translate_gva_result_code_HV_TRANSLATE_GVA_SUCCESS: hv_translate_gva_result_code = 0;
8754pub const hv_translate_gva_result_code_HV_TRANSLATE_GVA_PAGE_NOT_PRESENT:
8755 hv_translate_gva_result_code = 1;
8756pub const hv_translate_gva_result_code_HV_TRANSLATE_GVA_PRIVILEGE_VIOLATION:
8757 hv_translate_gva_result_code = 2;
8758pub const hv_translate_gva_result_code_HV_TRANSLATE_GVA_INVALIDE_PAGE_TABLE_FLAGS:
8759 hv_translate_gva_result_code = 3;
8760pub const hv_translate_gva_result_code_HV_TRANSLATE_GVA_GPA_UNMAPPED: hv_translate_gva_result_code =
8761 4;
8762pub const hv_translate_gva_result_code_HV_TRANSLATE_GVA_GPA_NO_READ_ACCESS:
8763 hv_translate_gva_result_code = 5;
8764pub const hv_translate_gva_result_code_HV_TRANSLATE_GVA_GPA_NO_WRITE_ACCESS:
8765 hv_translate_gva_result_code = 6;
8766pub const hv_translate_gva_result_code_HV_TRANSLATE_GVA_GPA_ILLEGAL_OVERLAY_ACCESS:
8767 hv_translate_gva_result_code = 7;
8768pub const hv_translate_gva_result_code_HV_TRANSLATE_GVA_INTERCEPT: hv_translate_gva_result_code = 8;
8769pub const hv_translate_gva_result_code_HV_TRANSLATE_GVA_GPA_UNACCEPTED:
8770 hv_translate_gva_result_code = 9;
8771pub type hv_translate_gva_result_code = ::std::os::raw::c_uint;
8772#[repr(C)]
8773#[derive(Copy, Clone)]
8774pub union hv_translate_gva_result {
8775 pub as_uint64: __u64,
8776 pub __bindgen_anon_1: hv_translate_gva_result__bindgen_ty_1,
8777}
8778#[repr(C, packed)]
8779#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
8780pub struct hv_translate_gva_result__bindgen_ty_1 {
8781 pub result_code: __u32,
8782 pub _bitfield_align_1: [u8; 0],
8783 pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize]>,
8784}
8785#[test]
8786fn bindgen_test_layout_hv_translate_gva_result__bindgen_ty_1() {
8787 const UNINIT: ::std::mem::MaybeUninit<hv_translate_gva_result__bindgen_ty_1> =
8788 ::std::mem::MaybeUninit::uninit();
8789 let ptr = UNINIT.as_ptr();
8790 assert_eq!(
8791 ::std::mem::size_of::<hv_translate_gva_result__bindgen_ty_1>(),
8792 8usize,
8793 concat!(
8794 "Size of: ",
8795 stringify!(hv_translate_gva_result__bindgen_ty_1)
8796 )
8797 );
8798 assert_eq!(
8799 ::std::mem::align_of::<hv_translate_gva_result__bindgen_ty_1>(),
8800 1usize,
8801 concat!(
8802 "Alignment of ",
8803 stringify!(hv_translate_gva_result__bindgen_ty_1)
8804 )
8805 );
8806 assert_eq!(
8807 unsafe { ::std::ptr::addr_of!((*ptr).result_code) as usize - ptr as usize },
8808 0usize,
8809 concat!(
8810 "Offset of field: ",
8811 stringify!(hv_translate_gva_result__bindgen_ty_1),
8812 "::",
8813 stringify!(result_code)
8814 )
8815 );
8816}
8817impl hv_translate_gva_result__bindgen_ty_1 {
8818 #[inline]
8819 pub fn cache_type(&self) -> __u32 {
8820 unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 8u8) as u32) }
8821 }
8822 #[inline]
8823 pub fn set_cache_type(&mut self, val: __u32) {
8824 unsafe {
8825 let val: u32 = ::std::mem::transmute(val);
8826 self._bitfield_1.set(0usize, 8u8, val as u64)
8827 }
8828 }
8829 #[inline]
8830 pub fn overlay_page(&self) -> __u32 {
8831 unsafe { ::std::mem::transmute(self._bitfield_1.get(8usize, 1u8) as u32) }
8832 }
8833 #[inline]
8834 pub fn set_overlay_page(&mut self, val: __u32) {
8835 unsafe {
8836 let val: u32 = ::std::mem::transmute(val);
8837 self._bitfield_1.set(8usize, 1u8, val as u64)
8838 }
8839 }
8840 #[inline]
8841 pub fn reserved(&self) -> __u32 {
8842 unsafe { ::std::mem::transmute(self._bitfield_1.get(9usize, 23u8) as u32) }
8843 }
8844 #[inline]
8845 pub fn set_reserved(&mut self, val: __u32) {
8846 unsafe {
8847 let val: u32 = ::std::mem::transmute(val);
8848 self._bitfield_1.set(9usize, 23u8, val as u64)
8849 }
8850 }
8851 #[inline]
8852 pub fn new_bitfield_1(
8853 cache_type: __u32,
8854 overlay_page: __u32,
8855 reserved: __u32,
8856 ) -> __BindgenBitfieldUnit<[u8; 4usize]> {
8857 let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 4usize]> = Default::default();
8858 __bindgen_bitfield_unit.set(0usize, 8u8, {
8859 let cache_type: u32 = unsafe { ::std::mem::transmute(cache_type) };
8860 cache_type as u64
8861 });
8862 __bindgen_bitfield_unit.set(8usize, 1u8, {
8863 let overlay_page: u32 = unsafe { ::std::mem::transmute(overlay_page) };
8864 overlay_page as u64
8865 });
8866 __bindgen_bitfield_unit.set(9usize, 23u8, {
8867 let reserved: u32 = unsafe { ::std::mem::transmute(reserved) };
8868 reserved as u64
8869 });
8870 __bindgen_bitfield_unit
8871 }
8872}
8873#[test]
8874fn bindgen_test_layout_hv_translate_gva_result() {
8875 const UNINIT: ::std::mem::MaybeUninit<hv_translate_gva_result> =
8876 ::std::mem::MaybeUninit::uninit();
8877 let ptr = UNINIT.as_ptr();
8878 assert_eq!(
8879 ::std::mem::size_of::<hv_translate_gva_result>(),
8880 8usize,
8881 concat!("Size of: ", stringify!(hv_translate_gva_result))
8882 );
8883 assert_eq!(
8884 ::std::mem::align_of::<hv_translate_gva_result>(),
8885 8usize,
8886 concat!("Alignment of ", stringify!(hv_translate_gva_result))
8887 );
8888 assert_eq!(
8889 unsafe { ::std::ptr::addr_of!((*ptr).as_uint64) as usize - ptr as usize },
8890 0usize,
8891 concat!(
8892 "Offset of field: ",
8893 stringify!(hv_translate_gva_result),
8894 "::",
8895 stringify!(as_uint64)
8896 )
8897 );
8898}
8899impl Default for hv_translate_gva_result {
8900 fn default() -> Self {
8901 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
8902 unsafe {
8903 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
8904 s.assume_init()
8905 }
8906 }
8907}
8908#[repr(C, packed)]
8909#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
8910pub struct hv_x64_apic_eoi_message {
8911 pub vp_index: __u32,
8912 pub interrupt_vector: __u32,
8913}
8914#[test]
8915fn bindgen_test_layout_hv_x64_apic_eoi_message() {
8916 const UNINIT: ::std::mem::MaybeUninit<hv_x64_apic_eoi_message> =
8917 ::std::mem::MaybeUninit::uninit();
8918 let ptr = UNINIT.as_ptr();
8919 assert_eq!(
8920 ::std::mem::size_of::<hv_x64_apic_eoi_message>(),
8921 8usize,
8922 concat!("Size of: ", stringify!(hv_x64_apic_eoi_message))
8923 );
8924 assert_eq!(
8925 ::std::mem::align_of::<hv_x64_apic_eoi_message>(),
8926 1usize,
8927 concat!("Alignment of ", stringify!(hv_x64_apic_eoi_message))
8928 );
8929 assert_eq!(
8930 unsafe { ::std::ptr::addr_of!((*ptr).vp_index) as usize - ptr as usize },
8931 0usize,
8932 concat!(
8933 "Offset of field: ",
8934 stringify!(hv_x64_apic_eoi_message),
8935 "::",
8936 stringify!(vp_index)
8937 )
8938 );
8939 assert_eq!(
8940 unsafe { ::std::ptr::addr_of!((*ptr).interrupt_vector) as usize - ptr as usize },
8941 4usize,
8942 concat!(
8943 "Offset of field: ",
8944 stringify!(hv_x64_apic_eoi_message),
8945 "::",
8946 stringify!(interrupt_vector)
8947 )
8948 );
8949}
8950#[repr(C, packed)]
8951#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
8952pub struct hv_opaque_intercept_message {
8953 pub vp_index: __u32,
8954}
8955#[test]
8956fn bindgen_test_layout_hv_opaque_intercept_message() {
8957 const UNINIT: ::std::mem::MaybeUninit<hv_opaque_intercept_message> =
8958 ::std::mem::MaybeUninit::uninit();
8959 let ptr = UNINIT.as_ptr();
8960 assert_eq!(
8961 ::std::mem::size_of::<hv_opaque_intercept_message>(),
8962 4usize,
8963 concat!("Size of: ", stringify!(hv_opaque_intercept_message))
8964 );
8965 assert_eq!(
8966 ::std::mem::align_of::<hv_opaque_intercept_message>(),
8967 1usize,
8968 concat!("Alignment of ", stringify!(hv_opaque_intercept_message))
8969 );
8970 assert_eq!(
8971 unsafe { ::std::ptr::addr_of!((*ptr).vp_index) as usize - ptr as usize },
8972 0usize,
8973 concat!(
8974 "Offset of field: ",
8975 stringify!(hv_opaque_intercept_message),
8976 "::",
8977 stringify!(vp_index)
8978 )
8979 );
8980}
8981pub const hv_port_type_HV_PORT_TYPE_MESSAGE: hv_port_type = 1;
8982pub const hv_port_type_HV_PORT_TYPE_EVENT: hv_port_type = 2;
8983pub const hv_port_type_HV_PORT_TYPE_MONITOR: hv_port_type = 3;
8984pub const hv_port_type_HV_PORT_TYPE_DOORBELL: hv_port_type = 4;
8985pub type hv_port_type = ::std::os::raw::c_uint;
8986#[repr(C, packed)]
8987#[derive(Copy, Clone)]
8988pub struct hv_port_info {
8989 pub port_type: __u32,
8990 pub padding: __u32,
8991 pub __bindgen_anon_1: hv_port_info__bindgen_ty_1,
8992}
8993#[repr(C)]
8994#[derive(Copy, Clone)]
8995pub union hv_port_info__bindgen_ty_1 {
8996 pub message_port_info: hv_port_info__bindgen_ty_1__bindgen_ty_1,
8997 pub event_port_info: hv_port_info__bindgen_ty_1__bindgen_ty_2,
8998 pub monitor_port_info: hv_port_info__bindgen_ty_1__bindgen_ty_3,
8999 pub doorbell_port_info: hv_port_info__bindgen_ty_1__bindgen_ty_4,
9000}
9001#[repr(C)]
9002#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
9003pub struct hv_port_info__bindgen_ty_1__bindgen_ty_1 {
9004 pub target_sint: __u32,
9005 pub target_vp: __u32,
9006 pub rsvdz: __u64,
9007}
9008#[test]
9009fn bindgen_test_layout_hv_port_info__bindgen_ty_1__bindgen_ty_1() {
9010 const UNINIT: ::std::mem::MaybeUninit<hv_port_info__bindgen_ty_1__bindgen_ty_1> =
9011 ::std::mem::MaybeUninit::uninit();
9012 let ptr = UNINIT.as_ptr();
9013 assert_eq!(
9014 ::std::mem::size_of::<hv_port_info__bindgen_ty_1__bindgen_ty_1>(),
9015 16usize,
9016 concat!(
9017 "Size of: ",
9018 stringify!(hv_port_info__bindgen_ty_1__bindgen_ty_1)
9019 )
9020 );
9021 assert_eq!(
9022 ::std::mem::align_of::<hv_port_info__bindgen_ty_1__bindgen_ty_1>(),
9023 8usize,
9024 concat!(
9025 "Alignment of ",
9026 stringify!(hv_port_info__bindgen_ty_1__bindgen_ty_1)
9027 )
9028 );
9029 assert_eq!(
9030 unsafe { ::std::ptr::addr_of!((*ptr).target_sint) as usize - ptr as usize },
9031 0usize,
9032 concat!(
9033 "Offset of field: ",
9034 stringify!(hv_port_info__bindgen_ty_1__bindgen_ty_1),
9035 "::",
9036 stringify!(target_sint)
9037 )
9038 );
9039 assert_eq!(
9040 unsafe { ::std::ptr::addr_of!((*ptr).target_vp) as usize - ptr as usize },
9041 4usize,
9042 concat!(
9043 "Offset of field: ",
9044 stringify!(hv_port_info__bindgen_ty_1__bindgen_ty_1),
9045 "::",
9046 stringify!(target_vp)
9047 )
9048 );
9049 assert_eq!(
9050 unsafe { ::std::ptr::addr_of!((*ptr).rsvdz) as usize - ptr as usize },
9051 8usize,
9052 concat!(
9053 "Offset of field: ",
9054 stringify!(hv_port_info__bindgen_ty_1__bindgen_ty_1),
9055 "::",
9056 stringify!(rsvdz)
9057 )
9058 );
9059}
9060#[repr(C)]
9061#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
9062pub struct hv_port_info__bindgen_ty_1__bindgen_ty_2 {
9063 pub target_sint: __u32,
9064 pub target_vp: __u32,
9065 pub base_flag_number: __u16,
9066 pub flag_count: __u16,
9067 pub rsvdz: __u32,
9068}
9069#[test]
9070fn bindgen_test_layout_hv_port_info__bindgen_ty_1__bindgen_ty_2() {
9071 const UNINIT: ::std::mem::MaybeUninit<hv_port_info__bindgen_ty_1__bindgen_ty_2> =
9072 ::std::mem::MaybeUninit::uninit();
9073 let ptr = UNINIT.as_ptr();
9074 assert_eq!(
9075 ::std::mem::size_of::<hv_port_info__bindgen_ty_1__bindgen_ty_2>(),
9076 16usize,
9077 concat!(
9078 "Size of: ",
9079 stringify!(hv_port_info__bindgen_ty_1__bindgen_ty_2)
9080 )
9081 );
9082 assert_eq!(
9083 ::std::mem::align_of::<hv_port_info__bindgen_ty_1__bindgen_ty_2>(),
9084 4usize,
9085 concat!(
9086 "Alignment of ",
9087 stringify!(hv_port_info__bindgen_ty_1__bindgen_ty_2)
9088 )
9089 );
9090 assert_eq!(
9091 unsafe { ::std::ptr::addr_of!((*ptr).target_sint) as usize - ptr as usize },
9092 0usize,
9093 concat!(
9094 "Offset of field: ",
9095 stringify!(hv_port_info__bindgen_ty_1__bindgen_ty_2),
9096 "::",
9097 stringify!(target_sint)
9098 )
9099 );
9100 assert_eq!(
9101 unsafe { ::std::ptr::addr_of!((*ptr).target_vp) as usize - ptr as usize },
9102 4usize,
9103 concat!(
9104 "Offset of field: ",
9105 stringify!(hv_port_info__bindgen_ty_1__bindgen_ty_2),
9106 "::",
9107 stringify!(target_vp)
9108 )
9109 );
9110 assert_eq!(
9111 unsafe { ::std::ptr::addr_of!((*ptr).base_flag_number) as usize - ptr as usize },
9112 8usize,
9113 concat!(
9114 "Offset of field: ",
9115 stringify!(hv_port_info__bindgen_ty_1__bindgen_ty_2),
9116 "::",
9117 stringify!(base_flag_number)
9118 )
9119 );
9120 assert_eq!(
9121 unsafe { ::std::ptr::addr_of!((*ptr).flag_count) as usize - ptr as usize },
9122 10usize,
9123 concat!(
9124 "Offset of field: ",
9125 stringify!(hv_port_info__bindgen_ty_1__bindgen_ty_2),
9126 "::",
9127 stringify!(flag_count)
9128 )
9129 );
9130 assert_eq!(
9131 unsafe { ::std::ptr::addr_of!((*ptr).rsvdz) as usize - ptr as usize },
9132 12usize,
9133 concat!(
9134 "Offset of field: ",
9135 stringify!(hv_port_info__bindgen_ty_1__bindgen_ty_2),
9136 "::",
9137 stringify!(rsvdz)
9138 )
9139 );
9140}
9141#[repr(C)]
9142#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
9143pub struct hv_port_info__bindgen_ty_1__bindgen_ty_3 {
9144 pub monitor_address: __u64,
9145 pub rsvdz: __u64,
9146}
9147#[test]
9148fn bindgen_test_layout_hv_port_info__bindgen_ty_1__bindgen_ty_3() {
9149 const UNINIT: ::std::mem::MaybeUninit<hv_port_info__bindgen_ty_1__bindgen_ty_3> =
9150 ::std::mem::MaybeUninit::uninit();
9151 let ptr = UNINIT.as_ptr();
9152 assert_eq!(
9153 ::std::mem::size_of::<hv_port_info__bindgen_ty_1__bindgen_ty_3>(),
9154 16usize,
9155 concat!(
9156 "Size of: ",
9157 stringify!(hv_port_info__bindgen_ty_1__bindgen_ty_3)
9158 )
9159 );
9160 assert_eq!(
9161 ::std::mem::align_of::<hv_port_info__bindgen_ty_1__bindgen_ty_3>(),
9162 8usize,
9163 concat!(
9164 "Alignment of ",
9165 stringify!(hv_port_info__bindgen_ty_1__bindgen_ty_3)
9166 )
9167 );
9168 assert_eq!(
9169 unsafe { ::std::ptr::addr_of!((*ptr).monitor_address) as usize - ptr as usize },
9170 0usize,
9171 concat!(
9172 "Offset of field: ",
9173 stringify!(hv_port_info__bindgen_ty_1__bindgen_ty_3),
9174 "::",
9175 stringify!(monitor_address)
9176 )
9177 );
9178 assert_eq!(
9179 unsafe { ::std::ptr::addr_of!((*ptr).rsvdz) as usize - ptr as usize },
9180 8usize,
9181 concat!(
9182 "Offset of field: ",
9183 stringify!(hv_port_info__bindgen_ty_1__bindgen_ty_3),
9184 "::",
9185 stringify!(rsvdz)
9186 )
9187 );
9188}
9189#[repr(C)]
9190#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
9191pub struct hv_port_info__bindgen_ty_1__bindgen_ty_4 {
9192 pub target_sint: __u32,
9193 pub target_vp: __u32,
9194 pub rsvdz: __u64,
9195}
9196#[test]
9197fn bindgen_test_layout_hv_port_info__bindgen_ty_1__bindgen_ty_4() {
9198 const UNINIT: ::std::mem::MaybeUninit<hv_port_info__bindgen_ty_1__bindgen_ty_4> =
9199 ::std::mem::MaybeUninit::uninit();
9200 let ptr = UNINIT.as_ptr();
9201 assert_eq!(
9202 ::std::mem::size_of::<hv_port_info__bindgen_ty_1__bindgen_ty_4>(),
9203 16usize,
9204 concat!(
9205 "Size of: ",
9206 stringify!(hv_port_info__bindgen_ty_1__bindgen_ty_4)
9207 )
9208 );
9209 assert_eq!(
9210 ::std::mem::align_of::<hv_port_info__bindgen_ty_1__bindgen_ty_4>(),
9211 8usize,
9212 concat!(
9213 "Alignment of ",
9214 stringify!(hv_port_info__bindgen_ty_1__bindgen_ty_4)
9215 )
9216 );
9217 assert_eq!(
9218 unsafe { ::std::ptr::addr_of!((*ptr).target_sint) as usize - ptr as usize },
9219 0usize,
9220 concat!(
9221 "Offset of field: ",
9222 stringify!(hv_port_info__bindgen_ty_1__bindgen_ty_4),
9223 "::",
9224 stringify!(target_sint)
9225 )
9226 );
9227 assert_eq!(
9228 unsafe { ::std::ptr::addr_of!((*ptr).target_vp) as usize - ptr as usize },
9229 4usize,
9230 concat!(
9231 "Offset of field: ",
9232 stringify!(hv_port_info__bindgen_ty_1__bindgen_ty_4),
9233 "::",
9234 stringify!(target_vp)
9235 )
9236 );
9237 assert_eq!(
9238 unsafe { ::std::ptr::addr_of!((*ptr).rsvdz) as usize - ptr as usize },
9239 8usize,
9240 concat!(
9241 "Offset of field: ",
9242 stringify!(hv_port_info__bindgen_ty_1__bindgen_ty_4),
9243 "::",
9244 stringify!(rsvdz)
9245 )
9246 );
9247}
9248#[test]
9249fn bindgen_test_layout_hv_port_info__bindgen_ty_1() {
9250 const UNINIT: ::std::mem::MaybeUninit<hv_port_info__bindgen_ty_1> =
9251 ::std::mem::MaybeUninit::uninit();
9252 let ptr = UNINIT.as_ptr();
9253 assert_eq!(
9254 ::std::mem::size_of::<hv_port_info__bindgen_ty_1>(),
9255 16usize,
9256 concat!("Size of: ", stringify!(hv_port_info__bindgen_ty_1))
9257 );
9258 assert_eq!(
9259 ::std::mem::align_of::<hv_port_info__bindgen_ty_1>(),
9260 8usize,
9261 concat!("Alignment of ", stringify!(hv_port_info__bindgen_ty_1))
9262 );
9263 assert_eq!(
9264 unsafe { ::std::ptr::addr_of!((*ptr).message_port_info) as usize - ptr as usize },
9265 0usize,
9266 concat!(
9267 "Offset of field: ",
9268 stringify!(hv_port_info__bindgen_ty_1),
9269 "::",
9270 stringify!(message_port_info)
9271 )
9272 );
9273 assert_eq!(
9274 unsafe { ::std::ptr::addr_of!((*ptr).event_port_info) as usize - ptr as usize },
9275 0usize,
9276 concat!(
9277 "Offset of field: ",
9278 stringify!(hv_port_info__bindgen_ty_1),
9279 "::",
9280 stringify!(event_port_info)
9281 )
9282 );
9283 assert_eq!(
9284 unsafe { ::std::ptr::addr_of!((*ptr).monitor_port_info) as usize - ptr as usize },
9285 0usize,
9286 concat!(
9287 "Offset of field: ",
9288 stringify!(hv_port_info__bindgen_ty_1),
9289 "::",
9290 stringify!(monitor_port_info)
9291 )
9292 );
9293 assert_eq!(
9294 unsafe { ::std::ptr::addr_of!((*ptr).doorbell_port_info) as usize - ptr as usize },
9295 0usize,
9296 concat!(
9297 "Offset of field: ",
9298 stringify!(hv_port_info__bindgen_ty_1),
9299 "::",
9300 stringify!(doorbell_port_info)
9301 )
9302 );
9303}
9304impl Default for hv_port_info__bindgen_ty_1 {
9305 fn default() -> Self {
9306 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
9307 unsafe {
9308 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
9309 s.assume_init()
9310 }
9311 }
9312}
9313#[test]
9314fn bindgen_test_layout_hv_port_info() {
9315 const UNINIT: ::std::mem::MaybeUninit<hv_port_info> = ::std::mem::MaybeUninit::uninit();
9316 let ptr = UNINIT.as_ptr();
9317 assert_eq!(
9318 ::std::mem::size_of::<hv_port_info>(),
9319 24usize,
9320 concat!("Size of: ", stringify!(hv_port_info))
9321 );
9322 assert_eq!(
9323 ::std::mem::align_of::<hv_port_info>(),
9324 1usize,
9325 concat!("Alignment of ", stringify!(hv_port_info))
9326 );
9327 assert_eq!(
9328 unsafe { ::std::ptr::addr_of!((*ptr).port_type) as usize - ptr as usize },
9329 0usize,
9330 concat!(
9331 "Offset of field: ",
9332 stringify!(hv_port_info),
9333 "::",
9334 stringify!(port_type)
9335 )
9336 );
9337 assert_eq!(
9338 unsafe { ::std::ptr::addr_of!((*ptr).padding) as usize - ptr as usize },
9339 4usize,
9340 concat!(
9341 "Offset of field: ",
9342 stringify!(hv_port_info),
9343 "::",
9344 stringify!(padding)
9345 )
9346 );
9347}
9348impl Default for hv_port_info {
9349 fn default() -> Self {
9350 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
9351 unsafe {
9352 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
9353 s.assume_init()
9354 }
9355 }
9356}
9357#[repr(C)]
9358#[derive(Copy, Clone)]
9359pub union hv_interrupt_control {
9360 pub as_uint64: __u64,
9361 pub __bindgen_anon_1: hv_interrupt_control__bindgen_ty_1,
9362}
9363#[repr(C, packed)]
9364#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
9365pub struct hv_interrupt_control__bindgen_ty_1 {
9366 pub interrupt_type: __u32,
9367 pub _bitfield_align_1: [u8; 0],
9368 pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize]>,
9369}
9370#[test]
9371fn bindgen_test_layout_hv_interrupt_control__bindgen_ty_1() {
9372 const UNINIT: ::std::mem::MaybeUninit<hv_interrupt_control__bindgen_ty_1> =
9373 ::std::mem::MaybeUninit::uninit();
9374 let ptr = UNINIT.as_ptr();
9375 assert_eq!(
9376 ::std::mem::size_of::<hv_interrupt_control__bindgen_ty_1>(),
9377 8usize,
9378 concat!("Size of: ", stringify!(hv_interrupt_control__bindgen_ty_1))
9379 );
9380 assert_eq!(
9381 ::std::mem::align_of::<hv_interrupt_control__bindgen_ty_1>(),
9382 1usize,
9383 concat!(
9384 "Alignment of ",
9385 stringify!(hv_interrupt_control__bindgen_ty_1)
9386 )
9387 );
9388 assert_eq!(
9389 unsafe { ::std::ptr::addr_of!((*ptr).interrupt_type) as usize - ptr as usize },
9390 0usize,
9391 concat!(
9392 "Offset of field: ",
9393 stringify!(hv_interrupt_control__bindgen_ty_1),
9394 "::",
9395 stringify!(interrupt_type)
9396 )
9397 );
9398}
9399impl hv_interrupt_control__bindgen_ty_1 {
9400 #[inline]
9401 pub fn level_triggered(&self) -> __u32 {
9402 unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 1u8) as u32) }
9403 }
9404 #[inline]
9405 pub fn set_level_triggered(&mut self, val: __u32) {
9406 unsafe {
9407 let val: u32 = ::std::mem::transmute(val);
9408 self._bitfield_1.set(0usize, 1u8, val as u64)
9409 }
9410 }
9411 #[inline]
9412 pub fn logical_dest_mode(&self) -> __u32 {
9413 unsafe { ::std::mem::transmute(self._bitfield_1.get(1usize, 1u8) as u32) }
9414 }
9415 #[inline]
9416 pub fn set_logical_dest_mode(&mut self, val: __u32) {
9417 unsafe {
9418 let val: u32 = ::std::mem::transmute(val);
9419 self._bitfield_1.set(1usize, 1u8, val as u64)
9420 }
9421 }
9422 #[inline]
9423 pub fn rsvd(&self) -> __u32 {
9424 unsafe { ::std::mem::transmute(self._bitfield_1.get(2usize, 30u8) as u32) }
9425 }
9426 #[inline]
9427 pub fn set_rsvd(&mut self, val: __u32) {
9428 unsafe {
9429 let val: u32 = ::std::mem::transmute(val);
9430 self._bitfield_1.set(2usize, 30u8, val as u64)
9431 }
9432 }
9433 #[inline]
9434 pub fn new_bitfield_1(
9435 level_triggered: __u32,
9436 logical_dest_mode: __u32,
9437 rsvd: __u32,
9438 ) -> __BindgenBitfieldUnit<[u8; 4usize]> {
9439 let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 4usize]> = Default::default();
9440 __bindgen_bitfield_unit.set(0usize, 1u8, {
9441 let level_triggered: u32 = unsafe { ::std::mem::transmute(level_triggered) };
9442 level_triggered as u64
9443 });
9444 __bindgen_bitfield_unit.set(1usize, 1u8, {
9445 let logical_dest_mode: u32 = unsafe { ::std::mem::transmute(logical_dest_mode) };
9446 logical_dest_mode as u64
9447 });
9448 __bindgen_bitfield_unit.set(2usize, 30u8, {
9449 let rsvd: u32 = unsafe { ::std::mem::transmute(rsvd) };
9450 rsvd as u64
9451 });
9452 __bindgen_bitfield_unit
9453 }
9454}
9455#[test]
9456fn bindgen_test_layout_hv_interrupt_control() {
9457 const UNINIT: ::std::mem::MaybeUninit<hv_interrupt_control> = ::std::mem::MaybeUninit::uninit();
9458 let ptr = UNINIT.as_ptr();
9459 assert_eq!(
9460 ::std::mem::size_of::<hv_interrupt_control>(),
9461 8usize,
9462 concat!("Size of: ", stringify!(hv_interrupt_control))
9463 );
9464 assert_eq!(
9465 ::std::mem::align_of::<hv_interrupt_control>(),
9466 8usize,
9467 concat!("Alignment of ", stringify!(hv_interrupt_control))
9468 );
9469 assert_eq!(
9470 unsafe { ::std::ptr::addr_of!((*ptr).as_uint64) as usize - ptr as usize },
9471 0usize,
9472 concat!(
9473 "Offset of field: ",
9474 stringify!(hv_interrupt_control),
9475 "::",
9476 stringify!(as_uint64)
9477 )
9478 );
9479}
9480impl Default for hv_interrupt_control {
9481 fn default() -> Self {
9482 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
9483 unsafe {
9484 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
9485 s.assume_init()
9486 }
9487 }
9488}
9489#[repr(C, packed)]
9490#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
9491pub struct hv_local_interrupt_controller_state {
9492 pub apic_id: __u32,
9493 pub apic_version: __u32,
9494 pub apic_ldr: __u32,
9495 pub apic_dfr: __u32,
9496 pub apic_spurious: __u32,
9497 pub apic_isr: [__u32; 8usize],
9498 pub apic_tmr: [__u32; 8usize],
9499 pub apic_irr: [__u32; 8usize],
9500 pub apic_esr: __u32,
9501 pub apic_icr_high: __u32,
9502 pub apic_icr_low: __u32,
9503 pub apic_lvt_timer: __u32,
9504 pub apic_lvt_thermal: __u32,
9505 pub apic_lvt_perfmon: __u32,
9506 pub apic_lvt_lint0: __u32,
9507 pub apic_lvt_lint1: __u32,
9508 pub apic_lvt_error: __u32,
9509 pub apic_lvt_cmci: __u32,
9510 pub apic_error_status: __u32,
9511 pub apic_initial_count: __u32,
9512 pub apic_counter_value: __u32,
9513 pub apic_divide_configuration: __u32,
9514 pub apic_remote_read: __u32,
9515}
9516#[test]
9517fn bindgen_test_layout_hv_local_interrupt_controller_state() {
9518 const UNINIT: ::std::mem::MaybeUninit<hv_local_interrupt_controller_state> =
9519 ::std::mem::MaybeUninit::uninit();
9520 let ptr = UNINIT.as_ptr();
9521 assert_eq!(
9522 ::std::mem::size_of::<hv_local_interrupt_controller_state>(),
9523 176usize,
9524 concat!("Size of: ", stringify!(hv_local_interrupt_controller_state))
9525 );
9526 assert_eq!(
9527 ::std::mem::align_of::<hv_local_interrupt_controller_state>(),
9528 1usize,
9529 concat!(
9530 "Alignment of ",
9531 stringify!(hv_local_interrupt_controller_state)
9532 )
9533 );
9534 assert_eq!(
9535 unsafe { ::std::ptr::addr_of!((*ptr).apic_id) as usize - ptr as usize },
9536 0usize,
9537 concat!(
9538 "Offset of field: ",
9539 stringify!(hv_local_interrupt_controller_state),
9540 "::",
9541 stringify!(apic_id)
9542 )
9543 );
9544 assert_eq!(
9545 unsafe { ::std::ptr::addr_of!((*ptr).apic_version) as usize - ptr as usize },
9546 4usize,
9547 concat!(
9548 "Offset of field: ",
9549 stringify!(hv_local_interrupt_controller_state),
9550 "::",
9551 stringify!(apic_version)
9552 )
9553 );
9554 assert_eq!(
9555 unsafe { ::std::ptr::addr_of!((*ptr).apic_ldr) as usize - ptr as usize },
9556 8usize,
9557 concat!(
9558 "Offset of field: ",
9559 stringify!(hv_local_interrupt_controller_state),
9560 "::",
9561 stringify!(apic_ldr)
9562 )
9563 );
9564 assert_eq!(
9565 unsafe { ::std::ptr::addr_of!((*ptr).apic_dfr) as usize - ptr as usize },
9566 12usize,
9567 concat!(
9568 "Offset of field: ",
9569 stringify!(hv_local_interrupt_controller_state),
9570 "::",
9571 stringify!(apic_dfr)
9572 )
9573 );
9574 assert_eq!(
9575 unsafe { ::std::ptr::addr_of!((*ptr).apic_spurious) as usize - ptr as usize },
9576 16usize,
9577 concat!(
9578 "Offset of field: ",
9579 stringify!(hv_local_interrupt_controller_state),
9580 "::",
9581 stringify!(apic_spurious)
9582 )
9583 );
9584 assert_eq!(
9585 unsafe { ::std::ptr::addr_of!((*ptr).apic_isr) as usize - ptr as usize },
9586 20usize,
9587 concat!(
9588 "Offset of field: ",
9589 stringify!(hv_local_interrupt_controller_state),
9590 "::",
9591 stringify!(apic_isr)
9592 )
9593 );
9594 assert_eq!(
9595 unsafe { ::std::ptr::addr_of!((*ptr).apic_tmr) as usize - ptr as usize },
9596 52usize,
9597 concat!(
9598 "Offset of field: ",
9599 stringify!(hv_local_interrupt_controller_state),
9600 "::",
9601 stringify!(apic_tmr)
9602 )
9603 );
9604 assert_eq!(
9605 unsafe { ::std::ptr::addr_of!((*ptr).apic_irr) as usize - ptr as usize },
9606 84usize,
9607 concat!(
9608 "Offset of field: ",
9609 stringify!(hv_local_interrupt_controller_state),
9610 "::",
9611 stringify!(apic_irr)
9612 )
9613 );
9614 assert_eq!(
9615 unsafe { ::std::ptr::addr_of!((*ptr).apic_esr) as usize - ptr as usize },
9616 116usize,
9617 concat!(
9618 "Offset of field: ",
9619 stringify!(hv_local_interrupt_controller_state),
9620 "::",
9621 stringify!(apic_esr)
9622 )
9623 );
9624 assert_eq!(
9625 unsafe { ::std::ptr::addr_of!((*ptr).apic_icr_high) as usize - ptr as usize },
9626 120usize,
9627 concat!(
9628 "Offset of field: ",
9629 stringify!(hv_local_interrupt_controller_state),
9630 "::",
9631 stringify!(apic_icr_high)
9632 )
9633 );
9634 assert_eq!(
9635 unsafe { ::std::ptr::addr_of!((*ptr).apic_icr_low) as usize - ptr as usize },
9636 124usize,
9637 concat!(
9638 "Offset of field: ",
9639 stringify!(hv_local_interrupt_controller_state),
9640 "::",
9641 stringify!(apic_icr_low)
9642 )
9643 );
9644 assert_eq!(
9645 unsafe { ::std::ptr::addr_of!((*ptr).apic_lvt_timer) as usize - ptr as usize },
9646 128usize,
9647 concat!(
9648 "Offset of field: ",
9649 stringify!(hv_local_interrupt_controller_state),
9650 "::",
9651 stringify!(apic_lvt_timer)
9652 )
9653 );
9654 assert_eq!(
9655 unsafe { ::std::ptr::addr_of!((*ptr).apic_lvt_thermal) as usize - ptr as usize },
9656 132usize,
9657 concat!(
9658 "Offset of field: ",
9659 stringify!(hv_local_interrupt_controller_state),
9660 "::",
9661 stringify!(apic_lvt_thermal)
9662 )
9663 );
9664 assert_eq!(
9665 unsafe { ::std::ptr::addr_of!((*ptr).apic_lvt_perfmon) as usize - ptr as usize },
9666 136usize,
9667 concat!(
9668 "Offset of field: ",
9669 stringify!(hv_local_interrupt_controller_state),
9670 "::",
9671 stringify!(apic_lvt_perfmon)
9672 )
9673 );
9674 assert_eq!(
9675 unsafe { ::std::ptr::addr_of!((*ptr).apic_lvt_lint0) as usize - ptr as usize },
9676 140usize,
9677 concat!(
9678 "Offset of field: ",
9679 stringify!(hv_local_interrupt_controller_state),
9680 "::",
9681 stringify!(apic_lvt_lint0)
9682 )
9683 );
9684 assert_eq!(
9685 unsafe { ::std::ptr::addr_of!((*ptr).apic_lvt_lint1) as usize - ptr as usize },
9686 144usize,
9687 concat!(
9688 "Offset of field: ",
9689 stringify!(hv_local_interrupt_controller_state),
9690 "::",
9691 stringify!(apic_lvt_lint1)
9692 )
9693 );
9694 assert_eq!(
9695 unsafe { ::std::ptr::addr_of!((*ptr).apic_lvt_error) as usize - ptr as usize },
9696 148usize,
9697 concat!(
9698 "Offset of field: ",
9699 stringify!(hv_local_interrupt_controller_state),
9700 "::",
9701 stringify!(apic_lvt_error)
9702 )
9703 );
9704 assert_eq!(
9705 unsafe { ::std::ptr::addr_of!((*ptr).apic_lvt_cmci) as usize - ptr as usize },
9706 152usize,
9707 concat!(
9708 "Offset of field: ",
9709 stringify!(hv_local_interrupt_controller_state),
9710 "::",
9711 stringify!(apic_lvt_cmci)
9712 )
9713 );
9714 assert_eq!(
9715 unsafe { ::std::ptr::addr_of!((*ptr).apic_error_status) as usize - ptr as usize },
9716 156usize,
9717 concat!(
9718 "Offset of field: ",
9719 stringify!(hv_local_interrupt_controller_state),
9720 "::",
9721 stringify!(apic_error_status)
9722 )
9723 );
9724 assert_eq!(
9725 unsafe { ::std::ptr::addr_of!((*ptr).apic_initial_count) as usize - ptr as usize },
9726 160usize,
9727 concat!(
9728 "Offset of field: ",
9729 stringify!(hv_local_interrupt_controller_state),
9730 "::",
9731 stringify!(apic_initial_count)
9732 )
9733 );
9734 assert_eq!(
9735 unsafe { ::std::ptr::addr_of!((*ptr).apic_counter_value) as usize - ptr as usize },
9736 164usize,
9737 concat!(
9738 "Offset of field: ",
9739 stringify!(hv_local_interrupt_controller_state),
9740 "::",
9741 stringify!(apic_counter_value)
9742 )
9743 );
9744 assert_eq!(
9745 unsafe { ::std::ptr::addr_of!((*ptr).apic_divide_configuration) as usize - ptr as usize },
9746 168usize,
9747 concat!(
9748 "Offset of field: ",
9749 stringify!(hv_local_interrupt_controller_state),
9750 "::",
9751 stringify!(apic_divide_configuration)
9752 )
9753 );
9754 assert_eq!(
9755 unsafe { ::std::ptr::addr_of!((*ptr).apic_remote_read) as usize - ptr as usize },
9756 172usize,
9757 concat!(
9758 "Offset of field: ",
9759 stringify!(hv_local_interrupt_controller_state),
9760 "::",
9761 stringify!(apic_remote_read)
9762 )
9763 );
9764}
9765#[repr(C, packed)]
9766#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
9767pub struct hv_stimer_state {
9768 pub flags: hv_stimer_state__bindgen_ty_1,
9769 pub resvd: __u32,
9770 pub config: __u64,
9771 pub count: __u64,
9772 pub adjustment: __u64,
9773 pub undelivered_exp_time: __u64,
9774}
9775#[repr(C, packed)]
9776#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
9777pub struct hv_stimer_state__bindgen_ty_1 {
9778 pub _bitfield_align_1: [u8; 0],
9779 pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize]>,
9780}
9781#[test]
9782fn bindgen_test_layout_hv_stimer_state__bindgen_ty_1() {
9783 assert_eq!(
9784 ::std::mem::size_of::<hv_stimer_state__bindgen_ty_1>(),
9785 4usize,
9786 concat!("Size of: ", stringify!(hv_stimer_state__bindgen_ty_1))
9787 );
9788 assert_eq!(
9789 ::std::mem::align_of::<hv_stimer_state__bindgen_ty_1>(),
9790 1usize,
9791 concat!("Alignment of ", stringify!(hv_stimer_state__bindgen_ty_1))
9792 );
9793}
9794impl hv_stimer_state__bindgen_ty_1 {
9795 #[inline]
9796 pub fn undelivered_msg_pending(&self) -> __u32 {
9797 unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 1u8) as u32) }
9798 }
9799 #[inline]
9800 pub fn set_undelivered_msg_pending(&mut self, val: __u32) {
9801 unsafe {
9802 let val: u32 = ::std::mem::transmute(val);
9803 self._bitfield_1.set(0usize, 1u8, val as u64)
9804 }
9805 }
9806 #[inline]
9807 pub fn reserved(&self) -> __u32 {
9808 unsafe { ::std::mem::transmute(self._bitfield_1.get(1usize, 31u8) as u32) }
9809 }
9810 #[inline]
9811 pub fn set_reserved(&mut self, val: __u32) {
9812 unsafe {
9813 let val: u32 = ::std::mem::transmute(val);
9814 self._bitfield_1.set(1usize, 31u8, val as u64)
9815 }
9816 }
9817 #[inline]
9818 pub fn new_bitfield_1(
9819 undelivered_msg_pending: __u32,
9820 reserved: __u32,
9821 ) -> __BindgenBitfieldUnit<[u8; 4usize]> {
9822 let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 4usize]> = Default::default();
9823 __bindgen_bitfield_unit.set(0usize, 1u8, {
9824 let undelivered_msg_pending: u32 =
9825 unsafe { ::std::mem::transmute(undelivered_msg_pending) };
9826 undelivered_msg_pending as u64
9827 });
9828 __bindgen_bitfield_unit.set(1usize, 31u8, {
9829 let reserved: u32 = unsafe { ::std::mem::transmute(reserved) };
9830 reserved as u64
9831 });
9832 __bindgen_bitfield_unit
9833 }
9834}
9835#[test]
9836fn bindgen_test_layout_hv_stimer_state() {
9837 const UNINIT: ::std::mem::MaybeUninit<hv_stimer_state> = ::std::mem::MaybeUninit::uninit();
9838 let ptr = UNINIT.as_ptr();
9839 assert_eq!(
9840 ::std::mem::size_of::<hv_stimer_state>(),
9841 40usize,
9842 concat!("Size of: ", stringify!(hv_stimer_state))
9843 );
9844 assert_eq!(
9845 ::std::mem::align_of::<hv_stimer_state>(),
9846 1usize,
9847 concat!("Alignment of ", stringify!(hv_stimer_state))
9848 );
9849 assert_eq!(
9850 unsafe { ::std::ptr::addr_of!((*ptr).flags) as usize - ptr as usize },
9851 0usize,
9852 concat!(
9853 "Offset of field: ",
9854 stringify!(hv_stimer_state),
9855 "::",
9856 stringify!(flags)
9857 )
9858 );
9859 assert_eq!(
9860 unsafe { ::std::ptr::addr_of!((*ptr).resvd) as usize - ptr as usize },
9861 4usize,
9862 concat!(
9863 "Offset of field: ",
9864 stringify!(hv_stimer_state),
9865 "::",
9866 stringify!(resvd)
9867 )
9868 );
9869 assert_eq!(
9870 unsafe { ::std::ptr::addr_of!((*ptr).config) as usize - ptr as usize },
9871 8usize,
9872 concat!(
9873 "Offset of field: ",
9874 stringify!(hv_stimer_state),
9875 "::",
9876 stringify!(config)
9877 )
9878 );
9879 assert_eq!(
9880 unsafe { ::std::ptr::addr_of!((*ptr).count) as usize - ptr as usize },
9881 16usize,
9882 concat!(
9883 "Offset of field: ",
9884 stringify!(hv_stimer_state),
9885 "::",
9886 stringify!(count)
9887 )
9888 );
9889 assert_eq!(
9890 unsafe { ::std::ptr::addr_of!((*ptr).adjustment) as usize - ptr as usize },
9891 24usize,
9892 concat!(
9893 "Offset of field: ",
9894 stringify!(hv_stimer_state),
9895 "::",
9896 stringify!(adjustment)
9897 )
9898 );
9899 assert_eq!(
9900 unsafe { ::std::ptr::addr_of!((*ptr).undelivered_exp_time) as usize - ptr as usize },
9901 32usize,
9902 concat!(
9903 "Offset of field: ",
9904 stringify!(hv_stimer_state),
9905 "::",
9906 stringify!(undelivered_exp_time)
9907 )
9908 );
9909}
9910#[repr(C, packed)]
9911#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
9912pub struct hv_synthetic_timers_state {
9913 pub timers: [hv_stimer_state; 4usize],
9914 pub reserved: [__u64; 5usize],
9915}
9916#[test]
9917fn bindgen_test_layout_hv_synthetic_timers_state() {
9918 const UNINIT: ::std::mem::MaybeUninit<hv_synthetic_timers_state> =
9919 ::std::mem::MaybeUninit::uninit();
9920 let ptr = UNINIT.as_ptr();
9921 assert_eq!(
9922 ::std::mem::size_of::<hv_synthetic_timers_state>(),
9923 200usize,
9924 concat!("Size of: ", stringify!(hv_synthetic_timers_state))
9925 );
9926 assert_eq!(
9927 ::std::mem::align_of::<hv_synthetic_timers_state>(),
9928 1usize,
9929 concat!("Alignment of ", stringify!(hv_synthetic_timers_state))
9930 );
9931 assert_eq!(
9932 unsafe { ::std::ptr::addr_of!((*ptr).timers) as usize - ptr as usize },
9933 0usize,
9934 concat!(
9935 "Offset of field: ",
9936 stringify!(hv_synthetic_timers_state),
9937 "::",
9938 stringify!(timers)
9939 )
9940 );
9941 assert_eq!(
9942 unsafe { ::std::ptr::addr_of!((*ptr).reserved) as usize - ptr as usize },
9943 160usize,
9944 concat!(
9945 "Offset of field: ",
9946 stringify!(hv_synthetic_timers_state),
9947 "::",
9948 stringify!(reserved)
9949 )
9950 );
9951}
9952#[repr(C)]
9953#[derive(Copy, Clone)]
9954pub union hv_x64_vp_execution_state {
9955 pub as_uint16: __u16,
9956 pub __bindgen_anon_1: hv_x64_vp_execution_state__bindgen_ty_1,
9957}
9958#[repr(C, packed)]
9959#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
9960pub struct hv_x64_vp_execution_state__bindgen_ty_1 {
9961 pub _bitfield_align_1: [u8; 0],
9962 pub _bitfield_1: __BindgenBitfieldUnit<[u8; 2usize]>,
9963}
9964#[test]
9965fn bindgen_test_layout_hv_x64_vp_execution_state__bindgen_ty_1() {
9966 assert_eq!(
9967 ::std::mem::size_of::<hv_x64_vp_execution_state__bindgen_ty_1>(),
9968 2usize,
9969 concat!(
9970 "Size of: ",
9971 stringify!(hv_x64_vp_execution_state__bindgen_ty_1)
9972 )
9973 );
9974 assert_eq!(
9975 ::std::mem::align_of::<hv_x64_vp_execution_state__bindgen_ty_1>(),
9976 1usize,
9977 concat!(
9978 "Alignment of ",
9979 stringify!(hv_x64_vp_execution_state__bindgen_ty_1)
9980 )
9981 );
9982}
9983impl hv_x64_vp_execution_state__bindgen_ty_1 {
9984 #[inline]
9985 pub fn cpl(&self) -> __u16 {
9986 unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 2u8) as u16) }
9987 }
9988 #[inline]
9989 pub fn set_cpl(&mut self, val: __u16) {
9990 unsafe {
9991 let val: u16 = ::std::mem::transmute(val);
9992 self._bitfield_1.set(0usize, 2u8, val as u64)
9993 }
9994 }
9995 #[inline]
9996 pub fn cr0_pe(&self) -> __u16 {
9997 unsafe { ::std::mem::transmute(self._bitfield_1.get(2usize, 1u8) as u16) }
9998 }
9999 #[inline]
10000 pub fn set_cr0_pe(&mut self, val: __u16) {
10001 unsafe {
10002 let val: u16 = ::std::mem::transmute(val);
10003 self._bitfield_1.set(2usize, 1u8, val as u64)
10004 }
10005 }
10006 #[inline]
10007 pub fn cr0_am(&self) -> __u16 {
10008 unsafe { ::std::mem::transmute(self._bitfield_1.get(3usize, 1u8) as u16) }
10009 }
10010 #[inline]
10011 pub fn set_cr0_am(&mut self, val: __u16) {
10012 unsafe {
10013 let val: u16 = ::std::mem::transmute(val);
10014 self._bitfield_1.set(3usize, 1u8, val as u64)
10015 }
10016 }
10017 #[inline]
10018 pub fn efer_lma(&self) -> __u16 {
10019 unsafe { ::std::mem::transmute(self._bitfield_1.get(4usize, 1u8) as u16) }
10020 }
10021 #[inline]
10022 pub fn set_efer_lma(&mut self, val: __u16) {
10023 unsafe {
10024 let val: u16 = ::std::mem::transmute(val);
10025 self._bitfield_1.set(4usize, 1u8, val as u64)
10026 }
10027 }
10028 #[inline]
10029 pub fn debug_active(&self) -> __u16 {
10030 unsafe { ::std::mem::transmute(self._bitfield_1.get(5usize, 1u8) as u16) }
10031 }
10032 #[inline]
10033 pub fn set_debug_active(&mut self, val: __u16) {
10034 unsafe {
10035 let val: u16 = ::std::mem::transmute(val);
10036 self._bitfield_1.set(5usize, 1u8, val as u64)
10037 }
10038 }
10039 #[inline]
10040 pub fn interruption_pending(&self) -> __u16 {
10041 unsafe { ::std::mem::transmute(self._bitfield_1.get(6usize, 1u8) as u16) }
10042 }
10043 #[inline]
10044 pub fn set_interruption_pending(&mut self, val: __u16) {
10045 unsafe {
10046 let val: u16 = ::std::mem::transmute(val);
10047 self._bitfield_1.set(6usize, 1u8, val as u64)
10048 }
10049 }
10050 #[inline]
10051 pub fn vtl(&self) -> __u16 {
10052 unsafe { ::std::mem::transmute(self._bitfield_1.get(7usize, 4u8) as u16) }
10053 }
10054 #[inline]
10055 pub fn set_vtl(&mut self, val: __u16) {
10056 unsafe {
10057 let val: u16 = ::std::mem::transmute(val);
10058 self._bitfield_1.set(7usize, 4u8, val as u64)
10059 }
10060 }
10061 #[inline]
10062 pub fn enclave_mode(&self) -> __u16 {
10063 unsafe { ::std::mem::transmute(self._bitfield_1.get(11usize, 1u8) as u16) }
10064 }
10065 #[inline]
10066 pub fn set_enclave_mode(&mut self, val: __u16) {
10067 unsafe {
10068 let val: u16 = ::std::mem::transmute(val);
10069 self._bitfield_1.set(11usize, 1u8, val as u64)
10070 }
10071 }
10072 #[inline]
10073 pub fn interrupt_shadow(&self) -> __u16 {
10074 unsafe { ::std::mem::transmute(self._bitfield_1.get(12usize, 1u8) as u16) }
10075 }
10076 #[inline]
10077 pub fn set_interrupt_shadow(&mut self, val: __u16) {
10078 unsafe {
10079 let val: u16 = ::std::mem::transmute(val);
10080 self._bitfield_1.set(12usize, 1u8, val as u64)
10081 }
10082 }
10083 #[inline]
10084 pub fn virtualization_fault_active(&self) -> __u16 {
10085 unsafe { ::std::mem::transmute(self._bitfield_1.get(13usize, 1u8) as u16) }
10086 }
10087 #[inline]
10088 pub fn set_virtualization_fault_active(&mut self, val: __u16) {
10089 unsafe {
10090 let val: u16 = ::std::mem::transmute(val);
10091 self._bitfield_1.set(13usize, 1u8, val as u64)
10092 }
10093 }
10094 #[inline]
10095 pub fn reserved(&self) -> __u16 {
10096 unsafe { ::std::mem::transmute(self._bitfield_1.get(14usize, 2u8) as u16) }
10097 }
10098 #[inline]
10099 pub fn set_reserved(&mut self, val: __u16) {
10100 unsafe {
10101 let val: u16 = ::std::mem::transmute(val);
10102 self._bitfield_1.set(14usize, 2u8, val as u64)
10103 }
10104 }
10105 #[inline]
10106 pub fn new_bitfield_1(
10107 cpl: __u16,
10108 cr0_pe: __u16,
10109 cr0_am: __u16,
10110 efer_lma: __u16,
10111 debug_active: __u16,
10112 interruption_pending: __u16,
10113 vtl: __u16,
10114 enclave_mode: __u16,
10115 interrupt_shadow: __u16,
10116 virtualization_fault_active: __u16,
10117 reserved: __u16,
10118 ) -> __BindgenBitfieldUnit<[u8; 2usize]> {
10119 let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 2usize]> = Default::default();
10120 __bindgen_bitfield_unit.set(0usize, 2u8, {
10121 let cpl: u16 = unsafe { ::std::mem::transmute(cpl) };
10122 cpl as u64
10123 });
10124 __bindgen_bitfield_unit.set(2usize, 1u8, {
10125 let cr0_pe: u16 = unsafe { ::std::mem::transmute(cr0_pe) };
10126 cr0_pe as u64
10127 });
10128 __bindgen_bitfield_unit.set(3usize, 1u8, {
10129 let cr0_am: u16 = unsafe { ::std::mem::transmute(cr0_am) };
10130 cr0_am as u64
10131 });
10132 __bindgen_bitfield_unit.set(4usize, 1u8, {
10133 let efer_lma: u16 = unsafe { ::std::mem::transmute(efer_lma) };
10134 efer_lma as u64
10135 });
10136 __bindgen_bitfield_unit.set(5usize, 1u8, {
10137 let debug_active: u16 = unsafe { ::std::mem::transmute(debug_active) };
10138 debug_active as u64
10139 });
10140 __bindgen_bitfield_unit.set(6usize, 1u8, {
10141 let interruption_pending: u16 = unsafe { ::std::mem::transmute(interruption_pending) };
10142 interruption_pending as u64
10143 });
10144 __bindgen_bitfield_unit.set(7usize, 4u8, {
10145 let vtl: u16 = unsafe { ::std::mem::transmute(vtl) };
10146 vtl as u64
10147 });
10148 __bindgen_bitfield_unit.set(11usize, 1u8, {
10149 let enclave_mode: u16 = unsafe { ::std::mem::transmute(enclave_mode) };
10150 enclave_mode as u64
10151 });
10152 __bindgen_bitfield_unit.set(12usize, 1u8, {
10153 let interrupt_shadow: u16 = unsafe { ::std::mem::transmute(interrupt_shadow) };
10154 interrupt_shadow as u64
10155 });
10156 __bindgen_bitfield_unit.set(13usize, 1u8, {
10157 let virtualization_fault_active: u16 =
10158 unsafe { ::std::mem::transmute(virtualization_fault_active) };
10159 virtualization_fault_active as u64
10160 });
10161 __bindgen_bitfield_unit.set(14usize, 2u8, {
10162 let reserved: u16 = unsafe { ::std::mem::transmute(reserved) };
10163 reserved as u64
10164 });
10165 __bindgen_bitfield_unit
10166 }
10167}
10168#[test]
10169fn bindgen_test_layout_hv_x64_vp_execution_state() {
10170 const UNINIT: ::std::mem::MaybeUninit<hv_x64_vp_execution_state> =
10171 ::std::mem::MaybeUninit::uninit();
10172 let ptr = UNINIT.as_ptr();
10173 assert_eq!(
10174 ::std::mem::size_of::<hv_x64_vp_execution_state>(),
10175 2usize,
10176 concat!("Size of: ", stringify!(hv_x64_vp_execution_state))
10177 );
10178 assert_eq!(
10179 ::std::mem::align_of::<hv_x64_vp_execution_state>(),
10180 2usize,
10181 concat!("Alignment of ", stringify!(hv_x64_vp_execution_state))
10182 );
10183 assert_eq!(
10184 unsafe { ::std::ptr::addr_of!((*ptr).as_uint16) as usize - ptr as usize },
10185 0usize,
10186 concat!(
10187 "Offset of field: ",
10188 stringify!(hv_x64_vp_execution_state),
10189 "::",
10190 stringify!(as_uint16)
10191 )
10192 );
10193}
10194impl Default for hv_x64_vp_execution_state {
10195 fn default() -> Self {
10196 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
10197 unsafe {
10198 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
10199 s.assume_init()
10200 }
10201 }
10202}
10203#[repr(C, packed)]
10204#[derive(Copy, Clone)]
10205pub struct hv_x64_intercept_message_header {
10206 pub vp_index: __u32,
10207 pub _bitfield_align_1: [u8; 0],
10208 pub _bitfield_1: __BindgenBitfieldUnit<[u8; 1usize]>,
10209 pub intercept_access_type: __u8,
10210 pub execution_state: hv_x64_vp_execution_state,
10211 pub cs_segment: hv_x64_segment_register,
10212 pub rip: __u64,
10213 pub rflags: __u64,
10214}
10215#[test]
10216fn bindgen_test_layout_hv_x64_intercept_message_header() {
10217 const UNINIT: ::std::mem::MaybeUninit<hv_x64_intercept_message_header> =
10218 ::std::mem::MaybeUninit::uninit();
10219 let ptr = UNINIT.as_ptr();
10220 assert_eq!(
10221 ::std::mem::size_of::<hv_x64_intercept_message_header>(),
10222 40usize,
10223 concat!("Size of: ", stringify!(hv_x64_intercept_message_header))
10224 );
10225 assert_eq!(
10226 ::std::mem::align_of::<hv_x64_intercept_message_header>(),
10227 1usize,
10228 concat!("Alignment of ", stringify!(hv_x64_intercept_message_header))
10229 );
10230 assert_eq!(
10231 unsafe { ::std::ptr::addr_of!((*ptr).vp_index) as usize - ptr as usize },
10232 0usize,
10233 concat!(
10234 "Offset of field: ",
10235 stringify!(hv_x64_intercept_message_header),
10236 "::",
10237 stringify!(vp_index)
10238 )
10239 );
10240 assert_eq!(
10241 unsafe { ::std::ptr::addr_of!((*ptr).intercept_access_type) as usize - ptr as usize },
10242 5usize,
10243 concat!(
10244 "Offset of field: ",
10245 stringify!(hv_x64_intercept_message_header),
10246 "::",
10247 stringify!(intercept_access_type)
10248 )
10249 );
10250 assert_eq!(
10251 unsafe { ::std::ptr::addr_of!((*ptr).execution_state) as usize - ptr as usize },
10252 6usize,
10253 concat!(
10254 "Offset of field: ",
10255 stringify!(hv_x64_intercept_message_header),
10256 "::",
10257 stringify!(execution_state)
10258 )
10259 );
10260 assert_eq!(
10261 unsafe { ::std::ptr::addr_of!((*ptr).cs_segment) as usize - ptr as usize },
10262 8usize,
10263 concat!(
10264 "Offset of field: ",
10265 stringify!(hv_x64_intercept_message_header),
10266 "::",
10267 stringify!(cs_segment)
10268 )
10269 );
10270 assert_eq!(
10271 unsafe { ::std::ptr::addr_of!((*ptr).rip) as usize - ptr as usize },
10272 24usize,
10273 concat!(
10274 "Offset of field: ",
10275 stringify!(hv_x64_intercept_message_header),
10276 "::",
10277 stringify!(rip)
10278 )
10279 );
10280 assert_eq!(
10281 unsafe { ::std::ptr::addr_of!((*ptr).rflags) as usize - ptr as usize },
10282 32usize,
10283 concat!(
10284 "Offset of field: ",
10285 stringify!(hv_x64_intercept_message_header),
10286 "::",
10287 stringify!(rflags)
10288 )
10289 );
10290}
10291impl Default for hv_x64_intercept_message_header {
10292 fn default() -> Self {
10293 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
10294 unsafe {
10295 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
10296 s.assume_init()
10297 }
10298 }
10299}
10300impl hv_x64_intercept_message_header {
10301 #[inline]
10302 pub fn instruction_length(&self) -> __u8 {
10303 unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 4u8) as u8) }
10304 }
10305 #[inline]
10306 pub fn set_instruction_length(&mut self, val: __u8) {
10307 unsafe {
10308 let val: u8 = ::std::mem::transmute(val);
10309 self._bitfield_1.set(0usize, 4u8, val as u64)
10310 }
10311 }
10312 #[inline]
10313 pub fn cr8(&self) -> __u8 {
10314 unsafe { ::std::mem::transmute(self._bitfield_1.get(4usize, 4u8) as u8) }
10315 }
10316 #[inline]
10317 pub fn set_cr8(&mut self, val: __u8) {
10318 unsafe {
10319 let val: u8 = ::std::mem::transmute(val);
10320 self._bitfield_1.set(4usize, 4u8, val as u64)
10321 }
10322 }
10323 #[inline]
10324 pub fn new_bitfield_1(
10325 instruction_length: __u8,
10326 cr8: __u8,
10327 ) -> __BindgenBitfieldUnit<[u8; 1usize]> {
10328 let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 1usize]> = Default::default();
10329 __bindgen_bitfield_unit.set(0usize, 4u8, {
10330 let instruction_length: u8 = unsafe { ::std::mem::transmute(instruction_length) };
10331 instruction_length as u64
10332 });
10333 __bindgen_bitfield_unit.set(4usize, 4u8, {
10334 let cr8: u8 = unsafe { ::std::mem::transmute(cr8) };
10335 cr8 as u64
10336 });
10337 __bindgen_bitfield_unit
10338 }
10339}
10340#[repr(C, packed)]
10341#[derive(Copy, Clone)]
10342pub struct hv_x64_hypercall_intercept_message {
10343 pub header: hv_x64_intercept_message_header,
10344 pub rax: __u64,
10345 pub rbx: __u64,
10346 pub rcx: __u64,
10347 pub rdx: __u64,
10348 pub r8: __u64,
10349 pub rsi: __u64,
10350 pub rdi: __u64,
10351 pub xmmregisters: [hv_u128; 6usize],
10352 pub __bindgen_anon_1: hv_x64_hypercall_intercept_message__bindgen_ty_1,
10353}
10354#[repr(C, packed)]
10355#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
10356pub struct hv_x64_hypercall_intercept_message__bindgen_ty_1 {
10357 pub _bitfield_align_1: [u8; 0],
10358 pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize]>,
10359}
10360#[test]
10361fn bindgen_test_layout_hv_x64_hypercall_intercept_message__bindgen_ty_1() {
10362 assert_eq!(
10363 ::std::mem::size_of::<hv_x64_hypercall_intercept_message__bindgen_ty_1>(),
10364 4usize,
10365 concat!(
10366 "Size of: ",
10367 stringify!(hv_x64_hypercall_intercept_message__bindgen_ty_1)
10368 )
10369 );
10370 assert_eq!(
10371 ::std::mem::align_of::<hv_x64_hypercall_intercept_message__bindgen_ty_1>(),
10372 1usize,
10373 concat!(
10374 "Alignment of ",
10375 stringify!(hv_x64_hypercall_intercept_message__bindgen_ty_1)
10376 )
10377 );
10378}
10379impl hv_x64_hypercall_intercept_message__bindgen_ty_1 {
10380 #[inline]
10381 pub fn isolated(&self) -> __u32 {
10382 unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 1u8) as u32) }
10383 }
10384 #[inline]
10385 pub fn set_isolated(&mut self, val: __u32) {
10386 unsafe {
10387 let val: u32 = ::std::mem::transmute(val);
10388 self._bitfield_1.set(0usize, 1u8, val as u64)
10389 }
10390 }
10391 #[inline]
10392 pub fn reserved(&self) -> __u32 {
10393 unsafe { ::std::mem::transmute(self._bitfield_1.get(1usize, 31u8) as u32) }
10394 }
10395 #[inline]
10396 pub fn set_reserved(&mut self, val: __u32) {
10397 unsafe {
10398 let val: u32 = ::std::mem::transmute(val);
10399 self._bitfield_1.set(1usize, 31u8, val as u64)
10400 }
10401 }
10402 #[inline]
10403 pub fn new_bitfield_1(isolated: __u32, reserved: __u32) -> __BindgenBitfieldUnit<[u8; 4usize]> {
10404 let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 4usize]> = Default::default();
10405 __bindgen_bitfield_unit.set(0usize, 1u8, {
10406 let isolated: u32 = unsafe { ::std::mem::transmute(isolated) };
10407 isolated as u64
10408 });
10409 __bindgen_bitfield_unit.set(1usize, 31u8, {
10410 let reserved: u32 = unsafe { ::std::mem::transmute(reserved) };
10411 reserved as u64
10412 });
10413 __bindgen_bitfield_unit
10414 }
10415}
10416#[test]
10417fn bindgen_test_layout_hv_x64_hypercall_intercept_message() {
10418 const UNINIT: ::std::mem::MaybeUninit<hv_x64_hypercall_intercept_message> =
10419 ::std::mem::MaybeUninit::uninit();
10420 let ptr = UNINIT.as_ptr();
10421 assert_eq!(
10422 ::std::mem::size_of::<hv_x64_hypercall_intercept_message>(),
10423 196usize,
10424 concat!("Size of: ", stringify!(hv_x64_hypercall_intercept_message))
10425 );
10426 assert_eq!(
10427 ::std::mem::align_of::<hv_x64_hypercall_intercept_message>(),
10428 1usize,
10429 concat!(
10430 "Alignment of ",
10431 stringify!(hv_x64_hypercall_intercept_message)
10432 )
10433 );
10434 assert_eq!(
10435 unsafe { ::std::ptr::addr_of!((*ptr).header) as usize - ptr as usize },
10436 0usize,
10437 concat!(
10438 "Offset of field: ",
10439 stringify!(hv_x64_hypercall_intercept_message),
10440 "::",
10441 stringify!(header)
10442 )
10443 );
10444 assert_eq!(
10445 unsafe { ::std::ptr::addr_of!((*ptr).rax) as usize - ptr as usize },
10446 40usize,
10447 concat!(
10448 "Offset of field: ",
10449 stringify!(hv_x64_hypercall_intercept_message),
10450 "::",
10451 stringify!(rax)
10452 )
10453 );
10454 assert_eq!(
10455 unsafe { ::std::ptr::addr_of!((*ptr).rbx) as usize - ptr as usize },
10456 48usize,
10457 concat!(
10458 "Offset of field: ",
10459 stringify!(hv_x64_hypercall_intercept_message),
10460 "::",
10461 stringify!(rbx)
10462 )
10463 );
10464 assert_eq!(
10465 unsafe { ::std::ptr::addr_of!((*ptr).rcx) as usize - ptr as usize },
10466 56usize,
10467 concat!(
10468 "Offset of field: ",
10469 stringify!(hv_x64_hypercall_intercept_message),
10470 "::",
10471 stringify!(rcx)
10472 )
10473 );
10474 assert_eq!(
10475 unsafe { ::std::ptr::addr_of!((*ptr).rdx) as usize - ptr as usize },
10476 64usize,
10477 concat!(
10478 "Offset of field: ",
10479 stringify!(hv_x64_hypercall_intercept_message),
10480 "::",
10481 stringify!(rdx)
10482 )
10483 );
10484 assert_eq!(
10485 unsafe { ::std::ptr::addr_of!((*ptr).r8) as usize - ptr as usize },
10486 72usize,
10487 concat!(
10488 "Offset of field: ",
10489 stringify!(hv_x64_hypercall_intercept_message),
10490 "::",
10491 stringify!(r8)
10492 )
10493 );
10494 assert_eq!(
10495 unsafe { ::std::ptr::addr_of!((*ptr).rsi) as usize - ptr as usize },
10496 80usize,
10497 concat!(
10498 "Offset of field: ",
10499 stringify!(hv_x64_hypercall_intercept_message),
10500 "::",
10501 stringify!(rsi)
10502 )
10503 );
10504 assert_eq!(
10505 unsafe { ::std::ptr::addr_of!((*ptr).rdi) as usize - ptr as usize },
10506 88usize,
10507 concat!(
10508 "Offset of field: ",
10509 stringify!(hv_x64_hypercall_intercept_message),
10510 "::",
10511 stringify!(rdi)
10512 )
10513 );
10514 assert_eq!(
10515 unsafe { ::std::ptr::addr_of!((*ptr).xmmregisters) as usize - ptr as usize },
10516 96usize,
10517 concat!(
10518 "Offset of field: ",
10519 stringify!(hv_x64_hypercall_intercept_message),
10520 "::",
10521 stringify!(xmmregisters)
10522 )
10523 );
10524}
10525impl Default for hv_x64_hypercall_intercept_message {
10526 fn default() -> Self {
10527 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
10528 unsafe {
10529 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
10530 s.assume_init()
10531 }
10532 }
10533}
10534#[repr(C)]
10535#[derive(Copy, Clone)]
10536pub union hv_x64_register_access_info {
10537 pub source_value: hv_register_value,
10538 pub destination_register: __u32,
10539 pub source_address: __u64,
10540 pub destination_address: __u64,
10541}
10542#[test]
10543fn bindgen_test_layout_hv_x64_register_access_info() {
10544 const UNINIT: ::std::mem::MaybeUninit<hv_x64_register_access_info> =
10545 ::std::mem::MaybeUninit::uninit();
10546 let ptr = UNINIT.as_ptr();
10547 assert_eq!(
10548 ::std::mem::size_of::<hv_x64_register_access_info>(),
10549 16usize,
10550 concat!("Size of: ", stringify!(hv_x64_register_access_info))
10551 );
10552 assert_eq!(
10553 ::std::mem::align_of::<hv_x64_register_access_info>(),
10554 8usize,
10555 concat!("Alignment of ", stringify!(hv_x64_register_access_info))
10556 );
10557 assert_eq!(
10558 unsafe { ::std::ptr::addr_of!((*ptr).source_value) as usize - ptr as usize },
10559 0usize,
10560 concat!(
10561 "Offset of field: ",
10562 stringify!(hv_x64_register_access_info),
10563 "::",
10564 stringify!(source_value)
10565 )
10566 );
10567 assert_eq!(
10568 unsafe { ::std::ptr::addr_of!((*ptr).destination_register) as usize - ptr as usize },
10569 0usize,
10570 concat!(
10571 "Offset of field: ",
10572 stringify!(hv_x64_register_access_info),
10573 "::",
10574 stringify!(destination_register)
10575 )
10576 );
10577 assert_eq!(
10578 unsafe { ::std::ptr::addr_of!((*ptr).source_address) as usize - ptr as usize },
10579 0usize,
10580 concat!(
10581 "Offset of field: ",
10582 stringify!(hv_x64_register_access_info),
10583 "::",
10584 stringify!(source_address)
10585 )
10586 );
10587 assert_eq!(
10588 unsafe { ::std::ptr::addr_of!((*ptr).destination_address) as usize - ptr as usize },
10589 0usize,
10590 concat!(
10591 "Offset of field: ",
10592 stringify!(hv_x64_register_access_info),
10593 "::",
10594 stringify!(destination_address)
10595 )
10596 );
10597}
10598impl Default for hv_x64_register_access_info {
10599 fn default() -> Self {
10600 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
10601 unsafe {
10602 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
10603 s.assume_init()
10604 }
10605 }
10606}
10607#[repr(C, packed)]
10608#[derive(Copy, Clone)]
10609pub struct hv_x64_register_intercept_message {
10610 pub header: hv_x64_intercept_message_header,
10611 pub __bindgen_anon_1: hv_x64_register_intercept_message__bindgen_ty_1,
10612 pub reserved8: __u8,
10613 pub reserved16: __u16,
10614 pub register_name: __u32,
10615 pub access_info: hv_x64_register_access_info,
10616}
10617#[repr(C, packed)]
10618#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
10619pub struct hv_x64_register_intercept_message__bindgen_ty_1 {
10620 pub _bitfield_align_1: [u8; 0],
10621 pub _bitfield_1: __BindgenBitfieldUnit<[u8; 1usize]>,
10622}
10623#[test]
10624fn bindgen_test_layout_hv_x64_register_intercept_message__bindgen_ty_1() {
10625 assert_eq!(
10626 ::std::mem::size_of::<hv_x64_register_intercept_message__bindgen_ty_1>(),
10627 1usize,
10628 concat!(
10629 "Size of: ",
10630 stringify!(hv_x64_register_intercept_message__bindgen_ty_1)
10631 )
10632 );
10633 assert_eq!(
10634 ::std::mem::align_of::<hv_x64_register_intercept_message__bindgen_ty_1>(),
10635 1usize,
10636 concat!(
10637 "Alignment of ",
10638 stringify!(hv_x64_register_intercept_message__bindgen_ty_1)
10639 )
10640 );
10641}
10642impl hv_x64_register_intercept_message__bindgen_ty_1 {
10643 #[inline]
10644 pub fn is_memory_op(&self) -> __u8 {
10645 unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 1u8) as u8) }
10646 }
10647 #[inline]
10648 pub fn set_is_memory_op(&mut self, val: __u8) {
10649 unsafe {
10650 let val: u8 = ::std::mem::transmute(val);
10651 self._bitfield_1.set(0usize, 1u8, val as u64)
10652 }
10653 }
10654 #[inline]
10655 pub fn reserved(&self) -> __u8 {
10656 unsafe { ::std::mem::transmute(self._bitfield_1.get(1usize, 7u8) as u8) }
10657 }
10658 #[inline]
10659 pub fn set_reserved(&mut self, val: __u8) {
10660 unsafe {
10661 let val: u8 = ::std::mem::transmute(val);
10662 self._bitfield_1.set(1usize, 7u8, val as u64)
10663 }
10664 }
10665 #[inline]
10666 pub fn new_bitfield_1(
10667 is_memory_op: __u8,
10668 reserved: __u8,
10669 ) -> __BindgenBitfieldUnit<[u8; 1usize]> {
10670 let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 1usize]> = Default::default();
10671 __bindgen_bitfield_unit.set(0usize, 1u8, {
10672 let is_memory_op: u8 = unsafe { ::std::mem::transmute(is_memory_op) };
10673 is_memory_op as u64
10674 });
10675 __bindgen_bitfield_unit.set(1usize, 7u8, {
10676 let reserved: u8 = unsafe { ::std::mem::transmute(reserved) };
10677 reserved as u64
10678 });
10679 __bindgen_bitfield_unit
10680 }
10681}
10682#[test]
10683fn bindgen_test_layout_hv_x64_register_intercept_message() {
10684 const UNINIT: ::std::mem::MaybeUninit<hv_x64_register_intercept_message> =
10685 ::std::mem::MaybeUninit::uninit();
10686 let ptr = UNINIT.as_ptr();
10687 assert_eq!(
10688 ::std::mem::size_of::<hv_x64_register_intercept_message>(),
10689 64usize,
10690 concat!("Size of: ", stringify!(hv_x64_register_intercept_message))
10691 );
10692 assert_eq!(
10693 ::std::mem::align_of::<hv_x64_register_intercept_message>(),
10694 1usize,
10695 concat!(
10696 "Alignment of ",
10697 stringify!(hv_x64_register_intercept_message)
10698 )
10699 );
10700 assert_eq!(
10701 unsafe { ::std::ptr::addr_of!((*ptr).header) as usize - ptr as usize },
10702 0usize,
10703 concat!(
10704 "Offset of field: ",
10705 stringify!(hv_x64_register_intercept_message),
10706 "::",
10707 stringify!(header)
10708 )
10709 );
10710 assert_eq!(
10711 unsafe { ::std::ptr::addr_of!((*ptr).reserved8) as usize - ptr as usize },
10712 41usize,
10713 concat!(
10714 "Offset of field: ",
10715 stringify!(hv_x64_register_intercept_message),
10716 "::",
10717 stringify!(reserved8)
10718 )
10719 );
10720 assert_eq!(
10721 unsafe { ::std::ptr::addr_of!((*ptr).reserved16) as usize - ptr as usize },
10722 42usize,
10723 concat!(
10724 "Offset of field: ",
10725 stringify!(hv_x64_register_intercept_message),
10726 "::",
10727 stringify!(reserved16)
10728 )
10729 );
10730 assert_eq!(
10731 unsafe { ::std::ptr::addr_of!((*ptr).register_name) as usize - ptr as usize },
10732 44usize,
10733 concat!(
10734 "Offset of field: ",
10735 stringify!(hv_x64_register_intercept_message),
10736 "::",
10737 stringify!(register_name)
10738 )
10739 );
10740 assert_eq!(
10741 unsafe { ::std::ptr::addr_of!((*ptr).access_info) as usize - ptr as usize },
10742 48usize,
10743 concat!(
10744 "Offset of field: ",
10745 stringify!(hv_x64_register_intercept_message),
10746 "::",
10747 stringify!(access_info)
10748 )
10749 );
10750}
10751impl Default for hv_x64_register_intercept_message {
10752 fn default() -> Self {
10753 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
10754 unsafe {
10755 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
10756 s.assume_init()
10757 }
10758 }
10759}
10760#[repr(C)]
10761#[derive(Copy, Clone)]
10762pub union hv_x64_memory_access_info {
10763 pub as_uint8: __u8,
10764 pub __bindgen_anon_1: hv_x64_memory_access_info__bindgen_ty_1,
10765}
10766#[repr(C, packed)]
10767#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
10768pub struct hv_x64_memory_access_info__bindgen_ty_1 {
10769 pub _bitfield_align_1: [u8; 0],
10770 pub _bitfield_1: __BindgenBitfieldUnit<[u8; 1usize]>,
10771}
10772#[test]
10773fn bindgen_test_layout_hv_x64_memory_access_info__bindgen_ty_1() {
10774 assert_eq!(
10775 ::std::mem::size_of::<hv_x64_memory_access_info__bindgen_ty_1>(),
10776 1usize,
10777 concat!(
10778 "Size of: ",
10779 stringify!(hv_x64_memory_access_info__bindgen_ty_1)
10780 )
10781 );
10782 assert_eq!(
10783 ::std::mem::align_of::<hv_x64_memory_access_info__bindgen_ty_1>(),
10784 1usize,
10785 concat!(
10786 "Alignment of ",
10787 stringify!(hv_x64_memory_access_info__bindgen_ty_1)
10788 )
10789 );
10790}
10791impl hv_x64_memory_access_info__bindgen_ty_1 {
10792 #[inline]
10793 pub fn gva_valid(&self) -> __u8 {
10794 unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 1u8) as u8) }
10795 }
10796 #[inline]
10797 pub fn set_gva_valid(&mut self, val: __u8) {
10798 unsafe {
10799 let val: u8 = ::std::mem::transmute(val);
10800 self._bitfield_1.set(0usize, 1u8, val as u64)
10801 }
10802 }
10803 #[inline]
10804 pub fn gva_gpa_valid(&self) -> __u8 {
10805 unsafe { ::std::mem::transmute(self._bitfield_1.get(1usize, 1u8) as u8) }
10806 }
10807 #[inline]
10808 pub fn set_gva_gpa_valid(&mut self, val: __u8) {
10809 unsafe {
10810 let val: u8 = ::std::mem::transmute(val);
10811 self._bitfield_1.set(1usize, 1u8, val as u64)
10812 }
10813 }
10814 #[inline]
10815 pub fn hypercall_output_pending(&self) -> __u8 {
10816 unsafe { ::std::mem::transmute(self._bitfield_1.get(2usize, 1u8) as u8) }
10817 }
10818 #[inline]
10819 pub fn set_hypercall_output_pending(&mut self, val: __u8) {
10820 unsafe {
10821 let val: u8 = ::std::mem::transmute(val);
10822 self._bitfield_1.set(2usize, 1u8, val as u64)
10823 }
10824 }
10825 #[inline]
10826 pub fn tlb_locked_no_overlay(&self) -> __u8 {
10827 unsafe { ::std::mem::transmute(self._bitfield_1.get(3usize, 1u8) as u8) }
10828 }
10829 #[inline]
10830 pub fn set_tlb_locked_no_overlay(&mut self, val: __u8) {
10831 unsafe {
10832 let val: u8 = ::std::mem::transmute(val);
10833 self._bitfield_1.set(3usize, 1u8, val as u64)
10834 }
10835 }
10836 #[inline]
10837 pub fn reserved(&self) -> __u8 {
10838 unsafe { ::std::mem::transmute(self._bitfield_1.get(4usize, 4u8) as u8) }
10839 }
10840 #[inline]
10841 pub fn set_reserved(&mut self, val: __u8) {
10842 unsafe {
10843 let val: u8 = ::std::mem::transmute(val);
10844 self._bitfield_1.set(4usize, 4u8, val as u64)
10845 }
10846 }
10847 #[inline]
10848 pub fn new_bitfield_1(
10849 gva_valid: __u8,
10850 gva_gpa_valid: __u8,
10851 hypercall_output_pending: __u8,
10852 tlb_locked_no_overlay: __u8,
10853 reserved: __u8,
10854 ) -> __BindgenBitfieldUnit<[u8; 1usize]> {
10855 let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 1usize]> = Default::default();
10856 __bindgen_bitfield_unit.set(0usize, 1u8, {
10857 let gva_valid: u8 = unsafe { ::std::mem::transmute(gva_valid) };
10858 gva_valid as u64
10859 });
10860 __bindgen_bitfield_unit.set(1usize, 1u8, {
10861 let gva_gpa_valid: u8 = unsafe { ::std::mem::transmute(gva_gpa_valid) };
10862 gva_gpa_valid as u64
10863 });
10864 __bindgen_bitfield_unit.set(2usize, 1u8, {
10865 let hypercall_output_pending: u8 =
10866 unsafe { ::std::mem::transmute(hypercall_output_pending) };
10867 hypercall_output_pending as u64
10868 });
10869 __bindgen_bitfield_unit.set(3usize, 1u8, {
10870 let tlb_locked_no_overlay: u8 = unsafe { ::std::mem::transmute(tlb_locked_no_overlay) };
10871 tlb_locked_no_overlay as u64
10872 });
10873 __bindgen_bitfield_unit.set(4usize, 4u8, {
10874 let reserved: u8 = unsafe { ::std::mem::transmute(reserved) };
10875 reserved as u64
10876 });
10877 __bindgen_bitfield_unit
10878 }
10879}
10880#[test]
10881fn bindgen_test_layout_hv_x64_memory_access_info() {
10882 const UNINIT: ::std::mem::MaybeUninit<hv_x64_memory_access_info> =
10883 ::std::mem::MaybeUninit::uninit();
10884 let ptr = UNINIT.as_ptr();
10885 assert_eq!(
10886 ::std::mem::size_of::<hv_x64_memory_access_info>(),
10887 1usize,
10888 concat!("Size of: ", stringify!(hv_x64_memory_access_info))
10889 );
10890 assert_eq!(
10891 ::std::mem::align_of::<hv_x64_memory_access_info>(),
10892 1usize,
10893 concat!("Alignment of ", stringify!(hv_x64_memory_access_info))
10894 );
10895 assert_eq!(
10896 unsafe { ::std::ptr::addr_of!((*ptr).as_uint8) as usize - ptr as usize },
10897 0usize,
10898 concat!(
10899 "Offset of field: ",
10900 stringify!(hv_x64_memory_access_info),
10901 "::",
10902 stringify!(as_uint8)
10903 )
10904 );
10905}
10906impl Default for hv_x64_memory_access_info {
10907 fn default() -> Self {
10908 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
10909 unsafe {
10910 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
10911 s.assume_init()
10912 }
10913 }
10914}
10915#[repr(C)]
10916#[derive(Copy, Clone)]
10917pub union hv_x64_io_port_access_info {
10918 pub as_uint8: __u8,
10919 pub __bindgen_anon_1: hv_x64_io_port_access_info__bindgen_ty_1,
10920}
10921#[repr(C, packed)]
10922#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
10923pub struct hv_x64_io_port_access_info__bindgen_ty_1 {
10924 pub _bitfield_align_1: [u8; 0],
10925 pub _bitfield_1: __BindgenBitfieldUnit<[u8; 1usize]>,
10926}
10927#[test]
10928fn bindgen_test_layout_hv_x64_io_port_access_info__bindgen_ty_1() {
10929 assert_eq!(
10930 ::std::mem::size_of::<hv_x64_io_port_access_info__bindgen_ty_1>(),
10931 1usize,
10932 concat!(
10933 "Size of: ",
10934 stringify!(hv_x64_io_port_access_info__bindgen_ty_1)
10935 )
10936 );
10937 assert_eq!(
10938 ::std::mem::align_of::<hv_x64_io_port_access_info__bindgen_ty_1>(),
10939 1usize,
10940 concat!(
10941 "Alignment of ",
10942 stringify!(hv_x64_io_port_access_info__bindgen_ty_1)
10943 )
10944 );
10945}
10946impl hv_x64_io_port_access_info__bindgen_ty_1 {
10947 #[inline]
10948 pub fn access_size(&self) -> __u8 {
10949 unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 3u8) as u8) }
10950 }
10951 #[inline]
10952 pub fn set_access_size(&mut self, val: __u8) {
10953 unsafe {
10954 let val: u8 = ::std::mem::transmute(val);
10955 self._bitfield_1.set(0usize, 3u8, val as u64)
10956 }
10957 }
10958 #[inline]
10959 pub fn string_op(&self) -> __u8 {
10960 unsafe { ::std::mem::transmute(self._bitfield_1.get(3usize, 1u8) as u8) }
10961 }
10962 #[inline]
10963 pub fn set_string_op(&mut self, val: __u8) {
10964 unsafe {
10965 let val: u8 = ::std::mem::transmute(val);
10966 self._bitfield_1.set(3usize, 1u8, val as u64)
10967 }
10968 }
10969 #[inline]
10970 pub fn rep_prefix(&self) -> __u8 {
10971 unsafe { ::std::mem::transmute(self._bitfield_1.get(4usize, 1u8) as u8) }
10972 }
10973 #[inline]
10974 pub fn set_rep_prefix(&mut self, val: __u8) {
10975 unsafe {
10976 let val: u8 = ::std::mem::transmute(val);
10977 self._bitfield_1.set(4usize, 1u8, val as u64)
10978 }
10979 }
10980 #[inline]
10981 pub fn reserved(&self) -> __u8 {
10982 unsafe { ::std::mem::transmute(self._bitfield_1.get(5usize, 3u8) as u8) }
10983 }
10984 #[inline]
10985 pub fn set_reserved(&mut self, val: __u8) {
10986 unsafe {
10987 let val: u8 = ::std::mem::transmute(val);
10988 self._bitfield_1.set(5usize, 3u8, val as u64)
10989 }
10990 }
10991 #[inline]
10992 pub fn new_bitfield_1(
10993 access_size: __u8,
10994 string_op: __u8,
10995 rep_prefix: __u8,
10996 reserved: __u8,
10997 ) -> __BindgenBitfieldUnit<[u8; 1usize]> {
10998 let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 1usize]> = Default::default();
10999 __bindgen_bitfield_unit.set(0usize, 3u8, {
11000 let access_size: u8 = unsafe { ::std::mem::transmute(access_size) };
11001 access_size as u64
11002 });
11003 __bindgen_bitfield_unit.set(3usize, 1u8, {
11004 let string_op: u8 = unsafe { ::std::mem::transmute(string_op) };
11005 string_op as u64
11006 });
11007 __bindgen_bitfield_unit.set(4usize, 1u8, {
11008 let rep_prefix: u8 = unsafe { ::std::mem::transmute(rep_prefix) };
11009 rep_prefix as u64
11010 });
11011 __bindgen_bitfield_unit.set(5usize, 3u8, {
11012 let reserved: u8 = unsafe { ::std::mem::transmute(reserved) };
11013 reserved as u64
11014 });
11015 __bindgen_bitfield_unit
11016 }
11017}
11018#[test]
11019fn bindgen_test_layout_hv_x64_io_port_access_info() {
11020 const UNINIT: ::std::mem::MaybeUninit<hv_x64_io_port_access_info> =
11021 ::std::mem::MaybeUninit::uninit();
11022 let ptr = UNINIT.as_ptr();
11023 assert_eq!(
11024 ::std::mem::size_of::<hv_x64_io_port_access_info>(),
11025 1usize,
11026 concat!("Size of: ", stringify!(hv_x64_io_port_access_info))
11027 );
11028 assert_eq!(
11029 ::std::mem::align_of::<hv_x64_io_port_access_info>(),
11030 1usize,
11031 concat!("Alignment of ", stringify!(hv_x64_io_port_access_info))
11032 );
11033 assert_eq!(
11034 unsafe { ::std::ptr::addr_of!((*ptr).as_uint8) as usize - ptr as usize },
11035 0usize,
11036 concat!(
11037 "Offset of field: ",
11038 stringify!(hv_x64_io_port_access_info),
11039 "::",
11040 stringify!(as_uint8)
11041 )
11042 );
11043}
11044impl Default for hv_x64_io_port_access_info {
11045 fn default() -> Self {
11046 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
11047 unsafe {
11048 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
11049 s.assume_init()
11050 }
11051 }
11052}
11053#[repr(C)]
11054#[derive(Copy, Clone)]
11055pub union hv_x64_exception_info {
11056 pub as_uint8: __u8,
11057 pub __bindgen_anon_1: hv_x64_exception_info__bindgen_ty_1,
11058}
11059#[repr(C, packed)]
11060#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
11061pub struct hv_x64_exception_info__bindgen_ty_1 {
11062 pub _bitfield_align_1: [u8; 0],
11063 pub _bitfield_1: __BindgenBitfieldUnit<[u8; 1usize]>,
11064}
11065#[test]
11066fn bindgen_test_layout_hv_x64_exception_info__bindgen_ty_1() {
11067 assert_eq!(
11068 ::std::mem::size_of::<hv_x64_exception_info__bindgen_ty_1>(),
11069 1usize,
11070 concat!("Size of: ", stringify!(hv_x64_exception_info__bindgen_ty_1))
11071 );
11072 assert_eq!(
11073 ::std::mem::align_of::<hv_x64_exception_info__bindgen_ty_1>(),
11074 1usize,
11075 concat!(
11076 "Alignment of ",
11077 stringify!(hv_x64_exception_info__bindgen_ty_1)
11078 )
11079 );
11080}
11081impl hv_x64_exception_info__bindgen_ty_1 {
11082 #[inline]
11083 pub fn error_code_valid(&self) -> __u8 {
11084 unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 1u8) as u8) }
11085 }
11086 #[inline]
11087 pub fn set_error_code_valid(&mut self, val: __u8) {
11088 unsafe {
11089 let val: u8 = ::std::mem::transmute(val);
11090 self._bitfield_1.set(0usize, 1u8, val as u64)
11091 }
11092 }
11093 #[inline]
11094 pub fn software_exception(&self) -> __u8 {
11095 unsafe { ::std::mem::transmute(self._bitfield_1.get(1usize, 1u8) as u8) }
11096 }
11097 #[inline]
11098 pub fn set_software_exception(&mut self, val: __u8) {
11099 unsafe {
11100 let val: u8 = ::std::mem::transmute(val);
11101 self._bitfield_1.set(1usize, 1u8, val as u64)
11102 }
11103 }
11104 #[inline]
11105 pub fn reserved(&self) -> __u8 {
11106 unsafe { ::std::mem::transmute(self._bitfield_1.get(2usize, 6u8) as u8) }
11107 }
11108 #[inline]
11109 pub fn set_reserved(&mut self, val: __u8) {
11110 unsafe {
11111 let val: u8 = ::std::mem::transmute(val);
11112 self._bitfield_1.set(2usize, 6u8, val as u64)
11113 }
11114 }
11115 #[inline]
11116 pub fn new_bitfield_1(
11117 error_code_valid: __u8,
11118 software_exception: __u8,
11119 reserved: __u8,
11120 ) -> __BindgenBitfieldUnit<[u8; 1usize]> {
11121 let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 1usize]> = Default::default();
11122 __bindgen_bitfield_unit.set(0usize, 1u8, {
11123 let error_code_valid: u8 = unsafe { ::std::mem::transmute(error_code_valid) };
11124 error_code_valid as u64
11125 });
11126 __bindgen_bitfield_unit.set(1usize, 1u8, {
11127 let software_exception: u8 = unsafe { ::std::mem::transmute(software_exception) };
11128 software_exception as u64
11129 });
11130 __bindgen_bitfield_unit.set(2usize, 6u8, {
11131 let reserved: u8 = unsafe { ::std::mem::transmute(reserved) };
11132 reserved as u64
11133 });
11134 __bindgen_bitfield_unit
11135 }
11136}
11137#[test]
11138fn bindgen_test_layout_hv_x64_exception_info() {
11139 const UNINIT: ::std::mem::MaybeUninit<hv_x64_exception_info> =
11140 ::std::mem::MaybeUninit::uninit();
11141 let ptr = UNINIT.as_ptr();
11142 assert_eq!(
11143 ::std::mem::size_of::<hv_x64_exception_info>(),
11144 1usize,
11145 concat!("Size of: ", stringify!(hv_x64_exception_info))
11146 );
11147 assert_eq!(
11148 ::std::mem::align_of::<hv_x64_exception_info>(),
11149 1usize,
11150 concat!("Alignment of ", stringify!(hv_x64_exception_info))
11151 );
11152 assert_eq!(
11153 unsafe { ::std::ptr::addr_of!((*ptr).as_uint8) as usize - ptr as usize },
11154 0usize,
11155 concat!(
11156 "Offset of field: ",
11157 stringify!(hv_x64_exception_info),
11158 "::",
11159 stringify!(as_uint8)
11160 )
11161 );
11162}
11163impl Default for hv_x64_exception_info {
11164 fn default() -> Self {
11165 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
11166 unsafe {
11167 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
11168 s.assume_init()
11169 }
11170 }
11171}
11172#[repr(C, packed)]
11173#[derive(Copy, Clone)]
11174pub struct hv_x64_memory_intercept_message {
11175 pub header: hv_x64_intercept_message_header,
11176 pub cache_type: __u32,
11177 pub instruction_byte_count: __u8,
11178 pub memory_access_info: hv_x64_memory_access_info,
11179 pub tpr_priority: __u8,
11180 pub reserved1: __u8,
11181 pub guest_virtual_address: __u64,
11182 pub guest_physical_address: __u64,
11183 pub instruction_bytes: [__u8; 16usize],
11184}
11185#[test]
11186fn bindgen_test_layout_hv_x64_memory_intercept_message() {
11187 const UNINIT: ::std::mem::MaybeUninit<hv_x64_memory_intercept_message> =
11188 ::std::mem::MaybeUninit::uninit();
11189 let ptr = UNINIT.as_ptr();
11190 assert_eq!(
11191 ::std::mem::size_of::<hv_x64_memory_intercept_message>(),
11192 80usize,
11193 concat!("Size of: ", stringify!(hv_x64_memory_intercept_message))
11194 );
11195 assert_eq!(
11196 ::std::mem::align_of::<hv_x64_memory_intercept_message>(),
11197 1usize,
11198 concat!("Alignment of ", stringify!(hv_x64_memory_intercept_message))
11199 );
11200 assert_eq!(
11201 unsafe { ::std::ptr::addr_of!((*ptr).header) as usize - ptr as usize },
11202 0usize,
11203 concat!(
11204 "Offset of field: ",
11205 stringify!(hv_x64_memory_intercept_message),
11206 "::",
11207 stringify!(header)
11208 )
11209 );
11210 assert_eq!(
11211 unsafe { ::std::ptr::addr_of!((*ptr).cache_type) as usize - ptr as usize },
11212 40usize,
11213 concat!(
11214 "Offset of field: ",
11215 stringify!(hv_x64_memory_intercept_message),
11216 "::",
11217 stringify!(cache_type)
11218 )
11219 );
11220 assert_eq!(
11221 unsafe { ::std::ptr::addr_of!((*ptr).instruction_byte_count) as usize - ptr as usize },
11222 44usize,
11223 concat!(
11224 "Offset of field: ",
11225 stringify!(hv_x64_memory_intercept_message),
11226 "::",
11227 stringify!(instruction_byte_count)
11228 )
11229 );
11230 assert_eq!(
11231 unsafe { ::std::ptr::addr_of!((*ptr).memory_access_info) as usize - ptr as usize },
11232 45usize,
11233 concat!(
11234 "Offset of field: ",
11235 stringify!(hv_x64_memory_intercept_message),
11236 "::",
11237 stringify!(memory_access_info)
11238 )
11239 );
11240 assert_eq!(
11241 unsafe { ::std::ptr::addr_of!((*ptr).tpr_priority) as usize - ptr as usize },
11242 46usize,
11243 concat!(
11244 "Offset of field: ",
11245 stringify!(hv_x64_memory_intercept_message),
11246 "::",
11247 stringify!(tpr_priority)
11248 )
11249 );
11250 assert_eq!(
11251 unsafe { ::std::ptr::addr_of!((*ptr).reserved1) as usize - ptr as usize },
11252 47usize,
11253 concat!(
11254 "Offset of field: ",
11255 stringify!(hv_x64_memory_intercept_message),
11256 "::",
11257 stringify!(reserved1)
11258 )
11259 );
11260 assert_eq!(
11261 unsafe { ::std::ptr::addr_of!((*ptr).guest_virtual_address) as usize - ptr as usize },
11262 48usize,
11263 concat!(
11264 "Offset of field: ",
11265 stringify!(hv_x64_memory_intercept_message),
11266 "::",
11267 stringify!(guest_virtual_address)
11268 )
11269 );
11270 assert_eq!(
11271 unsafe { ::std::ptr::addr_of!((*ptr).guest_physical_address) as usize - ptr as usize },
11272 56usize,
11273 concat!(
11274 "Offset of field: ",
11275 stringify!(hv_x64_memory_intercept_message),
11276 "::",
11277 stringify!(guest_physical_address)
11278 )
11279 );
11280 assert_eq!(
11281 unsafe { ::std::ptr::addr_of!((*ptr).instruction_bytes) as usize - ptr as usize },
11282 64usize,
11283 concat!(
11284 "Offset of field: ",
11285 stringify!(hv_x64_memory_intercept_message),
11286 "::",
11287 stringify!(instruction_bytes)
11288 )
11289 );
11290}
11291impl Default for hv_x64_memory_intercept_message {
11292 fn default() -> Self {
11293 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
11294 unsafe {
11295 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
11296 s.assume_init()
11297 }
11298 }
11299}
11300#[repr(C, packed)]
11301#[derive(Copy, Clone)]
11302pub struct hv_x64_cpuid_intercept_message {
11303 pub header: hv_x64_intercept_message_header,
11304 pub rax: __u64,
11305 pub rcx: __u64,
11306 pub rdx: __u64,
11307 pub rbx: __u64,
11308 pub default_result_rax: __u64,
11309 pub default_result_rcx: __u64,
11310 pub default_result_rdx: __u64,
11311 pub default_result_rbx: __u64,
11312}
11313#[test]
11314fn bindgen_test_layout_hv_x64_cpuid_intercept_message() {
11315 const UNINIT: ::std::mem::MaybeUninit<hv_x64_cpuid_intercept_message> =
11316 ::std::mem::MaybeUninit::uninit();
11317 let ptr = UNINIT.as_ptr();
11318 assert_eq!(
11319 ::std::mem::size_of::<hv_x64_cpuid_intercept_message>(),
11320 104usize,
11321 concat!("Size of: ", stringify!(hv_x64_cpuid_intercept_message))
11322 );
11323 assert_eq!(
11324 ::std::mem::align_of::<hv_x64_cpuid_intercept_message>(),
11325 1usize,
11326 concat!("Alignment of ", stringify!(hv_x64_cpuid_intercept_message))
11327 );
11328 assert_eq!(
11329 unsafe { ::std::ptr::addr_of!((*ptr).header) as usize - ptr as usize },
11330 0usize,
11331 concat!(
11332 "Offset of field: ",
11333 stringify!(hv_x64_cpuid_intercept_message),
11334 "::",
11335 stringify!(header)
11336 )
11337 );
11338 assert_eq!(
11339 unsafe { ::std::ptr::addr_of!((*ptr).rax) as usize - ptr as usize },
11340 40usize,
11341 concat!(
11342 "Offset of field: ",
11343 stringify!(hv_x64_cpuid_intercept_message),
11344 "::",
11345 stringify!(rax)
11346 )
11347 );
11348 assert_eq!(
11349 unsafe { ::std::ptr::addr_of!((*ptr).rcx) as usize - ptr as usize },
11350 48usize,
11351 concat!(
11352 "Offset of field: ",
11353 stringify!(hv_x64_cpuid_intercept_message),
11354 "::",
11355 stringify!(rcx)
11356 )
11357 );
11358 assert_eq!(
11359 unsafe { ::std::ptr::addr_of!((*ptr).rdx) as usize - ptr as usize },
11360 56usize,
11361 concat!(
11362 "Offset of field: ",
11363 stringify!(hv_x64_cpuid_intercept_message),
11364 "::",
11365 stringify!(rdx)
11366 )
11367 );
11368 assert_eq!(
11369 unsafe { ::std::ptr::addr_of!((*ptr).rbx) as usize - ptr as usize },
11370 64usize,
11371 concat!(
11372 "Offset of field: ",
11373 stringify!(hv_x64_cpuid_intercept_message),
11374 "::",
11375 stringify!(rbx)
11376 )
11377 );
11378 assert_eq!(
11379 unsafe { ::std::ptr::addr_of!((*ptr).default_result_rax) as usize - ptr as usize },
11380 72usize,
11381 concat!(
11382 "Offset of field: ",
11383 stringify!(hv_x64_cpuid_intercept_message),
11384 "::",
11385 stringify!(default_result_rax)
11386 )
11387 );
11388 assert_eq!(
11389 unsafe { ::std::ptr::addr_of!((*ptr).default_result_rcx) as usize - ptr as usize },
11390 80usize,
11391 concat!(
11392 "Offset of field: ",
11393 stringify!(hv_x64_cpuid_intercept_message),
11394 "::",
11395 stringify!(default_result_rcx)
11396 )
11397 );
11398 assert_eq!(
11399 unsafe { ::std::ptr::addr_of!((*ptr).default_result_rdx) as usize - ptr as usize },
11400 88usize,
11401 concat!(
11402 "Offset of field: ",
11403 stringify!(hv_x64_cpuid_intercept_message),
11404 "::",
11405 stringify!(default_result_rdx)
11406 )
11407 );
11408 assert_eq!(
11409 unsafe { ::std::ptr::addr_of!((*ptr).default_result_rbx) as usize - ptr as usize },
11410 96usize,
11411 concat!(
11412 "Offset of field: ",
11413 stringify!(hv_x64_cpuid_intercept_message),
11414 "::",
11415 stringify!(default_result_rbx)
11416 )
11417 );
11418}
11419impl Default for hv_x64_cpuid_intercept_message {
11420 fn default() -> Self {
11421 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
11422 unsafe {
11423 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
11424 s.assume_init()
11425 }
11426 }
11427}
11428#[repr(C, packed)]
11429#[derive(Copy, Clone)]
11430pub struct hv_x64_msr_intercept_message {
11431 pub header: hv_x64_intercept_message_header,
11432 pub msr_number: __u32,
11433 pub reserved: __u32,
11434 pub rdx: __u64,
11435 pub rax: __u64,
11436}
11437#[test]
11438fn bindgen_test_layout_hv_x64_msr_intercept_message() {
11439 const UNINIT: ::std::mem::MaybeUninit<hv_x64_msr_intercept_message> =
11440 ::std::mem::MaybeUninit::uninit();
11441 let ptr = UNINIT.as_ptr();
11442 assert_eq!(
11443 ::std::mem::size_of::<hv_x64_msr_intercept_message>(),
11444 64usize,
11445 concat!("Size of: ", stringify!(hv_x64_msr_intercept_message))
11446 );
11447 assert_eq!(
11448 ::std::mem::align_of::<hv_x64_msr_intercept_message>(),
11449 1usize,
11450 concat!("Alignment of ", stringify!(hv_x64_msr_intercept_message))
11451 );
11452 assert_eq!(
11453 unsafe { ::std::ptr::addr_of!((*ptr).header) as usize - ptr as usize },
11454 0usize,
11455 concat!(
11456 "Offset of field: ",
11457 stringify!(hv_x64_msr_intercept_message),
11458 "::",
11459 stringify!(header)
11460 )
11461 );
11462 assert_eq!(
11463 unsafe { ::std::ptr::addr_of!((*ptr).msr_number) as usize - ptr as usize },
11464 40usize,
11465 concat!(
11466 "Offset of field: ",
11467 stringify!(hv_x64_msr_intercept_message),
11468 "::",
11469 stringify!(msr_number)
11470 )
11471 );
11472 assert_eq!(
11473 unsafe { ::std::ptr::addr_of!((*ptr).reserved) as usize - ptr as usize },
11474 44usize,
11475 concat!(
11476 "Offset of field: ",
11477 stringify!(hv_x64_msr_intercept_message),
11478 "::",
11479 stringify!(reserved)
11480 )
11481 );
11482 assert_eq!(
11483 unsafe { ::std::ptr::addr_of!((*ptr).rdx) as usize - ptr as usize },
11484 48usize,
11485 concat!(
11486 "Offset of field: ",
11487 stringify!(hv_x64_msr_intercept_message),
11488 "::",
11489 stringify!(rdx)
11490 )
11491 );
11492 assert_eq!(
11493 unsafe { ::std::ptr::addr_of!((*ptr).rax) as usize - ptr as usize },
11494 56usize,
11495 concat!(
11496 "Offset of field: ",
11497 stringify!(hv_x64_msr_intercept_message),
11498 "::",
11499 stringify!(rax)
11500 )
11501 );
11502}
11503impl Default for hv_x64_msr_intercept_message {
11504 fn default() -> Self {
11505 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
11506 unsafe {
11507 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
11508 s.assume_init()
11509 }
11510 }
11511}
11512#[repr(C, packed)]
11513#[derive(Copy, Clone)]
11514pub struct hv_x64_io_port_intercept_message {
11515 pub header: hv_x64_intercept_message_header,
11516 pub port_number: __u16,
11517 pub access_info: hv_x64_io_port_access_info,
11518 pub instruction_byte_count: __u8,
11519 pub reserved: __u32,
11520 pub rax: __u64,
11521 pub instruction_bytes: [__u8; 16usize],
11522 pub ds_segment: hv_x64_segment_register,
11523 pub es_segment: hv_x64_segment_register,
11524 pub rcx: __u64,
11525 pub rsi: __u64,
11526 pub rdi: __u64,
11527}
11528#[test]
11529fn bindgen_test_layout_hv_x64_io_port_intercept_message() {
11530 const UNINIT: ::std::mem::MaybeUninit<hv_x64_io_port_intercept_message> =
11531 ::std::mem::MaybeUninit::uninit();
11532 let ptr = UNINIT.as_ptr();
11533 assert_eq!(
11534 ::std::mem::size_of::<hv_x64_io_port_intercept_message>(),
11535 128usize,
11536 concat!("Size of: ", stringify!(hv_x64_io_port_intercept_message))
11537 );
11538 assert_eq!(
11539 ::std::mem::align_of::<hv_x64_io_port_intercept_message>(),
11540 1usize,
11541 concat!(
11542 "Alignment of ",
11543 stringify!(hv_x64_io_port_intercept_message)
11544 )
11545 );
11546 assert_eq!(
11547 unsafe { ::std::ptr::addr_of!((*ptr).header) as usize - ptr as usize },
11548 0usize,
11549 concat!(
11550 "Offset of field: ",
11551 stringify!(hv_x64_io_port_intercept_message),
11552 "::",
11553 stringify!(header)
11554 )
11555 );
11556 assert_eq!(
11557 unsafe { ::std::ptr::addr_of!((*ptr).port_number) as usize - ptr as usize },
11558 40usize,
11559 concat!(
11560 "Offset of field: ",
11561 stringify!(hv_x64_io_port_intercept_message),
11562 "::",
11563 stringify!(port_number)
11564 )
11565 );
11566 assert_eq!(
11567 unsafe { ::std::ptr::addr_of!((*ptr).access_info) as usize - ptr as usize },
11568 42usize,
11569 concat!(
11570 "Offset of field: ",
11571 stringify!(hv_x64_io_port_intercept_message),
11572 "::",
11573 stringify!(access_info)
11574 )
11575 );
11576 assert_eq!(
11577 unsafe { ::std::ptr::addr_of!((*ptr).instruction_byte_count) as usize - ptr as usize },
11578 43usize,
11579 concat!(
11580 "Offset of field: ",
11581 stringify!(hv_x64_io_port_intercept_message),
11582 "::",
11583 stringify!(instruction_byte_count)
11584 )
11585 );
11586 assert_eq!(
11587 unsafe { ::std::ptr::addr_of!((*ptr).reserved) as usize - ptr as usize },
11588 44usize,
11589 concat!(
11590 "Offset of field: ",
11591 stringify!(hv_x64_io_port_intercept_message),
11592 "::",
11593 stringify!(reserved)
11594 )
11595 );
11596 assert_eq!(
11597 unsafe { ::std::ptr::addr_of!((*ptr).rax) as usize - ptr as usize },
11598 48usize,
11599 concat!(
11600 "Offset of field: ",
11601 stringify!(hv_x64_io_port_intercept_message),
11602 "::",
11603 stringify!(rax)
11604 )
11605 );
11606 assert_eq!(
11607 unsafe { ::std::ptr::addr_of!((*ptr).instruction_bytes) as usize - ptr as usize },
11608 56usize,
11609 concat!(
11610 "Offset of field: ",
11611 stringify!(hv_x64_io_port_intercept_message),
11612 "::",
11613 stringify!(instruction_bytes)
11614 )
11615 );
11616 assert_eq!(
11617 unsafe { ::std::ptr::addr_of!((*ptr).ds_segment) as usize - ptr as usize },
11618 72usize,
11619 concat!(
11620 "Offset of field: ",
11621 stringify!(hv_x64_io_port_intercept_message),
11622 "::",
11623 stringify!(ds_segment)
11624 )
11625 );
11626 assert_eq!(
11627 unsafe { ::std::ptr::addr_of!((*ptr).es_segment) as usize - ptr as usize },
11628 88usize,
11629 concat!(
11630 "Offset of field: ",
11631 stringify!(hv_x64_io_port_intercept_message),
11632 "::",
11633 stringify!(es_segment)
11634 )
11635 );
11636 assert_eq!(
11637 unsafe { ::std::ptr::addr_of!((*ptr).rcx) as usize - ptr as usize },
11638 104usize,
11639 concat!(
11640 "Offset of field: ",
11641 stringify!(hv_x64_io_port_intercept_message),
11642 "::",
11643 stringify!(rcx)
11644 )
11645 );
11646 assert_eq!(
11647 unsafe { ::std::ptr::addr_of!((*ptr).rsi) as usize - ptr as usize },
11648 112usize,
11649 concat!(
11650 "Offset of field: ",
11651 stringify!(hv_x64_io_port_intercept_message),
11652 "::",
11653 stringify!(rsi)
11654 )
11655 );
11656 assert_eq!(
11657 unsafe { ::std::ptr::addr_of!((*ptr).rdi) as usize - ptr as usize },
11658 120usize,
11659 concat!(
11660 "Offset of field: ",
11661 stringify!(hv_x64_io_port_intercept_message),
11662 "::",
11663 stringify!(rdi)
11664 )
11665 );
11666}
11667impl Default for hv_x64_io_port_intercept_message {
11668 fn default() -> Self {
11669 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
11670 unsafe {
11671 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
11672 s.assume_init()
11673 }
11674 }
11675}
11676#[repr(C, packed)]
11677#[derive(Copy, Clone)]
11678pub struct hv_x64_exception_intercept_message {
11679 pub header: hv_x64_intercept_message_header,
11680 pub exception_vector: __u16,
11681 pub exception_info: hv_x64_exception_info,
11682 pub instruction_byte_count: __u8,
11683 pub error_code: __u32,
11684 pub exception_parameter: __u64,
11685 pub reserved: __u64,
11686 pub instruction_bytes: [__u8; 16usize],
11687 pub ds_segment: hv_x64_segment_register,
11688 pub ss_segment: hv_x64_segment_register,
11689 pub rax: __u64,
11690 pub rcx: __u64,
11691 pub rdx: __u64,
11692 pub rbx: __u64,
11693 pub rsp: __u64,
11694 pub rbp: __u64,
11695 pub rsi: __u64,
11696 pub rdi: __u64,
11697 pub r8: __u64,
11698 pub r9: __u64,
11699 pub r10: __u64,
11700 pub r11: __u64,
11701 pub r12: __u64,
11702 pub r13: __u64,
11703 pub r14: __u64,
11704 pub r15: __u64,
11705}
11706#[test]
11707fn bindgen_test_layout_hv_x64_exception_intercept_message() {
11708 const UNINIT: ::std::mem::MaybeUninit<hv_x64_exception_intercept_message> =
11709 ::std::mem::MaybeUninit::uninit();
11710 let ptr = UNINIT.as_ptr();
11711 assert_eq!(
11712 ::std::mem::size_of::<hv_x64_exception_intercept_message>(),
11713 240usize,
11714 concat!("Size of: ", stringify!(hv_x64_exception_intercept_message))
11715 );
11716 assert_eq!(
11717 ::std::mem::align_of::<hv_x64_exception_intercept_message>(),
11718 1usize,
11719 concat!(
11720 "Alignment of ",
11721 stringify!(hv_x64_exception_intercept_message)
11722 )
11723 );
11724 assert_eq!(
11725 unsafe { ::std::ptr::addr_of!((*ptr).header) as usize - ptr as usize },
11726 0usize,
11727 concat!(
11728 "Offset of field: ",
11729 stringify!(hv_x64_exception_intercept_message),
11730 "::",
11731 stringify!(header)
11732 )
11733 );
11734 assert_eq!(
11735 unsafe { ::std::ptr::addr_of!((*ptr).exception_vector) as usize - ptr as usize },
11736 40usize,
11737 concat!(
11738 "Offset of field: ",
11739 stringify!(hv_x64_exception_intercept_message),
11740 "::",
11741 stringify!(exception_vector)
11742 )
11743 );
11744 assert_eq!(
11745 unsafe { ::std::ptr::addr_of!((*ptr).exception_info) as usize - ptr as usize },
11746 42usize,
11747 concat!(
11748 "Offset of field: ",
11749 stringify!(hv_x64_exception_intercept_message),
11750 "::",
11751 stringify!(exception_info)
11752 )
11753 );
11754 assert_eq!(
11755 unsafe { ::std::ptr::addr_of!((*ptr).instruction_byte_count) as usize - ptr as usize },
11756 43usize,
11757 concat!(
11758 "Offset of field: ",
11759 stringify!(hv_x64_exception_intercept_message),
11760 "::",
11761 stringify!(instruction_byte_count)
11762 )
11763 );
11764 assert_eq!(
11765 unsafe { ::std::ptr::addr_of!((*ptr).error_code) as usize - ptr as usize },
11766 44usize,
11767 concat!(
11768 "Offset of field: ",
11769 stringify!(hv_x64_exception_intercept_message),
11770 "::",
11771 stringify!(error_code)
11772 )
11773 );
11774 assert_eq!(
11775 unsafe { ::std::ptr::addr_of!((*ptr).exception_parameter) as usize - ptr as usize },
11776 48usize,
11777 concat!(
11778 "Offset of field: ",
11779 stringify!(hv_x64_exception_intercept_message),
11780 "::",
11781 stringify!(exception_parameter)
11782 )
11783 );
11784 assert_eq!(
11785 unsafe { ::std::ptr::addr_of!((*ptr).reserved) as usize - ptr as usize },
11786 56usize,
11787 concat!(
11788 "Offset of field: ",
11789 stringify!(hv_x64_exception_intercept_message),
11790 "::",
11791 stringify!(reserved)
11792 )
11793 );
11794 assert_eq!(
11795 unsafe { ::std::ptr::addr_of!((*ptr).instruction_bytes) as usize - ptr as usize },
11796 64usize,
11797 concat!(
11798 "Offset of field: ",
11799 stringify!(hv_x64_exception_intercept_message),
11800 "::",
11801 stringify!(instruction_bytes)
11802 )
11803 );
11804 assert_eq!(
11805 unsafe { ::std::ptr::addr_of!((*ptr).ds_segment) as usize - ptr as usize },
11806 80usize,
11807 concat!(
11808 "Offset of field: ",
11809 stringify!(hv_x64_exception_intercept_message),
11810 "::",
11811 stringify!(ds_segment)
11812 )
11813 );
11814 assert_eq!(
11815 unsafe { ::std::ptr::addr_of!((*ptr).ss_segment) as usize - ptr as usize },
11816 96usize,
11817 concat!(
11818 "Offset of field: ",
11819 stringify!(hv_x64_exception_intercept_message),
11820 "::",
11821 stringify!(ss_segment)
11822 )
11823 );
11824 assert_eq!(
11825 unsafe { ::std::ptr::addr_of!((*ptr).rax) as usize - ptr as usize },
11826 112usize,
11827 concat!(
11828 "Offset of field: ",
11829 stringify!(hv_x64_exception_intercept_message),
11830 "::",
11831 stringify!(rax)
11832 )
11833 );
11834 assert_eq!(
11835 unsafe { ::std::ptr::addr_of!((*ptr).rcx) as usize - ptr as usize },
11836 120usize,
11837 concat!(
11838 "Offset of field: ",
11839 stringify!(hv_x64_exception_intercept_message),
11840 "::",
11841 stringify!(rcx)
11842 )
11843 );
11844 assert_eq!(
11845 unsafe { ::std::ptr::addr_of!((*ptr).rdx) as usize - ptr as usize },
11846 128usize,
11847 concat!(
11848 "Offset of field: ",
11849 stringify!(hv_x64_exception_intercept_message),
11850 "::",
11851 stringify!(rdx)
11852 )
11853 );
11854 assert_eq!(
11855 unsafe { ::std::ptr::addr_of!((*ptr).rbx) as usize - ptr as usize },
11856 136usize,
11857 concat!(
11858 "Offset of field: ",
11859 stringify!(hv_x64_exception_intercept_message),
11860 "::",
11861 stringify!(rbx)
11862 )
11863 );
11864 assert_eq!(
11865 unsafe { ::std::ptr::addr_of!((*ptr).rsp) as usize - ptr as usize },
11866 144usize,
11867 concat!(
11868 "Offset of field: ",
11869 stringify!(hv_x64_exception_intercept_message),
11870 "::",
11871 stringify!(rsp)
11872 )
11873 );
11874 assert_eq!(
11875 unsafe { ::std::ptr::addr_of!((*ptr).rbp) as usize - ptr as usize },
11876 152usize,
11877 concat!(
11878 "Offset of field: ",
11879 stringify!(hv_x64_exception_intercept_message),
11880 "::",
11881 stringify!(rbp)
11882 )
11883 );
11884 assert_eq!(
11885 unsafe { ::std::ptr::addr_of!((*ptr).rsi) as usize - ptr as usize },
11886 160usize,
11887 concat!(
11888 "Offset of field: ",
11889 stringify!(hv_x64_exception_intercept_message),
11890 "::",
11891 stringify!(rsi)
11892 )
11893 );
11894 assert_eq!(
11895 unsafe { ::std::ptr::addr_of!((*ptr).rdi) as usize - ptr as usize },
11896 168usize,
11897 concat!(
11898 "Offset of field: ",
11899 stringify!(hv_x64_exception_intercept_message),
11900 "::",
11901 stringify!(rdi)
11902 )
11903 );
11904 assert_eq!(
11905 unsafe { ::std::ptr::addr_of!((*ptr).r8) as usize - ptr as usize },
11906 176usize,
11907 concat!(
11908 "Offset of field: ",
11909 stringify!(hv_x64_exception_intercept_message),
11910 "::",
11911 stringify!(r8)
11912 )
11913 );
11914 assert_eq!(
11915 unsafe { ::std::ptr::addr_of!((*ptr).r9) as usize - ptr as usize },
11916 184usize,
11917 concat!(
11918 "Offset of field: ",
11919 stringify!(hv_x64_exception_intercept_message),
11920 "::",
11921 stringify!(r9)
11922 )
11923 );
11924 assert_eq!(
11925 unsafe { ::std::ptr::addr_of!((*ptr).r10) as usize - ptr as usize },
11926 192usize,
11927 concat!(
11928 "Offset of field: ",
11929 stringify!(hv_x64_exception_intercept_message),
11930 "::",
11931 stringify!(r10)
11932 )
11933 );
11934 assert_eq!(
11935 unsafe { ::std::ptr::addr_of!((*ptr).r11) as usize - ptr as usize },
11936 200usize,
11937 concat!(
11938 "Offset of field: ",
11939 stringify!(hv_x64_exception_intercept_message),
11940 "::",
11941 stringify!(r11)
11942 )
11943 );
11944 assert_eq!(
11945 unsafe { ::std::ptr::addr_of!((*ptr).r12) as usize - ptr as usize },
11946 208usize,
11947 concat!(
11948 "Offset of field: ",
11949 stringify!(hv_x64_exception_intercept_message),
11950 "::",
11951 stringify!(r12)
11952 )
11953 );
11954 assert_eq!(
11955 unsafe { ::std::ptr::addr_of!((*ptr).r13) as usize - ptr as usize },
11956 216usize,
11957 concat!(
11958 "Offset of field: ",
11959 stringify!(hv_x64_exception_intercept_message),
11960 "::",
11961 stringify!(r13)
11962 )
11963 );
11964 assert_eq!(
11965 unsafe { ::std::ptr::addr_of!((*ptr).r14) as usize - ptr as usize },
11966 224usize,
11967 concat!(
11968 "Offset of field: ",
11969 stringify!(hv_x64_exception_intercept_message),
11970 "::",
11971 stringify!(r14)
11972 )
11973 );
11974 assert_eq!(
11975 unsafe { ::std::ptr::addr_of!((*ptr).r15) as usize - ptr as usize },
11976 232usize,
11977 concat!(
11978 "Offset of field: ",
11979 stringify!(hv_x64_exception_intercept_message),
11980 "::",
11981 stringify!(r15)
11982 )
11983 );
11984}
11985impl Default for hv_x64_exception_intercept_message {
11986 fn default() -> Self {
11987 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
11988 unsafe {
11989 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
11990 s.assume_init()
11991 }
11992 }
11993}
11994#[repr(C, packed)]
11995#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
11996pub struct hv_x64_invalid_vp_register_message {
11997 pub vp_index: __u32,
11998 pub reserved: __u32,
11999}
12000#[test]
12001fn bindgen_test_layout_hv_x64_invalid_vp_register_message() {
12002 const UNINIT: ::std::mem::MaybeUninit<hv_x64_invalid_vp_register_message> =
12003 ::std::mem::MaybeUninit::uninit();
12004 let ptr = UNINIT.as_ptr();
12005 assert_eq!(
12006 ::std::mem::size_of::<hv_x64_invalid_vp_register_message>(),
12007 8usize,
12008 concat!("Size of: ", stringify!(hv_x64_invalid_vp_register_message))
12009 );
12010 assert_eq!(
12011 ::std::mem::align_of::<hv_x64_invalid_vp_register_message>(),
12012 1usize,
12013 concat!(
12014 "Alignment of ",
12015 stringify!(hv_x64_invalid_vp_register_message)
12016 )
12017 );
12018 assert_eq!(
12019 unsafe { ::std::ptr::addr_of!((*ptr).vp_index) as usize - ptr as usize },
12020 0usize,
12021 concat!(
12022 "Offset of field: ",
12023 stringify!(hv_x64_invalid_vp_register_message),
12024 "::",
12025 stringify!(vp_index)
12026 )
12027 );
12028 assert_eq!(
12029 unsafe { ::std::ptr::addr_of!((*ptr).reserved) as usize - ptr as usize },
12030 4usize,
12031 concat!(
12032 "Offset of field: ",
12033 stringify!(hv_x64_invalid_vp_register_message),
12034 "::",
12035 stringify!(reserved)
12036 )
12037 );
12038}
12039#[repr(C, packed)]
12040#[derive(Copy, Clone)]
12041pub struct hv_x64_unrecoverable_exception_message {
12042 pub header: hv_x64_intercept_message_header,
12043}
12044#[test]
12045fn bindgen_test_layout_hv_x64_unrecoverable_exception_message() {
12046 const UNINIT: ::std::mem::MaybeUninit<hv_x64_unrecoverable_exception_message> =
12047 ::std::mem::MaybeUninit::uninit();
12048 let ptr = UNINIT.as_ptr();
12049 assert_eq!(
12050 ::std::mem::size_of::<hv_x64_unrecoverable_exception_message>(),
12051 40usize,
12052 concat!(
12053 "Size of: ",
12054 stringify!(hv_x64_unrecoverable_exception_message)
12055 )
12056 );
12057 assert_eq!(
12058 ::std::mem::align_of::<hv_x64_unrecoverable_exception_message>(),
12059 1usize,
12060 concat!(
12061 "Alignment of ",
12062 stringify!(hv_x64_unrecoverable_exception_message)
12063 )
12064 );
12065 assert_eq!(
12066 unsafe { ::std::ptr::addr_of!((*ptr).header) as usize - ptr as usize },
12067 0usize,
12068 concat!(
12069 "Offset of field: ",
12070 stringify!(hv_x64_unrecoverable_exception_message),
12071 "::",
12072 stringify!(header)
12073 )
12074 );
12075}
12076impl Default for hv_x64_unrecoverable_exception_message {
12077 fn default() -> Self {
12078 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
12079 unsafe {
12080 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
12081 s.assume_init()
12082 }
12083 }
12084}
12085#[repr(C, packed)]
12086#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
12087pub struct hv_x64_unsupported_feature_message {
12088 pub vp_index: __u32,
12089 pub feature_code: __u32,
12090 pub feature_parameter: __u64,
12091}
12092#[test]
12093fn bindgen_test_layout_hv_x64_unsupported_feature_message() {
12094 const UNINIT: ::std::mem::MaybeUninit<hv_x64_unsupported_feature_message> =
12095 ::std::mem::MaybeUninit::uninit();
12096 let ptr = UNINIT.as_ptr();
12097 assert_eq!(
12098 ::std::mem::size_of::<hv_x64_unsupported_feature_message>(),
12099 16usize,
12100 concat!("Size of: ", stringify!(hv_x64_unsupported_feature_message))
12101 );
12102 assert_eq!(
12103 ::std::mem::align_of::<hv_x64_unsupported_feature_message>(),
12104 1usize,
12105 concat!(
12106 "Alignment of ",
12107 stringify!(hv_x64_unsupported_feature_message)
12108 )
12109 );
12110 assert_eq!(
12111 unsafe { ::std::ptr::addr_of!((*ptr).vp_index) as usize - ptr as usize },
12112 0usize,
12113 concat!(
12114 "Offset of field: ",
12115 stringify!(hv_x64_unsupported_feature_message),
12116 "::",
12117 stringify!(vp_index)
12118 )
12119 );
12120 assert_eq!(
12121 unsafe { ::std::ptr::addr_of!((*ptr).feature_code) as usize - ptr as usize },
12122 4usize,
12123 concat!(
12124 "Offset of field: ",
12125 stringify!(hv_x64_unsupported_feature_message),
12126 "::",
12127 stringify!(feature_code)
12128 )
12129 );
12130 assert_eq!(
12131 unsafe { ::std::ptr::addr_of!((*ptr).feature_parameter) as usize - ptr as usize },
12132 8usize,
12133 concat!(
12134 "Offset of field: ",
12135 stringify!(hv_x64_unsupported_feature_message),
12136 "::",
12137 stringify!(feature_parameter)
12138 )
12139 );
12140}
12141#[repr(C, packed)]
12142#[derive(Copy, Clone)]
12143pub struct hv_x64_halt_message {
12144 pub header: hv_x64_intercept_message_header,
12145}
12146#[test]
12147fn bindgen_test_layout_hv_x64_halt_message() {
12148 const UNINIT: ::std::mem::MaybeUninit<hv_x64_halt_message> = ::std::mem::MaybeUninit::uninit();
12149 let ptr = UNINIT.as_ptr();
12150 assert_eq!(
12151 ::std::mem::size_of::<hv_x64_halt_message>(),
12152 40usize,
12153 concat!("Size of: ", stringify!(hv_x64_halt_message))
12154 );
12155 assert_eq!(
12156 ::std::mem::align_of::<hv_x64_halt_message>(),
12157 1usize,
12158 concat!("Alignment of ", stringify!(hv_x64_halt_message))
12159 );
12160 assert_eq!(
12161 unsafe { ::std::ptr::addr_of!((*ptr).header) as usize - ptr as usize },
12162 0usize,
12163 concat!(
12164 "Offset of field: ",
12165 stringify!(hv_x64_halt_message),
12166 "::",
12167 stringify!(header)
12168 )
12169 );
12170}
12171impl Default for hv_x64_halt_message {
12172 fn default() -> Self {
12173 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
12174 unsafe {
12175 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
12176 s.assume_init()
12177 }
12178 }
12179}
12180#[repr(C, packed)]
12181#[derive(Copy, Clone)]
12182pub struct hv_x64_interruption_deliverable_message {
12183 pub header: hv_x64_intercept_message_header,
12184 pub deliverable_type: __u32,
12185 pub rsvd: __u32,
12186}
12187#[test]
12188fn bindgen_test_layout_hv_x64_interruption_deliverable_message() {
12189 const UNINIT: ::std::mem::MaybeUninit<hv_x64_interruption_deliverable_message> =
12190 ::std::mem::MaybeUninit::uninit();
12191 let ptr = UNINIT.as_ptr();
12192 assert_eq!(
12193 ::std::mem::size_of::<hv_x64_interruption_deliverable_message>(),
12194 48usize,
12195 concat!(
12196 "Size of: ",
12197 stringify!(hv_x64_interruption_deliverable_message)
12198 )
12199 );
12200 assert_eq!(
12201 ::std::mem::align_of::<hv_x64_interruption_deliverable_message>(),
12202 1usize,
12203 concat!(
12204 "Alignment of ",
12205 stringify!(hv_x64_interruption_deliverable_message)
12206 )
12207 );
12208 assert_eq!(
12209 unsafe { ::std::ptr::addr_of!((*ptr).header) as usize - ptr as usize },
12210 0usize,
12211 concat!(
12212 "Offset of field: ",
12213 stringify!(hv_x64_interruption_deliverable_message),
12214 "::",
12215 stringify!(header)
12216 )
12217 );
12218 assert_eq!(
12219 unsafe { ::std::ptr::addr_of!((*ptr).deliverable_type) as usize - ptr as usize },
12220 40usize,
12221 concat!(
12222 "Offset of field: ",
12223 stringify!(hv_x64_interruption_deliverable_message),
12224 "::",
12225 stringify!(deliverable_type)
12226 )
12227 );
12228 assert_eq!(
12229 unsafe { ::std::ptr::addr_of!((*ptr).rsvd) as usize - ptr as usize },
12230 44usize,
12231 concat!(
12232 "Offset of field: ",
12233 stringify!(hv_x64_interruption_deliverable_message),
12234 "::",
12235 stringify!(rsvd)
12236 )
12237 );
12238}
12239impl Default for hv_x64_interruption_deliverable_message {
12240 fn default() -> Self {
12241 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
12242 unsafe {
12243 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
12244 s.assume_init()
12245 }
12246 }
12247}
12248#[repr(C, packed)]
12249#[derive(Copy, Clone)]
12250pub struct hv_x64_sint_deliverable_message {
12251 pub header: hv_x64_intercept_message_header,
12252 pub deliverable_sints: __u16,
12253 pub rsvd1: __u16,
12254 pub rsvd2: __u32,
12255}
12256#[test]
12257fn bindgen_test_layout_hv_x64_sint_deliverable_message() {
12258 const UNINIT: ::std::mem::MaybeUninit<hv_x64_sint_deliverable_message> =
12259 ::std::mem::MaybeUninit::uninit();
12260 let ptr = UNINIT.as_ptr();
12261 assert_eq!(
12262 ::std::mem::size_of::<hv_x64_sint_deliverable_message>(),
12263 48usize,
12264 concat!("Size of: ", stringify!(hv_x64_sint_deliverable_message))
12265 );
12266 assert_eq!(
12267 ::std::mem::align_of::<hv_x64_sint_deliverable_message>(),
12268 1usize,
12269 concat!("Alignment of ", stringify!(hv_x64_sint_deliverable_message))
12270 );
12271 assert_eq!(
12272 unsafe { ::std::ptr::addr_of!((*ptr).header) as usize - ptr as usize },
12273 0usize,
12274 concat!(
12275 "Offset of field: ",
12276 stringify!(hv_x64_sint_deliverable_message),
12277 "::",
12278 stringify!(header)
12279 )
12280 );
12281 assert_eq!(
12282 unsafe { ::std::ptr::addr_of!((*ptr).deliverable_sints) as usize - ptr as usize },
12283 40usize,
12284 concat!(
12285 "Offset of field: ",
12286 stringify!(hv_x64_sint_deliverable_message),
12287 "::",
12288 stringify!(deliverable_sints)
12289 )
12290 );
12291 assert_eq!(
12292 unsafe { ::std::ptr::addr_of!((*ptr).rsvd1) as usize - ptr as usize },
12293 42usize,
12294 concat!(
12295 "Offset of field: ",
12296 stringify!(hv_x64_sint_deliverable_message),
12297 "::",
12298 stringify!(rsvd1)
12299 )
12300 );
12301 assert_eq!(
12302 unsafe { ::std::ptr::addr_of!((*ptr).rsvd2) as usize - ptr as usize },
12303 44usize,
12304 concat!(
12305 "Offset of field: ",
12306 stringify!(hv_x64_sint_deliverable_message),
12307 "::",
12308 stringify!(rsvd2)
12309 )
12310 );
12311}
12312impl Default for hv_x64_sint_deliverable_message {
12313 fn default() -> Self {
12314 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
12315 unsafe {
12316 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
12317 s.assume_init()
12318 }
12319 }
12320}
12321#[repr(C, packed)]
12322#[derive(Copy, Clone)]
12323pub struct hv_x64_sipi_intercept_message {
12324 pub header: hv_x64_intercept_message_header,
12325 pub target_vp_index: __u32,
12326 pub interrupt_vector: __u32,
12327}
12328#[test]
12329fn bindgen_test_layout_hv_x64_sipi_intercept_message() {
12330 const UNINIT: ::std::mem::MaybeUninit<hv_x64_sipi_intercept_message> =
12331 ::std::mem::MaybeUninit::uninit();
12332 let ptr = UNINIT.as_ptr();
12333 assert_eq!(
12334 ::std::mem::size_of::<hv_x64_sipi_intercept_message>(),
12335 48usize,
12336 concat!("Size of: ", stringify!(hv_x64_sipi_intercept_message))
12337 );
12338 assert_eq!(
12339 ::std::mem::align_of::<hv_x64_sipi_intercept_message>(),
12340 1usize,
12341 concat!("Alignment of ", stringify!(hv_x64_sipi_intercept_message))
12342 );
12343 assert_eq!(
12344 unsafe { ::std::ptr::addr_of!((*ptr).header) as usize - ptr as usize },
12345 0usize,
12346 concat!(
12347 "Offset of field: ",
12348 stringify!(hv_x64_sipi_intercept_message),
12349 "::",
12350 stringify!(header)
12351 )
12352 );
12353 assert_eq!(
12354 unsafe { ::std::ptr::addr_of!((*ptr).target_vp_index) as usize - ptr as usize },
12355 40usize,
12356 concat!(
12357 "Offset of field: ",
12358 stringify!(hv_x64_sipi_intercept_message),
12359 "::",
12360 stringify!(target_vp_index)
12361 )
12362 );
12363 assert_eq!(
12364 unsafe { ::std::ptr::addr_of!((*ptr).interrupt_vector) as usize - ptr as usize },
12365 44usize,
12366 concat!(
12367 "Offset of field: ",
12368 stringify!(hv_x64_sipi_intercept_message),
12369 "::",
12370 stringify!(interrupt_vector)
12371 )
12372 );
12373}
12374impl Default for hv_x64_sipi_intercept_message {
12375 fn default() -> Self {
12376 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
12377 unsafe {
12378 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
12379 s.assume_init()
12380 }
12381 }
12382}
12383#[repr(C, packed)]
12384#[derive(Copy, Clone)]
12385pub struct hv_x64_gpa_attribute_intercept_message {
12386 pub vp_index: __u32,
12387 pub __bindgen_anon_1: hv_x64_gpa_attribute_intercept_message__bindgen_ty_1,
12388 pub ranges: [hv_gpa_page_range; 29usize],
12389}
12390#[repr(C, packed)]
12391#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
12392pub struct hv_x64_gpa_attribute_intercept_message__bindgen_ty_1 {
12393 pub _bitfield_align_1: [u8; 0],
12394 pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize]>,
12395}
12396#[test]
12397fn bindgen_test_layout_hv_x64_gpa_attribute_intercept_message__bindgen_ty_1() {
12398 assert_eq!(
12399 ::std::mem::size_of::<hv_x64_gpa_attribute_intercept_message__bindgen_ty_1>(),
12400 4usize,
12401 concat!(
12402 "Size of: ",
12403 stringify!(hv_x64_gpa_attribute_intercept_message__bindgen_ty_1)
12404 )
12405 );
12406 assert_eq!(
12407 ::std::mem::align_of::<hv_x64_gpa_attribute_intercept_message__bindgen_ty_1>(),
12408 1usize,
12409 concat!(
12410 "Alignment of ",
12411 stringify!(hv_x64_gpa_attribute_intercept_message__bindgen_ty_1)
12412 )
12413 );
12414}
12415impl hv_x64_gpa_attribute_intercept_message__bindgen_ty_1 {
12416 #[inline]
12417 pub fn range_count(&self) -> __u32 {
12418 unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 5u8) as u32) }
12419 }
12420 #[inline]
12421 pub fn set_range_count(&mut self, val: __u32) {
12422 unsafe {
12423 let val: u32 = ::std::mem::transmute(val);
12424 self._bitfield_1.set(0usize, 5u8, val as u64)
12425 }
12426 }
12427 #[inline]
12428 pub fn adjust(&self) -> __u32 {
12429 unsafe { ::std::mem::transmute(self._bitfield_1.get(5usize, 1u8) as u32) }
12430 }
12431 #[inline]
12432 pub fn set_adjust(&mut self, val: __u32) {
12433 unsafe {
12434 let val: u32 = ::std::mem::transmute(val);
12435 self._bitfield_1.set(5usize, 1u8, val as u64)
12436 }
12437 }
12438 #[inline]
12439 pub fn host_visibility(&self) -> __u32 {
12440 unsafe { ::std::mem::transmute(self._bitfield_1.get(6usize, 2u8) as u32) }
12441 }
12442 #[inline]
12443 pub fn set_host_visibility(&mut self, val: __u32) {
12444 unsafe {
12445 let val: u32 = ::std::mem::transmute(val);
12446 self._bitfield_1.set(6usize, 2u8, val as u64)
12447 }
12448 }
12449 #[inline]
12450 pub fn memory_type(&self) -> __u32 {
12451 unsafe { ::std::mem::transmute(self._bitfield_1.get(8usize, 6u8) as u32) }
12452 }
12453 #[inline]
12454 pub fn set_memory_type(&mut self, val: __u32) {
12455 unsafe {
12456 let val: u32 = ::std::mem::transmute(val);
12457 self._bitfield_1.set(8usize, 6u8, val as u64)
12458 }
12459 }
12460 #[inline]
12461 pub fn reserved(&self) -> __u32 {
12462 unsafe { ::std::mem::transmute(self._bitfield_1.get(14usize, 18u8) as u32) }
12463 }
12464 #[inline]
12465 pub fn set_reserved(&mut self, val: __u32) {
12466 unsafe {
12467 let val: u32 = ::std::mem::transmute(val);
12468 self._bitfield_1.set(14usize, 18u8, val as u64)
12469 }
12470 }
12471 #[inline]
12472 pub fn new_bitfield_1(
12473 range_count: __u32,
12474 adjust: __u32,
12475 host_visibility: __u32,
12476 memory_type: __u32,
12477 reserved: __u32,
12478 ) -> __BindgenBitfieldUnit<[u8; 4usize]> {
12479 let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 4usize]> = Default::default();
12480 __bindgen_bitfield_unit.set(0usize, 5u8, {
12481 let range_count: u32 = unsafe { ::std::mem::transmute(range_count) };
12482 range_count as u64
12483 });
12484 __bindgen_bitfield_unit.set(5usize, 1u8, {
12485 let adjust: u32 = unsafe { ::std::mem::transmute(adjust) };
12486 adjust as u64
12487 });
12488 __bindgen_bitfield_unit.set(6usize, 2u8, {
12489 let host_visibility: u32 = unsafe { ::std::mem::transmute(host_visibility) };
12490 host_visibility as u64
12491 });
12492 __bindgen_bitfield_unit.set(8usize, 6u8, {
12493 let memory_type: u32 = unsafe { ::std::mem::transmute(memory_type) };
12494 memory_type as u64
12495 });
12496 __bindgen_bitfield_unit.set(14usize, 18u8, {
12497 let reserved: u32 = unsafe { ::std::mem::transmute(reserved) };
12498 reserved as u64
12499 });
12500 __bindgen_bitfield_unit
12501 }
12502}
12503#[test]
12504fn bindgen_test_layout_hv_x64_gpa_attribute_intercept_message() {
12505 const UNINIT: ::std::mem::MaybeUninit<hv_x64_gpa_attribute_intercept_message> =
12506 ::std::mem::MaybeUninit::uninit();
12507 let ptr = UNINIT.as_ptr();
12508 assert_eq!(
12509 ::std::mem::size_of::<hv_x64_gpa_attribute_intercept_message>(),
12510 240usize,
12511 concat!(
12512 "Size of: ",
12513 stringify!(hv_x64_gpa_attribute_intercept_message)
12514 )
12515 );
12516 assert_eq!(
12517 ::std::mem::align_of::<hv_x64_gpa_attribute_intercept_message>(),
12518 1usize,
12519 concat!(
12520 "Alignment of ",
12521 stringify!(hv_x64_gpa_attribute_intercept_message)
12522 )
12523 );
12524 assert_eq!(
12525 unsafe { ::std::ptr::addr_of!((*ptr).vp_index) as usize - ptr as usize },
12526 0usize,
12527 concat!(
12528 "Offset of field: ",
12529 stringify!(hv_x64_gpa_attribute_intercept_message),
12530 "::",
12531 stringify!(vp_index)
12532 )
12533 );
12534 assert_eq!(
12535 unsafe { ::std::ptr::addr_of!((*ptr).ranges) as usize - ptr as usize },
12536 8usize,
12537 concat!(
12538 "Offset of field: ",
12539 stringify!(hv_x64_gpa_attribute_intercept_message),
12540 "::",
12541 stringify!(ranges)
12542 )
12543 );
12544}
12545impl Default for hv_x64_gpa_attribute_intercept_message {
12546 fn default() -> Self {
12547 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
12548 unsafe {
12549 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
12550 s.assume_init()
12551 }
12552 }
12553}
12554#[repr(C, packed)]
12555#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
12556pub struct hv_register_x64_cpuid_result_parameters {
12557 pub input: hv_register_x64_cpuid_result_parameters__bindgen_ty_1,
12558 pub result: hv_register_x64_cpuid_result_parameters__bindgen_ty_2,
12559}
12560#[repr(C, packed)]
12561#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
12562pub struct hv_register_x64_cpuid_result_parameters__bindgen_ty_1 {
12563 pub eax: __u32,
12564 pub ecx: __u32,
12565 pub subleaf_specific: __u8,
12566 pub always_override: __u8,
12567 pub padding: __u16,
12568}
12569#[test]
12570fn bindgen_test_layout_hv_register_x64_cpuid_result_parameters__bindgen_ty_1() {
12571 const UNINIT: ::std::mem::MaybeUninit<hv_register_x64_cpuid_result_parameters__bindgen_ty_1> =
12572 ::std::mem::MaybeUninit::uninit();
12573 let ptr = UNINIT.as_ptr();
12574 assert_eq!(
12575 ::std::mem::size_of::<hv_register_x64_cpuid_result_parameters__bindgen_ty_1>(),
12576 12usize,
12577 concat!(
12578 "Size of: ",
12579 stringify!(hv_register_x64_cpuid_result_parameters__bindgen_ty_1)
12580 )
12581 );
12582 assert_eq!(
12583 ::std::mem::align_of::<hv_register_x64_cpuid_result_parameters__bindgen_ty_1>(),
12584 1usize,
12585 concat!(
12586 "Alignment of ",
12587 stringify!(hv_register_x64_cpuid_result_parameters__bindgen_ty_1)
12588 )
12589 );
12590 assert_eq!(
12591 unsafe { ::std::ptr::addr_of!((*ptr).eax) as usize - ptr as usize },
12592 0usize,
12593 concat!(
12594 "Offset of field: ",
12595 stringify!(hv_register_x64_cpuid_result_parameters__bindgen_ty_1),
12596 "::",
12597 stringify!(eax)
12598 )
12599 );
12600 assert_eq!(
12601 unsafe { ::std::ptr::addr_of!((*ptr).ecx) as usize - ptr as usize },
12602 4usize,
12603 concat!(
12604 "Offset of field: ",
12605 stringify!(hv_register_x64_cpuid_result_parameters__bindgen_ty_1),
12606 "::",
12607 stringify!(ecx)
12608 )
12609 );
12610 assert_eq!(
12611 unsafe { ::std::ptr::addr_of!((*ptr).subleaf_specific) as usize - ptr as usize },
12612 8usize,
12613 concat!(
12614 "Offset of field: ",
12615 stringify!(hv_register_x64_cpuid_result_parameters__bindgen_ty_1),
12616 "::",
12617 stringify!(subleaf_specific)
12618 )
12619 );
12620 assert_eq!(
12621 unsafe { ::std::ptr::addr_of!((*ptr).always_override) as usize - ptr as usize },
12622 9usize,
12623 concat!(
12624 "Offset of field: ",
12625 stringify!(hv_register_x64_cpuid_result_parameters__bindgen_ty_1),
12626 "::",
12627 stringify!(always_override)
12628 )
12629 );
12630 assert_eq!(
12631 unsafe { ::std::ptr::addr_of!((*ptr).padding) as usize - ptr as usize },
12632 10usize,
12633 concat!(
12634 "Offset of field: ",
12635 stringify!(hv_register_x64_cpuid_result_parameters__bindgen_ty_1),
12636 "::",
12637 stringify!(padding)
12638 )
12639 );
12640}
12641#[repr(C, packed)]
12642#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
12643pub struct hv_register_x64_cpuid_result_parameters__bindgen_ty_2 {
12644 pub eax: __u32,
12645 pub eax_mask: __u32,
12646 pub ebx: __u32,
12647 pub ebx_mask: __u32,
12648 pub ecx: __u32,
12649 pub ecx_mask: __u32,
12650 pub edx: __u32,
12651 pub edx_mask: __u32,
12652}
12653#[test]
12654fn bindgen_test_layout_hv_register_x64_cpuid_result_parameters__bindgen_ty_2() {
12655 const UNINIT: ::std::mem::MaybeUninit<hv_register_x64_cpuid_result_parameters__bindgen_ty_2> =
12656 ::std::mem::MaybeUninit::uninit();
12657 let ptr = UNINIT.as_ptr();
12658 assert_eq!(
12659 ::std::mem::size_of::<hv_register_x64_cpuid_result_parameters__bindgen_ty_2>(),
12660 32usize,
12661 concat!(
12662 "Size of: ",
12663 stringify!(hv_register_x64_cpuid_result_parameters__bindgen_ty_2)
12664 )
12665 );
12666 assert_eq!(
12667 ::std::mem::align_of::<hv_register_x64_cpuid_result_parameters__bindgen_ty_2>(),
12668 1usize,
12669 concat!(
12670 "Alignment of ",
12671 stringify!(hv_register_x64_cpuid_result_parameters__bindgen_ty_2)
12672 )
12673 );
12674 assert_eq!(
12675 unsafe { ::std::ptr::addr_of!((*ptr).eax) as usize - ptr as usize },
12676 0usize,
12677 concat!(
12678 "Offset of field: ",
12679 stringify!(hv_register_x64_cpuid_result_parameters__bindgen_ty_2),
12680 "::",
12681 stringify!(eax)
12682 )
12683 );
12684 assert_eq!(
12685 unsafe { ::std::ptr::addr_of!((*ptr).eax_mask) as usize - ptr as usize },
12686 4usize,
12687 concat!(
12688 "Offset of field: ",
12689 stringify!(hv_register_x64_cpuid_result_parameters__bindgen_ty_2),
12690 "::",
12691 stringify!(eax_mask)
12692 )
12693 );
12694 assert_eq!(
12695 unsafe { ::std::ptr::addr_of!((*ptr).ebx) as usize - ptr as usize },
12696 8usize,
12697 concat!(
12698 "Offset of field: ",
12699 stringify!(hv_register_x64_cpuid_result_parameters__bindgen_ty_2),
12700 "::",
12701 stringify!(ebx)
12702 )
12703 );
12704 assert_eq!(
12705 unsafe { ::std::ptr::addr_of!((*ptr).ebx_mask) as usize - ptr as usize },
12706 12usize,
12707 concat!(
12708 "Offset of field: ",
12709 stringify!(hv_register_x64_cpuid_result_parameters__bindgen_ty_2),
12710 "::",
12711 stringify!(ebx_mask)
12712 )
12713 );
12714 assert_eq!(
12715 unsafe { ::std::ptr::addr_of!((*ptr).ecx) as usize - ptr as usize },
12716 16usize,
12717 concat!(
12718 "Offset of field: ",
12719 stringify!(hv_register_x64_cpuid_result_parameters__bindgen_ty_2),
12720 "::",
12721 stringify!(ecx)
12722 )
12723 );
12724 assert_eq!(
12725 unsafe { ::std::ptr::addr_of!((*ptr).ecx_mask) as usize - ptr as usize },
12726 20usize,
12727 concat!(
12728 "Offset of field: ",
12729 stringify!(hv_register_x64_cpuid_result_parameters__bindgen_ty_2),
12730 "::",
12731 stringify!(ecx_mask)
12732 )
12733 );
12734 assert_eq!(
12735 unsafe { ::std::ptr::addr_of!((*ptr).edx) as usize - ptr as usize },
12736 24usize,
12737 concat!(
12738 "Offset of field: ",
12739 stringify!(hv_register_x64_cpuid_result_parameters__bindgen_ty_2),
12740 "::",
12741 stringify!(edx)
12742 )
12743 );
12744 assert_eq!(
12745 unsafe { ::std::ptr::addr_of!((*ptr).edx_mask) as usize - ptr as usize },
12746 28usize,
12747 concat!(
12748 "Offset of field: ",
12749 stringify!(hv_register_x64_cpuid_result_parameters__bindgen_ty_2),
12750 "::",
12751 stringify!(edx_mask)
12752 )
12753 );
12754}
12755#[test]
12756fn bindgen_test_layout_hv_register_x64_cpuid_result_parameters() {
12757 const UNINIT: ::std::mem::MaybeUninit<hv_register_x64_cpuid_result_parameters> =
12758 ::std::mem::MaybeUninit::uninit();
12759 let ptr = UNINIT.as_ptr();
12760 assert_eq!(
12761 ::std::mem::size_of::<hv_register_x64_cpuid_result_parameters>(),
12762 44usize,
12763 concat!(
12764 "Size of: ",
12765 stringify!(hv_register_x64_cpuid_result_parameters)
12766 )
12767 );
12768 assert_eq!(
12769 ::std::mem::align_of::<hv_register_x64_cpuid_result_parameters>(),
12770 1usize,
12771 concat!(
12772 "Alignment of ",
12773 stringify!(hv_register_x64_cpuid_result_parameters)
12774 )
12775 );
12776 assert_eq!(
12777 unsafe { ::std::ptr::addr_of!((*ptr).input) as usize - ptr as usize },
12778 0usize,
12779 concat!(
12780 "Offset of field: ",
12781 stringify!(hv_register_x64_cpuid_result_parameters),
12782 "::",
12783 stringify!(input)
12784 )
12785 );
12786 assert_eq!(
12787 unsafe { ::std::ptr::addr_of!((*ptr).result) as usize - ptr as usize },
12788 12usize,
12789 concat!(
12790 "Offset of field: ",
12791 stringify!(hv_register_x64_cpuid_result_parameters),
12792 "::",
12793 stringify!(result)
12794 )
12795 );
12796}
12797#[repr(C, packed)]
12798#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
12799pub struct hv_register_x64_msr_result_parameters {
12800 pub msr_index: __u32,
12801 pub access_type: __u32,
12802 pub action: __u32,
12803}
12804#[test]
12805fn bindgen_test_layout_hv_register_x64_msr_result_parameters() {
12806 const UNINIT: ::std::mem::MaybeUninit<hv_register_x64_msr_result_parameters> =
12807 ::std::mem::MaybeUninit::uninit();
12808 let ptr = UNINIT.as_ptr();
12809 assert_eq!(
12810 ::std::mem::size_of::<hv_register_x64_msr_result_parameters>(),
12811 12usize,
12812 concat!(
12813 "Size of: ",
12814 stringify!(hv_register_x64_msr_result_parameters)
12815 )
12816 );
12817 assert_eq!(
12818 ::std::mem::align_of::<hv_register_x64_msr_result_parameters>(),
12819 1usize,
12820 concat!(
12821 "Alignment of ",
12822 stringify!(hv_register_x64_msr_result_parameters)
12823 )
12824 );
12825 assert_eq!(
12826 unsafe { ::std::ptr::addr_of!((*ptr).msr_index) as usize - ptr as usize },
12827 0usize,
12828 concat!(
12829 "Offset of field: ",
12830 stringify!(hv_register_x64_msr_result_parameters),
12831 "::",
12832 stringify!(msr_index)
12833 )
12834 );
12835 assert_eq!(
12836 unsafe { ::std::ptr::addr_of!((*ptr).access_type) as usize - ptr as usize },
12837 4usize,
12838 concat!(
12839 "Offset of field: ",
12840 stringify!(hv_register_x64_msr_result_parameters),
12841 "::",
12842 stringify!(access_type)
12843 )
12844 );
12845 assert_eq!(
12846 unsafe { ::std::ptr::addr_of!((*ptr).action) as usize - ptr as usize },
12847 8usize,
12848 concat!(
12849 "Offset of field: ",
12850 stringify!(hv_register_x64_msr_result_parameters),
12851 "::",
12852 stringify!(action)
12853 )
12854 );
12855}
12856#[repr(C, packed)]
12857#[derive(Copy, Clone)]
12858pub union hv_register_intercept_result_parameters {
12859 pub cpuid: hv_register_x64_cpuid_result_parameters,
12860 pub msr: hv_register_x64_msr_result_parameters,
12861}
12862#[test]
12863fn bindgen_test_layout_hv_register_intercept_result_parameters() {
12864 const UNINIT: ::std::mem::MaybeUninit<hv_register_intercept_result_parameters> =
12865 ::std::mem::MaybeUninit::uninit();
12866 let ptr = UNINIT.as_ptr();
12867 assert_eq!(
12868 ::std::mem::size_of::<hv_register_intercept_result_parameters>(),
12869 44usize,
12870 concat!(
12871 "Size of: ",
12872 stringify!(hv_register_intercept_result_parameters)
12873 )
12874 );
12875 assert_eq!(
12876 ::std::mem::align_of::<hv_register_intercept_result_parameters>(),
12877 1usize,
12878 concat!(
12879 "Alignment of ",
12880 stringify!(hv_register_intercept_result_parameters)
12881 )
12882 );
12883 assert_eq!(
12884 unsafe { ::std::ptr::addr_of!((*ptr).cpuid) as usize - ptr as usize },
12885 0usize,
12886 concat!(
12887 "Offset of field: ",
12888 stringify!(hv_register_intercept_result_parameters),
12889 "::",
12890 stringify!(cpuid)
12891 )
12892 );
12893 assert_eq!(
12894 unsafe { ::std::ptr::addr_of!((*ptr).msr) as usize - ptr as usize },
12895 0usize,
12896 concat!(
12897 "Offset of field: ",
12898 stringify!(hv_register_intercept_result_parameters),
12899 "::",
12900 stringify!(msr)
12901 )
12902 );
12903}
12904impl Default for hv_register_intercept_result_parameters {
12905 fn default() -> Self {
12906 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
12907 unsafe {
12908 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
12909 s.assume_init()
12910 }
12911 }
12912}
12913#[repr(C, packed)]
12914#[derive(Copy, Clone)]
12915pub struct hv_x64_vmgexit_intercept_message {
12916 pub header: hv_x64_intercept_message_header,
12917 pub ghcb_msr: __u64,
12918 pub __bindgen_anon_1: hv_x64_vmgexit_intercept_message__bindgen_ty_1,
12919 pub __bindgen_anon_2: hv_x64_vmgexit_intercept_message__bindgen_ty_2,
12920}
12921#[repr(C, packed)]
12922#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
12923pub struct hv_x64_vmgexit_intercept_message__bindgen_ty_1 {
12924 pub _bitfield_align_1: [u8; 0],
12925 pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>,
12926}
12927#[test]
12928fn bindgen_test_layout_hv_x64_vmgexit_intercept_message__bindgen_ty_1() {
12929 assert_eq!(
12930 ::std::mem::size_of::<hv_x64_vmgexit_intercept_message__bindgen_ty_1>(),
12931 8usize,
12932 concat!(
12933 "Size of: ",
12934 stringify!(hv_x64_vmgexit_intercept_message__bindgen_ty_1)
12935 )
12936 );
12937 assert_eq!(
12938 ::std::mem::align_of::<hv_x64_vmgexit_intercept_message__bindgen_ty_1>(),
12939 1usize,
12940 concat!(
12941 "Alignment of ",
12942 stringify!(hv_x64_vmgexit_intercept_message__bindgen_ty_1)
12943 )
12944 );
12945}
12946impl hv_x64_vmgexit_intercept_message__bindgen_ty_1 {
12947 #[inline]
12948 pub fn ghcb_page_valid(&self) -> __u64 {
12949 unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 1u8) as u64) }
12950 }
12951 #[inline]
12952 pub fn set_ghcb_page_valid(&mut self, val: __u64) {
12953 unsafe {
12954 let val: u64 = ::std::mem::transmute(val);
12955 self._bitfield_1.set(0usize, 1u8, val as u64)
12956 }
12957 }
12958 #[inline]
12959 pub fn reserved(&self) -> __u64 {
12960 unsafe { ::std::mem::transmute(self._bitfield_1.get(1usize, 63u8) as u64) }
12961 }
12962 #[inline]
12963 pub fn set_reserved(&mut self, val: __u64) {
12964 unsafe {
12965 let val: u64 = ::std::mem::transmute(val);
12966 self._bitfield_1.set(1usize, 63u8, val as u64)
12967 }
12968 }
12969 #[inline]
12970 pub fn new_bitfield_1(
12971 ghcb_page_valid: __u64,
12972 reserved: __u64,
12973 ) -> __BindgenBitfieldUnit<[u8; 8usize]> {
12974 let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 8usize]> = Default::default();
12975 __bindgen_bitfield_unit.set(0usize, 1u8, {
12976 let ghcb_page_valid: u64 = unsafe { ::std::mem::transmute(ghcb_page_valid) };
12977 ghcb_page_valid as u64
12978 });
12979 __bindgen_bitfield_unit.set(1usize, 63u8, {
12980 let reserved: u64 = unsafe { ::std::mem::transmute(reserved) };
12981 reserved as u64
12982 });
12983 __bindgen_bitfield_unit
12984 }
12985}
12986#[repr(C, packed)]
12987#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
12988pub struct hv_x64_vmgexit_intercept_message__bindgen_ty_2 {
12989 pub ghcb_usage: __u32,
12990 pub rserved_ghcb_page: __u32,
12991 pub __bindgen_anon_1: hv_x64_vmgexit_intercept_message__bindgen_ty_2__bindgen_ty_1,
12992}
12993#[repr(C, packed)]
12994#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
12995pub struct hv_x64_vmgexit_intercept_message__bindgen_ty_2__bindgen_ty_1 {
12996 pub ghcb_protocol_version: __u16,
12997 pub reserved_st: [__u16; 3usize],
12998 pub sw_exit_code: __u64,
12999 pub sw_exit_info1: __u64,
13000 pub sw_exit_info2: __u64,
13001 pub sw_scratch: __u64,
13002}
13003#[test]
13004fn bindgen_test_layout_hv_x64_vmgexit_intercept_message__bindgen_ty_2__bindgen_ty_1() {
13005 const UNINIT: ::std::mem::MaybeUninit<
13006 hv_x64_vmgexit_intercept_message__bindgen_ty_2__bindgen_ty_1,
13007 > = ::std::mem::MaybeUninit::uninit();
13008 let ptr = UNINIT.as_ptr();
13009 assert_eq!(
13010 ::std::mem::size_of::<hv_x64_vmgexit_intercept_message__bindgen_ty_2__bindgen_ty_1>(),
13011 40usize,
13012 concat!(
13013 "Size of: ",
13014 stringify!(hv_x64_vmgexit_intercept_message__bindgen_ty_2__bindgen_ty_1)
13015 )
13016 );
13017 assert_eq!(
13018 ::std::mem::align_of::<hv_x64_vmgexit_intercept_message__bindgen_ty_2__bindgen_ty_1>(),
13019 1usize,
13020 concat!(
13021 "Alignment of ",
13022 stringify!(hv_x64_vmgexit_intercept_message__bindgen_ty_2__bindgen_ty_1)
13023 )
13024 );
13025 assert_eq!(
13026 unsafe { ::std::ptr::addr_of!((*ptr).ghcb_protocol_version) as usize - ptr as usize },
13027 0usize,
13028 concat!(
13029 "Offset of field: ",
13030 stringify!(hv_x64_vmgexit_intercept_message__bindgen_ty_2__bindgen_ty_1),
13031 "::",
13032 stringify!(ghcb_protocol_version)
13033 )
13034 );
13035 assert_eq!(
13036 unsafe { ::std::ptr::addr_of!((*ptr).reserved_st) as usize - ptr as usize },
13037 2usize,
13038 concat!(
13039 "Offset of field: ",
13040 stringify!(hv_x64_vmgexit_intercept_message__bindgen_ty_2__bindgen_ty_1),
13041 "::",
13042 stringify!(reserved_st)
13043 )
13044 );
13045 assert_eq!(
13046 unsafe { ::std::ptr::addr_of!((*ptr).sw_exit_code) as usize - ptr as usize },
13047 8usize,
13048 concat!(
13049 "Offset of field: ",
13050 stringify!(hv_x64_vmgexit_intercept_message__bindgen_ty_2__bindgen_ty_1),
13051 "::",
13052 stringify!(sw_exit_code)
13053 )
13054 );
13055 assert_eq!(
13056 unsafe { ::std::ptr::addr_of!((*ptr).sw_exit_info1) as usize - ptr as usize },
13057 16usize,
13058 concat!(
13059 "Offset of field: ",
13060 stringify!(hv_x64_vmgexit_intercept_message__bindgen_ty_2__bindgen_ty_1),
13061 "::",
13062 stringify!(sw_exit_info1)
13063 )
13064 );
13065 assert_eq!(
13066 unsafe { ::std::ptr::addr_of!((*ptr).sw_exit_info2) as usize - ptr as usize },
13067 24usize,
13068 concat!(
13069 "Offset of field: ",
13070 stringify!(hv_x64_vmgexit_intercept_message__bindgen_ty_2__bindgen_ty_1),
13071 "::",
13072 stringify!(sw_exit_info2)
13073 )
13074 );
13075 assert_eq!(
13076 unsafe { ::std::ptr::addr_of!((*ptr).sw_scratch) as usize - ptr as usize },
13077 32usize,
13078 concat!(
13079 "Offset of field: ",
13080 stringify!(hv_x64_vmgexit_intercept_message__bindgen_ty_2__bindgen_ty_1),
13081 "::",
13082 stringify!(sw_scratch)
13083 )
13084 );
13085}
13086#[test]
13087fn bindgen_test_layout_hv_x64_vmgexit_intercept_message__bindgen_ty_2() {
13088 const UNINIT: ::std::mem::MaybeUninit<hv_x64_vmgexit_intercept_message__bindgen_ty_2> =
13089 ::std::mem::MaybeUninit::uninit();
13090 let ptr = UNINIT.as_ptr();
13091 assert_eq!(
13092 ::std::mem::size_of::<hv_x64_vmgexit_intercept_message__bindgen_ty_2>(),
13093 48usize,
13094 concat!(
13095 "Size of: ",
13096 stringify!(hv_x64_vmgexit_intercept_message__bindgen_ty_2)
13097 )
13098 );
13099 assert_eq!(
13100 ::std::mem::align_of::<hv_x64_vmgexit_intercept_message__bindgen_ty_2>(),
13101 1usize,
13102 concat!(
13103 "Alignment of ",
13104 stringify!(hv_x64_vmgexit_intercept_message__bindgen_ty_2)
13105 )
13106 );
13107 assert_eq!(
13108 unsafe { ::std::ptr::addr_of!((*ptr).ghcb_usage) as usize - ptr as usize },
13109 0usize,
13110 concat!(
13111 "Offset of field: ",
13112 stringify!(hv_x64_vmgexit_intercept_message__bindgen_ty_2),
13113 "::",
13114 stringify!(ghcb_usage)
13115 )
13116 );
13117 assert_eq!(
13118 unsafe { ::std::ptr::addr_of!((*ptr).rserved_ghcb_page) as usize - ptr as usize },
13119 4usize,
13120 concat!(
13121 "Offset of field: ",
13122 stringify!(hv_x64_vmgexit_intercept_message__bindgen_ty_2),
13123 "::",
13124 stringify!(rserved_ghcb_page)
13125 )
13126 );
13127}
13128#[test]
13129fn bindgen_test_layout_hv_x64_vmgexit_intercept_message() {
13130 const UNINIT: ::std::mem::MaybeUninit<hv_x64_vmgexit_intercept_message> =
13131 ::std::mem::MaybeUninit::uninit();
13132 let ptr = UNINIT.as_ptr();
13133 assert_eq!(
13134 ::std::mem::size_of::<hv_x64_vmgexit_intercept_message>(),
13135 104usize,
13136 concat!("Size of: ", stringify!(hv_x64_vmgexit_intercept_message))
13137 );
13138 assert_eq!(
13139 ::std::mem::align_of::<hv_x64_vmgexit_intercept_message>(),
13140 1usize,
13141 concat!(
13142 "Alignment of ",
13143 stringify!(hv_x64_vmgexit_intercept_message)
13144 )
13145 );
13146 assert_eq!(
13147 unsafe { ::std::ptr::addr_of!((*ptr).header) as usize - ptr as usize },
13148 0usize,
13149 concat!(
13150 "Offset of field: ",
13151 stringify!(hv_x64_vmgexit_intercept_message),
13152 "::",
13153 stringify!(header)
13154 )
13155 );
13156 assert_eq!(
13157 unsafe { ::std::ptr::addr_of!((*ptr).ghcb_msr) as usize - ptr as usize },
13158 40usize,
13159 concat!(
13160 "Offset of field: ",
13161 stringify!(hv_x64_vmgexit_intercept_message),
13162 "::",
13163 stringify!(ghcb_msr)
13164 )
13165 );
13166}
13167impl Default for hv_x64_vmgexit_intercept_message {
13168 fn default() -> Self {
13169 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
13170 unsafe {
13171 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
13172 s.assume_init()
13173 }
13174 }
13175}
13176#[repr(C, packed)]
13177#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
13178pub struct hv_input_translate_virtual_address {
13179 pub partition_id: __u64,
13180 pub vp_index: __u32,
13181 pub padding: __u32,
13182 pub control_flags: __u64,
13183 pub gva_page: __u64,
13184}
13185#[test]
13186fn bindgen_test_layout_hv_input_translate_virtual_address() {
13187 const UNINIT: ::std::mem::MaybeUninit<hv_input_translate_virtual_address> =
13188 ::std::mem::MaybeUninit::uninit();
13189 let ptr = UNINIT.as_ptr();
13190 assert_eq!(
13191 ::std::mem::size_of::<hv_input_translate_virtual_address>(),
13192 32usize,
13193 concat!("Size of: ", stringify!(hv_input_translate_virtual_address))
13194 );
13195 assert_eq!(
13196 ::std::mem::align_of::<hv_input_translate_virtual_address>(),
13197 1usize,
13198 concat!(
13199 "Alignment of ",
13200 stringify!(hv_input_translate_virtual_address)
13201 )
13202 );
13203 assert_eq!(
13204 unsafe { ::std::ptr::addr_of!((*ptr).partition_id) as usize - ptr as usize },
13205 0usize,
13206 concat!(
13207 "Offset of field: ",
13208 stringify!(hv_input_translate_virtual_address),
13209 "::",
13210 stringify!(partition_id)
13211 )
13212 );
13213 assert_eq!(
13214 unsafe { ::std::ptr::addr_of!((*ptr).vp_index) as usize - ptr as usize },
13215 8usize,
13216 concat!(
13217 "Offset of field: ",
13218 stringify!(hv_input_translate_virtual_address),
13219 "::",
13220 stringify!(vp_index)
13221 )
13222 );
13223 assert_eq!(
13224 unsafe { ::std::ptr::addr_of!((*ptr).padding) as usize - ptr as usize },
13225 12usize,
13226 concat!(
13227 "Offset of field: ",
13228 stringify!(hv_input_translate_virtual_address),
13229 "::",
13230 stringify!(padding)
13231 )
13232 );
13233 assert_eq!(
13234 unsafe { ::std::ptr::addr_of!((*ptr).control_flags) as usize - ptr as usize },
13235 16usize,
13236 concat!(
13237 "Offset of field: ",
13238 stringify!(hv_input_translate_virtual_address),
13239 "::",
13240 stringify!(control_flags)
13241 )
13242 );
13243 assert_eq!(
13244 unsafe { ::std::ptr::addr_of!((*ptr).gva_page) as usize - ptr as usize },
13245 24usize,
13246 concat!(
13247 "Offset of field: ",
13248 stringify!(hv_input_translate_virtual_address),
13249 "::",
13250 stringify!(gva_page)
13251 )
13252 );
13253}
13254#[repr(C, packed)]
13255#[derive(Copy, Clone)]
13256pub struct hv_output_translate_virtual_address {
13257 pub translation_result: hv_translate_gva_result,
13258 pub gpa_page: __u64,
13259}
13260#[test]
13261fn bindgen_test_layout_hv_output_translate_virtual_address() {
13262 const UNINIT: ::std::mem::MaybeUninit<hv_output_translate_virtual_address> =
13263 ::std::mem::MaybeUninit::uninit();
13264 let ptr = UNINIT.as_ptr();
13265 assert_eq!(
13266 ::std::mem::size_of::<hv_output_translate_virtual_address>(),
13267 16usize,
13268 concat!("Size of: ", stringify!(hv_output_translate_virtual_address))
13269 );
13270 assert_eq!(
13271 ::std::mem::align_of::<hv_output_translate_virtual_address>(),
13272 1usize,
13273 concat!(
13274 "Alignment of ",
13275 stringify!(hv_output_translate_virtual_address)
13276 )
13277 );
13278 assert_eq!(
13279 unsafe { ::std::ptr::addr_of!((*ptr).translation_result) as usize - ptr as usize },
13280 0usize,
13281 concat!(
13282 "Offset of field: ",
13283 stringify!(hv_output_translate_virtual_address),
13284 "::",
13285 stringify!(translation_result)
13286 )
13287 );
13288 assert_eq!(
13289 unsafe { ::std::ptr::addr_of!((*ptr).gpa_page) as usize - ptr as usize },
13290 8usize,
13291 concat!(
13292 "Offset of field: ",
13293 stringify!(hv_output_translate_virtual_address),
13294 "::",
13295 stringify!(gpa_page)
13296 )
13297 );
13298}
13299impl Default for hv_output_translate_virtual_address {
13300 fn default() -> Self {
13301 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
13302 unsafe {
13303 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
13304 s.assume_init()
13305 }
13306 }
13307}
13308#[repr(C, packed)]
13309#[derive(Copy, Clone)]
13310pub struct hv_input_register_intercept_result {
13311 pub partition_id: __u64,
13312 pub vp_index: __u32,
13313 pub intercept_type: __u32,
13314 pub parameters: hv_register_intercept_result_parameters,
13315}
13316#[test]
13317fn bindgen_test_layout_hv_input_register_intercept_result() {
13318 const UNINIT: ::std::mem::MaybeUninit<hv_input_register_intercept_result> =
13319 ::std::mem::MaybeUninit::uninit();
13320 let ptr = UNINIT.as_ptr();
13321 assert_eq!(
13322 ::std::mem::size_of::<hv_input_register_intercept_result>(),
13323 60usize,
13324 concat!("Size of: ", stringify!(hv_input_register_intercept_result))
13325 );
13326 assert_eq!(
13327 ::std::mem::align_of::<hv_input_register_intercept_result>(),
13328 1usize,
13329 concat!(
13330 "Alignment of ",
13331 stringify!(hv_input_register_intercept_result)
13332 )
13333 );
13334 assert_eq!(
13335 unsafe { ::std::ptr::addr_of!((*ptr).partition_id) as usize - ptr as usize },
13336 0usize,
13337 concat!(
13338 "Offset of field: ",
13339 stringify!(hv_input_register_intercept_result),
13340 "::",
13341 stringify!(partition_id)
13342 )
13343 );
13344 assert_eq!(
13345 unsafe { ::std::ptr::addr_of!((*ptr).vp_index) as usize - ptr as usize },
13346 8usize,
13347 concat!(
13348 "Offset of field: ",
13349 stringify!(hv_input_register_intercept_result),
13350 "::",
13351 stringify!(vp_index)
13352 )
13353 );
13354 assert_eq!(
13355 unsafe { ::std::ptr::addr_of!((*ptr).intercept_type) as usize - ptr as usize },
13356 12usize,
13357 concat!(
13358 "Offset of field: ",
13359 stringify!(hv_input_register_intercept_result),
13360 "::",
13361 stringify!(intercept_type)
13362 )
13363 );
13364 assert_eq!(
13365 unsafe { ::std::ptr::addr_of!((*ptr).parameters) as usize - ptr as usize },
13366 16usize,
13367 concat!(
13368 "Offset of field: ",
13369 stringify!(hv_input_register_intercept_result),
13370 "::",
13371 stringify!(parameters)
13372 )
13373 );
13374}
13375impl Default for hv_input_register_intercept_result {
13376 fn default() -> Self {
13377 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
13378 unsafe {
13379 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
13380 s.assume_init()
13381 }
13382 }
13383}
13384#[repr(C, packed)]
13385#[derive(Copy, Clone)]
13386pub struct hv_input_assert_virtual_interrupt {
13387 pub partition_id: __u64,
13388 pub control: hv_interrupt_control,
13389 pub dest_addr: __u64,
13390 pub vector: __u32,
13391 pub target_vtl: __u8,
13392 pub rsvd_z0: __u8,
13393 pub rsvd_z1: __u16,
13394}
13395#[test]
13396fn bindgen_test_layout_hv_input_assert_virtual_interrupt() {
13397 const UNINIT: ::std::mem::MaybeUninit<hv_input_assert_virtual_interrupt> =
13398 ::std::mem::MaybeUninit::uninit();
13399 let ptr = UNINIT.as_ptr();
13400 assert_eq!(
13401 ::std::mem::size_of::<hv_input_assert_virtual_interrupt>(),
13402 32usize,
13403 concat!("Size of: ", stringify!(hv_input_assert_virtual_interrupt))
13404 );
13405 assert_eq!(
13406 ::std::mem::align_of::<hv_input_assert_virtual_interrupt>(),
13407 1usize,
13408 concat!(
13409 "Alignment of ",
13410 stringify!(hv_input_assert_virtual_interrupt)
13411 )
13412 );
13413 assert_eq!(
13414 unsafe { ::std::ptr::addr_of!((*ptr).partition_id) as usize - ptr as usize },
13415 0usize,
13416 concat!(
13417 "Offset of field: ",
13418 stringify!(hv_input_assert_virtual_interrupt),
13419 "::",
13420 stringify!(partition_id)
13421 )
13422 );
13423 assert_eq!(
13424 unsafe { ::std::ptr::addr_of!((*ptr).control) as usize - ptr as usize },
13425 8usize,
13426 concat!(
13427 "Offset of field: ",
13428 stringify!(hv_input_assert_virtual_interrupt),
13429 "::",
13430 stringify!(control)
13431 )
13432 );
13433 assert_eq!(
13434 unsafe { ::std::ptr::addr_of!((*ptr).dest_addr) as usize - ptr as usize },
13435 16usize,
13436 concat!(
13437 "Offset of field: ",
13438 stringify!(hv_input_assert_virtual_interrupt),
13439 "::",
13440 stringify!(dest_addr)
13441 )
13442 );
13443 assert_eq!(
13444 unsafe { ::std::ptr::addr_of!((*ptr).vector) as usize - ptr as usize },
13445 24usize,
13446 concat!(
13447 "Offset of field: ",
13448 stringify!(hv_input_assert_virtual_interrupt),
13449 "::",
13450 stringify!(vector)
13451 )
13452 );
13453 assert_eq!(
13454 unsafe { ::std::ptr::addr_of!((*ptr).target_vtl) as usize - ptr as usize },
13455 28usize,
13456 concat!(
13457 "Offset of field: ",
13458 stringify!(hv_input_assert_virtual_interrupt),
13459 "::",
13460 stringify!(target_vtl)
13461 )
13462 );
13463 assert_eq!(
13464 unsafe { ::std::ptr::addr_of!((*ptr).rsvd_z0) as usize - ptr as usize },
13465 29usize,
13466 concat!(
13467 "Offset of field: ",
13468 stringify!(hv_input_assert_virtual_interrupt),
13469 "::",
13470 stringify!(rsvd_z0)
13471 )
13472 );
13473 assert_eq!(
13474 unsafe { ::std::ptr::addr_of!((*ptr).rsvd_z1) as usize - ptr as usize },
13475 30usize,
13476 concat!(
13477 "Offset of field: ",
13478 stringify!(hv_input_assert_virtual_interrupt),
13479 "::",
13480 stringify!(rsvd_z1)
13481 )
13482 );
13483}
13484impl Default for hv_input_assert_virtual_interrupt {
13485 fn default() -> Self {
13486 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
13487 unsafe {
13488 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
13489 s.assume_init()
13490 }
13491 }
13492}
13493#[repr(C, packed)]
13494#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
13495pub struct hv_input_signal_event_direct {
13496 pub target_partition: __u64,
13497 pub target_vp: __u32,
13498 pub target_vtl: __u8,
13499 pub target_sint: __u8,
13500 pub flag_number: __u16,
13501}
13502#[test]
13503fn bindgen_test_layout_hv_input_signal_event_direct() {
13504 const UNINIT: ::std::mem::MaybeUninit<hv_input_signal_event_direct> =
13505 ::std::mem::MaybeUninit::uninit();
13506 let ptr = UNINIT.as_ptr();
13507 assert_eq!(
13508 ::std::mem::size_of::<hv_input_signal_event_direct>(),
13509 16usize,
13510 concat!("Size of: ", stringify!(hv_input_signal_event_direct))
13511 );
13512 assert_eq!(
13513 ::std::mem::align_of::<hv_input_signal_event_direct>(),
13514 1usize,
13515 concat!("Alignment of ", stringify!(hv_input_signal_event_direct))
13516 );
13517 assert_eq!(
13518 unsafe { ::std::ptr::addr_of!((*ptr).target_partition) as usize - ptr as usize },
13519 0usize,
13520 concat!(
13521 "Offset of field: ",
13522 stringify!(hv_input_signal_event_direct),
13523 "::",
13524 stringify!(target_partition)
13525 )
13526 );
13527 assert_eq!(
13528 unsafe { ::std::ptr::addr_of!((*ptr).target_vp) as usize - ptr as usize },
13529 8usize,
13530 concat!(
13531 "Offset of field: ",
13532 stringify!(hv_input_signal_event_direct),
13533 "::",
13534 stringify!(target_vp)
13535 )
13536 );
13537 assert_eq!(
13538 unsafe { ::std::ptr::addr_of!((*ptr).target_vtl) as usize - ptr as usize },
13539 12usize,
13540 concat!(
13541 "Offset of field: ",
13542 stringify!(hv_input_signal_event_direct),
13543 "::",
13544 stringify!(target_vtl)
13545 )
13546 );
13547 assert_eq!(
13548 unsafe { ::std::ptr::addr_of!((*ptr).target_sint) as usize - ptr as usize },
13549 13usize,
13550 concat!(
13551 "Offset of field: ",
13552 stringify!(hv_input_signal_event_direct),
13553 "::",
13554 stringify!(target_sint)
13555 )
13556 );
13557 assert_eq!(
13558 unsafe { ::std::ptr::addr_of!((*ptr).flag_number) as usize - ptr as usize },
13559 14usize,
13560 concat!(
13561 "Offset of field: ",
13562 stringify!(hv_input_signal_event_direct),
13563 "::",
13564 stringify!(flag_number)
13565 )
13566 );
13567}
13568#[repr(C, packed)]
13569#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
13570pub struct hv_output_signal_event_direct {
13571 pub newly_signaled: __u8,
13572 pub reserved: [__u8; 7usize],
13573}
13574#[test]
13575fn bindgen_test_layout_hv_output_signal_event_direct() {
13576 const UNINIT: ::std::mem::MaybeUninit<hv_output_signal_event_direct> =
13577 ::std::mem::MaybeUninit::uninit();
13578 let ptr = UNINIT.as_ptr();
13579 assert_eq!(
13580 ::std::mem::size_of::<hv_output_signal_event_direct>(),
13581 8usize,
13582 concat!("Size of: ", stringify!(hv_output_signal_event_direct))
13583 );
13584 assert_eq!(
13585 ::std::mem::align_of::<hv_output_signal_event_direct>(),
13586 1usize,
13587 concat!("Alignment of ", stringify!(hv_output_signal_event_direct))
13588 );
13589 assert_eq!(
13590 unsafe { ::std::ptr::addr_of!((*ptr).newly_signaled) as usize - ptr as usize },
13591 0usize,
13592 concat!(
13593 "Offset of field: ",
13594 stringify!(hv_output_signal_event_direct),
13595 "::",
13596 stringify!(newly_signaled)
13597 )
13598 );
13599 assert_eq!(
13600 unsafe { ::std::ptr::addr_of!((*ptr).reserved) as usize - ptr as usize },
13601 1usize,
13602 concat!(
13603 "Offset of field: ",
13604 stringify!(hv_output_signal_event_direct),
13605 "::",
13606 stringify!(reserved)
13607 )
13608 );
13609}
13610#[repr(C, packed)]
13611#[derive(Debug, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
13612pub struct hv_input_post_message_direct {
13613 pub partition_id: __u64,
13614 pub vp_index: __u32,
13615 pub vtl: __u8,
13616 pub padding: [__u8; 3usize],
13617 pub sint_index: __u32,
13618 pub message: [__u8; 256usize],
13619 pub padding2: __u32,
13620}
13621#[test]
13622fn bindgen_test_layout_hv_input_post_message_direct() {
13623 const UNINIT: ::std::mem::MaybeUninit<hv_input_post_message_direct> =
13624 ::std::mem::MaybeUninit::uninit();
13625 let ptr = UNINIT.as_ptr();
13626 assert_eq!(
13627 ::std::mem::size_of::<hv_input_post_message_direct>(),
13628 280usize,
13629 concat!("Size of: ", stringify!(hv_input_post_message_direct))
13630 );
13631 assert_eq!(
13632 ::std::mem::align_of::<hv_input_post_message_direct>(),
13633 1usize,
13634 concat!("Alignment of ", stringify!(hv_input_post_message_direct))
13635 );
13636 assert_eq!(
13637 unsafe { ::std::ptr::addr_of!((*ptr).partition_id) as usize - ptr as usize },
13638 0usize,
13639 concat!(
13640 "Offset of field: ",
13641 stringify!(hv_input_post_message_direct),
13642 "::",
13643 stringify!(partition_id)
13644 )
13645 );
13646 assert_eq!(
13647 unsafe { ::std::ptr::addr_of!((*ptr).vp_index) as usize - ptr as usize },
13648 8usize,
13649 concat!(
13650 "Offset of field: ",
13651 stringify!(hv_input_post_message_direct),
13652 "::",
13653 stringify!(vp_index)
13654 )
13655 );
13656 assert_eq!(
13657 unsafe { ::std::ptr::addr_of!((*ptr).vtl) as usize - ptr as usize },
13658 12usize,
13659 concat!(
13660 "Offset of field: ",
13661 stringify!(hv_input_post_message_direct),
13662 "::",
13663 stringify!(vtl)
13664 )
13665 );
13666 assert_eq!(
13667 unsafe { ::std::ptr::addr_of!((*ptr).padding) as usize - ptr as usize },
13668 13usize,
13669 concat!(
13670 "Offset of field: ",
13671 stringify!(hv_input_post_message_direct),
13672 "::",
13673 stringify!(padding)
13674 )
13675 );
13676 assert_eq!(
13677 unsafe { ::std::ptr::addr_of!((*ptr).sint_index) as usize - ptr as usize },
13678 16usize,
13679 concat!(
13680 "Offset of field: ",
13681 stringify!(hv_input_post_message_direct),
13682 "::",
13683 stringify!(sint_index)
13684 )
13685 );
13686 assert_eq!(
13687 unsafe { ::std::ptr::addr_of!((*ptr).message) as usize - ptr as usize },
13688 20usize,
13689 concat!(
13690 "Offset of field: ",
13691 stringify!(hv_input_post_message_direct),
13692 "::",
13693 stringify!(message)
13694 )
13695 );
13696 assert_eq!(
13697 unsafe { ::std::ptr::addr_of!((*ptr).padding2) as usize - ptr as usize },
13698 276usize,
13699 concat!(
13700 "Offset of field: ",
13701 stringify!(hv_input_post_message_direct),
13702 "::",
13703 stringify!(padding2)
13704 )
13705 );
13706}
13707impl Default for hv_input_post_message_direct {
13708 fn default() -> Self {
13709 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
13710 unsafe {
13711 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
13712 s.assume_init()
13713 }
13714 }
13715}
13716#[repr(C, packed)]
13717#[derive(Copy, Clone)]
13718pub struct hv_vp_state_data_xsave {
13719 pub flags: __u64,
13720 pub states: hv_x64_xsave_xfem_register,
13721}
13722#[test]
13723fn bindgen_test_layout_hv_vp_state_data_xsave() {
13724 const UNINIT: ::std::mem::MaybeUninit<hv_vp_state_data_xsave> =
13725 ::std::mem::MaybeUninit::uninit();
13726 let ptr = UNINIT.as_ptr();
13727 assert_eq!(
13728 ::std::mem::size_of::<hv_vp_state_data_xsave>(),
13729 16usize,
13730 concat!("Size of: ", stringify!(hv_vp_state_data_xsave))
13731 );
13732 assert_eq!(
13733 ::std::mem::align_of::<hv_vp_state_data_xsave>(),
13734 1usize,
13735 concat!("Alignment of ", stringify!(hv_vp_state_data_xsave))
13736 );
13737 assert_eq!(
13738 unsafe { ::std::ptr::addr_of!((*ptr).flags) as usize - ptr as usize },
13739 0usize,
13740 concat!(
13741 "Offset of field: ",
13742 stringify!(hv_vp_state_data_xsave),
13743 "::",
13744 stringify!(flags)
13745 )
13746 );
13747 assert_eq!(
13748 unsafe { ::std::ptr::addr_of!((*ptr).states) as usize - ptr as usize },
13749 8usize,
13750 concat!(
13751 "Offset of field: ",
13752 stringify!(hv_vp_state_data_xsave),
13753 "::",
13754 stringify!(states)
13755 )
13756 );
13757}
13758impl Default for hv_vp_state_data_xsave {
13759 fn default() -> Self {
13760 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
13761 unsafe {
13762 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
13763 s.assume_init()
13764 }
13765 }
13766}
13767#[repr(C, packed)]
13768#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
13769pub struct hv_psp_cpuid_leaf {
13770 pub eax_in: __u32,
13771 pub ecx_in: __u32,
13772 pub xfem_in: __u64,
13773 pub xss_in: __u64,
13774 pub eax_out: __u32,
13775 pub ebx_out: __u32,
13776 pub ecx_out: __u32,
13777 pub edx_out: __u32,
13778 pub reserved_z: __u64,
13779}
13780#[test]
13781fn bindgen_test_layout_hv_psp_cpuid_leaf() {
13782 const UNINIT: ::std::mem::MaybeUninit<hv_psp_cpuid_leaf> = ::std::mem::MaybeUninit::uninit();
13783 let ptr = UNINIT.as_ptr();
13784 assert_eq!(
13785 ::std::mem::size_of::<hv_psp_cpuid_leaf>(),
13786 48usize,
13787 concat!("Size of: ", stringify!(hv_psp_cpuid_leaf))
13788 );
13789 assert_eq!(
13790 ::std::mem::align_of::<hv_psp_cpuid_leaf>(),
13791 1usize,
13792 concat!("Alignment of ", stringify!(hv_psp_cpuid_leaf))
13793 );
13794 assert_eq!(
13795 unsafe { ::std::ptr::addr_of!((*ptr).eax_in) as usize - ptr as usize },
13796 0usize,
13797 concat!(
13798 "Offset of field: ",
13799 stringify!(hv_psp_cpuid_leaf),
13800 "::",
13801 stringify!(eax_in)
13802 )
13803 );
13804 assert_eq!(
13805 unsafe { ::std::ptr::addr_of!((*ptr).ecx_in) as usize - ptr as usize },
13806 4usize,
13807 concat!(
13808 "Offset of field: ",
13809 stringify!(hv_psp_cpuid_leaf),
13810 "::",
13811 stringify!(ecx_in)
13812 )
13813 );
13814 assert_eq!(
13815 unsafe { ::std::ptr::addr_of!((*ptr).xfem_in) as usize - ptr as usize },
13816 8usize,
13817 concat!(
13818 "Offset of field: ",
13819 stringify!(hv_psp_cpuid_leaf),
13820 "::",
13821 stringify!(xfem_in)
13822 )
13823 );
13824 assert_eq!(
13825 unsafe { ::std::ptr::addr_of!((*ptr).xss_in) as usize - ptr as usize },
13826 16usize,
13827 concat!(
13828 "Offset of field: ",
13829 stringify!(hv_psp_cpuid_leaf),
13830 "::",
13831 stringify!(xss_in)
13832 )
13833 );
13834 assert_eq!(
13835 unsafe { ::std::ptr::addr_of!((*ptr).eax_out) as usize - ptr as usize },
13836 24usize,
13837 concat!(
13838 "Offset of field: ",
13839 stringify!(hv_psp_cpuid_leaf),
13840 "::",
13841 stringify!(eax_out)
13842 )
13843 );
13844 assert_eq!(
13845 unsafe { ::std::ptr::addr_of!((*ptr).ebx_out) as usize - ptr as usize },
13846 28usize,
13847 concat!(
13848 "Offset of field: ",
13849 stringify!(hv_psp_cpuid_leaf),
13850 "::",
13851 stringify!(ebx_out)
13852 )
13853 );
13854 assert_eq!(
13855 unsafe { ::std::ptr::addr_of!((*ptr).ecx_out) as usize - ptr as usize },
13856 32usize,
13857 concat!(
13858 "Offset of field: ",
13859 stringify!(hv_psp_cpuid_leaf),
13860 "::",
13861 stringify!(ecx_out)
13862 )
13863 );
13864 assert_eq!(
13865 unsafe { ::std::ptr::addr_of!((*ptr).edx_out) as usize - ptr as usize },
13866 36usize,
13867 concat!(
13868 "Offset of field: ",
13869 stringify!(hv_psp_cpuid_leaf),
13870 "::",
13871 stringify!(edx_out)
13872 )
13873 );
13874 assert_eq!(
13875 unsafe { ::std::ptr::addr_of!((*ptr).reserved_z) as usize - ptr as usize },
13876 40usize,
13877 concat!(
13878 "Offset of field: ",
13879 stringify!(hv_psp_cpuid_leaf),
13880 "::",
13881 stringify!(reserved_z)
13882 )
13883 );
13884}
13885#[repr(C, packed)]
13886#[derive(Debug, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
13887pub struct hv_psp_cpuid_page {
13888 pub count: __u32,
13889 pub reserved_z1: __u32,
13890 pub reserved_z2: __u64,
13891 pub cpuid_leaf_info: [hv_psp_cpuid_leaf; 64usize],
13892}
13893#[test]
13894fn bindgen_test_layout_hv_psp_cpuid_page() {
13895 const UNINIT: ::std::mem::MaybeUninit<hv_psp_cpuid_page> = ::std::mem::MaybeUninit::uninit();
13896 let ptr = UNINIT.as_ptr();
13897 assert_eq!(
13898 ::std::mem::size_of::<hv_psp_cpuid_page>(),
13899 3088usize,
13900 concat!("Size of: ", stringify!(hv_psp_cpuid_page))
13901 );
13902 assert_eq!(
13903 ::std::mem::align_of::<hv_psp_cpuid_page>(),
13904 1usize,
13905 concat!("Alignment of ", stringify!(hv_psp_cpuid_page))
13906 );
13907 assert_eq!(
13908 unsafe { ::std::ptr::addr_of!((*ptr).count) as usize - ptr as usize },
13909 0usize,
13910 concat!(
13911 "Offset of field: ",
13912 stringify!(hv_psp_cpuid_page),
13913 "::",
13914 stringify!(count)
13915 )
13916 );
13917 assert_eq!(
13918 unsafe { ::std::ptr::addr_of!((*ptr).reserved_z1) as usize - ptr as usize },
13919 4usize,
13920 concat!(
13921 "Offset of field: ",
13922 stringify!(hv_psp_cpuid_page),
13923 "::",
13924 stringify!(reserved_z1)
13925 )
13926 );
13927 assert_eq!(
13928 unsafe { ::std::ptr::addr_of!((*ptr).reserved_z2) as usize - ptr as usize },
13929 8usize,
13930 concat!(
13931 "Offset of field: ",
13932 stringify!(hv_psp_cpuid_page),
13933 "::",
13934 stringify!(reserved_z2)
13935 )
13936 );
13937 assert_eq!(
13938 unsafe { ::std::ptr::addr_of!((*ptr).cpuid_leaf_info) as usize - ptr as usize },
13939 16usize,
13940 concat!(
13941 "Offset of field: ",
13942 stringify!(hv_psp_cpuid_page),
13943 "::",
13944 stringify!(cpuid_leaf_info)
13945 )
13946 );
13947}
13948impl Default for hv_psp_cpuid_page {
13949 fn default() -> Self {
13950 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
13951 unsafe {
13952 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
13953 s.assume_init()
13954 }
13955 }
13956}
13957pub const hv_isolated_page_type_HV_ISOLATED_PAGE_TYPE_NORMAL: hv_isolated_page_type = 0;
13958pub const hv_isolated_page_type_HV_ISOLATED_PAGE_TYPE_VMSA: hv_isolated_page_type = 1;
13959pub const hv_isolated_page_type_HV_ISOLATED_PAGE_TYPE_ZERO: hv_isolated_page_type = 2;
13960pub const hv_isolated_page_type_HV_ISOLATED_PAGE_TYPE_UNMEASURED: hv_isolated_page_type = 3;
13961pub const hv_isolated_page_type_HV_ISOLATED_PAGE_TYPE_SECRETS: hv_isolated_page_type = 4;
13962pub const hv_isolated_page_type_HV_ISOLATED_PAGE_TYPE_CPUID: hv_isolated_page_type = 5;
13963pub const hv_isolated_page_type_HV_ISOLATED_PAGE_TYPE_COUNT: hv_isolated_page_type = 6;
13964pub type hv_isolated_page_type = ::std::os::raw::c_uint;
13965pub const hv_isolated_page_size_HV_ISOLATED_PAGE_SIZE_4KB: hv_isolated_page_size = 0;
13966pub const hv_isolated_page_size_HV_ISOLATED_PAGE_SIZE_2MB: hv_isolated_page_size = 1;
13967pub type hv_isolated_page_size = ::std::os::raw::c_uint;
13968#[repr(C, packed)]
13969pub struct hv_input_import_isolated_pages {
13970 pub partition_id: __u64,
13971 pub page_type: __u32,
13972 pub page_size: __u32,
13973 pub page_number: __IncompleteArrayField<__u64>,
13974}
13975#[test]
13976fn bindgen_test_layout_hv_input_import_isolated_pages() {
13977 const UNINIT: ::std::mem::MaybeUninit<hv_input_import_isolated_pages> =
13978 ::std::mem::MaybeUninit::uninit();
13979 let ptr = UNINIT.as_ptr();
13980 assert_eq!(
13981 ::std::mem::size_of::<hv_input_import_isolated_pages>(),
13982 16usize,
13983 concat!("Size of: ", stringify!(hv_input_import_isolated_pages))
13984 );
13985 assert_eq!(
13986 ::std::mem::align_of::<hv_input_import_isolated_pages>(),
13987 1usize,
13988 concat!("Alignment of ", stringify!(hv_input_import_isolated_pages))
13989 );
13990 assert_eq!(
13991 unsafe { ::std::ptr::addr_of!((*ptr).partition_id) as usize - ptr as usize },
13992 0usize,
13993 concat!(
13994 "Offset of field: ",
13995 stringify!(hv_input_import_isolated_pages),
13996 "::",
13997 stringify!(partition_id)
13998 )
13999 );
14000 assert_eq!(
14001 unsafe { ::std::ptr::addr_of!((*ptr).page_type) as usize - ptr as usize },
14002 8usize,
14003 concat!(
14004 "Offset of field: ",
14005 stringify!(hv_input_import_isolated_pages),
14006 "::",
14007 stringify!(page_type)
14008 )
14009 );
14010 assert_eq!(
14011 unsafe { ::std::ptr::addr_of!((*ptr).page_size) as usize - ptr as usize },
14012 12usize,
14013 concat!(
14014 "Offset of field: ",
14015 stringify!(hv_input_import_isolated_pages),
14016 "::",
14017 stringify!(page_size)
14018 )
14019 );
14020 assert_eq!(
14021 unsafe { ::std::ptr::addr_of!((*ptr).page_number) as usize - ptr as usize },
14022 16usize,
14023 concat!(
14024 "Offset of field: ",
14025 stringify!(hv_input_import_isolated_pages),
14026 "::",
14027 stringify!(page_number)
14028 )
14029 );
14030}
14031impl Default for hv_input_import_isolated_pages {
14032 fn default() -> Self {
14033 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
14034 unsafe {
14035 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
14036 s.assume_init()
14037 }
14038 }
14039}
14040#[repr(C)]
14041#[derive(Copy, Clone)]
14042pub union hv_sev_vmgexit_offload {
14043 pub as_uint64: __u64,
14044 pub __bindgen_anon_1: hv_sev_vmgexit_offload__bindgen_ty_1,
14045}
14046#[repr(C, packed)]
14047#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
14048pub struct hv_sev_vmgexit_offload__bindgen_ty_1 {
14049 pub _bitfield_align_1: [u8; 0],
14050 pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>,
14051}
14052#[test]
14053fn bindgen_test_layout_hv_sev_vmgexit_offload__bindgen_ty_1() {
14054 assert_eq!(
14055 ::std::mem::size_of::<hv_sev_vmgexit_offload__bindgen_ty_1>(),
14056 8usize,
14057 concat!(
14058 "Size of: ",
14059 stringify!(hv_sev_vmgexit_offload__bindgen_ty_1)
14060 )
14061 );
14062 assert_eq!(
14063 ::std::mem::align_of::<hv_sev_vmgexit_offload__bindgen_ty_1>(),
14064 1usize,
14065 concat!(
14066 "Alignment of ",
14067 stringify!(hv_sev_vmgexit_offload__bindgen_ty_1)
14068 )
14069 );
14070}
14071impl hv_sev_vmgexit_offload__bindgen_ty_1 {
14072 #[inline]
14073 pub fn nae_rdtsc(&self) -> __u64 {
14074 unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 1u8) as u64) }
14075 }
14076 #[inline]
14077 pub fn set_nae_rdtsc(&mut self, val: __u64) {
14078 unsafe {
14079 let val: u64 = ::std::mem::transmute(val);
14080 self._bitfield_1.set(0usize, 1u8, val as u64)
14081 }
14082 }
14083 #[inline]
14084 pub fn nae_cpuid(&self) -> __u64 {
14085 unsafe { ::std::mem::transmute(self._bitfield_1.get(1usize, 1u8) as u64) }
14086 }
14087 #[inline]
14088 pub fn set_nae_cpuid(&mut self, val: __u64) {
14089 unsafe {
14090 let val: u64 = ::std::mem::transmute(val);
14091 self._bitfield_1.set(1usize, 1u8, val as u64)
14092 }
14093 }
14094 #[inline]
14095 pub fn nae_reserved_io_port(&self) -> __u64 {
14096 unsafe { ::std::mem::transmute(self._bitfield_1.get(2usize, 1u8) as u64) }
14097 }
14098 #[inline]
14099 pub fn set_nae_reserved_io_port(&mut self, val: __u64) {
14100 unsafe {
14101 let val: u64 = ::std::mem::transmute(val);
14102 self._bitfield_1.set(2usize, 1u8, val as u64)
14103 }
14104 }
14105 #[inline]
14106 pub fn nae_rdmsr(&self) -> __u64 {
14107 unsafe { ::std::mem::transmute(self._bitfield_1.get(3usize, 1u8) as u64) }
14108 }
14109 #[inline]
14110 pub fn set_nae_rdmsr(&mut self, val: __u64) {
14111 unsafe {
14112 let val: u64 = ::std::mem::transmute(val);
14113 self._bitfield_1.set(3usize, 1u8, val as u64)
14114 }
14115 }
14116 #[inline]
14117 pub fn nae_wrmsr(&self) -> __u64 {
14118 unsafe { ::std::mem::transmute(self._bitfield_1.get(4usize, 1u8) as u64) }
14119 }
14120 #[inline]
14121 pub fn set_nae_wrmsr(&mut self, val: __u64) {
14122 unsafe {
14123 let val: u64 = ::std::mem::transmute(val);
14124 self._bitfield_1.set(4usize, 1u8, val as u64)
14125 }
14126 }
14127 #[inline]
14128 pub fn nae_vmmcall(&self) -> __u64 {
14129 unsafe { ::std::mem::transmute(self._bitfield_1.get(5usize, 1u8) as u64) }
14130 }
14131 #[inline]
14132 pub fn set_nae_vmmcall(&mut self, val: __u64) {
14133 unsafe {
14134 let val: u64 = ::std::mem::transmute(val);
14135 self._bitfield_1.set(5usize, 1u8, val as u64)
14136 }
14137 }
14138 #[inline]
14139 pub fn nae_wbinvd(&self) -> __u64 {
14140 unsafe { ::std::mem::transmute(self._bitfield_1.get(6usize, 1u8) as u64) }
14141 }
14142 #[inline]
14143 pub fn set_nae_wbinvd(&mut self, val: __u64) {
14144 unsafe {
14145 let val: u64 = ::std::mem::transmute(val);
14146 self._bitfield_1.set(6usize, 1u8, val as u64)
14147 }
14148 }
14149 #[inline]
14150 pub fn nae_snp_page_state_change(&self) -> __u64 {
14151 unsafe { ::std::mem::transmute(self._bitfield_1.get(7usize, 1u8) as u64) }
14152 }
14153 #[inline]
14154 pub fn set_nae_snp_page_state_change(&mut self, val: __u64) {
14155 unsafe {
14156 let val: u64 = ::std::mem::transmute(val);
14157 self._bitfield_1.set(7usize, 1u8, val as u64)
14158 }
14159 }
14160 #[inline]
14161 pub fn reserved0(&self) -> __u64 {
14162 unsafe { ::std::mem::transmute(self._bitfield_1.get(8usize, 24u8) as u64) }
14163 }
14164 #[inline]
14165 pub fn set_reserved0(&mut self, val: __u64) {
14166 unsafe {
14167 let val: u64 = ::std::mem::transmute(val);
14168 self._bitfield_1.set(8usize, 24u8, val as u64)
14169 }
14170 }
14171 #[inline]
14172 pub fn msr_cpuid(&self) -> __u64 {
14173 unsafe { ::std::mem::transmute(self._bitfield_1.get(32usize, 1u8) as u64) }
14174 }
14175 #[inline]
14176 pub fn set_msr_cpuid(&mut self, val: __u64) {
14177 unsafe {
14178 let val: u64 = ::std::mem::transmute(val);
14179 self._bitfield_1.set(32usize, 1u8, val as u64)
14180 }
14181 }
14182 #[inline]
14183 pub fn msr_snp_page_state_change(&self) -> __u64 {
14184 unsafe { ::std::mem::transmute(self._bitfield_1.get(33usize, 1u8) as u64) }
14185 }
14186 #[inline]
14187 pub fn set_msr_snp_page_state_change(&mut self, val: __u64) {
14188 unsafe {
14189 let val: u64 = ::std::mem::transmute(val);
14190 self._bitfield_1.set(33usize, 1u8, val as u64)
14191 }
14192 }
14193 #[inline]
14194 pub fn reserved1(&self) -> __u64 {
14195 unsafe { ::std::mem::transmute(self._bitfield_1.get(34usize, 30u8) as u64) }
14196 }
14197 #[inline]
14198 pub fn set_reserved1(&mut self, val: __u64) {
14199 unsafe {
14200 let val: u64 = ::std::mem::transmute(val);
14201 self._bitfield_1.set(34usize, 30u8, val as u64)
14202 }
14203 }
14204 #[inline]
14205 pub fn new_bitfield_1(
14206 nae_rdtsc: __u64,
14207 nae_cpuid: __u64,
14208 nae_reserved_io_port: __u64,
14209 nae_rdmsr: __u64,
14210 nae_wrmsr: __u64,
14211 nae_vmmcall: __u64,
14212 nae_wbinvd: __u64,
14213 nae_snp_page_state_change: __u64,
14214 reserved0: __u64,
14215 msr_cpuid: __u64,
14216 msr_snp_page_state_change: __u64,
14217 reserved1: __u64,
14218 ) -> __BindgenBitfieldUnit<[u8; 8usize]> {
14219 let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 8usize]> = Default::default();
14220 __bindgen_bitfield_unit.set(0usize, 1u8, {
14221 let nae_rdtsc: u64 = unsafe { ::std::mem::transmute(nae_rdtsc) };
14222 nae_rdtsc as u64
14223 });
14224 __bindgen_bitfield_unit.set(1usize, 1u8, {
14225 let nae_cpuid: u64 = unsafe { ::std::mem::transmute(nae_cpuid) };
14226 nae_cpuid as u64
14227 });
14228 __bindgen_bitfield_unit.set(2usize, 1u8, {
14229 let nae_reserved_io_port: u64 = unsafe { ::std::mem::transmute(nae_reserved_io_port) };
14230 nae_reserved_io_port as u64
14231 });
14232 __bindgen_bitfield_unit.set(3usize, 1u8, {
14233 let nae_rdmsr: u64 = unsafe { ::std::mem::transmute(nae_rdmsr) };
14234 nae_rdmsr as u64
14235 });
14236 __bindgen_bitfield_unit.set(4usize, 1u8, {
14237 let nae_wrmsr: u64 = unsafe { ::std::mem::transmute(nae_wrmsr) };
14238 nae_wrmsr as u64
14239 });
14240 __bindgen_bitfield_unit.set(5usize, 1u8, {
14241 let nae_vmmcall: u64 = unsafe { ::std::mem::transmute(nae_vmmcall) };
14242 nae_vmmcall as u64
14243 });
14244 __bindgen_bitfield_unit.set(6usize, 1u8, {
14245 let nae_wbinvd: u64 = unsafe { ::std::mem::transmute(nae_wbinvd) };
14246 nae_wbinvd as u64
14247 });
14248 __bindgen_bitfield_unit.set(7usize, 1u8, {
14249 let nae_snp_page_state_change: u64 =
14250 unsafe { ::std::mem::transmute(nae_snp_page_state_change) };
14251 nae_snp_page_state_change as u64
14252 });
14253 __bindgen_bitfield_unit.set(8usize, 24u8, {
14254 let reserved0: u64 = unsafe { ::std::mem::transmute(reserved0) };
14255 reserved0 as u64
14256 });
14257 __bindgen_bitfield_unit.set(32usize, 1u8, {
14258 let msr_cpuid: u64 = unsafe { ::std::mem::transmute(msr_cpuid) };
14259 msr_cpuid as u64
14260 });
14261 __bindgen_bitfield_unit.set(33usize, 1u8, {
14262 let msr_snp_page_state_change: u64 =
14263 unsafe { ::std::mem::transmute(msr_snp_page_state_change) };
14264 msr_snp_page_state_change as u64
14265 });
14266 __bindgen_bitfield_unit.set(34usize, 30u8, {
14267 let reserved1: u64 = unsafe { ::std::mem::transmute(reserved1) };
14268 reserved1 as u64
14269 });
14270 __bindgen_bitfield_unit
14271 }
14272}
14273#[test]
14274fn bindgen_test_layout_hv_sev_vmgexit_offload() {
14275 const UNINIT: ::std::mem::MaybeUninit<hv_sev_vmgexit_offload> =
14276 ::std::mem::MaybeUninit::uninit();
14277 let ptr = UNINIT.as_ptr();
14278 assert_eq!(
14279 ::std::mem::size_of::<hv_sev_vmgexit_offload>(),
14280 8usize,
14281 concat!("Size of: ", stringify!(hv_sev_vmgexit_offload))
14282 );
14283 assert_eq!(
14284 ::std::mem::align_of::<hv_sev_vmgexit_offload>(),
14285 8usize,
14286 concat!("Alignment of ", stringify!(hv_sev_vmgexit_offload))
14287 );
14288 assert_eq!(
14289 unsafe { ::std::ptr::addr_of!((*ptr).as_uint64) as usize - ptr as usize },
14290 0usize,
14291 concat!(
14292 "Offset of field: ",
14293 stringify!(hv_sev_vmgexit_offload),
14294 "::",
14295 stringify!(as_uint64)
14296 )
14297 );
14298}
14299impl Default for hv_sev_vmgexit_offload {
14300 fn default() -> Self {
14301 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
14302 unsafe {
14303 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
14304 s.assume_init()
14305 }
14306 }
14307}
14308pub const hv_access_gpa_result_code_HV_ACCESS_GPA_SUCCESS: hv_access_gpa_result_code = 0;
14309pub const hv_access_gpa_result_code_HV_ACCESS_GPA_UNMAPPED: hv_access_gpa_result_code = 1;
14310pub const hv_access_gpa_result_code_HV_ACCESS_GPA_READ_INTERCEPT: hv_access_gpa_result_code = 2;
14311pub const hv_access_gpa_result_code_HV_ACCESS_GPA_WRITE_INTERCEPT: hv_access_gpa_result_code = 3;
14312pub const hv_access_gpa_result_code_HV_ACCESS_GPA_ILLEGAL_OVERLAY_ACCESS:
14313 hv_access_gpa_result_code = 4;
14314pub type hv_access_gpa_result_code = ::std::os::raw::c_uint;
14315#[repr(C)]
14316#[derive(Copy, Clone)]
14317pub union hv_access_gpa_result {
14318 pub as_uint64: __u64,
14319 pub __bindgen_anon_1: hv_access_gpa_result__bindgen_ty_1,
14320}
14321#[repr(C, packed)]
14322#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
14323pub struct hv_access_gpa_result__bindgen_ty_1 {
14324 pub result_code: __u32,
14325 pub reserved: __u32,
14326}
14327#[test]
14328fn bindgen_test_layout_hv_access_gpa_result__bindgen_ty_1() {
14329 const UNINIT: ::std::mem::MaybeUninit<hv_access_gpa_result__bindgen_ty_1> =
14330 ::std::mem::MaybeUninit::uninit();
14331 let ptr = UNINIT.as_ptr();
14332 assert_eq!(
14333 ::std::mem::size_of::<hv_access_gpa_result__bindgen_ty_1>(),
14334 8usize,
14335 concat!("Size of: ", stringify!(hv_access_gpa_result__bindgen_ty_1))
14336 );
14337 assert_eq!(
14338 ::std::mem::align_of::<hv_access_gpa_result__bindgen_ty_1>(),
14339 1usize,
14340 concat!(
14341 "Alignment of ",
14342 stringify!(hv_access_gpa_result__bindgen_ty_1)
14343 )
14344 );
14345 assert_eq!(
14346 unsafe { ::std::ptr::addr_of!((*ptr).result_code) as usize - ptr as usize },
14347 0usize,
14348 concat!(
14349 "Offset of field: ",
14350 stringify!(hv_access_gpa_result__bindgen_ty_1),
14351 "::",
14352 stringify!(result_code)
14353 )
14354 );
14355 assert_eq!(
14356 unsafe { ::std::ptr::addr_of!((*ptr).reserved) as usize - ptr as usize },
14357 4usize,
14358 concat!(
14359 "Offset of field: ",
14360 stringify!(hv_access_gpa_result__bindgen_ty_1),
14361 "::",
14362 stringify!(reserved)
14363 )
14364 );
14365}
14366#[test]
14367fn bindgen_test_layout_hv_access_gpa_result() {
14368 const UNINIT: ::std::mem::MaybeUninit<hv_access_gpa_result> = ::std::mem::MaybeUninit::uninit();
14369 let ptr = UNINIT.as_ptr();
14370 assert_eq!(
14371 ::std::mem::size_of::<hv_access_gpa_result>(),
14372 8usize,
14373 concat!("Size of: ", stringify!(hv_access_gpa_result))
14374 );
14375 assert_eq!(
14376 ::std::mem::align_of::<hv_access_gpa_result>(),
14377 8usize,
14378 concat!("Alignment of ", stringify!(hv_access_gpa_result))
14379 );
14380 assert_eq!(
14381 unsafe { ::std::ptr::addr_of!((*ptr).as_uint64) as usize - ptr as usize },
14382 0usize,
14383 concat!(
14384 "Offset of field: ",
14385 stringify!(hv_access_gpa_result),
14386 "::",
14387 stringify!(as_uint64)
14388 )
14389 );
14390}
14391impl Default for hv_access_gpa_result {
14392 fn default() -> Self {
14393 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
14394 unsafe {
14395 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
14396 s.assume_init()
14397 }
14398 }
14399}
14400#[repr(C)]
14401#[derive(Copy, Clone)]
14402pub union hv_access_gpa_control_flags {
14403 pub as_uint64: __u64,
14404 pub __bindgen_anon_1: hv_access_gpa_control_flags__bindgen_ty_1,
14405}
14406#[repr(C, packed)]
14407#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
14408pub struct hv_access_gpa_control_flags__bindgen_ty_1 {
14409 pub _bitfield_align_1: [u8; 0],
14410 pub _bitfield_1: __BindgenBitfieldUnit<[u8; 8usize]>,
14411}
14412#[test]
14413fn bindgen_test_layout_hv_access_gpa_control_flags__bindgen_ty_1() {
14414 assert_eq!(
14415 ::std::mem::size_of::<hv_access_gpa_control_flags__bindgen_ty_1>(),
14416 8usize,
14417 concat!(
14418 "Size of: ",
14419 stringify!(hv_access_gpa_control_flags__bindgen_ty_1)
14420 )
14421 );
14422 assert_eq!(
14423 ::std::mem::align_of::<hv_access_gpa_control_flags__bindgen_ty_1>(),
14424 1usize,
14425 concat!(
14426 "Alignment of ",
14427 stringify!(hv_access_gpa_control_flags__bindgen_ty_1)
14428 )
14429 );
14430}
14431impl hv_access_gpa_control_flags__bindgen_ty_1 {
14432 #[inline]
14433 pub fn cache_type(&self) -> __u64 {
14434 unsafe { ::std::mem::transmute(self._bitfield_1.get(0usize, 8u8) as u64) }
14435 }
14436 #[inline]
14437 pub fn set_cache_type(&mut self, val: __u64) {
14438 unsafe {
14439 let val: u64 = ::std::mem::transmute(val);
14440 self._bitfield_1.set(0usize, 8u8, val as u64)
14441 }
14442 }
14443 #[inline]
14444 pub fn reserved(&self) -> __u64 {
14445 unsafe { ::std::mem::transmute(self._bitfield_1.get(8usize, 56u8) as u64) }
14446 }
14447 #[inline]
14448 pub fn set_reserved(&mut self, val: __u64) {
14449 unsafe {
14450 let val: u64 = ::std::mem::transmute(val);
14451 self._bitfield_1.set(8usize, 56u8, val as u64)
14452 }
14453 }
14454 #[inline]
14455 pub fn new_bitfield_1(
14456 cache_type: __u64,
14457 reserved: __u64,
14458 ) -> __BindgenBitfieldUnit<[u8; 8usize]> {
14459 let mut __bindgen_bitfield_unit: __BindgenBitfieldUnit<[u8; 8usize]> = Default::default();
14460 __bindgen_bitfield_unit.set(0usize, 8u8, {
14461 let cache_type: u64 = unsafe { ::std::mem::transmute(cache_type) };
14462 cache_type as u64
14463 });
14464 __bindgen_bitfield_unit.set(8usize, 56u8, {
14465 let reserved: u64 = unsafe { ::std::mem::transmute(reserved) };
14466 reserved as u64
14467 });
14468 __bindgen_bitfield_unit
14469 }
14470}
14471#[test]
14472fn bindgen_test_layout_hv_access_gpa_control_flags() {
14473 const UNINIT: ::std::mem::MaybeUninit<hv_access_gpa_control_flags> =
14474 ::std::mem::MaybeUninit::uninit();
14475 let ptr = UNINIT.as_ptr();
14476 assert_eq!(
14477 ::std::mem::size_of::<hv_access_gpa_control_flags>(),
14478 8usize,
14479 concat!("Size of: ", stringify!(hv_access_gpa_control_flags))
14480 );
14481 assert_eq!(
14482 ::std::mem::align_of::<hv_access_gpa_control_flags>(),
14483 8usize,
14484 concat!("Alignment of ", stringify!(hv_access_gpa_control_flags))
14485 );
14486 assert_eq!(
14487 unsafe { ::std::ptr::addr_of!((*ptr).as_uint64) as usize - ptr as usize },
14488 0usize,
14489 concat!(
14490 "Offset of field: ",
14491 stringify!(hv_access_gpa_control_flags),
14492 "::",
14493 stringify!(as_uint64)
14494 )
14495 );
14496}
14497impl Default for hv_access_gpa_control_flags {
14498 fn default() -> Self {
14499 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
14500 unsafe {
14501 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
14502 s.assume_init()
14503 }
14504 }
14505}
14506#[repr(C, packed)]
14507#[derive(Copy, Clone)]
14508pub struct hv_input_read_gpa {
14509 pub partition_id: __u64,
14510 pub vp_index: __u32,
14511 pub byte_count: __u32,
14512 pub base_gpa: __u64,
14513 pub control_flags: hv_access_gpa_control_flags,
14514}
14515#[test]
14516fn bindgen_test_layout_hv_input_read_gpa() {
14517 const UNINIT: ::std::mem::MaybeUninit<hv_input_read_gpa> = ::std::mem::MaybeUninit::uninit();
14518 let ptr = UNINIT.as_ptr();
14519 assert_eq!(
14520 ::std::mem::size_of::<hv_input_read_gpa>(),
14521 32usize,
14522 concat!("Size of: ", stringify!(hv_input_read_gpa))
14523 );
14524 assert_eq!(
14525 ::std::mem::align_of::<hv_input_read_gpa>(),
14526 1usize,
14527 concat!("Alignment of ", stringify!(hv_input_read_gpa))
14528 );
14529 assert_eq!(
14530 unsafe { ::std::ptr::addr_of!((*ptr).partition_id) as usize - ptr as usize },
14531 0usize,
14532 concat!(
14533 "Offset of field: ",
14534 stringify!(hv_input_read_gpa),
14535 "::",
14536 stringify!(partition_id)
14537 )
14538 );
14539 assert_eq!(
14540 unsafe { ::std::ptr::addr_of!((*ptr).vp_index) as usize - ptr as usize },
14541 8usize,
14542 concat!(
14543 "Offset of field: ",
14544 stringify!(hv_input_read_gpa),
14545 "::",
14546 stringify!(vp_index)
14547 )
14548 );
14549 assert_eq!(
14550 unsafe { ::std::ptr::addr_of!((*ptr).byte_count) as usize - ptr as usize },
14551 12usize,
14552 concat!(
14553 "Offset of field: ",
14554 stringify!(hv_input_read_gpa),
14555 "::",
14556 stringify!(byte_count)
14557 )
14558 );
14559 assert_eq!(
14560 unsafe { ::std::ptr::addr_of!((*ptr).base_gpa) as usize - ptr as usize },
14561 16usize,
14562 concat!(
14563 "Offset of field: ",
14564 stringify!(hv_input_read_gpa),
14565 "::",
14566 stringify!(base_gpa)
14567 )
14568 );
14569 assert_eq!(
14570 unsafe { ::std::ptr::addr_of!((*ptr).control_flags) as usize - ptr as usize },
14571 24usize,
14572 concat!(
14573 "Offset of field: ",
14574 stringify!(hv_input_read_gpa),
14575 "::",
14576 stringify!(control_flags)
14577 )
14578 );
14579}
14580impl Default for hv_input_read_gpa {
14581 fn default() -> Self {
14582 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
14583 unsafe {
14584 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
14585 s.assume_init()
14586 }
14587 }
14588}
14589#[repr(C, packed)]
14590#[derive(Copy, Clone)]
14591pub struct hv_output_read_gpa {
14592 pub access_result: hv_access_gpa_result,
14593 pub data: [__u8; 16usize],
14594}
14595#[test]
14596fn bindgen_test_layout_hv_output_read_gpa() {
14597 const UNINIT: ::std::mem::MaybeUninit<hv_output_read_gpa> = ::std::mem::MaybeUninit::uninit();
14598 let ptr = UNINIT.as_ptr();
14599 assert_eq!(
14600 ::std::mem::size_of::<hv_output_read_gpa>(),
14601 24usize,
14602 concat!("Size of: ", stringify!(hv_output_read_gpa))
14603 );
14604 assert_eq!(
14605 ::std::mem::align_of::<hv_output_read_gpa>(),
14606 1usize,
14607 concat!("Alignment of ", stringify!(hv_output_read_gpa))
14608 );
14609 assert_eq!(
14610 unsafe { ::std::ptr::addr_of!((*ptr).access_result) as usize - ptr as usize },
14611 0usize,
14612 concat!(
14613 "Offset of field: ",
14614 stringify!(hv_output_read_gpa),
14615 "::",
14616 stringify!(access_result)
14617 )
14618 );
14619 assert_eq!(
14620 unsafe { ::std::ptr::addr_of!((*ptr).data) as usize - ptr as usize },
14621 8usize,
14622 concat!(
14623 "Offset of field: ",
14624 stringify!(hv_output_read_gpa),
14625 "::",
14626 stringify!(data)
14627 )
14628 );
14629}
14630impl Default for hv_output_read_gpa {
14631 fn default() -> Self {
14632 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
14633 unsafe {
14634 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
14635 s.assume_init()
14636 }
14637 }
14638}
14639#[repr(C, packed)]
14640#[derive(Copy, Clone)]
14641pub struct hv_input_write_gpa {
14642 pub partition_id: __u64,
14643 pub vp_index: __u32,
14644 pub byte_count: __u32,
14645 pub base_gpa: __u64,
14646 pub control_flags: hv_access_gpa_control_flags,
14647 pub data: [__u8; 16usize],
14648}
14649#[test]
14650fn bindgen_test_layout_hv_input_write_gpa() {
14651 const UNINIT: ::std::mem::MaybeUninit<hv_input_write_gpa> = ::std::mem::MaybeUninit::uninit();
14652 let ptr = UNINIT.as_ptr();
14653 assert_eq!(
14654 ::std::mem::size_of::<hv_input_write_gpa>(),
14655 48usize,
14656 concat!("Size of: ", stringify!(hv_input_write_gpa))
14657 );
14658 assert_eq!(
14659 ::std::mem::align_of::<hv_input_write_gpa>(),
14660 1usize,
14661 concat!("Alignment of ", stringify!(hv_input_write_gpa))
14662 );
14663 assert_eq!(
14664 unsafe { ::std::ptr::addr_of!((*ptr).partition_id) as usize - ptr as usize },
14665 0usize,
14666 concat!(
14667 "Offset of field: ",
14668 stringify!(hv_input_write_gpa),
14669 "::",
14670 stringify!(partition_id)
14671 )
14672 );
14673 assert_eq!(
14674 unsafe { ::std::ptr::addr_of!((*ptr).vp_index) as usize - ptr as usize },
14675 8usize,
14676 concat!(
14677 "Offset of field: ",
14678 stringify!(hv_input_write_gpa),
14679 "::",
14680 stringify!(vp_index)
14681 )
14682 );
14683 assert_eq!(
14684 unsafe { ::std::ptr::addr_of!((*ptr).byte_count) as usize - ptr as usize },
14685 12usize,
14686 concat!(
14687 "Offset of field: ",
14688 stringify!(hv_input_write_gpa),
14689 "::",
14690 stringify!(byte_count)
14691 )
14692 );
14693 assert_eq!(
14694 unsafe { ::std::ptr::addr_of!((*ptr).base_gpa) as usize - ptr as usize },
14695 16usize,
14696 concat!(
14697 "Offset of field: ",
14698 stringify!(hv_input_write_gpa),
14699 "::",
14700 stringify!(base_gpa)
14701 )
14702 );
14703 assert_eq!(
14704 unsafe { ::std::ptr::addr_of!((*ptr).control_flags) as usize - ptr as usize },
14705 24usize,
14706 concat!(
14707 "Offset of field: ",
14708 stringify!(hv_input_write_gpa),
14709 "::",
14710 stringify!(control_flags)
14711 )
14712 );
14713 assert_eq!(
14714 unsafe { ::std::ptr::addr_of!((*ptr).data) as usize - ptr as usize },
14715 32usize,
14716 concat!(
14717 "Offset of field: ",
14718 stringify!(hv_input_write_gpa),
14719 "::",
14720 stringify!(data)
14721 )
14722 );
14723}
14724impl Default for hv_input_write_gpa {
14725 fn default() -> Self {
14726 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
14727 unsafe {
14728 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
14729 s.assume_init()
14730 }
14731 }
14732}
14733#[repr(C, packed)]
14734#[derive(Copy, Clone)]
14735pub struct hv_output_write_gpa {
14736 pub access_result: hv_access_gpa_result,
14737}
14738#[test]
14739fn bindgen_test_layout_hv_output_write_gpa() {
14740 const UNINIT: ::std::mem::MaybeUninit<hv_output_write_gpa> = ::std::mem::MaybeUninit::uninit();
14741 let ptr = UNINIT.as_ptr();
14742 assert_eq!(
14743 ::std::mem::size_of::<hv_output_write_gpa>(),
14744 8usize,
14745 concat!("Size of: ", stringify!(hv_output_write_gpa))
14746 );
14747 assert_eq!(
14748 ::std::mem::align_of::<hv_output_write_gpa>(),
14749 1usize,
14750 concat!("Alignment of ", stringify!(hv_output_write_gpa))
14751 );
14752 assert_eq!(
14753 unsafe { ::std::ptr::addr_of!((*ptr).access_result) as usize - ptr as usize },
14754 0usize,
14755 concat!(
14756 "Offset of field: ",
14757 stringify!(hv_output_write_gpa),
14758 "::",
14759 stringify!(access_result)
14760 )
14761 );
14762}
14763impl Default for hv_output_write_gpa {
14764 fn default() -> Self {
14765 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
14766 unsafe {
14767 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
14768 s.assume_init()
14769 }
14770 }
14771}
14772#[repr(C, packed)]
14773#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
14774pub struct hv_input_issue_psp_guest_request {
14775 pub partition_id: __u64,
14776 pub request_page: __u64,
14777 pub response_page: __u64,
14778}
14779#[test]
14780fn bindgen_test_layout_hv_input_issue_psp_guest_request() {
14781 const UNINIT: ::std::mem::MaybeUninit<hv_input_issue_psp_guest_request> =
14782 ::std::mem::MaybeUninit::uninit();
14783 let ptr = UNINIT.as_ptr();
14784 assert_eq!(
14785 ::std::mem::size_of::<hv_input_issue_psp_guest_request>(),
14786 24usize,
14787 concat!("Size of: ", stringify!(hv_input_issue_psp_guest_request))
14788 );
14789 assert_eq!(
14790 ::std::mem::align_of::<hv_input_issue_psp_guest_request>(),
14791 1usize,
14792 concat!(
14793 "Alignment of ",
14794 stringify!(hv_input_issue_psp_guest_request)
14795 )
14796 );
14797 assert_eq!(
14798 unsafe { ::std::ptr::addr_of!((*ptr).partition_id) as usize - ptr as usize },
14799 0usize,
14800 concat!(
14801 "Offset of field: ",
14802 stringify!(hv_input_issue_psp_guest_request),
14803 "::",
14804 stringify!(partition_id)
14805 )
14806 );
14807 assert_eq!(
14808 unsafe { ::std::ptr::addr_of!((*ptr).request_page) as usize - ptr as usize },
14809 8usize,
14810 concat!(
14811 "Offset of field: ",
14812 stringify!(hv_input_issue_psp_guest_request),
14813 "::",
14814 stringify!(request_page)
14815 )
14816 );
14817 assert_eq!(
14818 unsafe { ::std::ptr::addr_of!((*ptr).response_page) as usize - ptr as usize },
14819 16usize,
14820 concat!(
14821 "Offset of field: ",
14822 stringify!(hv_input_issue_psp_guest_request),
14823 "::",
14824 stringify!(response_page)
14825 )
14826 );
14827}
14828#[repr(C)]
14829#[derive(Debug, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
14830pub struct mshv_vp_registers {
14831 pub count: ::std::os::raw::c_int,
14832 pub regs: *mut hv_register_assoc,
14833}
14834#[test]
14835fn bindgen_test_layout_mshv_vp_registers() {
14836 const UNINIT: ::std::mem::MaybeUninit<mshv_vp_registers> = ::std::mem::MaybeUninit::uninit();
14837 let ptr = UNINIT.as_ptr();
14838 assert_eq!(
14839 ::std::mem::size_of::<mshv_vp_registers>(),
14840 16usize,
14841 concat!("Size of: ", stringify!(mshv_vp_registers))
14842 );
14843 assert_eq!(
14844 ::std::mem::align_of::<mshv_vp_registers>(),
14845 8usize,
14846 concat!("Alignment of ", stringify!(mshv_vp_registers))
14847 );
14848 assert_eq!(
14849 unsafe { ::std::ptr::addr_of!((*ptr).count) as usize - ptr as usize },
14850 0usize,
14851 concat!(
14852 "Offset of field: ",
14853 stringify!(mshv_vp_registers),
14854 "::",
14855 stringify!(count)
14856 )
14857 );
14858 assert_eq!(
14859 unsafe { ::std::ptr::addr_of!((*ptr).regs) as usize - ptr as usize },
14860 8usize,
14861 concat!(
14862 "Offset of field: ",
14863 stringify!(mshv_vp_registers),
14864 "::",
14865 stringify!(regs)
14866 )
14867 );
14868}
14869impl Default for mshv_vp_registers {
14870 fn default() -> Self {
14871 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
14872 unsafe {
14873 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
14874 s.assume_init()
14875 }
14876 }
14877}
14878#[repr(C)]
14879#[derive(Copy, Clone)]
14880pub struct mshv_install_intercept {
14881 pub access_type_mask: __u32,
14882 pub intercept_type: hv_intercept_type,
14883 pub intercept_parameter: hv_intercept_parameters,
14884}
14885#[test]
14886fn bindgen_test_layout_mshv_install_intercept() {
14887 const UNINIT: ::std::mem::MaybeUninit<mshv_install_intercept> =
14888 ::std::mem::MaybeUninit::uninit();
14889 let ptr = UNINIT.as_ptr();
14890 assert_eq!(
14891 ::std::mem::size_of::<mshv_install_intercept>(),
14892 16usize,
14893 concat!("Size of: ", stringify!(mshv_install_intercept))
14894 );
14895 assert_eq!(
14896 ::std::mem::align_of::<mshv_install_intercept>(),
14897 8usize,
14898 concat!("Alignment of ", stringify!(mshv_install_intercept))
14899 );
14900 assert_eq!(
14901 unsafe { ::std::ptr::addr_of!((*ptr).access_type_mask) as usize - ptr as usize },
14902 0usize,
14903 concat!(
14904 "Offset of field: ",
14905 stringify!(mshv_install_intercept),
14906 "::",
14907 stringify!(access_type_mask)
14908 )
14909 );
14910 assert_eq!(
14911 unsafe { ::std::ptr::addr_of!((*ptr).intercept_type) as usize - ptr as usize },
14912 4usize,
14913 concat!(
14914 "Offset of field: ",
14915 stringify!(mshv_install_intercept),
14916 "::",
14917 stringify!(intercept_type)
14918 )
14919 );
14920 assert_eq!(
14921 unsafe { ::std::ptr::addr_of!((*ptr).intercept_parameter) as usize - ptr as usize },
14922 8usize,
14923 concat!(
14924 "Offset of field: ",
14925 stringify!(mshv_install_intercept),
14926 "::",
14927 stringify!(intercept_parameter)
14928 )
14929 );
14930}
14931impl Default for mshv_install_intercept {
14932 fn default() -> Self {
14933 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
14934 unsafe {
14935 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
14936 s.assume_init()
14937 }
14938 }
14939}
14940#[repr(C)]
14941#[derive(Copy, Clone)]
14942pub struct mshv_assert_interrupt {
14943 pub control: hv_interrupt_control,
14944 pub dest_addr: __u64,
14945 pub vector: __u32,
14946 pub rsvd: __u32,
14947}
14948#[test]
14949fn bindgen_test_layout_mshv_assert_interrupt() {
14950 const UNINIT: ::std::mem::MaybeUninit<mshv_assert_interrupt> =
14951 ::std::mem::MaybeUninit::uninit();
14952 let ptr = UNINIT.as_ptr();
14953 assert_eq!(
14954 ::std::mem::size_of::<mshv_assert_interrupt>(),
14955 24usize,
14956 concat!("Size of: ", stringify!(mshv_assert_interrupt))
14957 );
14958 assert_eq!(
14959 ::std::mem::align_of::<mshv_assert_interrupt>(),
14960 8usize,
14961 concat!("Alignment of ", stringify!(mshv_assert_interrupt))
14962 );
14963 assert_eq!(
14964 unsafe { ::std::ptr::addr_of!((*ptr).control) as usize - ptr as usize },
14965 0usize,
14966 concat!(
14967 "Offset of field: ",
14968 stringify!(mshv_assert_interrupt),
14969 "::",
14970 stringify!(control)
14971 )
14972 );
14973 assert_eq!(
14974 unsafe { ::std::ptr::addr_of!((*ptr).dest_addr) as usize - ptr as usize },
14975 8usize,
14976 concat!(
14977 "Offset of field: ",
14978 stringify!(mshv_assert_interrupt),
14979 "::",
14980 stringify!(dest_addr)
14981 )
14982 );
14983 assert_eq!(
14984 unsafe { ::std::ptr::addr_of!((*ptr).vector) as usize - ptr as usize },
14985 16usize,
14986 concat!(
14987 "Offset of field: ",
14988 stringify!(mshv_assert_interrupt),
14989 "::",
14990 stringify!(vector)
14991 )
14992 );
14993 assert_eq!(
14994 unsafe { ::std::ptr::addr_of!((*ptr).rsvd) as usize - ptr as usize },
14995 20usize,
14996 concat!(
14997 "Offset of field: ",
14998 stringify!(mshv_assert_interrupt),
14999 "::",
15000 stringify!(rsvd)
15001 )
15002 );
15003}
15004impl Default for mshv_assert_interrupt {
15005 fn default() -> Self {
15006 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
15007 unsafe {
15008 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
15009 s.assume_init()
15010 }
15011 }
15012}
15013#[repr(C)]
15014#[derive(Debug, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
15015pub struct mshv_partition_property {
15016 pub property_code: hv_partition_property_code,
15017 pub property_value: __u64,
15018}
15019#[test]
15020fn bindgen_test_layout_mshv_partition_property() {
15021 const UNINIT: ::std::mem::MaybeUninit<mshv_partition_property> =
15022 ::std::mem::MaybeUninit::uninit();
15023 let ptr = UNINIT.as_ptr();
15024 assert_eq!(
15025 ::std::mem::size_of::<mshv_partition_property>(),
15026 16usize,
15027 concat!("Size of: ", stringify!(mshv_partition_property))
15028 );
15029 assert_eq!(
15030 ::std::mem::align_of::<mshv_partition_property>(),
15031 8usize,
15032 concat!("Alignment of ", stringify!(mshv_partition_property))
15033 );
15034 assert_eq!(
15035 unsafe { ::std::ptr::addr_of!((*ptr).property_code) as usize - ptr as usize },
15036 0usize,
15037 concat!(
15038 "Offset of field: ",
15039 stringify!(mshv_partition_property),
15040 "::",
15041 stringify!(property_code)
15042 )
15043 );
15044 assert_eq!(
15045 unsafe { ::std::ptr::addr_of!((*ptr).property_value) as usize - ptr as usize },
15046 8usize,
15047 concat!(
15048 "Offset of field: ",
15049 stringify!(mshv_partition_property),
15050 "::",
15051 stringify!(property_value)
15052 )
15053 );
15054}
15055impl Default for mshv_partition_property {
15056 fn default() -> Self {
15057 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
15058 unsafe {
15059 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
15060 s.assume_init()
15061 }
15062 }
15063}
15064#[repr(C)]
15065#[derive(Debug, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
15066pub struct mshv_translate_gva {
15067 pub gva: __u64,
15068 pub flags: __u64,
15069 pub result: *mut hv_translate_gva_result,
15070 pub gpa: *mut __u64,
15071}
15072#[test]
15073fn bindgen_test_layout_mshv_translate_gva() {
15074 const UNINIT: ::std::mem::MaybeUninit<mshv_translate_gva> = ::std::mem::MaybeUninit::uninit();
15075 let ptr = UNINIT.as_ptr();
15076 assert_eq!(
15077 ::std::mem::size_of::<mshv_translate_gva>(),
15078 32usize,
15079 concat!("Size of: ", stringify!(mshv_translate_gva))
15080 );
15081 assert_eq!(
15082 ::std::mem::align_of::<mshv_translate_gva>(),
15083 8usize,
15084 concat!("Alignment of ", stringify!(mshv_translate_gva))
15085 );
15086 assert_eq!(
15087 unsafe { ::std::ptr::addr_of!((*ptr).gva) as usize - ptr as usize },
15088 0usize,
15089 concat!(
15090 "Offset of field: ",
15091 stringify!(mshv_translate_gva),
15092 "::",
15093 stringify!(gva)
15094 )
15095 );
15096 assert_eq!(
15097 unsafe { ::std::ptr::addr_of!((*ptr).flags) as usize - ptr as usize },
15098 8usize,
15099 concat!(
15100 "Offset of field: ",
15101 stringify!(mshv_translate_gva),
15102 "::",
15103 stringify!(flags)
15104 )
15105 );
15106 assert_eq!(
15107 unsafe { ::std::ptr::addr_of!((*ptr).result) as usize - ptr as usize },
15108 16usize,
15109 concat!(
15110 "Offset of field: ",
15111 stringify!(mshv_translate_gva),
15112 "::",
15113 stringify!(result)
15114 )
15115 );
15116 assert_eq!(
15117 unsafe { ::std::ptr::addr_of!((*ptr).gpa) as usize - ptr as usize },
15118 24usize,
15119 concat!(
15120 "Offset of field: ",
15121 stringify!(mshv_translate_gva),
15122 "::",
15123 stringify!(gpa)
15124 )
15125 );
15126}
15127impl Default for mshv_translate_gva {
15128 fn default() -> Self {
15129 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
15130 unsafe {
15131 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
15132 s.assume_init()
15133 }
15134 }
15135}
15136#[repr(C)]
15137#[derive(Copy, Clone)]
15138pub struct mshv_register_intercept_result {
15139 pub intercept_type: __u32,
15140 pub parameters: hv_register_intercept_result_parameters,
15141}
15142#[test]
15143fn bindgen_test_layout_mshv_register_intercept_result() {
15144 const UNINIT: ::std::mem::MaybeUninit<mshv_register_intercept_result> =
15145 ::std::mem::MaybeUninit::uninit();
15146 let ptr = UNINIT.as_ptr();
15147 assert_eq!(
15148 ::std::mem::size_of::<mshv_register_intercept_result>(),
15149 48usize,
15150 concat!("Size of: ", stringify!(mshv_register_intercept_result))
15151 );
15152 assert_eq!(
15153 ::std::mem::align_of::<mshv_register_intercept_result>(),
15154 4usize,
15155 concat!("Alignment of ", stringify!(mshv_register_intercept_result))
15156 );
15157 assert_eq!(
15158 unsafe { ::std::ptr::addr_of!((*ptr).intercept_type) as usize - ptr as usize },
15159 0usize,
15160 concat!(
15161 "Offset of field: ",
15162 stringify!(mshv_register_intercept_result),
15163 "::",
15164 stringify!(intercept_type)
15165 )
15166 );
15167 assert_eq!(
15168 unsafe { ::std::ptr::addr_of!((*ptr).parameters) as usize - ptr as usize },
15169 4usize,
15170 concat!(
15171 "Offset of field: ",
15172 stringify!(mshv_register_intercept_result),
15173 "::",
15174 stringify!(parameters)
15175 )
15176 );
15177}
15178impl Default for mshv_register_intercept_result {
15179 fn default() -> Self {
15180 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
15181 unsafe {
15182 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
15183 s.assume_init()
15184 }
15185 }
15186}
15187#[repr(C)]
15188#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
15189pub struct mshv_signal_event_direct {
15190 pub vp: __u32,
15191 pub vtl: __u8,
15192 pub sint: __u8,
15193 pub flag: __u16,
15194 pub newly_signaled: __u8,
15195}
15196#[test]
15197fn bindgen_test_layout_mshv_signal_event_direct() {
15198 const UNINIT: ::std::mem::MaybeUninit<mshv_signal_event_direct> =
15199 ::std::mem::MaybeUninit::uninit();
15200 let ptr = UNINIT.as_ptr();
15201 assert_eq!(
15202 ::std::mem::size_of::<mshv_signal_event_direct>(),
15203 12usize,
15204 concat!("Size of: ", stringify!(mshv_signal_event_direct))
15205 );
15206 assert_eq!(
15207 ::std::mem::align_of::<mshv_signal_event_direct>(),
15208 4usize,
15209 concat!("Alignment of ", stringify!(mshv_signal_event_direct))
15210 );
15211 assert_eq!(
15212 unsafe { ::std::ptr::addr_of!((*ptr).vp) as usize - ptr as usize },
15213 0usize,
15214 concat!(
15215 "Offset of field: ",
15216 stringify!(mshv_signal_event_direct),
15217 "::",
15218 stringify!(vp)
15219 )
15220 );
15221 assert_eq!(
15222 unsafe { ::std::ptr::addr_of!((*ptr).vtl) as usize - ptr as usize },
15223 4usize,
15224 concat!(
15225 "Offset of field: ",
15226 stringify!(mshv_signal_event_direct),
15227 "::",
15228 stringify!(vtl)
15229 )
15230 );
15231 assert_eq!(
15232 unsafe { ::std::ptr::addr_of!((*ptr).sint) as usize - ptr as usize },
15233 5usize,
15234 concat!(
15235 "Offset of field: ",
15236 stringify!(mshv_signal_event_direct),
15237 "::",
15238 stringify!(sint)
15239 )
15240 );
15241 assert_eq!(
15242 unsafe { ::std::ptr::addr_of!((*ptr).flag) as usize - ptr as usize },
15243 6usize,
15244 concat!(
15245 "Offset of field: ",
15246 stringify!(mshv_signal_event_direct),
15247 "::",
15248 stringify!(flag)
15249 )
15250 );
15251 assert_eq!(
15252 unsafe { ::std::ptr::addr_of!((*ptr).newly_signaled) as usize - ptr as usize },
15253 8usize,
15254 concat!(
15255 "Offset of field: ",
15256 stringify!(mshv_signal_event_direct),
15257 "::",
15258 stringify!(newly_signaled)
15259 )
15260 );
15261}
15262#[repr(C)]
15263#[derive(Debug, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
15264pub struct mshv_post_message_direct {
15265 pub vp: __u32,
15266 pub vtl: __u8,
15267 pub sint: __u8,
15268 pub length: __u16,
15269 pub message: *const __u8,
15270}
15271#[test]
15272fn bindgen_test_layout_mshv_post_message_direct() {
15273 const UNINIT: ::std::mem::MaybeUninit<mshv_post_message_direct> =
15274 ::std::mem::MaybeUninit::uninit();
15275 let ptr = UNINIT.as_ptr();
15276 assert_eq!(
15277 ::std::mem::size_of::<mshv_post_message_direct>(),
15278 16usize,
15279 concat!("Size of: ", stringify!(mshv_post_message_direct))
15280 );
15281 assert_eq!(
15282 ::std::mem::align_of::<mshv_post_message_direct>(),
15283 8usize,
15284 concat!("Alignment of ", stringify!(mshv_post_message_direct))
15285 );
15286 assert_eq!(
15287 unsafe { ::std::ptr::addr_of!((*ptr).vp) as usize - ptr as usize },
15288 0usize,
15289 concat!(
15290 "Offset of field: ",
15291 stringify!(mshv_post_message_direct),
15292 "::",
15293 stringify!(vp)
15294 )
15295 );
15296 assert_eq!(
15297 unsafe { ::std::ptr::addr_of!((*ptr).vtl) as usize - ptr as usize },
15298 4usize,
15299 concat!(
15300 "Offset of field: ",
15301 stringify!(mshv_post_message_direct),
15302 "::",
15303 stringify!(vtl)
15304 )
15305 );
15306 assert_eq!(
15307 unsafe { ::std::ptr::addr_of!((*ptr).sint) as usize - ptr as usize },
15308 5usize,
15309 concat!(
15310 "Offset of field: ",
15311 stringify!(mshv_post_message_direct),
15312 "::",
15313 stringify!(sint)
15314 )
15315 );
15316 assert_eq!(
15317 unsafe { ::std::ptr::addr_of!((*ptr).length) as usize - ptr as usize },
15318 6usize,
15319 concat!(
15320 "Offset of field: ",
15321 stringify!(mshv_post_message_direct),
15322 "::",
15323 stringify!(length)
15324 )
15325 );
15326 assert_eq!(
15327 unsafe { ::std::ptr::addr_of!((*ptr).message) as usize - ptr as usize },
15328 8usize,
15329 concat!(
15330 "Offset of field: ",
15331 stringify!(mshv_post_message_direct),
15332 "::",
15333 stringify!(message)
15334 )
15335 );
15336}
15337impl Default for mshv_post_message_direct {
15338 fn default() -> Self {
15339 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
15340 unsafe {
15341 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
15342 s.assume_init()
15343 }
15344 }
15345}
15346#[repr(C)]
15347#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
15348pub struct mshv_register_deliverabilty_notifications {
15349 pub vp: __u32,
15350 pub pad: __u32,
15351 pub flag: __u64,
15352}
15353#[test]
15354fn bindgen_test_layout_mshv_register_deliverabilty_notifications() {
15355 const UNINIT: ::std::mem::MaybeUninit<mshv_register_deliverabilty_notifications> =
15356 ::std::mem::MaybeUninit::uninit();
15357 let ptr = UNINIT.as_ptr();
15358 assert_eq!(
15359 ::std::mem::size_of::<mshv_register_deliverabilty_notifications>(),
15360 16usize,
15361 concat!(
15362 "Size of: ",
15363 stringify!(mshv_register_deliverabilty_notifications)
15364 )
15365 );
15366 assert_eq!(
15367 ::std::mem::align_of::<mshv_register_deliverabilty_notifications>(),
15368 8usize,
15369 concat!(
15370 "Alignment of ",
15371 stringify!(mshv_register_deliverabilty_notifications)
15372 )
15373 );
15374 assert_eq!(
15375 unsafe { ::std::ptr::addr_of!((*ptr).vp) as usize - ptr as usize },
15376 0usize,
15377 concat!(
15378 "Offset of field: ",
15379 stringify!(mshv_register_deliverabilty_notifications),
15380 "::",
15381 stringify!(vp)
15382 )
15383 );
15384 assert_eq!(
15385 unsafe { ::std::ptr::addr_of!((*ptr).pad) as usize - ptr as usize },
15386 4usize,
15387 concat!(
15388 "Offset of field: ",
15389 stringify!(mshv_register_deliverabilty_notifications),
15390 "::",
15391 stringify!(pad)
15392 )
15393 );
15394 assert_eq!(
15395 unsafe { ::std::ptr::addr_of!((*ptr).flag) as usize - ptr as usize },
15396 8usize,
15397 concat!(
15398 "Offset of field: ",
15399 stringify!(mshv_register_deliverabilty_notifications),
15400 "::",
15401 stringify!(flag)
15402 )
15403 );
15404}
15405#[repr(C)]
15406#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
15407pub struct mshv_get_vp_cpuid_values {
15408 pub function: __u32,
15409 pub index: __u32,
15410 pub xfem: __u64,
15411 pub xss: __u64,
15412 pub eax: __u32,
15413 pub ebx: __u32,
15414 pub ecx: __u32,
15415 pub edx: __u32,
15416}
15417#[test]
15418fn bindgen_test_layout_mshv_get_vp_cpuid_values() {
15419 const UNINIT: ::std::mem::MaybeUninit<mshv_get_vp_cpuid_values> =
15420 ::std::mem::MaybeUninit::uninit();
15421 let ptr = UNINIT.as_ptr();
15422 assert_eq!(
15423 ::std::mem::size_of::<mshv_get_vp_cpuid_values>(),
15424 40usize,
15425 concat!("Size of: ", stringify!(mshv_get_vp_cpuid_values))
15426 );
15427 assert_eq!(
15428 ::std::mem::align_of::<mshv_get_vp_cpuid_values>(),
15429 8usize,
15430 concat!("Alignment of ", stringify!(mshv_get_vp_cpuid_values))
15431 );
15432 assert_eq!(
15433 unsafe { ::std::ptr::addr_of!((*ptr).function) as usize - ptr as usize },
15434 0usize,
15435 concat!(
15436 "Offset of field: ",
15437 stringify!(mshv_get_vp_cpuid_values),
15438 "::",
15439 stringify!(function)
15440 )
15441 );
15442 assert_eq!(
15443 unsafe { ::std::ptr::addr_of!((*ptr).index) as usize - ptr as usize },
15444 4usize,
15445 concat!(
15446 "Offset of field: ",
15447 stringify!(mshv_get_vp_cpuid_values),
15448 "::",
15449 stringify!(index)
15450 )
15451 );
15452 assert_eq!(
15453 unsafe { ::std::ptr::addr_of!((*ptr).xfem) as usize - ptr as usize },
15454 8usize,
15455 concat!(
15456 "Offset of field: ",
15457 stringify!(mshv_get_vp_cpuid_values),
15458 "::",
15459 stringify!(xfem)
15460 )
15461 );
15462 assert_eq!(
15463 unsafe { ::std::ptr::addr_of!((*ptr).xss) as usize - ptr as usize },
15464 16usize,
15465 concat!(
15466 "Offset of field: ",
15467 stringify!(mshv_get_vp_cpuid_values),
15468 "::",
15469 stringify!(xss)
15470 )
15471 );
15472 assert_eq!(
15473 unsafe { ::std::ptr::addr_of!((*ptr).eax) as usize - ptr as usize },
15474 24usize,
15475 concat!(
15476 "Offset of field: ",
15477 stringify!(mshv_get_vp_cpuid_values),
15478 "::",
15479 stringify!(eax)
15480 )
15481 );
15482 assert_eq!(
15483 unsafe { ::std::ptr::addr_of!((*ptr).ebx) as usize - ptr as usize },
15484 28usize,
15485 concat!(
15486 "Offset of field: ",
15487 stringify!(mshv_get_vp_cpuid_values),
15488 "::",
15489 stringify!(ebx)
15490 )
15491 );
15492 assert_eq!(
15493 unsafe { ::std::ptr::addr_of!((*ptr).ecx) as usize - ptr as usize },
15494 32usize,
15495 concat!(
15496 "Offset of field: ",
15497 stringify!(mshv_get_vp_cpuid_values),
15498 "::",
15499 stringify!(ecx)
15500 )
15501 );
15502 assert_eq!(
15503 unsafe { ::std::ptr::addr_of!((*ptr).edx) as usize - ptr as usize },
15504 36usize,
15505 concat!(
15506 "Offset of field: ",
15507 stringify!(mshv_get_vp_cpuid_values),
15508 "::",
15509 stringify!(edx)
15510 )
15511 );
15512}
15513#[repr(C)]
15514#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
15515pub struct mshv_read_write_gpa {
15516 pub base_gpa: __u64,
15517 pub byte_count: __u32,
15518 pub flags: __u32,
15519 pub data: [__u8; 16usize],
15520}
15521#[test]
15522fn bindgen_test_layout_mshv_read_write_gpa() {
15523 const UNINIT: ::std::mem::MaybeUninit<mshv_read_write_gpa> = ::std::mem::MaybeUninit::uninit();
15524 let ptr = UNINIT.as_ptr();
15525 assert_eq!(
15526 ::std::mem::size_of::<mshv_read_write_gpa>(),
15527 32usize,
15528 concat!("Size of: ", stringify!(mshv_read_write_gpa))
15529 );
15530 assert_eq!(
15531 ::std::mem::align_of::<mshv_read_write_gpa>(),
15532 8usize,
15533 concat!("Alignment of ", stringify!(mshv_read_write_gpa))
15534 );
15535 assert_eq!(
15536 unsafe { ::std::ptr::addr_of!((*ptr).base_gpa) as usize - ptr as usize },
15537 0usize,
15538 concat!(
15539 "Offset of field: ",
15540 stringify!(mshv_read_write_gpa),
15541 "::",
15542 stringify!(base_gpa)
15543 )
15544 );
15545 assert_eq!(
15546 unsafe { ::std::ptr::addr_of!((*ptr).byte_count) as usize - ptr as usize },
15547 8usize,
15548 concat!(
15549 "Offset of field: ",
15550 stringify!(mshv_read_write_gpa),
15551 "::",
15552 stringify!(byte_count)
15553 )
15554 );
15555 assert_eq!(
15556 unsafe { ::std::ptr::addr_of!((*ptr).flags) as usize - ptr as usize },
15557 12usize,
15558 concat!(
15559 "Offset of field: ",
15560 stringify!(mshv_read_write_gpa),
15561 "::",
15562 stringify!(flags)
15563 )
15564 );
15565 assert_eq!(
15566 unsafe { ::std::ptr::addr_of!((*ptr).data) as usize - ptr as usize },
15567 16usize,
15568 concat!(
15569 "Offset of field: ",
15570 stringify!(mshv_read_write_gpa),
15571 "::",
15572 stringify!(data)
15573 )
15574 );
15575}
15576#[repr(C)]
15577#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
15578pub struct mshv_sev_snp_ap_create {
15579 pub vp_id: __u64,
15580 pub vmsa_gpa: __u64,
15581}
15582#[test]
15583fn bindgen_test_layout_mshv_sev_snp_ap_create() {
15584 const UNINIT: ::std::mem::MaybeUninit<mshv_sev_snp_ap_create> =
15585 ::std::mem::MaybeUninit::uninit();
15586 let ptr = UNINIT.as_ptr();
15587 assert_eq!(
15588 ::std::mem::size_of::<mshv_sev_snp_ap_create>(),
15589 16usize,
15590 concat!("Size of: ", stringify!(mshv_sev_snp_ap_create))
15591 );
15592 assert_eq!(
15593 ::std::mem::align_of::<mshv_sev_snp_ap_create>(),
15594 8usize,
15595 concat!("Alignment of ", stringify!(mshv_sev_snp_ap_create))
15596 );
15597 assert_eq!(
15598 unsafe { ::std::ptr::addr_of!((*ptr).vp_id) as usize - ptr as usize },
15599 0usize,
15600 concat!(
15601 "Offset of field: ",
15602 stringify!(mshv_sev_snp_ap_create),
15603 "::",
15604 stringify!(vp_id)
15605 )
15606 );
15607 assert_eq!(
15608 unsafe { ::std::ptr::addr_of!((*ptr).vmsa_gpa) as usize - ptr as usize },
15609 8usize,
15610 concat!(
15611 "Offset of field: ",
15612 stringify!(mshv_sev_snp_ap_create),
15613 "::",
15614 stringify!(vmsa_gpa)
15615 )
15616 );
15617}
15618#[repr(C)]
15619#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
15620pub struct mshv_issue_psp_guest_request {
15621 pub req_gpa: __u64,
15622 pub rsp_gpa: __u64,
15623}
15624#[test]
15625fn bindgen_test_layout_mshv_issue_psp_guest_request() {
15626 const UNINIT: ::std::mem::MaybeUninit<mshv_issue_psp_guest_request> =
15627 ::std::mem::MaybeUninit::uninit();
15628 let ptr = UNINIT.as_ptr();
15629 assert_eq!(
15630 ::std::mem::size_of::<mshv_issue_psp_guest_request>(),
15631 16usize,
15632 concat!("Size of: ", stringify!(mshv_issue_psp_guest_request))
15633 );
15634 assert_eq!(
15635 ::std::mem::align_of::<mshv_issue_psp_guest_request>(),
15636 8usize,
15637 concat!("Alignment of ", stringify!(mshv_issue_psp_guest_request))
15638 );
15639 assert_eq!(
15640 unsafe { ::std::ptr::addr_of!((*ptr).req_gpa) as usize - ptr as usize },
15641 0usize,
15642 concat!(
15643 "Offset of field: ",
15644 stringify!(mshv_issue_psp_guest_request),
15645 "::",
15646 stringify!(req_gpa)
15647 )
15648 );
15649 assert_eq!(
15650 unsafe { ::std::ptr::addr_of!((*ptr).rsp_gpa) as usize - ptr as usize },
15651 8usize,
15652 concat!(
15653 "Offset of field: ",
15654 stringify!(mshv_issue_psp_guest_request),
15655 "::",
15656 stringify!(rsp_gpa)
15657 )
15658 );
15659}
15660#[repr(C)]
15661#[derive(Copy, Clone)]
15662pub struct mshv_complete_isolated_import {
15663 pub import_data: hv_partition_complete_isolated_import_data,
15664}
15665#[test]
15666fn bindgen_test_layout_mshv_complete_isolated_import() {
15667 const UNINIT: ::std::mem::MaybeUninit<mshv_complete_isolated_import> =
15668 ::std::mem::MaybeUninit::uninit();
15669 let ptr = UNINIT.as_ptr();
15670 assert_eq!(
15671 ::std::mem::size_of::<mshv_complete_isolated_import>(),
15672 3334usize,
15673 concat!("Size of: ", stringify!(mshv_complete_isolated_import))
15674 );
15675 assert_eq!(
15676 ::std::mem::align_of::<mshv_complete_isolated_import>(),
15677 1usize,
15678 concat!("Alignment of ", stringify!(mshv_complete_isolated_import))
15679 );
15680 assert_eq!(
15681 unsafe { ::std::ptr::addr_of!((*ptr).import_data) as usize - ptr as usize },
15682 0usize,
15683 concat!(
15684 "Offset of field: ",
15685 stringify!(mshv_complete_isolated_import),
15686 "::",
15687 stringify!(import_data)
15688 )
15689 );
15690}
15691impl Default for mshv_complete_isolated_import {
15692 fn default() -> Self {
15693 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
15694 unsafe {
15695 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
15696 s.assume_init()
15697 }
15698 }
15699}
15700pub const MSHV_VTL_CAP_BIT_REGISTER_PAGE: _bindgen_ty_1 = 0;
15701pub const MSHV_VTL_CAP_BIT_RETURN_ACTION: _bindgen_ty_1 = 1;
15702pub const MSHV_VTL_CAP_BIT_DR6_SHARED: _bindgen_ty_1 = 2;
15703pub const MSHV_VTL_CAP_BIT_COUNT: _bindgen_ty_1 = 3;
15704pub type _bindgen_ty_1 = ::std::os::raw::c_uint;
15705#[repr(C)]
15706#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
15707pub struct mshv_vtl_capabilities {
15708 pub bits: __u64,
15709}
15710#[test]
15711fn bindgen_test_layout_mshv_vtl_capabilities() {
15712 const UNINIT: ::std::mem::MaybeUninit<mshv_vtl_capabilities> =
15713 ::std::mem::MaybeUninit::uninit();
15714 let ptr = UNINIT.as_ptr();
15715 assert_eq!(
15716 ::std::mem::size_of::<mshv_vtl_capabilities>(),
15717 8usize,
15718 concat!("Size of: ", stringify!(mshv_vtl_capabilities))
15719 );
15720 assert_eq!(
15721 ::std::mem::align_of::<mshv_vtl_capabilities>(),
15722 8usize,
15723 concat!("Alignment of ", stringify!(mshv_vtl_capabilities))
15724 );
15725 assert_eq!(
15726 unsafe { ::std::ptr::addr_of!((*ptr).bits) as usize - ptr as usize },
15727 0usize,
15728 concat!(
15729 "Offset of field: ",
15730 stringify!(mshv_vtl_capabilities),
15731 "::",
15732 stringify!(bits)
15733 )
15734 );
15735}
15736pub const MSHV_PT_BIT_LAPIC: _bindgen_ty_2 = 0;
15737pub const MSHV_PT_BIT_X2APIC: _bindgen_ty_2 = 1;
15738pub const MSHV_PT_BIT_GPA_SUPER_PAGES: _bindgen_ty_2 = 2;
15739pub const MSHV_PT_BIT_COUNT: _bindgen_ty_2 = 3;
15740pub type _bindgen_ty_2 = ::std::os::raw::c_uint;
15741pub const MSHV_PT_ISOLATION_NONE: _bindgen_ty_3 = 0;
15742pub const MSHV_PT_ISOLATION_SNP: _bindgen_ty_3 = 1;
15743pub const MSHV_PT_ISOLATION_COUNT: _bindgen_ty_3 = 2;
15744pub type _bindgen_ty_3 = ::std::os::raw::c_uint;
15745#[repr(C)]
15746#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
15747pub struct mshv_create_partition {
15748 pub pt_flags: __u64,
15749 pub pt_isolation: __u64,
15750}
15751#[test]
15752fn bindgen_test_layout_mshv_create_partition() {
15753 const UNINIT: ::std::mem::MaybeUninit<mshv_create_partition> =
15754 ::std::mem::MaybeUninit::uninit();
15755 let ptr = UNINIT.as_ptr();
15756 assert_eq!(
15757 ::std::mem::size_of::<mshv_create_partition>(),
15758 16usize,
15759 concat!("Size of: ", stringify!(mshv_create_partition))
15760 );
15761 assert_eq!(
15762 ::std::mem::align_of::<mshv_create_partition>(),
15763 8usize,
15764 concat!("Alignment of ", stringify!(mshv_create_partition))
15765 );
15766 assert_eq!(
15767 unsafe { ::std::ptr::addr_of!((*ptr).pt_flags) as usize - ptr as usize },
15768 0usize,
15769 concat!(
15770 "Offset of field: ",
15771 stringify!(mshv_create_partition),
15772 "::",
15773 stringify!(pt_flags)
15774 )
15775 );
15776 assert_eq!(
15777 unsafe { ::std::ptr::addr_of!((*ptr).pt_isolation) as usize - ptr as usize },
15778 8usize,
15779 concat!(
15780 "Offset of field: ",
15781 stringify!(mshv_create_partition),
15782 "::",
15783 stringify!(pt_isolation)
15784 )
15785 );
15786}
15787#[repr(C)]
15788#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
15789pub struct mshv_create_vp {
15790 pub vp_index: __u32,
15791}
15792#[test]
15793fn bindgen_test_layout_mshv_create_vp() {
15794 const UNINIT: ::std::mem::MaybeUninit<mshv_create_vp> = ::std::mem::MaybeUninit::uninit();
15795 let ptr = UNINIT.as_ptr();
15796 assert_eq!(
15797 ::std::mem::size_of::<mshv_create_vp>(),
15798 4usize,
15799 concat!("Size of: ", stringify!(mshv_create_vp))
15800 );
15801 assert_eq!(
15802 ::std::mem::align_of::<mshv_create_vp>(),
15803 4usize,
15804 concat!("Alignment of ", stringify!(mshv_create_vp))
15805 );
15806 assert_eq!(
15807 unsafe { ::std::ptr::addr_of!((*ptr).vp_index) as usize - ptr as usize },
15808 0usize,
15809 concat!(
15810 "Offset of field: ",
15811 stringify!(mshv_create_vp),
15812 "::",
15813 stringify!(vp_index)
15814 )
15815 );
15816}
15817pub const MSHV_SET_MEM_BIT_WRITABLE: _bindgen_ty_4 = 0;
15818pub const MSHV_SET_MEM_BIT_EXECUTABLE: _bindgen_ty_4 = 1;
15819pub const MSHV_SET_MEM_BIT_UNMAP: _bindgen_ty_4 = 2;
15820pub const MSHV_SET_MEM_BIT_COUNT: _bindgen_ty_4 = 3;
15821pub type _bindgen_ty_4 = ::std::os::raw::c_uint;
15822#[repr(C)]
15823#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
15824pub struct mshv_user_mem_region {
15825 pub size: __u64,
15826 pub guest_pfn: __u64,
15827 pub userspace_addr: __u64,
15828 pub flags: __u8,
15829 pub rsvd: [__u8; 7usize],
15830}
15831#[test]
15832fn bindgen_test_layout_mshv_user_mem_region() {
15833 const UNINIT: ::std::mem::MaybeUninit<mshv_user_mem_region> = ::std::mem::MaybeUninit::uninit();
15834 let ptr = UNINIT.as_ptr();
15835 assert_eq!(
15836 ::std::mem::size_of::<mshv_user_mem_region>(),
15837 32usize,
15838 concat!("Size of: ", stringify!(mshv_user_mem_region))
15839 );
15840 assert_eq!(
15841 ::std::mem::align_of::<mshv_user_mem_region>(),
15842 8usize,
15843 concat!("Alignment of ", stringify!(mshv_user_mem_region))
15844 );
15845 assert_eq!(
15846 unsafe { ::std::ptr::addr_of!((*ptr).size) as usize - ptr as usize },
15847 0usize,
15848 concat!(
15849 "Offset of field: ",
15850 stringify!(mshv_user_mem_region),
15851 "::",
15852 stringify!(size)
15853 )
15854 );
15855 assert_eq!(
15856 unsafe { ::std::ptr::addr_of!((*ptr).guest_pfn) as usize - ptr as usize },
15857 8usize,
15858 concat!(
15859 "Offset of field: ",
15860 stringify!(mshv_user_mem_region),
15861 "::",
15862 stringify!(guest_pfn)
15863 )
15864 );
15865 assert_eq!(
15866 unsafe { ::std::ptr::addr_of!((*ptr).userspace_addr) as usize - ptr as usize },
15867 16usize,
15868 concat!(
15869 "Offset of field: ",
15870 stringify!(mshv_user_mem_region),
15871 "::",
15872 stringify!(userspace_addr)
15873 )
15874 );
15875 assert_eq!(
15876 unsafe { ::std::ptr::addr_of!((*ptr).flags) as usize - ptr as usize },
15877 24usize,
15878 concat!(
15879 "Offset of field: ",
15880 stringify!(mshv_user_mem_region),
15881 "::",
15882 stringify!(flags)
15883 )
15884 );
15885 assert_eq!(
15886 unsafe { ::std::ptr::addr_of!((*ptr).rsvd) as usize - ptr as usize },
15887 25usize,
15888 concat!(
15889 "Offset of field: ",
15890 stringify!(mshv_user_mem_region),
15891 "::",
15892 stringify!(rsvd)
15893 )
15894 );
15895}
15896pub const MSHV_IRQFD_BIT_DEASSIGN: _bindgen_ty_5 = 0;
15897pub const MSHV_IRQFD_BIT_RESAMPLE: _bindgen_ty_5 = 1;
15898pub const MSHV_IRQFD_BIT_COUNT: _bindgen_ty_5 = 2;
15899pub type _bindgen_ty_5 = ::std::os::raw::c_uint;
15900#[repr(C)]
15901#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
15902pub struct mshv_user_irqfd {
15903 pub fd: __s32,
15904 pub resamplefd: __s32,
15905 pub gsi: __u32,
15906 pub flags: __u32,
15907}
15908#[test]
15909fn bindgen_test_layout_mshv_user_irqfd() {
15910 const UNINIT: ::std::mem::MaybeUninit<mshv_user_irqfd> = ::std::mem::MaybeUninit::uninit();
15911 let ptr = UNINIT.as_ptr();
15912 assert_eq!(
15913 ::std::mem::size_of::<mshv_user_irqfd>(),
15914 16usize,
15915 concat!("Size of: ", stringify!(mshv_user_irqfd))
15916 );
15917 assert_eq!(
15918 ::std::mem::align_of::<mshv_user_irqfd>(),
15919 4usize,
15920 concat!("Alignment of ", stringify!(mshv_user_irqfd))
15921 );
15922 assert_eq!(
15923 unsafe { ::std::ptr::addr_of!((*ptr).fd) as usize - ptr as usize },
15924 0usize,
15925 concat!(
15926 "Offset of field: ",
15927 stringify!(mshv_user_irqfd),
15928 "::",
15929 stringify!(fd)
15930 )
15931 );
15932 assert_eq!(
15933 unsafe { ::std::ptr::addr_of!((*ptr).resamplefd) as usize - ptr as usize },
15934 4usize,
15935 concat!(
15936 "Offset of field: ",
15937 stringify!(mshv_user_irqfd),
15938 "::",
15939 stringify!(resamplefd)
15940 )
15941 );
15942 assert_eq!(
15943 unsafe { ::std::ptr::addr_of!((*ptr).gsi) as usize - ptr as usize },
15944 8usize,
15945 concat!(
15946 "Offset of field: ",
15947 stringify!(mshv_user_irqfd),
15948 "::",
15949 stringify!(gsi)
15950 )
15951 );
15952 assert_eq!(
15953 unsafe { ::std::ptr::addr_of!((*ptr).flags) as usize - ptr as usize },
15954 12usize,
15955 concat!(
15956 "Offset of field: ",
15957 stringify!(mshv_user_irqfd),
15958 "::",
15959 stringify!(flags)
15960 )
15961 );
15962}
15963pub const MSHV_IOEVENTFD_BIT_DATAMATCH: _bindgen_ty_6 = 0;
15964pub const MSHV_IOEVENTFD_BIT_PIO: _bindgen_ty_6 = 1;
15965pub const MSHV_IOEVENTFD_BIT_DEASSIGN: _bindgen_ty_6 = 2;
15966pub const MSHV_IOEVENTFD_BIT_COUNT: _bindgen_ty_6 = 3;
15967pub type _bindgen_ty_6 = ::std::os::raw::c_uint;
15968#[repr(C)]
15969#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
15970pub struct mshv_user_ioeventfd {
15971 pub datamatch: __u64,
15972 pub addr: __u64,
15973 pub len: __u32,
15974 pub fd: __s32,
15975 pub flags: __u32,
15976 pub rsvd: [__u8; 4usize],
15977}
15978#[test]
15979fn bindgen_test_layout_mshv_user_ioeventfd() {
15980 const UNINIT: ::std::mem::MaybeUninit<mshv_user_ioeventfd> = ::std::mem::MaybeUninit::uninit();
15981 let ptr = UNINIT.as_ptr();
15982 assert_eq!(
15983 ::std::mem::size_of::<mshv_user_ioeventfd>(),
15984 32usize,
15985 concat!("Size of: ", stringify!(mshv_user_ioeventfd))
15986 );
15987 assert_eq!(
15988 ::std::mem::align_of::<mshv_user_ioeventfd>(),
15989 8usize,
15990 concat!("Alignment of ", stringify!(mshv_user_ioeventfd))
15991 );
15992 assert_eq!(
15993 unsafe { ::std::ptr::addr_of!((*ptr).datamatch) as usize - ptr as usize },
15994 0usize,
15995 concat!(
15996 "Offset of field: ",
15997 stringify!(mshv_user_ioeventfd),
15998 "::",
15999 stringify!(datamatch)
16000 )
16001 );
16002 assert_eq!(
16003 unsafe { ::std::ptr::addr_of!((*ptr).addr) as usize - ptr as usize },
16004 8usize,
16005 concat!(
16006 "Offset of field: ",
16007 stringify!(mshv_user_ioeventfd),
16008 "::",
16009 stringify!(addr)
16010 )
16011 );
16012 assert_eq!(
16013 unsafe { ::std::ptr::addr_of!((*ptr).len) as usize - ptr as usize },
16014 16usize,
16015 concat!(
16016 "Offset of field: ",
16017 stringify!(mshv_user_ioeventfd),
16018 "::",
16019 stringify!(len)
16020 )
16021 );
16022 assert_eq!(
16023 unsafe { ::std::ptr::addr_of!((*ptr).fd) as usize - ptr as usize },
16024 20usize,
16025 concat!(
16026 "Offset of field: ",
16027 stringify!(mshv_user_ioeventfd),
16028 "::",
16029 stringify!(fd)
16030 )
16031 );
16032 assert_eq!(
16033 unsafe { ::std::ptr::addr_of!((*ptr).flags) as usize - ptr as usize },
16034 24usize,
16035 concat!(
16036 "Offset of field: ",
16037 stringify!(mshv_user_ioeventfd),
16038 "::",
16039 stringify!(flags)
16040 )
16041 );
16042 assert_eq!(
16043 unsafe { ::std::ptr::addr_of!((*ptr).rsvd) as usize - ptr as usize },
16044 28usize,
16045 concat!(
16046 "Offset of field: ",
16047 stringify!(mshv_user_ioeventfd),
16048 "::",
16049 stringify!(rsvd)
16050 )
16051 );
16052}
16053#[repr(C)]
16054#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
16055pub struct mshv_user_irq_entry {
16056 pub gsi: __u32,
16057 pub address_lo: __u32,
16058 pub address_hi: __u32,
16059 pub data: __u32,
16060}
16061#[test]
16062fn bindgen_test_layout_mshv_user_irq_entry() {
16063 const UNINIT: ::std::mem::MaybeUninit<mshv_user_irq_entry> = ::std::mem::MaybeUninit::uninit();
16064 let ptr = UNINIT.as_ptr();
16065 assert_eq!(
16066 ::std::mem::size_of::<mshv_user_irq_entry>(),
16067 16usize,
16068 concat!("Size of: ", stringify!(mshv_user_irq_entry))
16069 );
16070 assert_eq!(
16071 ::std::mem::align_of::<mshv_user_irq_entry>(),
16072 4usize,
16073 concat!("Alignment of ", stringify!(mshv_user_irq_entry))
16074 );
16075 assert_eq!(
16076 unsafe { ::std::ptr::addr_of!((*ptr).gsi) as usize - ptr as usize },
16077 0usize,
16078 concat!(
16079 "Offset of field: ",
16080 stringify!(mshv_user_irq_entry),
16081 "::",
16082 stringify!(gsi)
16083 )
16084 );
16085 assert_eq!(
16086 unsafe { ::std::ptr::addr_of!((*ptr).address_lo) as usize - ptr as usize },
16087 4usize,
16088 concat!(
16089 "Offset of field: ",
16090 stringify!(mshv_user_irq_entry),
16091 "::",
16092 stringify!(address_lo)
16093 )
16094 );
16095 assert_eq!(
16096 unsafe { ::std::ptr::addr_of!((*ptr).address_hi) as usize - ptr as usize },
16097 8usize,
16098 concat!(
16099 "Offset of field: ",
16100 stringify!(mshv_user_irq_entry),
16101 "::",
16102 stringify!(address_hi)
16103 )
16104 );
16105 assert_eq!(
16106 unsafe { ::std::ptr::addr_of!((*ptr).data) as usize - ptr as usize },
16107 12usize,
16108 concat!(
16109 "Offset of field: ",
16110 stringify!(mshv_user_irq_entry),
16111 "::",
16112 stringify!(data)
16113 )
16114 );
16115}
16116#[repr(C)]
16117#[derive(Debug, Default)]
16118pub struct mshv_user_irq_table {
16119 pub nr: __u32,
16120 pub rsvd: __u32,
16121 pub entries: __IncompleteArrayField<mshv_user_irq_entry>,
16122}
16123#[test]
16124fn bindgen_test_layout_mshv_user_irq_table() {
16125 const UNINIT: ::std::mem::MaybeUninit<mshv_user_irq_table> = ::std::mem::MaybeUninit::uninit();
16126 let ptr = UNINIT.as_ptr();
16127 assert_eq!(
16128 ::std::mem::size_of::<mshv_user_irq_table>(),
16129 8usize,
16130 concat!("Size of: ", stringify!(mshv_user_irq_table))
16131 );
16132 assert_eq!(
16133 ::std::mem::align_of::<mshv_user_irq_table>(),
16134 4usize,
16135 concat!("Alignment of ", stringify!(mshv_user_irq_table))
16136 );
16137 assert_eq!(
16138 unsafe { ::std::ptr::addr_of!((*ptr).nr) as usize - ptr as usize },
16139 0usize,
16140 concat!(
16141 "Offset of field: ",
16142 stringify!(mshv_user_irq_table),
16143 "::",
16144 stringify!(nr)
16145 )
16146 );
16147 assert_eq!(
16148 unsafe { ::std::ptr::addr_of!((*ptr).rsvd) as usize - ptr as usize },
16149 4usize,
16150 concat!(
16151 "Offset of field: ",
16152 stringify!(mshv_user_irq_table),
16153 "::",
16154 stringify!(rsvd)
16155 )
16156 );
16157 assert_eq!(
16158 unsafe { ::std::ptr::addr_of!((*ptr).entries) as usize - ptr as usize },
16159 8usize,
16160 concat!(
16161 "Offset of field: ",
16162 stringify!(mshv_user_irq_table),
16163 "::",
16164 stringify!(entries)
16165 )
16166 );
16167}
16168pub const MSHV_GPAP_ACCESS_TYPE_ACCESSED: _bindgen_ty_7 = 0;
16169pub const MSHV_GPAP_ACCESS_TYPE_DIRTY: _bindgen_ty_7 = 1;
16170pub const MSHV_GPAP_ACCESS_TYPE_COUNT: _bindgen_ty_7 = 2;
16171pub type _bindgen_ty_7 = ::std::os::raw::c_uint;
16172pub const MSHV_GPAP_ACCESS_OP_NOOP: _bindgen_ty_8 = 0;
16173pub const MSHV_GPAP_ACCESS_OP_CLEAR: _bindgen_ty_8 = 1;
16174pub const MSHV_GPAP_ACCESS_OP_SET: _bindgen_ty_8 = 2;
16175pub const MSHV_GPAP_ACCESS_OP_COUNT: _bindgen_ty_8 = 3;
16176pub type _bindgen_ty_8 = ::std::os::raw::c_uint;
16177#[repr(C)]
16178#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
16179pub struct mshv_gpap_access_bitmap {
16180 pub access_type: __u8,
16181 pub access_op: __u8,
16182 pub rsvd: [__u8; 6usize],
16183 pub page_count: __u64,
16184 pub gpap_base: __u64,
16185 pub bitmap_ptr: __u64,
16186}
16187#[test]
16188fn bindgen_test_layout_mshv_gpap_access_bitmap() {
16189 const UNINIT: ::std::mem::MaybeUninit<mshv_gpap_access_bitmap> =
16190 ::std::mem::MaybeUninit::uninit();
16191 let ptr = UNINIT.as_ptr();
16192 assert_eq!(
16193 ::std::mem::size_of::<mshv_gpap_access_bitmap>(),
16194 32usize,
16195 concat!("Size of: ", stringify!(mshv_gpap_access_bitmap))
16196 );
16197 assert_eq!(
16198 ::std::mem::align_of::<mshv_gpap_access_bitmap>(),
16199 8usize,
16200 concat!("Alignment of ", stringify!(mshv_gpap_access_bitmap))
16201 );
16202 assert_eq!(
16203 unsafe { ::std::ptr::addr_of!((*ptr).access_type) as usize - ptr as usize },
16204 0usize,
16205 concat!(
16206 "Offset of field: ",
16207 stringify!(mshv_gpap_access_bitmap),
16208 "::",
16209 stringify!(access_type)
16210 )
16211 );
16212 assert_eq!(
16213 unsafe { ::std::ptr::addr_of!((*ptr).access_op) as usize - ptr as usize },
16214 1usize,
16215 concat!(
16216 "Offset of field: ",
16217 stringify!(mshv_gpap_access_bitmap),
16218 "::",
16219 stringify!(access_op)
16220 )
16221 );
16222 assert_eq!(
16223 unsafe { ::std::ptr::addr_of!((*ptr).rsvd) as usize - ptr as usize },
16224 2usize,
16225 concat!(
16226 "Offset of field: ",
16227 stringify!(mshv_gpap_access_bitmap),
16228 "::",
16229 stringify!(rsvd)
16230 )
16231 );
16232 assert_eq!(
16233 unsafe { ::std::ptr::addr_of!((*ptr).page_count) as usize - ptr as usize },
16234 8usize,
16235 concat!(
16236 "Offset of field: ",
16237 stringify!(mshv_gpap_access_bitmap),
16238 "::",
16239 stringify!(page_count)
16240 )
16241 );
16242 assert_eq!(
16243 unsafe { ::std::ptr::addr_of!((*ptr).gpap_base) as usize - ptr as usize },
16244 16usize,
16245 concat!(
16246 "Offset of field: ",
16247 stringify!(mshv_gpap_access_bitmap),
16248 "::",
16249 stringify!(gpap_base)
16250 )
16251 );
16252 assert_eq!(
16253 unsafe { ::std::ptr::addr_of!((*ptr).bitmap_ptr) as usize - ptr as usize },
16254 24usize,
16255 concat!(
16256 "Offset of field: ",
16257 stringify!(mshv_gpap_access_bitmap),
16258 "::",
16259 stringify!(bitmap_ptr)
16260 )
16261 );
16262}
16263pub const MSHV_GPA_HOST_ACCESS_BIT_ACQUIRE: _bindgen_ty_9 = 0;
16264pub const MSHV_GPA_HOST_ACCESS_BIT_READABLE: _bindgen_ty_9 = 1;
16265pub const MSHV_GPA_HOST_ACCESS_BIT_WRITABLE: _bindgen_ty_9 = 2;
16266pub const MSHV_GPA_HOST_ACCESS_BIT_LARGE_PAGE: _bindgen_ty_9 = 3;
16267pub const MSHV_GPA_HOST_ACCESS_BIT_COUNT: _bindgen_ty_9 = 4;
16268pub type _bindgen_ty_9 = ::std::os::raw::c_uint;
16269#[repr(C)]
16270#[derive(Debug, Default)]
16271pub struct mshv_modify_gpa_host_access {
16272 pub flags: __u8,
16273 pub rsvd: [__u8; 7usize],
16274 pub page_count: __u64,
16275 pub guest_pfns: __IncompleteArrayField<__u64>,
16276}
16277#[test]
16278fn bindgen_test_layout_mshv_modify_gpa_host_access() {
16279 const UNINIT: ::std::mem::MaybeUninit<mshv_modify_gpa_host_access> =
16280 ::std::mem::MaybeUninit::uninit();
16281 let ptr = UNINIT.as_ptr();
16282 assert_eq!(
16283 ::std::mem::size_of::<mshv_modify_gpa_host_access>(),
16284 16usize,
16285 concat!("Size of: ", stringify!(mshv_modify_gpa_host_access))
16286 );
16287 assert_eq!(
16288 ::std::mem::align_of::<mshv_modify_gpa_host_access>(),
16289 8usize,
16290 concat!("Alignment of ", stringify!(mshv_modify_gpa_host_access))
16291 );
16292 assert_eq!(
16293 unsafe { ::std::ptr::addr_of!((*ptr).flags) as usize - ptr as usize },
16294 0usize,
16295 concat!(
16296 "Offset of field: ",
16297 stringify!(mshv_modify_gpa_host_access),
16298 "::",
16299 stringify!(flags)
16300 )
16301 );
16302 assert_eq!(
16303 unsafe { ::std::ptr::addr_of!((*ptr).rsvd) as usize - ptr as usize },
16304 1usize,
16305 concat!(
16306 "Offset of field: ",
16307 stringify!(mshv_modify_gpa_host_access),
16308 "::",
16309 stringify!(rsvd)
16310 )
16311 );
16312 assert_eq!(
16313 unsafe { ::std::ptr::addr_of!((*ptr).page_count) as usize - ptr as usize },
16314 8usize,
16315 concat!(
16316 "Offset of field: ",
16317 stringify!(mshv_modify_gpa_host_access),
16318 "::",
16319 stringify!(page_count)
16320 )
16321 );
16322 assert_eq!(
16323 unsafe { ::std::ptr::addr_of!((*ptr).guest_pfns) as usize - ptr as usize },
16324 16usize,
16325 concat!(
16326 "Offset of field: ",
16327 stringify!(mshv_modify_gpa_host_access),
16328 "::",
16329 stringify!(guest_pfns)
16330 )
16331 );
16332}
16333pub const MSHV_ISOLATED_PAGE_NORMAL: _bindgen_ty_10 = 0;
16334pub const MSHV_ISOLATED_PAGE_VMSA: _bindgen_ty_10 = 1;
16335pub const MSHV_ISOLATED_PAGE_ZERO: _bindgen_ty_10 = 2;
16336pub const MSHV_ISOLATED_PAGE_UNMEASURED: _bindgen_ty_10 = 3;
16337pub const MSHV_ISOLATED_PAGE_SECRETS: _bindgen_ty_10 = 4;
16338pub const MSHV_ISOLATED_PAGE_CPUID: _bindgen_ty_10 = 5;
16339pub const MSHV_ISOLATED_PAGE_COUNT: _bindgen_ty_10 = 6;
16340pub type _bindgen_ty_10 = ::std::os::raw::c_uint;
16341#[repr(C)]
16342#[derive(Debug, Default)]
16343pub struct mshv_import_isolated_pages {
16344 pub page_type: __u8,
16345 pub rsvd: [__u8; 7usize],
16346 pub page_count: __u64,
16347 pub guest_pfns: __IncompleteArrayField<__u64>,
16348}
16349#[test]
16350fn bindgen_test_layout_mshv_import_isolated_pages() {
16351 const UNINIT: ::std::mem::MaybeUninit<mshv_import_isolated_pages> =
16352 ::std::mem::MaybeUninit::uninit();
16353 let ptr = UNINIT.as_ptr();
16354 assert_eq!(
16355 ::std::mem::size_of::<mshv_import_isolated_pages>(),
16356 16usize,
16357 concat!("Size of: ", stringify!(mshv_import_isolated_pages))
16358 );
16359 assert_eq!(
16360 ::std::mem::align_of::<mshv_import_isolated_pages>(),
16361 8usize,
16362 concat!("Alignment of ", stringify!(mshv_import_isolated_pages))
16363 );
16364 assert_eq!(
16365 unsafe { ::std::ptr::addr_of!((*ptr).page_type) as usize - ptr as usize },
16366 0usize,
16367 concat!(
16368 "Offset of field: ",
16369 stringify!(mshv_import_isolated_pages),
16370 "::",
16371 stringify!(page_type)
16372 )
16373 );
16374 assert_eq!(
16375 unsafe { ::std::ptr::addr_of!((*ptr).rsvd) as usize - ptr as usize },
16376 1usize,
16377 concat!(
16378 "Offset of field: ",
16379 stringify!(mshv_import_isolated_pages),
16380 "::",
16381 stringify!(rsvd)
16382 )
16383 );
16384 assert_eq!(
16385 unsafe { ::std::ptr::addr_of!((*ptr).page_count) as usize - ptr as usize },
16386 8usize,
16387 concat!(
16388 "Offset of field: ",
16389 stringify!(mshv_import_isolated_pages),
16390 "::",
16391 stringify!(page_count)
16392 )
16393 );
16394 assert_eq!(
16395 unsafe { ::std::ptr::addr_of!((*ptr).guest_pfns) as usize - ptr as usize },
16396 16usize,
16397 concat!(
16398 "Offset of field: ",
16399 stringify!(mshv_import_isolated_pages),
16400 "::",
16401 stringify!(guest_pfns)
16402 )
16403 );
16404}
16405#[repr(C)]
16406#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
16407pub struct mshv_root_hvcall {
16408 pub code: __u16,
16409 pub reps: __u16,
16410 pub in_sz: __u16,
16411 pub out_sz: __u16,
16412 pub status: __u16,
16413 pub rsvd: [__u8; 6usize],
16414 pub in_ptr: __u64,
16415 pub out_ptr: __u64,
16416}
16417#[test]
16418fn bindgen_test_layout_mshv_root_hvcall() {
16419 const UNINIT: ::std::mem::MaybeUninit<mshv_root_hvcall> = ::std::mem::MaybeUninit::uninit();
16420 let ptr = UNINIT.as_ptr();
16421 assert_eq!(
16422 ::std::mem::size_of::<mshv_root_hvcall>(),
16423 32usize,
16424 concat!("Size of: ", stringify!(mshv_root_hvcall))
16425 );
16426 assert_eq!(
16427 ::std::mem::align_of::<mshv_root_hvcall>(),
16428 8usize,
16429 concat!("Alignment of ", stringify!(mshv_root_hvcall))
16430 );
16431 assert_eq!(
16432 unsafe { ::std::ptr::addr_of!((*ptr).code) as usize - ptr as usize },
16433 0usize,
16434 concat!(
16435 "Offset of field: ",
16436 stringify!(mshv_root_hvcall),
16437 "::",
16438 stringify!(code)
16439 )
16440 );
16441 assert_eq!(
16442 unsafe { ::std::ptr::addr_of!((*ptr).reps) as usize - ptr as usize },
16443 2usize,
16444 concat!(
16445 "Offset of field: ",
16446 stringify!(mshv_root_hvcall),
16447 "::",
16448 stringify!(reps)
16449 )
16450 );
16451 assert_eq!(
16452 unsafe { ::std::ptr::addr_of!((*ptr).in_sz) as usize - ptr as usize },
16453 4usize,
16454 concat!(
16455 "Offset of field: ",
16456 stringify!(mshv_root_hvcall),
16457 "::",
16458 stringify!(in_sz)
16459 )
16460 );
16461 assert_eq!(
16462 unsafe { ::std::ptr::addr_of!((*ptr).out_sz) as usize - ptr as usize },
16463 6usize,
16464 concat!(
16465 "Offset of field: ",
16466 stringify!(mshv_root_hvcall),
16467 "::",
16468 stringify!(out_sz)
16469 )
16470 );
16471 assert_eq!(
16472 unsafe { ::std::ptr::addr_of!((*ptr).status) as usize - ptr as usize },
16473 8usize,
16474 concat!(
16475 "Offset of field: ",
16476 stringify!(mshv_root_hvcall),
16477 "::",
16478 stringify!(status)
16479 )
16480 );
16481 assert_eq!(
16482 unsafe { ::std::ptr::addr_of!((*ptr).rsvd) as usize - ptr as usize },
16483 10usize,
16484 concat!(
16485 "Offset of field: ",
16486 stringify!(mshv_root_hvcall),
16487 "::",
16488 stringify!(rsvd)
16489 )
16490 );
16491 assert_eq!(
16492 unsafe { ::std::ptr::addr_of!((*ptr).in_ptr) as usize - ptr as usize },
16493 16usize,
16494 concat!(
16495 "Offset of field: ",
16496 stringify!(mshv_root_hvcall),
16497 "::",
16498 stringify!(in_ptr)
16499 )
16500 );
16501 assert_eq!(
16502 unsafe { ::std::ptr::addr_of!((*ptr).out_ptr) as usize - ptr as usize },
16503 24usize,
16504 concat!(
16505 "Offset of field: ",
16506 stringify!(mshv_root_hvcall),
16507 "::",
16508 stringify!(out_ptr)
16509 )
16510 );
16511}
16512pub const MSHV_VP_MMAP_OFFSET_REGISTERS: _bindgen_ty_11 = 0;
16513pub const MSHV_VP_MMAP_OFFSET_INTERCEPT_MESSAGE: _bindgen_ty_11 = 1;
16514pub const MSHV_VP_MMAP_OFFSET_GHCB: _bindgen_ty_11 = 2;
16515pub const MSHV_VP_MMAP_OFFSET_COUNT: _bindgen_ty_11 = 3;
16516pub type _bindgen_ty_11 = ::std::os::raw::c_uint;
16517#[repr(C)]
16518#[derive(Debug, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
16519pub struct mshv_run_vp {
16520 pub msg_buf: [__u8; 256usize],
16521}
16522#[test]
16523fn bindgen_test_layout_mshv_run_vp() {
16524 const UNINIT: ::std::mem::MaybeUninit<mshv_run_vp> = ::std::mem::MaybeUninit::uninit();
16525 let ptr = UNINIT.as_ptr();
16526 assert_eq!(
16527 ::std::mem::size_of::<mshv_run_vp>(),
16528 256usize,
16529 concat!("Size of: ", stringify!(mshv_run_vp))
16530 );
16531 assert_eq!(
16532 ::std::mem::align_of::<mshv_run_vp>(),
16533 1usize,
16534 concat!("Alignment of ", stringify!(mshv_run_vp))
16535 );
16536 assert_eq!(
16537 unsafe { ::std::ptr::addr_of!((*ptr).msg_buf) as usize - ptr as usize },
16538 0usize,
16539 concat!(
16540 "Offset of field: ",
16541 stringify!(mshv_run_vp),
16542 "::",
16543 stringify!(msg_buf)
16544 )
16545 );
16546}
16547impl Default for mshv_run_vp {
16548 fn default() -> Self {
16549 let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
16550 unsafe {
16551 ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
16552 s.assume_init()
16553 }
16554 }
16555}
16556pub const MSHV_VP_STATE_LAPIC: _bindgen_ty_12 = 0;
16557pub const MSHV_VP_STATE_XSAVE: _bindgen_ty_12 = 1;
16558pub const MSHV_VP_STATE_SIMP: _bindgen_ty_12 = 2;
16559pub const MSHV_VP_STATE_SIEFP: _bindgen_ty_12 = 3;
16560pub const MSHV_VP_STATE_SYNTHETIC_TIMERS: _bindgen_ty_12 = 4;
16561pub const MSHV_VP_STATE_COUNT: _bindgen_ty_12 = 5;
16562pub type _bindgen_ty_12 = ::std::os::raw::c_uint;
16563#[repr(C)]
16564#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
16565pub struct mshv_get_set_vp_state {
16566 pub type_: __u8,
16567 pub rsvd: [__u8; 3usize],
16568 pub buf_sz: __u32,
16569 pub buf_ptr: __u64,
16570}
16571#[test]
16572fn bindgen_test_layout_mshv_get_set_vp_state() {
16573 const UNINIT: ::std::mem::MaybeUninit<mshv_get_set_vp_state> =
16574 ::std::mem::MaybeUninit::uninit();
16575 let ptr = UNINIT.as_ptr();
16576 assert_eq!(
16577 ::std::mem::size_of::<mshv_get_set_vp_state>(),
16578 16usize,
16579 concat!("Size of: ", stringify!(mshv_get_set_vp_state))
16580 );
16581 assert_eq!(
16582 ::std::mem::align_of::<mshv_get_set_vp_state>(),
16583 8usize,
16584 concat!("Alignment of ", stringify!(mshv_get_set_vp_state))
16585 );
16586 assert_eq!(
16587 unsafe { ::std::ptr::addr_of!((*ptr).type_) as usize - ptr as usize },
16588 0usize,
16589 concat!(
16590 "Offset of field: ",
16591 stringify!(mshv_get_set_vp_state),
16592 "::",
16593 stringify!(type_)
16594 )
16595 );
16596 assert_eq!(
16597 unsafe { ::std::ptr::addr_of!((*ptr).rsvd) as usize - ptr as usize },
16598 1usize,
16599 concat!(
16600 "Offset of field: ",
16601 stringify!(mshv_get_set_vp_state),
16602 "::",
16603 stringify!(rsvd)
16604 )
16605 );
16606 assert_eq!(
16607 unsafe { ::std::ptr::addr_of!((*ptr).buf_sz) as usize - ptr as usize },
16608 4usize,
16609 concat!(
16610 "Offset of field: ",
16611 stringify!(mshv_get_set_vp_state),
16612 "::",
16613 stringify!(buf_sz)
16614 )
16615 );
16616 assert_eq!(
16617 unsafe { ::std::ptr::addr_of!((*ptr).buf_ptr) as usize - ptr as usize },
16618 8usize,
16619 concat!(
16620 "Offset of field: ",
16621 stringify!(mshv_get_set_vp_state),
16622 "::",
16623 stringify!(buf_ptr)
16624 )
16625 );
16626}
16627pub const MSHV_DEV_TYPE_VFIO: _bindgen_ty_13 = 0;
16628pub const MSHV_DEV_TYPE_MAX: _bindgen_ty_13 = 1;
16629pub type _bindgen_ty_13 = ::std::os::raw::c_uint;
16630#[repr(C)]
16631#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
16632pub struct mshv_create_device {
16633 pub type_: __u32,
16634 pub fd: __u32,
16635 pub flags: __u32,
16636}
16637#[test]
16638fn bindgen_test_layout_mshv_create_device() {
16639 const UNINIT: ::std::mem::MaybeUninit<mshv_create_device> = ::std::mem::MaybeUninit::uninit();
16640 let ptr = UNINIT.as_ptr();
16641 assert_eq!(
16642 ::std::mem::size_of::<mshv_create_device>(),
16643 12usize,
16644 concat!("Size of: ", stringify!(mshv_create_device))
16645 );
16646 assert_eq!(
16647 ::std::mem::align_of::<mshv_create_device>(),
16648 4usize,
16649 concat!("Alignment of ", stringify!(mshv_create_device))
16650 );
16651 assert_eq!(
16652 unsafe { ::std::ptr::addr_of!((*ptr).type_) as usize - ptr as usize },
16653 0usize,
16654 concat!(
16655 "Offset of field: ",
16656 stringify!(mshv_create_device),
16657 "::",
16658 stringify!(type_)
16659 )
16660 );
16661 assert_eq!(
16662 unsafe { ::std::ptr::addr_of!((*ptr).fd) as usize - ptr as usize },
16663 4usize,
16664 concat!(
16665 "Offset of field: ",
16666 stringify!(mshv_create_device),
16667 "::",
16668 stringify!(fd)
16669 )
16670 );
16671 assert_eq!(
16672 unsafe { ::std::ptr::addr_of!((*ptr).flags) as usize - ptr as usize },
16673 8usize,
16674 concat!(
16675 "Offset of field: ",
16676 stringify!(mshv_create_device),
16677 "::",
16678 stringify!(flags)
16679 )
16680 );
16681}
16682#[repr(C)]
16683#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
16684pub struct mshv_device_attr {
16685 pub flags: __u32,
16686 pub group: __u32,
16687 pub attr: __u64,
16688 pub addr: __u64,
16689}
16690#[test]
16691fn bindgen_test_layout_mshv_device_attr() {
16692 const UNINIT: ::std::mem::MaybeUninit<mshv_device_attr> = ::std::mem::MaybeUninit::uninit();
16693 let ptr = UNINIT.as_ptr();
16694 assert_eq!(
16695 ::std::mem::size_of::<mshv_device_attr>(),
16696 24usize,
16697 concat!("Size of: ", stringify!(mshv_device_attr))
16698 );
16699 assert_eq!(
16700 ::std::mem::align_of::<mshv_device_attr>(),
16701 8usize,
16702 concat!("Alignment of ", stringify!(mshv_device_attr))
16703 );
16704 assert_eq!(
16705 unsafe { ::std::ptr::addr_of!((*ptr).flags) as usize - ptr as usize },
16706 0usize,
16707 concat!(
16708 "Offset of field: ",
16709 stringify!(mshv_device_attr),
16710 "::",
16711 stringify!(flags)
16712 )
16713 );
16714 assert_eq!(
16715 unsafe { ::std::ptr::addr_of!((*ptr).group) as usize - ptr as usize },
16716 4usize,
16717 concat!(
16718 "Offset of field: ",
16719 stringify!(mshv_device_attr),
16720 "::",
16721 stringify!(group)
16722 )
16723 );
16724 assert_eq!(
16725 unsafe { ::std::ptr::addr_of!((*ptr).attr) as usize - ptr as usize },
16726 8usize,
16727 concat!(
16728 "Offset of field: ",
16729 stringify!(mshv_device_attr),
16730 "::",
16731 stringify!(attr)
16732 )
16733 );
16734 assert_eq!(
16735 unsafe { ::std::ptr::addr_of!((*ptr).addr) as usize - ptr as usize },
16736 16usize,
16737 concat!(
16738 "Offset of field: ",
16739 stringify!(mshv_device_attr),
16740 "::",
16741 stringify!(addr)
16742 )
16743 );
16744}
16745#[repr(C)]
16746#[derive(Debug, Default, Copy, Clone, PartialOrd, Ord, PartialEq, Eq)]
16747pub struct mshv_trace_config {
16748 pub mode: __u32,
16749 pub max_buffers_count: __u32,
16750 pub pages_per_buffer: __u32,
16751 pub buffers_threshold: __u32,
16752 pub time_basis: __u32,
16753 pub system_time: __u64,
16754}
16755#[test]
16756fn bindgen_test_layout_mshv_trace_config() {
16757 const UNINIT: ::std::mem::MaybeUninit<mshv_trace_config> = ::std::mem::MaybeUninit::uninit();
16758 let ptr = UNINIT.as_ptr();
16759 assert_eq!(
16760 ::std::mem::size_of::<mshv_trace_config>(),
16761 32usize,
16762 concat!("Size of: ", stringify!(mshv_trace_config))
16763 );
16764 assert_eq!(
16765 ::std::mem::align_of::<mshv_trace_config>(),
16766 8usize,
16767 concat!("Alignment of ", stringify!(mshv_trace_config))
16768 );
16769 assert_eq!(
16770 unsafe { ::std::ptr::addr_of!((*ptr).mode) as usize - ptr as usize },
16771 0usize,
16772 concat!(
16773 "Offset of field: ",
16774 stringify!(mshv_trace_config),
16775 "::",
16776 stringify!(mode)
16777 )
16778 );
16779 assert_eq!(
16780 unsafe { ::std::ptr::addr_of!((*ptr).max_buffers_count) as usize - ptr as usize },
16781 4usize,
16782 concat!(
16783 "Offset of field: ",
16784 stringify!(mshv_trace_config),
16785 "::",
16786 stringify!(max_buffers_count)
16787 )
16788 );
16789 assert_eq!(
16790 unsafe { ::std::ptr::addr_of!((*ptr).pages_per_buffer) as usize - ptr as usize },
16791 8usize,
16792 concat!(
16793 "Offset of field: ",
16794 stringify!(mshv_trace_config),
16795 "::",
16796 stringify!(pages_per_buffer)
16797 )
16798 );
16799 assert_eq!(
16800 unsafe { ::std::ptr::addr_of!((*ptr).buffers_threshold) as usize - ptr as usize },
16801 12usize,
16802 concat!(
16803 "Offset of field: ",
16804 stringify!(mshv_trace_config),
16805 "::",
16806 stringify!(buffers_threshold)
16807 )
16808 );
16809 assert_eq!(
16810 unsafe { ::std::ptr::addr_of!((*ptr).time_basis) as usize - ptr as usize },
16811 16usize,
16812 concat!(
16813 "Offset of field: ",
16814 stringify!(mshv_trace_config),
16815 "::",
16816 stringify!(time_basis)
16817 )
16818 );
16819 assert_eq!(
16820 unsafe { ::std::ptr::addr_of!((*ptr).system_time) as usize - ptr as usize },
16821 24usize,
16822 concat!(
16823 "Offset of field: ",
16824 stringify!(mshv_trace_config),
16825 "::",
16826 stringify!(system_time)
16827 )
16828 );
16829}