/* automatically generated by rust-bindgen 0.71.1 */

#[repr(C)]
#[derive(Default)]
pub struct __IncompleteArrayField<T>(::std::marker::PhantomData<T>, [T; 0]);
impl<T> __IncompleteArrayField<T> {
    #[inline]
    pub const fn new() -> Self {
        __IncompleteArrayField(::std::marker::PhantomData, [])
    }
    #[inline]
    pub fn as_ptr(&self) -> *const T {
        self as *const _ as *const T
    }
    #[inline]
    pub fn as_mut_ptr(&mut self) -> *mut T {
        self as *mut _ as *mut T
    }
    #[inline]
    pub unsafe fn as_slice(&self, len: usize) -> &[T] {
        ::std::slice::from_raw_parts(self.as_ptr(), len)
    }
    #[inline]
    pub unsafe fn as_mut_slice(&mut self, len: usize) -> &mut [T] {
        ::std::slice::from_raw_parts_mut(self.as_mut_ptr(), len)
    }
}
impl<T> ::std::fmt::Debug for __IncompleteArrayField<T> {
    fn fmt(&self, fmt: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
        fmt.write_str("__IncompleteArrayField")
    }
}
pub const VIRTIO_GPU_F_VIRGL: u32 = 0;
pub const VIRTIO_GPU_F_EDID: u32 = 1;
pub const VIRTIO_GPU_F_RESOURCE_UUID: u32 = 2;
pub const VIRTIO_GPU_F_RESOURCE_BLOB: u32 = 3;
pub const VIRTIO_GPU_F_CONTEXT_INIT: u32 = 4;
pub const VIRTIO_GPU_FLAG_FENCE: u32 = 1;
pub const VIRTIO_GPU_FLAG_INFO_RING_IDX: u32 = 2;
pub const VIRTIO_GPU_MAX_SCANOUTS: u32 = 16;
pub const VIRTIO_GPU_RESOURCE_FLAG_Y_0_TOP: u32 = 1;
pub const VIRTIO_GPU_CONTEXT_INIT_CAPSET_ID_MASK: u32 = 255;
pub const VIRTIO_GPU_CAPSET_VIRGL: u32 = 1;
pub const VIRTIO_GPU_CAPSET_VIRGL2: u32 = 2;
pub const VIRTIO_GPU_CAPSET_VENUS: u32 = 4;
pub const VIRTIO_GPU_CAPSET_DRM: u32 = 6;
pub const VIRTIO_GPU_EVENT_DISPLAY: u32 = 1;
pub const VIRTIO_GPU_BLOB_MEM_GUEST: u32 = 1;
pub const VIRTIO_GPU_BLOB_MEM_HOST3D: u32 = 2;
pub const VIRTIO_GPU_BLOB_MEM_HOST3D_GUEST: u32 = 3;
pub const VIRTIO_GPU_BLOB_FLAG_USE_MAPPABLE: u32 = 1;
pub const VIRTIO_GPU_BLOB_FLAG_USE_SHAREABLE: u32 = 2;
pub const VIRTIO_GPU_BLOB_FLAG_USE_CROSS_DEVICE: u32 = 4;
pub const VIRTIO_GPU_MAP_CACHE_MASK: u32 = 15;
pub const VIRTIO_GPU_MAP_CACHE_NONE: u32 = 0;
pub const VIRTIO_GPU_MAP_CACHE_CACHED: u32 = 1;
pub const VIRTIO_GPU_MAP_CACHE_UNCACHED: u32 = 2;
pub const VIRTIO_GPU_MAP_CACHE_WC: u32 = 3;
pub type __u8 = ::std::os::raw::c_uchar;
pub type __u32 = ::std::os::raw::c_uint;
pub type __u64 = ::std::os::raw::c_ulonglong;
pub type __le32 = __u32;
pub type __le64 = __u64;
pub const virtio_gpu_ctrl_type_VIRTIO_GPU_UNDEFINED: virtio_gpu_ctrl_type = 0;
pub const virtio_gpu_ctrl_type_VIRTIO_GPU_CMD_GET_DISPLAY_INFO: virtio_gpu_ctrl_type = 256;
pub const virtio_gpu_ctrl_type_VIRTIO_GPU_CMD_RESOURCE_CREATE_2D: virtio_gpu_ctrl_type = 257;
pub const virtio_gpu_ctrl_type_VIRTIO_GPU_CMD_RESOURCE_UNREF: virtio_gpu_ctrl_type = 258;
pub const virtio_gpu_ctrl_type_VIRTIO_GPU_CMD_SET_SCANOUT: virtio_gpu_ctrl_type = 259;
pub const virtio_gpu_ctrl_type_VIRTIO_GPU_CMD_RESOURCE_FLUSH: virtio_gpu_ctrl_type = 260;
pub const virtio_gpu_ctrl_type_VIRTIO_GPU_CMD_TRANSFER_TO_HOST_2D: virtio_gpu_ctrl_type = 261;
pub const virtio_gpu_ctrl_type_VIRTIO_GPU_CMD_RESOURCE_ATTACH_BACKING: virtio_gpu_ctrl_type = 262;
pub const virtio_gpu_ctrl_type_VIRTIO_GPU_CMD_RESOURCE_DETACH_BACKING: virtio_gpu_ctrl_type = 263;
pub const virtio_gpu_ctrl_type_VIRTIO_GPU_CMD_GET_CAPSET_INFO: virtio_gpu_ctrl_type = 264;
pub const virtio_gpu_ctrl_type_VIRTIO_GPU_CMD_GET_CAPSET: virtio_gpu_ctrl_type = 265;
pub const virtio_gpu_ctrl_type_VIRTIO_GPU_CMD_GET_EDID: virtio_gpu_ctrl_type = 266;
pub const virtio_gpu_ctrl_type_VIRTIO_GPU_CMD_RESOURCE_ASSIGN_UUID: virtio_gpu_ctrl_type = 267;
pub const virtio_gpu_ctrl_type_VIRTIO_GPU_CMD_RESOURCE_CREATE_BLOB: virtio_gpu_ctrl_type = 268;
pub const virtio_gpu_ctrl_type_VIRTIO_GPU_CMD_SET_SCANOUT_BLOB: virtio_gpu_ctrl_type = 269;
pub const virtio_gpu_ctrl_type_VIRTIO_GPU_CMD_CTX_CREATE: virtio_gpu_ctrl_type = 512;
pub const virtio_gpu_ctrl_type_VIRTIO_GPU_CMD_CTX_DESTROY: virtio_gpu_ctrl_type = 513;
pub const virtio_gpu_ctrl_type_VIRTIO_GPU_CMD_CTX_ATTACH_RESOURCE: virtio_gpu_ctrl_type = 514;
pub const virtio_gpu_ctrl_type_VIRTIO_GPU_CMD_CTX_DETACH_RESOURCE: virtio_gpu_ctrl_type = 515;
pub const virtio_gpu_ctrl_type_VIRTIO_GPU_CMD_RESOURCE_CREATE_3D: virtio_gpu_ctrl_type = 516;
pub const virtio_gpu_ctrl_type_VIRTIO_GPU_CMD_TRANSFER_TO_HOST_3D: virtio_gpu_ctrl_type = 517;
pub const virtio_gpu_ctrl_type_VIRTIO_GPU_CMD_TRANSFER_FROM_HOST_3D: virtio_gpu_ctrl_type = 518;
pub const virtio_gpu_ctrl_type_VIRTIO_GPU_CMD_SUBMIT_3D: virtio_gpu_ctrl_type = 519;
pub const virtio_gpu_ctrl_type_VIRTIO_GPU_CMD_RESOURCE_MAP_BLOB: virtio_gpu_ctrl_type = 520;
pub const virtio_gpu_ctrl_type_VIRTIO_GPU_CMD_RESOURCE_UNMAP_BLOB: virtio_gpu_ctrl_type = 521;
pub const virtio_gpu_ctrl_type_VIRTIO_GPU_CMD_UPDATE_CURSOR: virtio_gpu_ctrl_type = 768;
pub const virtio_gpu_ctrl_type_VIRTIO_GPU_CMD_MOVE_CURSOR: virtio_gpu_ctrl_type = 769;
pub const virtio_gpu_ctrl_type_VIRTIO_GPU_RESP_OK_NODATA: virtio_gpu_ctrl_type = 4352;
pub const virtio_gpu_ctrl_type_VIRTIO_GPU_RESP_OK_DISPLAY_INFO: virtio_gpu_ctrl_type = 4353;
pub const virtio_gpu_ctrl_type_VIRTIO_GPU_RESP_OK_CAPSET_INFO: virtio_gpu_ctrl_type = 4354;
pub const virtio_gpu_ctrl_type_VIRTIO_GPU_RESP_OK_CAPSET: virtio_gpu_ctrl_type = 4355;
pub const virtio_gpu_ctrl_type_VIRTIO_GPU_RESP_OK_EDID: virtio_gpu_ctrl_type = 4356;
pub const virtio_gpu_ctrl_type_VIRTIO_GPU_RESP_OK_RESOURCE_UUID: virtio_gpu_ctrl_type = 4357;
pub const virtio_gpu_ctrl_type_VIRTIO_GPU_RESP_OK_MAP_INFO: virtio_gpu_ctrl_type = 4358;
pub const virtio_gpu_ctrl_type_VIRTIO_GPU_RESP_ERR_UNSPEC: virtio_gpu_ctrl_type = 4608;
pub const virtio_gpu_ctrl_type_VIRTIO_GPU_RESP_ERR_OUT_OF_MEMORY: virtio_gpu_ctrl_type = 4609;
pub const virtio_gpu_ctrl_type_VIRTIO_GPU_RESP_ERR_INVALID_SCANOUT_ID: virtio_gpu_ctrl_type = 4610;
pub const virtio_gpu_ctrl_type_VIRTIO_GPU_RESP_ERR_INVALID_RESOURCE_ID: virtio_gpu_ctrl_type = 4611;
pub const virtio_gpu_ctrl_type_VIRTIO_GPU_RESP_ERR_INVALID_CONTEXT_ID: virtio_gpu_ctrl_type = 4612;
pub const virtio_gpu_ctrl_type_VIRTIO_GPU_RESP_ERR_INVALID_PARAMETER: virtio_gpu_ctrl_type = 4613;
pub type virtio_gpu_ctrl_type = ::std::os::raw::c_uint;
pub const virtio_gpu_shm_id_VIRTIO_GPU_SHM_ID_UNDEFINED: virtio_gpu_shm_id = 0;
pub const virtio_gpu_shm_id_VIRTIO_GPU_SHM_ID_HOST_VISIBLE: virtio_gpu_shm_id = 1;
pub type virtio_gpu_shm_id = ::std::os::raw::c_uint;
#[repr(C)]
#[derive(Debug, Default, Copy, Clone, PartialEq)]
pub struct virtio_gpu_ctrl_hdr {
    pub type_: __le32,
    pub flags: __le32,
    pub fence_id: __le64,
    pub ctx_id: __le32,
    pub ring_idx: __u8,
    pub padding: [__u8; 3usize],
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of virtio_gpu_ctrl_hdr"][::std::mem::size_of::<virtio_gpu_ctrl_hdr>() - 24usize];
    ["Alignment of virtio_gpu_ctrl_hdr"][::std::mem::align_of::<virtio_gpu_ctrl_hdr>() - 4usize];
    ["Offset of field: virtio_gpu_ctrl_hdr::type_"]
        [::std::mem::offset_of!(virtio_gpu_ctrl_hdr, type_) - 0usize];
    ["Offset of field: virtio_gpu_ctrl_hdr::flags"]
        [::std::mem::offset_of!(virtio_gpu_ctrl_hdr, flags) - 4usize];
    ["Offset of field: virtio_gpu_ctrl_hdr::fence_id"]
        [::std::mem::offset_of!(virtio_gpu_ctrl_hdr, fence_id) - 8usize];
    ["Offset of field: virtio_gpu_ctrl_hdr::ctx_id"]
        [::std::mem::offset_of!(virtio_gpu_ctrl_hdr, ctx_id) - 16usize];
    ["Offset of field: virtio_gpu_ctrl_hdr::ring_idx"]
        [::std::mem::offset_of!(virtio_gpu_ctrl_hdr, ring_idx) - 20usize];
    ["Offset of field: virtio_gpu_ctrl_hdr::padding"]
        [::std::mem::offset_of!(virtio_gpu_ctrl_hdr, padding) - 21usize];
};
#[repr(C)]
#[derive(Debug, Default, Copy, Clone, PartialEq)]
pub struct virtio_gpu_cursor_pos {
    pub scanout_id: __le32,
    pub x: __le32,
    pub y: __le32,
    pub padding: __le32,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of virtio_gpu_cursor_pos"][::std::mem::size_of::<virtio_gpu_cursor_pos>() - 16usize];
    ["Alignment of virtio_gpu_cursor_pos"]
        [::std::mem::align_of::<virtio_gpu_cursor_pos>() - 4usize];
    ["Offset of field: virtio_gpu_cursor_pos::scanout_id"]
        [::std::mem::offset_of!(virtio_gpu_cursor_pos, scanout_id) - 0usize];
    ["Offset of field: virtio_gpu_cursor_pos::x"]
        [::std::mem::offset_of!(virtio_gpu_cursor_pos, x) - 4usize];
    ["Offset of field: virtio_gpu_cursor_pos::y"]
        [::std::mem::offset_of!(virtio_gpu_cursor_pos, y) - 8usize];
    ["Offset of field: virtio_gpu_cursor_pos::padding"]
        [::std::mem::offset_of!(virtio_gpu_cursor_pos, padding) - 12usize];
};
#[repr(C)]
#[derive(Debug, Default, Copy, Clone, PartialEq)]
pub struct virtio_gpu_update_cursor {
    pub hdr: virtio_gpu_ctrl_hdr,
    pub pos: virtio_gpu_cursor_pos,
    pub resource_id: __le32,
    pub hot_x: __le32,
    pub hot_y: __le32,
    pub padding: __le32,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of virtio_gpu_update_cursor"]
        [::std::mem::size_of::<virtio_gpu_update_cursor>() - 56usize];
    ["Alignment of virtio_gpu_update_cursor"]
        [::std::mem::align_of::<virtio_gpu_update_cursor>() - 4usize];
    ["Offset of field: virtio_gpu_update_cursor::hdr"]
        [::std::mem::offset_of!(virtio_gpu_update_cursor, hdr) - 0usize];
    ["Offset of field: virtio_gpu_update_cursor::pos"]
        [::std::mem::offset_of!(virtio_gpu_update_cursor, pos) - 24usize];
    ["Offset of field: virtio_gpu_update_cursor::resource_id"]
        [::std::mem::offset_of!(virtio_gpu_update_cursor, resource_id) - 40usize];
    ["Offset of field: virtio_gpu_update_cursor::hot_x"]
        [::std::mem::offset_of!(virtio_gpu_update_cursor, hot_x) - 44usize];
    ["Offset of field: virtio_gpu_update_cursor::hot_y"]
        [::std::mem::offset_of!(virtio_gpu_update_cursor, hot_y) - 48usize];
    ["Offset of field: virtio_gpu_update_cursor::padding"]
        [::std::mem::offset_of!(virtio_gpu_update_cursor, padding) - 52usize];
};
#[repr(C)]
#[derive(Debug, Default, Copy, Clone, PartialEq)]
pub struct virtio_gpu_rect {
    pub x: __le32,
    pub y: __le32,
    pub width: __le32,
    pub height: __le32,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of virtio_gpu_rect"][::std::mem::size_of::<virtio_gpu_rect>() - 16usize];
    ["Alignment of virtio_gpu_rect"][::std::mem::align_of::<virtio_gpu_rect>() - 4usize];
    ["Offset of field: virtio_gpu_rect::x"][::std::mem::offset_of!(virtio_gpu_rect, x) - 0usize];
    ["Offset of field: virtio_gpu_rect::y"][::std::mem::offset_of!(virtio_gpu_rect, y) - 4usize];
    ["Offset of field: virtio_gpu_rect::width"]
        [::std::mem::offset_of!(virtio_gpu_rect, width) - 8usize];
    ["Offset of field: virtio_gpu_rect::height"]
        [::std::mem::offset_of!(virtio_gpu_rect, height) - 12usize];
};
#[repr(C)]
#[derive(Debug, Default, Copy, Clone, PartialEq)]
pub struct virtio_gpu_resource_unref {
    pub hdr: virtio_gpu_ctrl_hdr,
    pub resource_id: __le32,
    pub padding: __le32,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of virtio_gpu_resource_unref"]
        [::std::mem::size_of::<virtio_gpu_resource_unref>() - 32usize];
    ["Alignment of virtio_gpu_resource_unref"]
        [::std::mem::align_of::<virtio_gpu_resource_unref>() - 4usize];
    ["Offset of field: virtio_gpu_resource_unref::hdr"]
        [::std::mem::offset_of!(virtio_gpu_resource_unref, hdr) - 0usize];
    ["Offset of field: virtio_gpu_resource_unref::resource_id"]
        [::std::mem::offset_of!(virtio_gpu_resource_unref, resource_id) - 24usize];
    ["Offset of field: virtio_gpu_resource_unref::padding"]
        [::std::mem::offset_of!(virtio_gpu_resource_unref, padding) - 28usize];
};
#[repr(C)]
#[derive(Debug, Default, Copy, Clone, PartialEq)]
pub struct virtio_gpu_resource_create_2d {
    pub hdr: virtio_gpu_ctrl_hdr,
    pub resource_id: __le32,
    pub format: __le32,
    pub width: __le32,
    pub height: __le32,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of virtio_gpu_resource_create_2d"]
        [::std::mem::size_of::<virtio_gpu_resource_create_2d>() - 40usize];
    ["Alignment of virtio_gpu_resource_create_2d"]
        [::std::mem::align_of::<virtio_gpu_resource_create_2d>() - 4usize];
    ["Offset of field: virtio_gpu_resource_create_2d::hdr"]
        [::std::mem::offset_of!(virtio_gpu_resource_create_2d, hdr) - 0usize];
    ["Offset of field: virtio_gpu_resource_create_2d::resource_id"]
        [::std::mem::offset_of!(virtio_gpu_resource_create_2d, resource_id) - 24usize];
    ["Offset of field: virtio_gpu_resource_create_2d::format"]
        [::std::mem::offset_of!(virtio_gpu_resource_create_2d, format) - 28usize];
    ["Offset of field: virtio_gpu_resource_create_2d::width"]
        [::std::mem::offset_of!(virtio_gpu_resource_create_2d, width) - 32usize];
    ["Offset of field: virtio_gpu_resource_create_2d::height"]
        [::std::mem::offset_of!(virtio_gpu_resource_create_2d, height) - 36usize];
};
#[repr(C)]
#[derive(Debug, Default, Copy, Clone, PartialEq)]
pub struct virtio_gpu_set_scanout {
    pub hdr: virtio_gpu_ctrl_hdr,
    pub r: virtio_gpu_rect,
    pub scanout_id: __le32,
    pub resource_id: __le32,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of virtio_gpu_set_scanout"][::std::mem::size_of::<virtio_gpu_set_scanout>() - 48usize];
    ["Alignment of virtio_gpu_set_scanout"]
        [::std::mem::align_of::<virtio_gpu_set_scanout>() - 4usize];
    ["Offset of field: virtio_gpu_set_scanout::hdr"]
        [::std::mem::offset_of!(virtio_gpu_set_scanout, hdr) - 0usize];
    ["Offset of field: virtio_gpu_set_scanout::r"]
        [::std::mem::offset_of!(virtio_gpu_set_scanout, r) - 24usize];
    ["Offset of field: virtio_gpu_set_scanout::scanout_id"]
        [::std::mem::offset_of!(virtio_gpu_set_scanout, scanout_id) - 40usize];
    ["Offset of field: virtio_gpu_set_scanout::resource_id"]
        [::std::mem::offset_of!(virtio_gpu_set_scanout, resource_id) - 44usize];
};
#[repr(C)]
#[derive(Debug, Default, Copy, Clone, PartialEq)]
pub struct virtio_gpu_resource_flush {
    pub hdr: virtio_gpu_ctrl_hdr,
    pub r: virtio_gpu_rect,
    pub resource_id: __le32,
    pub padding: __le32,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of virtio_gpu_resource_flush"]
        [::std::mem::size_of::<virtio_gpu_resource_flush>() - 48usize];
    ["Alignment of virtio_gpu_resource_flush"]
        [::std::mem::align_of::<virtio_gpu_resource_flush>() - 4usize];
    ["Offset of field: virtio_gpu_resource_flush::hdr"]
        [::std::mem::offset_of!(virtio_gpu_resource_flush, hdr) - 0usize];
    ["Offset of field: virtio_gpu_resource_flush::r"]
        [::std::mem::offset_of!(virtio_gpu_resource_flush, r) - 24usize];
    ["Offset of field: virtio_gpu_resource_flush::resource_id"]
        [::std::mem::offset_of!(virtio_gpu_resource_flush, resource_id) - 40usize];
    ["Offset of field: virtio_gpu_resource_flush::padding"]
        [::std::mem::offset_of!(virtio_gpu_resource_flush, padding) - 44usize];
};
#[repr(C)]
#[derive(Debug, Default, Copy, Clone, PartialEq)]
pub struct virtio_gpu_transfer_to_host_2d {
    pub hdr: virtio_gpu_ctrl_hdr,
    pub r: virtio_gpu_rect,
    pub offset: __le64,
    pub resource_id: __le32,
    pub padding: __le32,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of virtio_gpu_transfer_to_host_2d"]
        [::std::mem::size_of::<virtio_gpu_transfer_to_host_2d>() - 56usize];
    ["Alignment of virtio_gpu_transfer_to_host_2d"]
        [::std::mem::align_of::<virtio_gpu_transfer_to_host_2d>() - 4usize];
    ["Offset of field: virtio_gpu_transfer_to_host_2d::hdr"]
        [::std::mem::offset_of!(virtio_gpu_transfer_to_host_2d, hdr) - 0usize];
    ["Offset of field: virtio_gpu_transfer_to_host_2d::r"]
        [::std::mem::offset_of!(virtio_gpu_transfer_to_host_2d, r) - 24usize];
    ["Offset of field: virtio_gpu_transfer_to_host_2d::offset"]
        [::std::mem::offset_of!(virtio_gpu_transfer_to_host_2d, offset) - 40usize];
    ["Offset of field: virtio_gpu_transfer_to_host_2d::resource_id"]
        [::std::mem::offset_of!(virtio_gpu_transfer_to_host_2d, resource_id) - 48usize];
    ["Offset of field: virtio_gpu_transfer_to_host_2d::padding"]
        [::std::mem::offset_of!(virtio_gpu_transfer_to_host_2d, padding) - 52usize];
};
#[repr(C)]
#[derive(Debug, Default, Copy, Clone, PartialEq)]
pub struct virtio_gpu_mem_entry {
    pub addr: __le64,
    pub length: __le32,
    pub padding: __le32,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of virtio_gpu_mem_entry"][::std::mem::size_of::<virtio_gpu_mem_entry>() - 16usize];
    ["Alignment of virtio_gpu_mem_entry"][::std::mem::align_of::<virtio_gpu_mem_entry>() - 4usize];
    ["Offset of field: virtio_gpu_mem_entry::addr"]
        [::std::mem::offset_of!(virtio_gpu_mem_entry, addr) - 0usize];
    ["Offset of field: virtio_gpu_mem_entry::length"]
        [::std::mem::offset_of!(virtio_gpu_mem_entry, length) - 8usize];
    ["Offset of field: virtio_gpu_mem_entry::padding"]
        [::std::mem::offset_of!(virtio_gpu_mem_entry, padding) - 12usize];
};
#[repr(C)]
#[derive(Debug, Default, Copy, Clone, PartialEq)]
pub struct virtio_gpu_resource_attach_backing {
    pub hdr: virtio_gpu_ctrl_hdr,
    pub resource_id: __le32,
    pub nr_entries: __le32,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of virtio_gpu_resource_attach_backing"]
        [::std::mem::size_of::<virtio_gpu_resource_attach_backing>() - 32usize];
    ["Alignment of virtio_gpu_resource_attach_backing"]
        [::std::mem::align_of::<virtio_gpu_resource_attach_backing>() - 4usize];
    ["Offset of field: virtio_gpu_resource_attach_backing::hdr"]
        [::std::mem::offset_of!(virtio_gpu_resource_attach_backing, hdr) - 0usize];
    ["Offset of field: virtio_gpu_resource_attach_backing::resource_id"]
        [::std::mem::offset_of!(virtio_gpu_resource_attach_backing, resource_id) - 24usize];
    ["Offset of field: virtio_gpu_resource_attach_backing::nr_entries"]
        [::std::mem::offset_of!(virtio_gpu_resource_attach_backing, nr_entries) - 28usize];
};
#[repr(C)]
#[derive(Debug, Default, Copy, Clone, PartialEq)]
pub struct virtio_gpu_resource_detach_backing {
    pub hdr: virtio_gpu_ctrl_hdr,
    pub resource_id: __le32,
    pub padding: __le32,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of virtio_gpu_resource_detach_backing"]
        [::std::mem::size_of::<virtio_gpu_resource_detach_backing>() - 32usize];
    ["Alignment of virtio_gpu_resource_detach_backing"]
        [::std::mem::align_of::<virtio_gpu_resource_detach_backing>() - 4usize];
    ["Offset of field: virtio_gpu_resource_detach_backing::hdr"]
        [::std::mem::offset_of!(virtio_gpu_resource_detach_backing, hdr) - 0usize];
    ["Offset of field: virtio_gpu_resource_detach_backing::resource_id"]
        [::std::mem::offset_of!(virtio_gpu_resource_detach_backing, resource_id) - 24usize];
    ["Offset of field: virtio_gpu_resource_detach_backing::padding"]
        [::std::mem::offset_of!(virtio_gpu_resource_detach_backing, padding) - 28usize];
};
#[repr(C)]
#[derive(Debug, Default, Copy, Clone, PartialEq)]
pub struct virtio_gpu_resp_display_info {
    pub hdr: virtio_gpu_ctrl_hdr,
    pub pmodes: [virtio_gpu_resp_display_info_virtio_gpu_display_one; 16usize],
}
#[repr(C)]
#[derive(Debug, Default, Copy, Clone, PartialEq)]
pub struct virtio_gpu_resp_display_info_virtio_gpu_display_one {
    pub r: virtio_gpu_rect,
    pub enabled: __le32,
    pub flags: __le32,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of virtio_gpu_resp_display_info_virtio_gpu_display_one"]
        [::std::mem::size_of::<virtio_gpu_resp_display_info_virtio_gpu_display_one>() - 24usize];
    ["Alignment of virtio_gpu_resp_display_info_virtio_gpu_display_one"]
        [::std::mem::align_of::<virtio_gpu_resp_display_info_virtio_gpu_display_one>() - 4usize];
    ["Offset of field: virtio_gpu_resp_display_info_virtio_gpu_display_one::r"]
        [::std::mem::offset_of!(virtio_gpu_resp_display_info_virtio_gpu_display_one, r) - 0usize];
    ["Offset of field: virtio_gpu_resp_display_info_virtio_gpu_display_one::enabled"][::std::mem::offset_of!(
        virtio_gpu_resp_display_info_virtio_gpu_display_one,
        enabled
    ) - 16usize];
    ["Offset of field: virtio_gpu_resp_display_info_virtio_gpu_display_one::flags"][::std::mem::offset_of!(
        virtio_gpu_resp_display_info_virtio_gpu_display_one,
        flags
    ) - 20usize];
};
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of virtio_gpu_resp_display_info"]
        [::std::mem::size_of::<virtio_gpu_resp_display_info>() - 408usize];
    ["Alignment of virtio_gpu_resp_display_info"]
        [::std::mem::align_of::<virtio_gpu_resp_display_info>() - 4usize];
    ["Offset of field: virtio_gpu_resp_display_info::hdr"]
        [::std::mem::offset_of!(virtio_gpu_resp_display_info, hdr) - 0usize];
    ["Offset of field: virtio_gpu_resp_display_info::pmodes"]
        [::std::mem::offset_of!(virtio_gpu_resp_display_info, pmodes) - 24usize];
};
#[repr(C)]
#[derive(Debug, Default, Copy, Clone, PartialEq)]
pub struct virtio_gpu_box {
    pub x: __le32,
    pub y: __le32,
    pub z: __le32,
    pub w: __le32,
    pub h: __le32,
    pub d: __le32,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of virtio_gpu_box"][::std::mem::size_of::<virtio_gpu_box>() - 24usize];
    ["Alignment of virtio_gpu_box"][::std::mem::align_of::<virtio_gpu_box>() - 4usize];
    ["Offset of field: virtio_gpu_box::x"][::std::mem::offset_of!(virtio_gpu_box, x) - 0usize];
    ["Offset of field: virtio_gpu_box::y"][::std::mem::offset_of!(virtio_gpu_box, y) - 4usize];
    ["Offset of field: virtio_gpu_box::z"][::std::mem::offset_of!(virtio_gpu_box, z) - 8usize];
    ["Offset of field: virtio_gpu_box::w"][::std::mem::offset_of!(virtio_gpu_box, w) - 12usize];
    ["Offset of field: virtio_gpu_box::h"][::std::mem::offset_of!(virtio_gpu_box, h) - 16usize];
    ["Offset of field: virtio_gpu_box::d"][::std::mem::offset_of!(virtio_gpu_box, d) - 20usize];
};
#[repr(C)]
#[derive(Debug, Default, Copy, Clone, PartialEq)]
pub struct virtio_gpu_transfer_host_3d {
    pub hdr: virtio_gpu_ctrl_hdr,
    pub box_: virtio_gpu_box,
    pub offset: __le64,
    pub resource_id: __le32,
    pub level: __le32,
    pub stride: __le32,
    pub layer_stride: __le32,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of virtio_gpu_transfer_host_3d"]
        [::std::mem::size_of::<virtio_gpu_transfer_host_3d>() - 72usize];
    ["Alignment of virtio_gpu_transfer_host_3d"]
        [::std::mem::align_of::<virtio_gpu_transfer_host_3d>() - 4usize];
    ["Offset of field: virtio_gpu_transfer_host_3d::hdr"]
        [::std::mem::offset_of!(virtio_gpu_transfer_host_3d, hdr) - 0usize];
    ["Offset of field: virtio_gpu_transfer_host_3d::box_"]
        [::std::mem::offset_of!(virtio_gpu_transfer_host_3d, box_) - 24usize];
    ["Offset of field: virtio_gpu_transfer_host_3d::offset"]
        [::std::mem::offset_of!(virtio_gpu_transfer_host_3d, offset) - 48usize];
    ["Offset of field: virtio_gpu_transfer_host_3d::resource_id"]
        [::std::mem::offset_of!(virtio_gpu_transfer_host_3d, resource_id) - 56usize];
    ["Offset of field: virtio_gpu_transfer_host_3d::level"]
        [::std::mem::offset_of!(virtio_gpu_transfer_host_3d, level) - 60usize];
    ["Offset of field: virtio_gpu_transfer_host_3d::stride"]
        [::std::mem::offset_of!(virtio_gpu_transfer_host_3d, stride) - 64usize];
    ["Offset of field: virtio_gpu_transfer_host_3d::layer_stride"]
        [::std::mem::offset_of!(virtio_gpu_transfer_host_3d, layer_stride) - 68usize];
};
#[repr(C)]
#[derive(Debug, Default, Copy, Clone, PartialEq)]
pub struct virtio_gpu_resource_create_3d {
    pub hdr: virtio_gpu_ctrl_hdr,
    pub resource_id: __le32,
    pub target: __le32,
    pub format: __le32,
    pub bind: __le32,
    pub width: __le32,
    pub height: __le32,
    pub depth: __le32,
    pub array_size: __le32,
    pub last_level: __le32,
    pub nr_samples: __le32,
    pub flags: __le32,
    pub padding: __le32,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of virtio_gpu_resource_create_3d"]
        [::std::mem::size_of::<virtio_gpu_resource_create_3d>() - 72usize];
    ["Alignment of virtio_gpu_resource_create_3d"]
        [::std::mem::align_of::<virtio_gpu_resource_create_3d>() - 4usize];
    ["Offset of field: virtio_gpu_resource_create_3d::hdr"]
        [::std::mem::offset_of!(virtio_gpu_resource_create_3d, hdr) - 0usize];
    ["Offset of field: virtio_gpu_resource_create_3d::resource_id"]
        [::std::mem::offset_of!(virtio_gpu_resource_create_3d, resource_id) - 24usize];
    ["Offset of field: virtio_gpu_resource_create_3d::target"]
        [::std::mem::offset_of!(virtio_gpu_resource_create_3d, target) - 28usize];
    ["Offset of field: virtio_gpu_resource_create_3d::format"]
        [::std::mem::offset_of!(virtio_gpu_resource_create_3d, format) - 32usize];
    ["Offset of field: virtio_gpu_resource_create_3d::bind"]
        [::std::mem::offset_of!(virtio_gpu_resource_create_3d, bind) - 36usize];
    ["Offset of field: virtio_gpu_resource_create_3d::width"]
        [::std::mem::offset_of!(virtio_gpu_resource_create_3d, width) - 40usize];
    ["Offset of field: virtio_gpu_resource_create_3d::height"]
        [::std::mem::offset_of!(virtio_gpu_resource_create_3d, height) - 44usize];
    ["Offset of field: virtio_gpu_resource_create_3d::depth"]
        [::std::mem::offset_of!(virtio_gpu_resource_create_3d, depth) - 48usize];
    ["Offset of field: virtio_gpu_resource_create_3d::array_size"]
        [::std::mem::offset_of!(virtio_gpu_resource_create_3d, array_size) - 52usize];
    ["Offset of field: virtio_gpu_resource_create_3d::last_level"]
        [::std::mem::offset_of!(virtio_gpu_resource_create_3d, last_level) - 56usize];
    ["Offset of field: virtio_gpu_resource_create_3d::nr_samples"]
        [::std::mem::offset_of!(virtio_gpu_resource_create_3d, nr_samples) - 60usize];
    ["Offset of field: virtio_gpu_resource_create_3d::flags"]
        [::std::mem::offset_of!(virtio_gpu_resource_create_3d, flags) - 64usize];
    ["Offset of field: virtio_gpu_resource_create_3d::padding"]
        [::std::mem::offset_of!(virtio_gpu_resource_create_3d, padding) - 68usize];
};
#[repr(C)]
#[derive(Debug, Copy, Clone, PartialEq)]
pub struct virtio_gpu_ctx_create {
    pub hdr: virtio_gpu_ctrl_hdr,
    pub nlen: __le32,
    pub context_init: __le32,
    pub debug_name: [::std::os::raw::c_char; 64usize],
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of virtio_gpu_ctx_create"][::std::mem::size_of::<virtio_gpu_ctx_create>() - 96usize];
    ["Alignment of virtio_gpu_ctx_create"]
        [::std::mem::align_of::<virtio_gpu_ctx_create>() - 4usize];
    ["Offset of field: virtio_gpu_ctx_create::hdr"]
        [::std::mem::offset_of!(virtio_gpu_ctx_create, hdr) - 0usize];
    ["Offset of field: virtio_gpu_ctx_create::nlen"]
        [::std::mem::offset_of!(virtio_gpu_ctx_create, nlen) - 24usize];
    ["Offset of field: virtio_gpu_ctx_create::context_init"]
        [::std::mem::offset_of!(virtio_gpu_ctx_create, context_init) - 28usize];
    ["Offset of field: virtio_gpu_ctx_create::debug_name"]
        [::std::mem::offset_of!(virtio_gpu_ctx_create, debug_name) - 32usize];
};
impl Default for virtio_gpu_ctx_create {
    fn default() -> Self {
        let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
        unsafe {
            ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
            s.assume_init()
        }
    }
}
#[repr(C)]
#[derive(Debug, Default, Copy, Clone, PartialEq)]
pub struct virtio_gpu_ctx_destroy {
    pub hdr: virtio_gpu_ctrl_hdr,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of virtio_gpu_ctx_destroy"][::std::mem::size_of::<virtio_gpu_ctx_destroy>() - 24usize];
    ["Alignment of virtio_gpu_ctx_destroy"]
        [::std::mem::align_of::<virtio_gpu_ctx_destroy>() - 4usize];
    ["Offset of field: virtio_gpu_ctx_destroy::hdr"]
        [::std::mem::offset_of!(virtio_gpu_ctx_destroy, hdr) - 0usize];
};
#[repr(C)]
#[derive(Debug, Default, Copy, Clone, PartialEq)]
pub struct virtio_gpu_ctx_resource {
    pub hdr: virtio_gpu_ctrl_hdr,
    pub resource_id: __le32,
    pub padding: __le32,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of virtio_gpu_ctx_resource"][::std::mem::size_of::<virtio_gpu_ctx_resource>() - 32usize];
    ["Alignment of virtio_gpu_ctx_resource"]
        [::std::mem::align_of::<virtio_gpu_ctx_resource>() - 4usize];
    ["Offset of field: virtio_gpu_ctx_resource::hdr"]
        [::std::mem::offset_of!(virtio_gpu_ctx_resource, hdr) - 0usize];
    ["Offset of field: virtio_gpu_ctx_resource::resource_id"]
        [::std::mem::offset_of!(virtio_gpu_ctx_resource, resource_id) - 24usize];
    ["Offset of field: virtio_gpu_ctx_resource::padding"]
        [::std::mem::offset_of!(virtio_gpu_ctx_resource, padding) - 28usize];
};
#[repr(C)]
#[derive(Debug, Default, Copy, Clone, PartialEq)]
pub struct virtio_gpu_cmd_submit {
    pub hdr: virtio_gpu_ctrl_hdr,
    pub size: __le32,
    pub padding: __le32,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of virtio_gpu_cmd_submit"][::std::mem::size_of::<virtio_gpu_cmd_submit>() - 32usize];
    ["Alignment of virtio_gpu_cmd_submit"]
        [::std::mem::align_of::<virtio_gpu_cmd_submit>() - 4usize];
    ["Offset of field: virtio_gpu_cmd_submit::hdr"]
        [::std::mem::offset_of!(virtio_gpu_cmd_submit, hdr) - 0usize];
    ["Offset of field: virtio_gpu_cmd_submit::size"]
        [::std::mem::offset_of!(virtio_gpu_cmd_submit, size) - 24usize];
    ["Offset of field: virtio_gpu_cmd_submit::padding"]
        [::std::mem::offset_of!(virtio_gpu_cmd_submit, padding) - 28usize];
};
#[repr(C)]
#[derive(Debug, Default, Copy, Clone, PartialEq)]
pub struct virtio_gpu_get_capset_info {
    pub hdr: virtio_gpu_ctrl_hdr,
    pub capset_index: __le32,
    pub padding: __le32,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of virtio_gpu_get_capset_info"]
        [::std::mem::size_of::<virtio_gpu_get_capset_info>() - 32usize];
    ["Alignment of virtio_gpu_get_capset_info"]
        [::std::mem::align_of::<virtio_gpu_get_capset_info>() - 4usize];
    ["Offset of field: virtio_gpu_get_capset_info::hdr"]
        [::std::mem::offset_of!(virtio_gpu_get_capset_info, hdr) - 0usize];
    ["Offset of field: virtio_gpu_get_capset_info::capset_index"]
        [::std::mem::offset_of!(virtio_gpu_get_capset_info, capset_index) - 24usize];
    ["Offset of field: virtio_gpu_get_capset_info::padding"]
        [::std::mem::offset_of!(virtio_gpu_get_capset_info, padding) - 28usize];
};
#[repr(C)]
#[derive(Debug, Default, Copy, Clone, PartialEq)]
pub struct virtio_gpu_resp_capset_info {
    pub hdr: virtio_gpu_ctrl_hdr,
    pub capset_id: __le32,
    pub capset_max_version: __le32,
    pub capset_max_size: __le32,
    pub padding: __le32,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of virtio_gpu_resp_capset_info"]
        [::std::mem::size_of::<virtio_gpu_resp_capset_info>() - 40usize];
    ["Alignment of virtio_gpu_resp_capset_info"]
        [::std::mem::align_of::<virtio_gpu_resp_capset_info>() - 4usize];
    ["Offset of field: virtio_gpu_resp_capset_info::hdr"]
        [::std::mem::offset_of!(virtio_gpu_resp_capset_info, hdr) - 0usize];
    ["Offset of field: virtio_gpu_resp_capset_info::capset_id"]
        [::std::mem::offset_of!(virtio_gpu_resp_capset_info, capset_id) - 24usize];
    ["Offset of field: virtio_gpu_resp_capset_info::capset_max_version"]
        [::std::mem::offset_of!(virtio_gpu_resp_capset_info, capset_max_version) - 28usize];
    ["Offset of field: virtio_gpu_resp_capset_info::capset_max_size"]
        [::std::mem::offset_of!(virtio_gpu_resp_capset_info, capset_max_size) - 32usize];
    ["Offset of field: virtio_gpu_resp_capset_info::padding"]
        [::std::mem::offset_of!(virtio_gpu_resp_capset_info, padding) - 36usize];
};
#[repr(C)]
#[derive(Debug, Default, Copy, Clone, PartialEq)]
pub struct virtio_gpu_get_capset {
    pub hdr: virtio_gpu_ctrl_hdr,
    pub capset_id: __le32,
    pub capset_version: __le32,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of virtio_gpu_get_capset"][::std::mem::size_of::<virtio_gpu_get_capset>() - 32usize];
    ["Alignment of virtio_gpu_get_capset"]
        [::std::mem::align_of::<virtio_gpu_get_capset>() - 4usize];
    ["Offset of field: virtio_gpu_get_capset::hdr"]
        [::std::mem::offset_of!(virtio_gpu_get_capset, hdr) - 0usize];
    ["Offset of field: virtio_gpu_get_capset::capset_id"]
        [::std::mem::offset_of!(virtio_gpu_get_capset, capset_id) - 24usize];
    ["Offset of field: virtio_gpu_get_capset::capset_version"]
        [::std::mem::offset_of!(virtio_gpu_get_capset, capset_version) - 28usize];
};
#[repr(C)]
#[derive(Debug, Default)]
pub struct virtio_gpu_resp_capset {
    pub hdr: virtio_gpu_ctrl_hdr,
    pub capset_data: __IncompleteArrayField<__u8>,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of virtio_gpu_resp_capset"][::std::mem::size_of::<virtio_gpu_resp_capset>() - 24usize];
    ["Alignment of virtio_gpu_resp_capset"]
        [::std::mem::align_of::<virtio_gpu_resp_capset>() - 4usize];
    ["Offset of field: virtio_gpu_resp_capset::hdr"]
        [::std::mem::offset_of!(virtio_gpu_resp_capset, hdr) - 0usize];
    ["Offset of field: virtio_gpu_resp_capset::capset_data"]
        [::std::mem::offset_of!(virtio_gpu_resp_capset, capset_data) - 24usize];
};
#[repr(C)]
#[derive(Debug, Default, Copy, Clone, PartialEq)]
pub struct virtio_gpu_cmd_get_edid {
    pub hdr: virtio_gpu_ctrl_hdr,
    pub scanout: __le32,
    pub padding: __le32,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of virtio_gpu_cmd_get_edid"][::std::mem::size_of::<virtio_gpu_cmd_get_edid>() - 32usize];
    ["Alignment of virtio_gpu_cmd_get_edid"]
        [::std::mem::align_of::<virtio_gpu_cmd_get_edid>() - 4usize];
    ["Offset of field: virtio_gpu_cmd_get_edid::hdr"]
        [::std::mem::offset_of!(virtio_gpu_cmd_get_edid, hdr) - 0usize];
    ["Offset of field: virtio_gpu_cmd_get_edid::scanout"]
        [::std::mem::offset_of!(virtio_gpu_cmd_get_edid, scanout) - 24usize];
    ["Offset of field: virtio_gpu_cmd_get_edid::padding"]
        [::std::mem::offset_of!(virtio_gpu_cmd_get_edid, padding) - 28usize];
};
#[repr(C)]
#[derive(Debug, Copy, Clone, PartialEq)]
pub struct virtio_gpu_resp_edid {
    pub hdr: virtio_gpu_ctrl_hdr,
    pub size: __le32,
    pub padding: __le32,
    pub edid: [__u8; 1024usize],
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of virtio_gpu_resp_edid"][::std::mem::size_of::<virtio_gpu_resp_edid>() - 1056usize];
    ["Alignment of virtio_gpu_resp_edid"][::std::mem::align_of::<virtio_gpu_resp_edid>() - 4usize];
    ["Offset of field: virtio_gpu_resp_edid::hdr"]
        [::std::mem::offset_of!(virtio_gpu_resp_edid, hdr) - 0usize];
    ["Offset of field: virtio_gpu_resp_edid::size"]
        [::std::mem::offset_of!(virtio_gpu_resp_edid, size) - 24usize];
    ["Offset of field: virtio_gpu_resp_edid::padding"]
        [::std::mem::offset_of!(virtio_gpu_resp_edid, padding) - 28usize];
    ["Offset of field: virtio_gpu_resp_edid::edid"]
        [::std::mem::offset_of!(virtio_gpu_resp_edid, edid) - 32usize];
};
impl Default for virtio_gpu_resp_edid {
    fn default() -> Self {
        let mut s = ::std::mem::MaybeUninit::<Self>::uninit();
        unsafe {
            ::std::ptr::write_bytes(s.as_mut_ptr(), 0, 1);
            s.assume_init()
        }
    }
}
#[repr(C)]
#[derive(Debug, Default, Copy, Clone, PartialEq)]
pub struct virtio_gpu_config {
    pub events_read: __le32,
    pub events_clear: __le32,
    pub num_scanouts: __le32,
    pub num_capsets: __le32,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of virtio_gpu_config"][::std::mem::size_of::<virtio_gpu_config>() - 16usize];
    ["Alignment of virtio_gpu_config"][::std::mem::align_of::<virtio_gpu_config>() - 4usize];
    ["Offset of field: virtio_gpu_config::events_read"]
        [::std::mem::offset_of!(virtio_gpu_config, events_read) - 0usize];
    ["Offset of field: virtio_gpu_config::events_clear"]
        [::std::mem::offset_of!(virtio_gpu_config, events_clear) - 4usize];
    ["Offset of field: virtio_gpu_config::num_scanouts"]
        [::std::mem::offset_of!(virtio_gpu_config, num_scanouts) - 8usize];
    ["Offset of field: virtio_gpu_config::num_capsets"]
        [::std::mem::offset_of!(virtio_gpu_config, num_capsets) - 12usize];
};
pub const virtio_gpu_formats_VIRTIO_GPU_FORMAT_B8G8R8A8_UNORM: virtio_gpu_formats = 1;
pub const virtio_gpu_formats_VIRTIO_GPU_FORMAT_B8G8R8X8_UNORM: virtio_gpu_formats = 2;
pub const virtio_gpu_formats_VIRTIO_GPU_FORMAT_A8R8G8B8_UNORM: virtio_gpu_formats = 3;
pub const virtio_gpu_formats_VIRTIO_GPU_FORMAT_X8R8G8B8_UNORM: virtio_gpu_formats = 4;
pub const virtio_gpu_formats_VIRTIO_GPU_FORMAT_R8G8B8A8_UNORM: virtio_gpu_formats = 67;
pub const virtio_gpu_formats_VIRTIO_GPU_FORMAT_X8B8G8R8_UNORM: virtio_gpu_formats = 68;
pub const virtio_gpu_formats_VIRTIO_GPU_FORMAT_A8B8G8R8_UNORM: virtio_gpu_formats = 121;
pub const virtio_gpu_formats_VIRTIO_GPU_FORMAT_R8G8B8X8_UNORM: virtio_gpu_formats = 134;
pub type virtio_gpu_formats = ::std::os::raw::c_uint;
#[repr(C)]
#[derive(Debug, Default, Copy, Clone, PartialEq)]
pub struct virtio_gpu_resource_assign_uuid {
    pub hdr: virtio_gpu_ctrl_hdr,
    pub resource_id: __le32,
    pub padding: __le32,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of virtio_gpu_resource_assign_uuid"]
        [::std::mem::size_of::<virtio_gpu_resource_assign_uuid>() - 32usize];
    ["Alignment of virtio_gpu_resource_assign_uuid"]
        [::std::mem::align_of::<virtio_gpu_resource_assign_uuid>() - 4usize];
    ["Offset of field: virtio_gpu_resource_assign_uuid::hdr"]
        [::std::mem::offset_of!(virtio_gpu_resource_assign_uuid, hdr) - 0usize];
    ["Offset of field: virtio_gpu_resource_assign_uuid::resource_id"]
        [::std::mem::offset_of!(virtio_gpu_resource_assign_uuid, resource_id) - 24usize];
    ["Offset of field: virtio_gpu_resource_assign_uuid::padding"]
        [::std::mem::offset_of!(virtio_gpu_resource_assign_uuid, padding) - 28usize];
};
#[repr(C)]
#[derive(Debug, Default, Copy, Clone, PartialEq)]
pub struct virtio_gpu_resp_resource_uuid {
    pub hdr: virtio_gpu_ctrl_hdr,
    pub uuid: [__u8; 16usize],
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of virtio_gpu_resp_resource_uuid"]
        [::std::mem::size_of::<virtio_gpu_resp_resource_uuid>() - 40usize];
    ["Alignment of virtio_gpu_resp_resource_uuid"]
        [::std::mem::align_of::<virtio_gpu_resp_resource_uuid>() - 4usize];
    ["Offset of field: virtio_gpu_resp_resource_uuid::hdr"]
        [::std::mem::offset_of!(virtio_gpu_resp_resource_uuid, hdr) - 0usize];
    ["Offset of field: virtio_gpu_resp_resource_uuid::uuid"]
        [::std::mem::offset_of!(virtio_gpu_resp_resource_uuid, uuid) - 24usize];
};
#[repr(C)]
#[derive(Debug, Default, Copy, Clone, PartialEq)]
pub struct virtio_gpu_resource_create_blob {
    pub hdr: virtio_gpu_ctrl_hdr,
    pub resource_id: __le32,
    pub blob_mem: __le32,
    pub blob_flags: __le32,
    pub nr_entries: __le32,
    pub blob_id: __le64,
    pub size: __le64,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of virtio_gpu_resource_create_blob"]
        [::std::mem::size_of::<virtio_gpu_resource_create_blob>() - 56usize];
    ["Alignment of virtio_gpu_resource_create_blob"]
        [::std::mem::align_of::<virtio_gpu_resource_create_blob>() - 4usize];
    ["Offset of field: virtio_gpu_resource_create_blob::hdr"]
        [::std::mem::offset_of!(virtio_gpu_resource_create_blob, hdr) - 0usize];
    ["Offset of field: virtio_gpu_resource_create_blob::resource_id"]
        [::std::mem::offset_of!(virtio_gpu_resource_create_blob, resource_id) - 24usize];
    ["Offset of field: virtio_gpu_resource_create_blob::blob_mem"]
        [::std::mem::offset_of!(virtio_gpu_resource_create_blob, blob_mem) - 28usize];
    ["Offset of field: virtio_gpu_resource_create_blob::blob_flags"]
        [::std::mem::offset_of!(virtio_gpu_resource_create_blob, blob_flags) - 32usize];
    ["Offset of field: virtio_gpu_resource_create_blob::nr_entries"]
        [::std::mem::offset_of!(virtio_gpu_resource_create_blob, nr_entries) - 36usize];
    ["Offset of field: virtio_gpu_resource_create_blob::blob_id"]
        [::std::mem::offset_of!(virtio_gpu_resource_create_blob, blob_id) - 40usize];
    ["Offset of field: virtio_gpu_resource_create_blob::size"]
        [::std::mem::offset_of!(virtio_gpu_resource_create_blob, size) - 48usize];
};
#[repr(C)]
#[derive(Debug, Default, Copy, Clone, PartialEq)]
pub struct virtio_gpu_set_scanout_blob {
    pub hdr: virtio_gpu_ctrl_hdr,
    pub r: virtio_gpu_rect,
    pub scanout_id: __le32,
    pub resource_id: __le32,
    pub width: __le32,
    pub height: __le32,
    pub format: __le32,
    pub padding: __le32,
    pub strides: [__le32; 4usize],
    pub offsets: [__le32; 4usize],
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of virtio_gpu_set_scanout_blob"]
        [::std::mem::size_of::<virtio_gpu_set_scanout_blob>() - 96usize];
    ["Alignment of virtio_gpu_set_scanout_blob"]
        [::std::mem::align_of::<virtio_gpu_set_scanout_blob>() - 4usize];
    ["Offset of field: virtio_gpu_set_scanout_blob::hdr"]
        [::std::mem::offset_of!(virtio_gpu_set_scanout_blob, hdr) - 0usize];
    ["Offset of field: virtio_gpu_set_scanout_blob::r"]
        [::std::mem::offset_of!(virtio_gpu_set_scanout_blob, r) - 24usize];
    ["Offset of field: virtio_gpu_set_scanout_blob::scanout_id"]
        [::std::mem::offset_of!(virtio_gpu_set_scanout_blob, scanout_id) - 40usize];
    ["Offset of field: virtio_gpu_set_scanout_blob::resource_id"]
        [::std::mem::offset_of!(virtio_gpu_set_scanout_blob, resource_id) - 44usize];
    ["Offset of field: virtio_gpu_set_scanout_blob::width"]
        [::std::mem::offset_of!(virtio_gpu_set_scanout_blob, width) - 48usize];
    ["Offset of field: virtio_gpu_set_scanout_blob::height"]
        [::std::mem::offset_of!(virtio_gpu_set_scanout_blob, height) - 52usize];
    ["Offset of field: virtio_gpu_set_scanout_blob::format"]
        [::std::mem::offset_of!(virtio_gpu_set_scanout_blob, format) - 56usize];
    ["Offset of field: virtio_gpu_set_scanout_blob::padding"]
        [::std::mem::offset_of!(virtio_gpu_set_scanout_blob, padding) - 60usize];
    ["Offset of field: virtio_gpu_set_scanout_blob::strides"]
        [::std::mem::offset_of!(virtio_gpu_set_scanout_blob, strides) - 64usize];
    ["Offset of field: virtio_gpu_set_scanout_blob::offsets"]
        [::std::mem::offset_of!(virtio_gpu_set_scanout_blob, offsets) - 80usize];
};
#[repr(C)]
#[derive(Debug, Default, Copy, Clone, PartialEq)]
pub struct virtio_gpu_resource_map_blob {
    pub hdr: virtio_gpu_ctrl_hdr,
    pub resource_id: __le32,
    pub padding: __le32,
    pub offset: __le64,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of virtio_gpu_resource_map_blob"]
        [::std::mem::size_of::<virtio_gpu_resource_map_blob>() - 40usize];
    ["Alignment of virtio_gpu_resource_map_blob"]
        [::std::mem::align_of::<virtio_gpu_resource_map_blob>() - 4usize];
    ["Offset of field: virtio_gpu_resource_map_blob::hdr"]
        [::std::mem::offset_of!(virtio_gpu_resource_map_blob, hdr) - 0usize];
    ["Offset of field: virtio_gpu_resource_map_blob::resource_id"]
        [::std::mem::offset_of!(virtio_gpu_resource_map_blob, resource_id) - 24usize];
    ["Offset of field: virtio_gpu_resource_map_blob::padding"]
        [::std::mem::offset_of!(virtio_gpu_resource_map_blob, padding) - 28usize];
    ["Offset of field: virtio_gpu_resource_map_blob::offset"]
        [::std::mem::offset_of!(virtio_gpu_resource_map_blob, offset) - 32usize];
};
#[repr(C)]
#[derive(Debug, Default, Copy, Clone, PartialEq)]
pub struct virtio_gpu_resp_map_info {
    pub hdr: virtio_gpu_ctrl_hdr,
    pub map_info: __u32,
    pub padding: __u32,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of virtio_gpu_resp_map_info"]
        [::std::mem::size_of::<virtio_gpu_resp_map_info>() - 32usize];
    ["Alignment of virtio_gpu_resp_map_info"]
        [::std::mem::align_of::<virtio_gpu_resp_map_info>() - 4usize];
    ["Offset of field: virtio_gpu_resp_map_info::hdr"]
        [::std::mem::offset_of!(virtio_gpu_resp_map_info, hdr) - 0usize];
    ["Offset of field: virtio_gpu_resp_map_info::map_info"]
        [::std::mem::offset_of!(virtio_gpu_resp_map_info, map_info) - 24usize];
    ["Offset of field: virtio_gpu_resp_map_info::padding"]
        [::std::mem::offset_of!(virtio_gpu_resp_map_info, padding) - 28usize];
};
#[repr(C)]
#[derive(Debug, Default, Copy, Clone, PartialEq)]
pub struct virtio_gpu_resource_unmap_blob {
    pub hdr: virtio_gpu_ctrl_hdr,
    pub resource_id: __le32,
    pub padding: __le32,
}
#[allow(clippy::unnecessary_operation, clippy::identity_op)]
const _: () = {
    ["Size of virtio_gpu_resource_unmap_blob"]
        [::std::mem::size_of::<virtio_gpu_resource_unmap_blob>() - 32usize];
    ["Alignment of virtio_gpu_resource_unmap_blob"]
        [::std::mem::align_of::<virtio_gpu_resource_unmap_blob>() - 4usize];
    ["Offset of field: virtio_gpu_resource_unmap_blob::hdr"]
        [::std::mem::offset_of!(virtio_gpu_resource_unmap_blob, hdr) - 0usize];
    ["Offset of field: virtio_gpu_resource_unmap_blob::resource_id"]
        [::std::mem::offset_of!(virtio_gpu_resource_unmap_blob, resource_id) - 24usize];
    ["Offset of field: virtio_gpu_resource_unmap_blob::padding"]
        [::std::mem::offset_of!(virtio_gpu_resource_unmap_blob, padding) - 28usize];
};
