1 // SPDX-License-Identifier: GPL-2.0-or-later 2 #![allow( 3 dead_code, 4 improper_ctypes_definitions, 5 improper_ctypes, 6 non_camel_case_types, 7 non_snake_case, 8 non_upper_case_globals, 9 unsafe_op_in_unsafe_fn, 10 clippy::pedantic, 11 clippy::restriction, 12 clippy::style, 13 clippy::missing_const_for_fn, 14 clippy::ptr_offset_with_cast, 15 clippy::useless_transmute, 16 clippy::missing_safety_doc 17 )] 18 19 //! `bindgen`-generated declarations. 20 21 #[cfg(MESON)] 22 include!("bindings.inc.rs"); 23 24 #[cfg(not(MESON))] 25 include!(concat!(env!("OUT_DIR"), "/bindings.inc.rs")); 26 27 // SAFETY: these are implemented in C; the bindings need to assert that the 28 // BQL is taken, either directly or via `BqlCell` and `BqlRefCell`. 29 // When bindings for character devices are introduced, this can be 30 // moved to the Opaque<> wrapper in src/chardev.rs. 31 unsafe impl Send for CharBackend {} 32 unsafe impl Sync for CharBackend {} 33 34 // SAFETY: this is a pure data struct 35 unsafe impl Send for CoalescedMemoryRange {} 36 unsafe impl Sync for CoalescedMemoryRange {} 37 38 // SAFETY: these are constants and vtables; the Send and Sync requirements 39 // are deferred to the unsafe callbacks that they contain 40 unsafe impl Send for MemoryRegionOps {} 41 unsafe impl Sync for MemoryRegionOps {} 42 43 unsafe impl Send for Property {} 44 unsafe impl Sync for Property {} 45 46 unsafe impl Send for TypeInfo {} 47 unsafe impl Sync for TypeInfo {} 48 49 unsafe impl Send for VMStateDescription {} 50 unsafe impl Sync for VMStateDescription {} 51 52 unsafe impl Send for VMStateField {} 53 unsafe impl Sync for VMStateField {} 54 55 unsafe impl Send for VMStateInfo {} 56 unsafe impl Sync for VMStateInfo {} 57