/* automatically generated by rust-bindgen 0.69.4 */ pub const VIR_TYPED_PARAM_FIELD_LENGTH: u32 = 80; pub const VIR_SECURITY_LABEL_BUFLEN: u32 = 4097; pub const VIR_SECURITY_MODEL_BUFLEN: u32 = 257; pub const VIR_SECURITY_DOI_BUFLEN: u32 = 257; pub const VIR_NODE_CPU_STATS_FIELD_LENGTH: u32 = 80; #[allow(unsafe_code)] pub const VIR_NODE_CPU_STATS_KERNEL: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"kernel\0") }; #[allow(unsafe_code)] pub const VIR_NODE_CPU_STATS_USER: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"user\0") }; #[allow(unsafe_code)] pub const VIR_NODE_CPU_STATS_IDLE: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"idle\0") }; #[allow(unsafe_code)] pub const VIR_NODE_CPU_STATS_IOWAIT: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"iowait\0") }; #[allow(unsafe_code)] pub const VIR_NODE_CPU_STATS_INTR: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"intr\0") }; #[allow(unsafe_code)] pub const VIR_NODE_CPU_STATS_UTILIZATION: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"utilization\0") }; pub const VIR_NODE_MEMORY_STATS_FIELD_LENGTH: u32 = 80; #[allow(unsafe_code)] pub const VIR_NODE_MEMORY_STATS_TOTAL: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"total\0") }; #[allow(unsafe_code)] pub const VIR_NODE_MEMORY_STATS_FREE: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"free\0") }; #[allow(unsafe_code)] pub const VIR_NODE_MEMORY_STATS_BUFFERS: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"buffers\0") }; #[allow(unsafe_code)] pub const VIR_NODE_MEMORY_STATS_CACHED: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"cached\0") }; #[allow(unsafe_code)] pub const VIR_NODE_MEMORY_SHARED_PAGES_TO_SCAN: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"shm_pages_to_scan\0") }; #[allow(unsafe_code)] pub const VIR_NODE_MEMORY_SHARED_SLEEP_MILLISECS: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"shm_sleep_millisecs\0") }; #[allow(unsafe_code)] pub const VIR_NODE_MEMORY_SHARED_PAGES_SHARED: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"shm_pages_shared\0") }; #[allow(unsafe_code)] pub const VIR_NODE_MEMORY_SHARED_PAGES_SHARING: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"shm_pages_sharing\0") }; #[allow(unsafe_code)] pub const VIR_NODE_MEMORY_SHARED_PAGES_UNSHARED: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"shm_pages_unshared\0") }; #[allow(unsafe_code)] pub const VIR_NODE_MEMORY_SHARED_PAGES_VOLATILE: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"shm_pages_volatile\0") }; #[allow(unsafe_code)] pub const VIR_NODE_MEMORY_SHARED_FULL_SCANS: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"shm_full_scans\0") }; #[allow(unsafe_code)] pub const VIR_NODE_MEMORY_SHARED_MERGE_ACROSS_NODES: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"shm_merge_across_nodes\0") }; #[allow(unsafe_code)] pub const VIR_NODE_SEV_PDH: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"pdh\0") }; #[allow(unsafe_code)] pub const VIR_NODE_SEV_CERT_CHAIN: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"cert-chain\0") }; #[allow(unsafe_code)] pub const VIR_NODE_SEV_CPU0_ID: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"cpu0-id\0") }; #[allow(unsafe_code)] pub const VIR_NODE_SEV_CBITPOS: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"cbitpos\0") }; #[allow(unsafe_code)] pub const VIR_NODE_SEV_REDUCED_PHYS_BITS: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"reduced-phys-bits\0") }; #[allow(unsafe_code)] pub const VIR_NODE_SEV_MAX_GUESTS: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"max-guests\0") }; #[allow(unsafe_code)] pub const VIR_NODE_SEV_MAX_ES_GUESTS: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"max-es-guests\0") }; pub const VIR_UUID_BUFLEN: u32 = 16; pub const VIR_UUID_STRING_BUFLEN: u32 = 37; #[allow(unsafe_code)] pub const VIR_CONNECT_IDENTITY_USER_NAME: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"user-name\0") }; #[allow(unsafe_code)] pub const VIR_CONNECT_IDENTITY_UNIX_USER_ID: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"unix-user-id\0") }; #[allow(unsafe_code)] pub const VIR_CONNECT_IDENTITY_GROUP_NAME: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"group-name\0") }; #[allow(unsafe_code)] pub const VIR_CONNECT_IDENTITY_UNIX_GROUP_ID: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"unix-group-id\0") }; #[allow(unsafe_code)] pub const VIR_CONNECT_IDENTITY_PROCESS_ID: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"process-id\0") }; #[allow(unsafe_code)] pub const VIR_CONNECT_IDENTITY_PROCESS_TIME: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"process-time\0") }; #[allow(unsafe_code)] pub const VIR_CONNECT_IDENTITY_SASL_USER_NAME: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"sasl-user-name\0") }; #[allow(unsafe_code)] pub const VIR_CONNECT_IDENTITY_X509_DISTINGUISHED_NAME: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"x509-distinguished-name\0") }; #[allow(unsafe_code)] pub const VIR_CONNECT_IDENTITY_SELINUX_CONTEXT: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"selinux-context\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_SCHEDULER_CPU_SHARES: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"cpu_shares\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_SCHEDULER_GLOBAL_PERIOD: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"global_period\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_SCHEDULER_GLOBAL_QUOTA: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"global_quota\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_SCHEDULER_VCPU_PERIOD: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"vcpu_period\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_SCHEDULER_VCPU_QUOTA: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"vcpu_quota\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_SCHEDULER_EMULATOR_PERIOD: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"emulator_period\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_SCHEDULER_EMULATOR_QUOTA: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"emulator_quota\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_SCHEDULER_IOTHREAD_PERIOD: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"iothread_period\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_SCHEDULER_IOTHREAD_QUOTA: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"iothread_quota\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_SCHEDULER_WEIGHT: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"weight\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_SCHEDULER_CAP: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"cap\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_SCHEDULER_RESERVATION: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"reservation\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_SCHEDULER_LIMIT: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"limit\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_SCHEDULER_SHARES: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"shares\0") }; pub const VIR_DOMAIN_BLOCK_STATS_FIELD_LENGTH: u32 = 80; #[allow(unsafe_code)] pub const VIR_DOMAIN_BLOCK_STATS_READ_BYTES: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"rd_bytes\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_BLOCK_STATS_READ_REQ: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"rd_operations\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_BLOCK_STATS_READ_TOTAL_TIMES: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"rd_total_times\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_BLOCK_STATS_WRITE_BYTES: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"wr_bytes\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_BLOCK_STATS_WRITE_REQ: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"wr_operations\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_BLOCK_STATS_WRITE_TOTAL_TIMES: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"wr_total_times\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_BLOCK_STATS_FLUSH_REQ: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"flush_operations\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_BLOCK_STATS_FLUSH_TOTAL_TIMES: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"flush_total_times\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_BLOCK_STATS_ERRS: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"errs\0") }; #[allow(unsafe_code)] pub const VIR_MIGRATE_PARAM_URI: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"migrate_uri\0") }; #[allow(unsafe_code)] pub const VIR_MIGRATE_PARAM_DEST_NAME: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"destination_name\0") }; #[allow(unsafe_code)] pub const VIR_MIGRATE_PARAM_DEST_XML: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"destination_xml\0") }; #[allow(unsafe_code)] pub const VIR_MIGRATE_PARAM_PERSIST_XML: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"persistent_xml\0") }; #[allow(unsafe_code)] pub const VIR_MIGRATE_PARAM_BANDWIDTH: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"bandwidth\0") }; #[allow(unsafe_code)] pub const VIR_MIGRATE_PARAM_BANDWIDTH_POSTCOPY: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"bandwidth.postcopy\0") }; #[allow(unsafe_code)] pub const VIR_MIGRATE_PARAM_GRAPHICS_URI: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"graphics_uri\0") }; #[allow(unsafe_code)] pub const VIR_MIGRATE_PARAM_LISTEN_ADDRESS: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"listen_address\0") }; #[allow(unsafe_code)] pub const VIR_MIGRATE_PARAM_MIGRATE_DISKS: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"migrate_disks\0") }; #[allow(unsafe_code)] pub const VIR_MIGRATE_PARAM_DISKS_PORT: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"disks_port\0") }; #[allow(unsafe_code)] pub const VIR_MIGRATE_PARAM_DISKS_URI: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"disks_uri\0") }; #[allow(unsafe_code)] pub const VIR_MIGRATE_PARAM_COMPRESSION: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"compression\0") }; #[allow(unsafe_code)] pub const VIR_MIGRATE_PARAM_COMPRESSION_MT_LEVEL: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"compression.mt.level\0") }; #[allow(unsafe_code)] pub const VIR_MIGRATE_PARAM_COMPRESSION_MT_THREADS: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"compression.mt.threads\0") }; #[allow(unsafe_code)] pub const VIR_MIGRATE_PARAM_COMPRESSION_MT_DTHREADS: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"compression.mt.dthreads\0") }; #[allow(unsafe_code)] pub const VIR_MIGRATE_PARAM_COMPRESSION_XBZRLE_CACHE: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"compression.xbzrle.cache\0") }; #[allow(unsafe_code)] pub const VIR_MIGRATE_PARAM_COMPRESSION_ZLIB_LEVEL: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"compression.zlib.level\0") }; #[allow(unsafe_code)] pub const VIR_MIGRATE_PARAM_COMPRESSION_ZSTD_LEVEL: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"compression.zstd.level\0") }; #[allow(unsafe_code)] pub const VIR_MIGRATE_PARAM_AUTO_CONVERGE_INITIAL: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"auto_converge.initial\0") }; #[allow(unsafe_code)] pub const VIR_MIGRATE_PARAM_AUTO_CONVERGE_INCREMENT: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"auto_converge.increment\0") }; #[allow(unsafe_code)] pub const VIR_MIGRATE_PARAM_PARALLEL_CONNECTIONS: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"parallel.connections\0") }; #[allow(unsafe_code)] pub const VIR_MIGRATE_PARAM_TLS_DESTINATION: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"tls.destination\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_SAVE_PARAM_FILE: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"file\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_SAVE_PARAM_DXML: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"dxml\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_CPU_STATS_CPUTIME: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"cpu_time\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_CPU_STATS_USERTIME: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"user_time\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_CPU_STATS_SYSTEMTIME: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"system_time\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_CPU_STATS_VCPUTIME: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"vcpu_time\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_BLKIO_WEIGHT: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"weight\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_BLKIO_DEVICE_WEIGHT: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"device_weight\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_BLKIO_DEVICE_READ_IOPS: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"device_read_iops_sec\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_BLKIO_DEVICE_WRITE_IOPS: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"device_write_iops_sec\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_BLKIO_DEVICE_READ_BPS: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"device_read_bytes_sec\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_BLKIO_DEVICE_WRITE_BPS: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"device_write_bytes_sec\0") }; pub const VIR_DOMAIN_MEMORY_PARAM_UNLIMITED: u64 = 9007199254740991; #[allow(unsafe_code)] pub const VIR_DOMAIN_MEMORY_HARD_LIMIT: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"hard_limit\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_MEMORY_SOFT_LIMIT: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"soft_limit\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_MEMORY_MIN_GUARANTEE: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"min_guarantee\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_MEMORY_SWAP_HARD_LIMIT: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"swap_hard_limit\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_NUMA_NODESET: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"numa_nodeset\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_NUMA_MODE: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"numa_mode\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_BANDWIDTH_IN_AVERAGE: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"inbound.average\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_BANDWIDTH_IN_PEAK: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"inbound.peak\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_BANDWIDTH_IN_BURST: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"inbound.burst\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_BANDWIDTH_IN_FLOOR: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"inbound.floor\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_BANDWIDTH_OUT_AVERAGE: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"outbound.average\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_BANDWIDTH_OUT_PEAK: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"outbound.peak\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_BANDWIDTH_OUT_BURST: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"outbound.burst\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_IOTHREAD_POLL_MAX_NS: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"poll_max_ns\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_IOTHREAD_POLL_GROW: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"poll_grow\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_IOTHREAD_POLL_SHRINK: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"poll_shrink\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_IOTHREAD_THREAD_POOL_MIN: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"thread_pool_min\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_IOTHREAD_THREAD_POOL_MAX: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"thread_pool_max\0") }; #[allow(unsafe_code)] pub const VIR_PERF_PARAM_CMT: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"cmt\0") }; #[allow(unsafe_code)] pub const VIR_PERF_PARAM_MBMT: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"mbmt\0") }; #[allow(unsafe_code)] pub const VIR_PERF_PARAM_MBML: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"mbml\0") }; #[allow(unsafe_code)] pub const VIR_PERF_PARAM_CACHE_MISSES: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"cache_misses\0") }; #[allow(unsafe_code)] pub const VIR_PERF_PARAM_CACHE_REFERENCES: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"cache_references\0") }; #[allow(unsafe_code)] pub const VIR_PERF_PARAM_INSTRUCTIONS: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"instructions\0") }; #[allow(unsafe_code)] pub const VIR_PERF_PARAM_CPU_CYCLES: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"cpu_cycles\0") }; #[allow(unsafe_code)] pub const VIR_PERF_PARAM_BRANCH_INSTRUCTIONS: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"branch_instructions\0") }; #[allow(unsafe_code)] pub const VIR_PERF_PARAM_BRANCH_MISSES: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"branch_misses\0") }; #[allow(unsafe_code)] pub const VIR_PERF_PARAM_BUS_CYCLES: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"bus_cycles\0") }; #[allow(unsafe_code)] pub const VIR_PERF_PARAM_STALLED_CYCLES_FRONTEND: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"stalled_cycles_frontend\0") }; #[allow(unsafe_code)] pub const VIR_PERF_PARAM_STALLED_CYCLES_BACKEND: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"stalled_cycles_backend\0") }; #[allow(unsafe_code)] pub const VIR_PERF_PARAM_REF_CPU_CYCLES: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"ref_cpu_cycles\0") }; #[allow(unsafe_code)] pub const VIR_PERF_PARAM_CPU_CLOCK: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"cpu_clock\0") }; #[allow(unsafe_code)] pub const VIR_PERF_PARAM_TASK_CLOCK: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"task_clock\0") }; #[allow(unsafe_code)] pub const VIR_PERF_PARAM_PAGE_FAULTS: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"page_faults\0") }; #[allow(unsafe_code)] pub const VIR_PERF_PARAM_CONTEXT_SWITCHES: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"context_switches\0") }; #[allow(unsafe_code)] pub const VIR_PERF_PARAM_CPU_MIGRATIONS: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"cpu_migrations\0") }; #[allow(unsafe_code)] pub const VIR_PERF_PARAM_PAGE_FAULTS_MIN: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"page_faults_min\0") }; #[allow(unsafe_code)] pub const VIR_PERF_PARAM_PAGE_FAULTS_MAJ: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"page_faults_maj\0") }; #[allow(unsafe_code)] pub const VIR_PERF_PARAM_ALIGNMENT_FAULTS: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"alignment_faults\0") }; #[allow(unsafe_code)] pub const VIR_PERF_PARAM_EMULATION_FAULTS: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"emulation_faults\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_BLOCK_COPY_BANDWIDTH: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"bandwidth\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_BLOCK_COPY_GRANULARITY: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"granularity\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_BLOCK_COPY_BUF_SIZE: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"buf-size\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_BLOCK_IOTUNE_TOTAL_BYTES_SEC: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"total_bytes_sec\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_BLOCK_IOTUNE_READ_BYTES_SEC: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"read_bytes_sec\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_BLOCK_IOTUNE_WRITE_BYTES_SEC: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"write_bytes_sec\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_BLOCK_IOTUNE_TOTAL_IOPS_SEC: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"total_iops_sec\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_BLOCK_IOTUNE_READ_IOPS_SEC: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"read_iops_sec\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_BLOCK_IOTUNE_WRITE_IOPS_SEC: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"write_iops_sec\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_BLOCK_IOTUNE_TOTAL_BYTES_SEC_MAX: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"total_bytes_sec_max\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_BLOCK_IOTUNE_READ_BYTES_SEC_MAX: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"read_bytes_sec_max\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_BLOCK_IOTUNE_WRITE_BYTES_SEC_MAX: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"write_bytes_sec_max\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_BLOCK_IOTUNE_TOTAL_IOPS_SEC_MAX: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"total_iops_sec_max\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_BLOCK_IOTUNE_READ_IOPS_SEC_MAX: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"read_iops_sec_max\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_BLOCK_IOTUNE_WRITE_IOPS_SEC_MAX: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"write_iops_sec_max\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_BLOCK_IOTUNE_TOTAL_BYTES_SEC_MAX_LENGTH: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"total_bytes_sec_max_length\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_BLOCK_IOTUNE_READ_BYTES_SEC_MAX_LENGTH: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"read_bytes_sec_max_length\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_BLOCK_IOTUNE_WRITE_BYTES_SEC_MAX_LENGTH: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"write_bytes_sec_max_length\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_BLOCK_IOTUNE_TOTAL_IOPS_SEC_MAX_LENGTH: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"total_iops_sec_max_length\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_BLOCK_IOTUNE_READ_IOPS_SEC_MAX_LENGTH: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"read_iops_sec_max_length\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_BLOCK_IOTUNE_WRITE_IOPS_SEC_MAX_LENGTH: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"write_iops_sec_max_length\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_BLOCK_IOTUNE_SIZE_IOPS_SEC: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"size_iops_sec\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_BLOCK_IOTUNE_GROUP_NAME: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"group_name\0") }; pub const VIR_DOMAIN_SEND_KEY_MAX_KEYS: u32 = 16; #[allow(unsafe_code)] pub const VIR_DOMAIN_JOB_OPERATION: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"operation\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_JOB_TIME_ELAPSED: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"time_elapsed\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_JOB_TIME_ELAPSED_NET: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"time_elapsed_net\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_JOB_TIME_REMAINING: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"time_remaining\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_JOB_DOWNTIME: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"downtime\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_JOB_DOWNTIME_NET: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"downtime_net\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_JOB_SETUP_TIME: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"setup_time\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_JOB_DATA_TOTAL: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"data_total\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_JOB_DATA_PROCESSED: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"data_processed\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_JOB_DATA_REMAINING: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"data_remaining\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_JOB_MEMORY_TOTAL: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"memory_total\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_JOB_MEMORY_PROCESSED: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"memory_processed\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_JOB_MEMORY_REMAINING: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"memory_remaining\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_JOB_MEMORY_CONSTANT: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"memory_constant\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_JOB_MEMORY_NORMAL: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"memory_normal\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_JOB_MEMORY_NORMAL_BYTES: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"memory_normal_bytes\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_JOB_MEMORY_BPS: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"memory_bps\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_JOB_MEMORY_DIRTY_RATE: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"memory_dirty_rate\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_JOB_MEMORY_PAGE_SIZE: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"memory_page_size\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_JOB_MEMORY_ITERATION: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"memory_iteration\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_JOB_MEMORY_POSTCOPY_REQS: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"memory_postcopy_requests\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_JOB_DISK_TOTAL: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"disk_total\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_JOB_DISK_PROCESSED: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"disk_processed\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_JOB_DISK_REMAINING: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"disk_remaining\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_JOB_DISK_BPS: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"disk_bps\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_JOB_COMPRESSION_CACHE: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"compression_cache\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_JOB_COMPRESSION_BYTES: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"compression_bytes\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_JOB_COMPRESSION_PAGES: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"compression_pages\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_JOB_COMPRESSION_CACHE_MISSES: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"compression_cache_misses\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_JOB_COMPRESSION_OVERFLOW: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"compression_overflow\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_JOB_AUTO_CONVERGE_THROTTLE: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"auto_converge_throttle\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_JOB_SUCCESS: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"success\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_JOB_ERRMSG: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"errmsg\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_JOB_DISK_TEMP_USED: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"disk_temp_used\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_JOB_DISK_TEMP_TOTAL: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"disk_temp_total\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_TUNABLE_CPU_VCPUPIN: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"cputune.vcpupin%u\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_TUNABLE_CPU_EMULATORPIN: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"cputune.emulatorpin\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_TUNABLE_CPU_IOTHREADSPIN: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"cputune.iothreadpin%u\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_TUNABLE_CPU_CPU_SHARES: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"cputune.cpu_shares\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_TUNABLE_CPU_GLOBAL_PERIOD: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"cputune.global_period\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_TUNABLE_CPU_GLOBAL_QUOTA: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"cputune.global_quota\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_TUNABLE_CPU_VCPU_PERIOD: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"cputune.vcpu_period\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_TUNABLE_CPU_VCPU_QUOTA: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"cputune.vcpu_quota\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_TUNABLE_CPU_EMULATOR_PERIOD: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"cputune.emulator_period\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_TUNABLE_CPU_EMULATOR_QUOTA: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"cputune.emulator_quota\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_TUNABLE_CPU_IOTHREAD_PERIOD: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"cputune.iothread_period\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_TUNABLE_CPU_IOTHREAD_QUOTA: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"cputune.iothread_quota\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_TUNABLE_BLKDEV_DISK: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"blkdeviotune.disk\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_TUNABLE_BLKDEV_TOTAL_BYTES_SEC: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"blkdeviotune.total_bytes_sec\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_TUNABLE_BLKDEV_READ_BYTES_SEC: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"blkdeviotune.read_bytes_sec\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_TUNABLE_BLKDEV_WRITE_BYTES_SEC: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"blkdeviotune.write_bytes_sec\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_TUNABLE_BLKDEV_TOTAL_IOPS_SEC: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"blkdeviotune.total_iops_sec\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_TUNABLE_BLKDEV_READ_IOPS_SEC: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"blkdeviotune.read_iops_sec\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_TUNABLE_BLKDEV_WRITE_IOPS_SEC: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"blkdeviotune.write_iops_sec\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_TUNABLE_BLKDEV_TOTAL_BYTES_SEC_MAX: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"blkdeviotune.total_bytes_sec_max\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_TUNABLE_BLKDEV_READ_BYTES_SEC_MAX: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"blkdeviotune.read_bytes_sec_max\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_TUNABLE_BLKDEV_WRITE_BYTES_SEC_MAX: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"blkdeviotune.write_bytes_sec_max\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_TUNABLE_BLKDEV_TOTAL_IOPS_SEC_MAX: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"blkdeviotune.total_iops_sec_max\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_TUNABLE_BLKDEV_READ_IOPS_SEC_MAX: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"blkdeviotune.read_iops_sec_max\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_TUNABLE_BLKDEV_WRITE_IOPS_SEC_MAX: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"blkdeviotune.write_iops_sec_max\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_TUNABLE_BLKDEV_SIZE_IOPS_SEC: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"blkdeviotune.size_iops_sec\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_TUNABLE_BLKDEV_GROUP_NAME: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"blkdeviotune.group_name\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_TUNABLE_BLKDEV_TOTAL_BYTES_SEC_MAX_LENGTH: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"blkdeviotune.total_bytes_sec_max_length\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_TUNABLE_BLKDEV_READ_BYTES_SEC_MAX_LENGTH: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"blkdeviotune.read_bytes_sec_max_length\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_TUNABLE_BLKDEV_WRITE_BYTES_SEC_MAX_LENGTH: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"blkdeviotune.write_bytes_sec_max_length\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_TUNABLE_BLKDEV_TOTAL_IOPS_SEC_MAX_LENGTH: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"blkdeviotune.total_iops_sec_max_length\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_TUNABLE_BLKDEV_READ_IOPS_SEC_MAX_LENGTH: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"blkdeviotune.read_iops_sec_max_length\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_TUNABLE_BLKDEV_WRITE_IOPS_SEC_MAX_LENGTH: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"blkdeviotune.write_iops_sec_max_length\0") }; pub const VIR_DOMAIN_SCHED_FIELD_LENGTH: u32 = 80; pub const VIR_DOMAIN_BLKIO_FIELD_LENGTH: u32 = 80; pub const VIR_DOMAIN_MEMORY_FIELD_LENGTH: u32 = 80; #[allow(unsafe_code)] pub const VIR_DOMAIN_LAUNCH_SECURITY_SEV_MEASUREMENT: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"sev-measurement\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_LAUNCH_SECURITY_SEV_API_MAJOR: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"sev-api-major\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_LAUNCH_SECURITY_SEV_API_MINOR: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"sev-api-minor\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_LAUNCH_SECURITY_SEV_BUILD_ID: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"sev-build-id\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_LAUNCH_SECURITY_SEV_POLICY: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"sev-policy\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_LAUNCH_SECURITY_SEV_SNP_POLICY: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"sev-snp-policy\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_LAUNCH_SECURITY_SEV_SECRET_HEADER: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"sev-secret-header\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_LAUNCH_SECURITY_SEV_SECRET: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"sev-secret\0") }; #[allow(unsafe_code)] pub const VIR_DOMAIN_LAUNCH_SECURITY_SEV_SECRET_SET_ADDRESS: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"sev-secret-set-address\0") }; #[allow(unsafe_code)] pub const VIR_NETWORK_PORT_BANDWIDTH_IN_AVERAGE: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"inbound.average\0") }; #[allow(unsafe_code)] pub const VIR_NETWORK_PORT_BANDWIDTH_IN_PEAK: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"inbound.peak\0") }; #[allow(unsafe_code)] pub const VIR_NETWORK_PORT_BANDWIDTH_IN_BURST: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"inbound.burst\0") }; #[allow(unsafe_code)] pub const VIR_NETWORK_PORT_BANDWIDTH_IN_FLOOR: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"inbound.floor\0") }; #[allow(unsafe_code)] pub const VIR_NETWORK_PORT_BANDWIDTH_OUT_AVERAGE: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"outbound.average\0") }; #[allow(unsafe_code)] pub const VIR_NETWORK_PORT_BANDWIDTH_OUT_PEAK: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"outbound.peak\0") }; #[allow(unsafe_code)] pub const VIR_NETWORK_PORT_BANDWIDTH_OUT_BURST: &::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"outbound.burst\0") }; pub type virFreeCallback = ::std::option::Option; pub const VIR_CONNECT_CLOSE_REASON_ERROR: virConnectCloseReason = 0; pub const VIR_CONNECT_CLOSE_REASON_EOF: virConnectCloseReason = 1; pub const VIR_CONNECT_CLOSE_REASON_KEEPALIVE: virConnectCloseReason = 2; pub const VIR_CONNECT_CLOSE_REASON_CLIENT: virConnectCloseReason = 3; pub type virConnectCloseReason = ::libc::c_uint; pub const VIR_TYPED_PARAM_INT: virTypedParameterType = 1; pub const VIR_TYPED_PARAM_UINT: virTypedParameterType = 2; pub const VIR_TYPED_PARAM_LLONG: virTypedParameterType = 3; pub const VIR_TYPED_PARAM_ULLONG: virTypedParameterType = 4; pub const VIR_TYPED_PARAM_DOUBLE: virTypedParameterType = 5; pub const VIR_TYPED_PARAM_BOOLEAN: virTypedParameterType = 6; pub const VIR_TYPED_PARAM_STRING: virTypedParameterType = 7; pub type virTypedParameterType = ::libc::c_uint; pub const VIR_TYPED_PARAM_STRING_OKAY: virTypedParameterFlags = 4; pub type virTypedParameterFlags = ::libc::c_uint; pub type virTypedParameter = _virTypedParameter; #[repr(C)] #[derive(Copy, Clone)] pub struct _virTypedParameter { pub field: [::libc::c_char; 80usize], pub type_: ::libc::c_int, pub value: _virTypedParameter__bindgen_ty_1, } #[repr(C)] #[derive(Copy, Clone)] pub union _virTypedParameter__bindgen_ty_1 { pub i: ::libc::c_int, pub ui: ::libc::c_uint, pub l: ::libc::c_longlong, pub ul: ::libc::c_ulonglong, pub d: f64, pub b: ::libc::c_char, pub s: *mut ::libc::c_char, } #[test] fn bindgen_test_layout__virTypedParameter__bindgen_ty_1() { const UNINIT: ::std::mem::MaybeUninit<_virTypedParameter__bindgen_ty_1> = ::std::mem::MaybeUninit::uninit(); let ptr = UNINIT.as_ptr(); assert_eq!( ::std::mem::size_of::<_virTypedParameter__bindgen_ty_1>(), 8usize, concat!("Size of: ", stringify!(_virTypedParameter__bindgen_ty_1)) ); assert_eq!( ::std::mem::align_of::<_virTypedParameter__bindgen_ty_1>(), 8usize, concat!( "Alignment of ", stringify!(_virTypedParameter__bindgen_ty_1) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).i) as usize - ptr as usize }, 0usize, concat!( "Offset of field: ", stringify!(_virTypedParameter__bindgen_ty_1), "::", stringify!(i) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).ui) as usize - ptr as usize }, 0usize, concat!( "Offset of field: ", stringify!(_virTypedParameter__bindgen_ty_1), "::", stringify!(ui) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).l) as usize - ptr as usize }, 0usize, concat!( "Offset of field: ", stringify!(_virTypedParameter__bindgen_ty_1), "::", stringify!(l) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).ul) as usize - ptr as usize }, 0usize, concat!( "Offset of field: ", stringify!(_virTypedParameter__bindgen_ty_1), "::", stringify!(ul) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).d) as usize - ptr as usize }, 0usize, concat!( "Offset of field: ", stringify!(_virTypedParameter__bindgen_ty_1), "::", stringify!(d) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).b) as usize - ptr as usize }, 0usize, concat!( "Offset of field: ", stringify!(_virTypedParameter__bindgen_ty_1), "::", stringify!(b) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).s) as usize - ptr as usize }, 0usize, concat!( "Offset of field: ", stringify!(_virTypedParameter__bindgen_ty_1), "::", stringify!(s) ) ); } #[test] fn bindgen_test_layout__virTypedParameter() { const UNINIT: ::std::mem::MaybeUninit<_virTypedParameter> = ::std::mem::MaybeUninit::uninit(); let ptr = UNINIT.as_ptr(); assert_eq!( ::std::mem::size_of::<_virTypedParameter>(), 96usize, concat!("Size of: ", stringify!(_virTypedParameter)) ); assert_eq!( ::std::mem::align_of::<_virTypedParameter>(), 8usize, concat!("Alignment of ", stringify!(_virTypedParameter)) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).field) as usize - ptr as usize }, 0usize, concat!( "Offset of field: ", stringify!(_virTypedParameter), "::", stringify!(field) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).type_) as usize - ptr as usize }, 80usize, concat!( "Offset of field: ", stringify!(_virTypedParameter), "::", stringify!(type_) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).value) as usize - ptr as usize }, 88usize, concat!( "Offset of field: ", stringify!(_virTypedParameter), "::", stringify!(value) ) ); } pub type virTypedParameterPtr = *mut virTypedParameter; extern "C" { pub fn virTypedParamsGet( params: virTypedParameterPtr, nparams: ::libc::c_int, name: *const ::libc::c_char, ) -> virTypedParameterPtr; } extern "C" { pub fn virTypedParamsGetInt( params: virTypedParameterPtr, nparams: ::libc::c_int, name: *const ::libc::c_char, value: *mut ::libc::c_int, ) -> ::libc::c_int; } extern "C" { pub fn virTypedParamsGetUInt( params: virTypedParameterPtr, nparams: ::libc::c_int, name: *const ::libc::c_char, value: *mut ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virTypedParamsGetLLong( params: virTypedParameterPtr, nparams: ::libc::c_int, name: *const ::libc::c_char, value: *mut ::libc::c_longlong, ) -> ::libc::c_int; } extern "C" { pub fn virTypedParamsGetULLong( params: virTypedParameterPtr, nparams: ::libc::c_int, name: *const ::libc::c_char, value: *mut ::libc::c_ulonglong, ) -> ::libc::c_int; } extern "C" { pub fn virTypedParamsGetDouble( params: virTypedParameterPtr, nparams: ::libc::c_int, name: *const ::libc::c_char, value: *mut f64, ) -> ::libc::c_int; } extern "C" { pub fn virTypedParamsGetBoolean( params: virTypedParameterPtr, nparams: ::libc::c_int, name: *const ::libc::c_char, value: *mut ::libc::c_int, ) -> ::libc::c_int; } extern "C" { pub fn virTypedParamsGetString( params: virTypedParameterPtr, nparams: ::libc::c_int, name: *const ::libc::c_char, value: *mut *const ::libc::c_char, ) -> ::libc::c_int; } extern "C" { pub fn virTypedParamsAddInt( params: *mut virTypedParameterPtr, nparams: *mut ::libc::c_int, maxparams: *mut ::libc::c_int, name: *const ::libc::c_char, value: ::libc::c_int, ) -> ::libc::c_int; } extern "C" { pub fn virTypedParamsAddUInt( params: *mut virTypedParameterPtr, nparams: *mut ::libc::c_int, maxparams: *mut ::libc::c_int, name: *const ::libc::c_char, value: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virTypedParamsAddLLong( params: *mut virTypedParameterPtr, nparams: *mut ::libc::c_int, maxparams: *mut ::libc::c_int, name: *const ::libc::c_char, value: ::libc::c_longlong, ) -> ::libc::c_int; } extern "C" { pub fn virTypedParamsAddULLong( params: *mut virTypedParameterPtr, nparams: *mut ::libc::c_int, maxparams: *mut ::libc::c_int, name: *const ::libc::c_char, value: ::libc::c_ulonglong, ) -> ::libc::c_int; } extern "C" { pub fn virTypedParamsAddDouble( params: *mut virTypedParameterPtr, nparams: *mut ::libc::c_int, maxparams: *mut ::libc::c_int, name: *const ::libc::c_char, value: f64, ) -> ::libc::c_int; } extern "C" { pub fn virTypedParamsAddBoolean( params: *mut virTypedParameterPtr, nparams: *mut ::libc::c_int, maxparams: *mut ::libc::c_int, name: *const ::libc::c_char, value: ::libc::c_int, ) -> ::libc::c_int; } extern "C" { pub fn virTypedParamsAddString( params: *mut virTypedParameterPtr, nparams: *mut ::libc::c_int, maxparams: *mut ::libc::c_int, name: *const ::libc::c_char, value: *const ::libc::c_char, ) -> ::libc::c_int; } extern "C" { pub fn virTypedParamsAddStringList( params: *mut virTypedParameterPtr, nparams: *mut ::libc::c_int, maxparams: *mut ::libc::c_int, name: *const ::libc::c_char, values: *mut *const ::libc::c_char, ) -> ::libc::c_int; } extern "C" { pub fn virTypedParamsAddFromString( params: *mut virTypedParameterPtr, nparams: *mut ::libc::c_int, maxparams: *mut ::libc::c_int, name: *const ::libc::c_char, type_: ::libc::c_int, value: *const ::libc::c_char, ) -> ::libc::c_int; } extern "C" { pub fn virTypedParamsClear(params: virTypedParameterPtr, nparams: ::libc::c_int); } extern "C" { pub fn virTypedParamsFree(params: virTypedParameterPtr, nparams: ::libc::c_int); } #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct _virConnect { _unused: [u8; 0], } pub type virConnect = _virConnect; pub type virConnectPtr = *mut virConnect; pub const VIR_NODE_SUSPEND_TARGET_MEM: virNodeSuspendTarget = 0; pub const VIR_NODE_SUSPEND_TARGET_DISK: virNodeSuspendTarget = 1; pub const VIR_NODE_SUSPEND_TARGET_HYBRID: virNodeSuspendTarget = 2; pub type virNodeSuspendTarget = ::libc::c_uint; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct _virStream { _unused: [u8; 0], } pub type virStream = _virStream; pub type virStreamPtr = *mut virStream; pub type virSecurityLabel = _virSecurityLabel; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct _virSecurityLabel { pub label: [::libc::c_char; 4097usize], pub enforcing: ::libc::c_int, } #[test] fn bindgen_test_layout__virSecurityLabel() { const UNINIT: ::std::mem::MaybeUninit<_virSecurityLabel> = ::std::mem::MaybeUninit::uninit(); let ptr = UNINIT.as_ptr(); assert_eq!( ::std::mem::size_of::<_virSecurityLabel>(), 4104usize, concat!("Size of: ", stringify!(_virSecurityLabel)) ); assert_eq!( ::std::mem::align_of::<_virSecurityLabel>(), 4usize, concat!("Alignment of ", stringify!(_virSecurityLabel)) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).label) as usize - ptr as usize }, 0usize, concat!( "Offset of field: ", stringify!(_virSecurityLabel), "::", stringify!(label) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).enforcing) as usize - ptr as usize }, 4100usize, concat!( "Offset of field: ", stringify!(_virSecurityLabel), "::", stringify!(enforcing) ) ); } pub type virSecurityLabelPtr = *mut virSecurityLabel; pub type virSecurityModel = _virSecurityModel; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct _virSecurityModel { pub model: [::libc::c_char; 257usize], pub doi: [::libc::c_char; 257usize], } #[test] fn bindgen_test_layout__virSecurityModel() { const UNINIT: ::std::mem::MaybeUninit<_virSecurityModel> = ::std::mem::MaybeUninit::uninit(); let ptr = UNINIT.as_ptr(); assert_eq!( ::std::mem::size_of::<_virSecurityModel>(), 514usize, concat!("Size of: ", stringify!(_virSecurityModel)) ); assert_eq!( ::std::mem::align_of::<_virSecurityModel>(), 1usize, concat!("Alignment of ", stringify!(_virSecurityModel)) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).model) as usize - ptr as usize }, 0usize, concat!( "Offset of field: ", stringify!(_virSecurityModel), "::", stringify!(model) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).doi) as usize - ptr as usize }, 257usize, concat!( "Offset of field: ", stringify!(_virSecurityModel), "::", stringify!(doi) ) ); } pub type virSecurityModelPtr = *mut virSecurityModel; pub type virNodeInfo = _virNodeInfo; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct _virNodeInfo { pub model: [::libc::c_char; 32usize], pub memory: ::libc::c_ulong, pub cpus: ::libc::c_uint, pub mhz: ::libc::c_uint, pub nodes: ::libc::c_uint, pub sockets: ::libc::c_uint, pub cores: ::libc::c_uint, pub threads: ::libc::c_uint, } #[test] fn bindgen_test_layout__virNodeInfo() { const UNINIT: ::std::mem::MaybeUninit<_virNodeInfo> = ::std::mem::MaybeUninit::uninit(); let ptr = UNINIT.as_ptr(); assert_eq!( ::std::mem::size_of::<_virNodeInfo>(), 64usize, concat!("Size of: ", stringify!(_virNodeInfo)) ); assert_eq!( ::std::mem::align_of::<_virNodeInfo>(), 8usize, concat!("Alignment of ", stringify!(_virNodeInfo)) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).model) as usize - ptr as usize }, 0usize, concat!( "Offset of field: ", stringify!(_virNodeInfo), "::", stringify!(model) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).memory) as usize - ptr as usize }, 32usize, concat!( "Offset of field: ", stringify!(_virNodeInfo), "::", stringify!(memory) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).cpus) as usize - ptr as usize }, 40usize, concat!( "Offset of field: ", stringify!(_virNodeInfo), "::", stringify!(cpus) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).mhz) as usize - ptr as usize }, 44usize, concat!( "Offset of field: ", stringify!(_virNodeInfo), "::", stringify!(mhz) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).nodes) as usize - ptr as usize }, 48usize, concat!( "Offset of field: ", stringify!(_virNodeInfo), "::", stringify!(nodes) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).sockets) as usize - ptr as usize }, 52usize, concat!( "Offset of field: ", stringify!(_virNodeInfo), "::", stringify!(sockets) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).cores) as usize - ptr as usize }, 56usize, concat!( "Offset of field: ", stringify!(_virNodeInfo), "::", stringify!(cores) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).threads) as usize - ptr as usize }, 60usize, concat!( "Offset of field: ", stringify!(_virNodeInfo), "::", stringify!(threads) ) ); } pub const VIR_NODE_CPU_STATS_ALL_CPUS: virNodeGetCPUStatsAllCPUs = -1; pub type virNodeGetCPUStatsAllCPUs = ::libc::c_int; pub type virNodeCPUStats = _virNodeCPUStats; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct _virNodeCPUStats { pub field: [::libc::c_char; 80usize], pub value: ::libc::c_ulonglong, } #[test] fn bindgen_test_layout__virNodeCPUStats() { const UNINIT: ::std::mem::MaybeUninit<_virNodeCPUStats> = ::std::mem::MaybeUninit::uninit(); let ptr = UNINIT.as_ptr(); assert_eq!( ::std::mem::size_of::<_virNodeCPUStats>(), 88usize, concat!("Size of: ", stringify!(_virNodeCPUStats)) ); assert_eq!( ::std::mem::align_of::<_virNodeCPUStats>(), 8usize, concat!("Alignment of ", stringify!(_virNodeCPUStats)) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).field) as usize - ptr as usize }, 0usize, concat!( "Offset of field: ", stringify!(_virNodeCPUStats), "::", stringify!(field) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).value) as usize - ptr as usize }, 80usize, concat!( "Offset of field: ", stringify!(_virNodeCPUStats), "::", stringify!(value) ) ); } pub const VIR_NODE_MEMORY_STATS_ALL_CELLS: virNodeGetMemoryStatsAllCells = -1; pub type virNodeGetMemoryStatsAllCells = ::libc::c_int; pub type virNodeMemoryStats = _virNodeMemoryStats; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct _virNodeMemoryStats { pub field: [::libc::c_char; 80usize], pub value: ::libc::c_ulonglong, } #[test] fn bindgen_test_layout__virNodeMemoryStats() { const UNINIT: ::std::mem::MaybeUninit<_virNodeMemoryStats> = ::std::mem::MaybeUninit::uninit(); let ptr = UNINIT.as_ptr(); assert_eq!( ::std::mem::size_of::<_virNodeMemoryStats>(), 88usize, concat!("Size of: ", stringify!(_virNodeMemoryStats)) ); assert_eq!( ::std::mem::align_of::<_virNodeMemoryStats>(), 8usize, concat!("Alignment of ", stringify!(_virNodeMemoryStats)) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).field) as usize - ptr as usize }, 0usize, concat!( "Offset of field: ", stringify!(_virNodeMemoryStats), "::", stringify!(field) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).value) as usize - ptr as usize }, 80usize, concat!( "Offset of field: ", stringify!(_virNodeMemoryStats), "::", stringify!(value) ) ); } extern "C" { pub fn virNodeGetMemoryParameters( conn: virConnectPtr, params: virTypedParameterPtr, nparams: *mut ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virNodeSetMemoryParameters( conn: virConnectPtr, params: virTypedParameterPtr, nparams: ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virNodeGetCPUMap( conn: virConnectPtr, cpumap: *mut *mut ::libc::c_uchar, online: *mut ::libc::c_uint, flags: ::libc::c_uint, ) -> ::libc::c_int; } pub type virNodeInfoPtr = *mut virNodeInfo; pub type virNodeCPUStatsPtr = *mut virNodeCPUStats; pub type virNodeMemoryStatsPtr = *mut virNodeMemoryStats; extern "C" { pub fn virNodeGetSEVInfo( conn: virConnectPtr, params: *mut virTypedParameterPtr, nparams: *mut ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } pub const VIR_CONNECT_RO: virConnectFlags = 1; pub const VIR_CONNECT_NO_ALIASES: virConnectFlags = 2; pub type virConnectFlags = ::libc::c_uint; pub const VIR_CRED_USERNAME: virConnectCredentialType = 1; pub const VIR_CRED_AUTHNAME: virConnectCredentialType = 2; pub const VIR_CRED_LANGUAGE: virConnectCredentialType = 3; pub const VIR_CRED_CNONCE: virConnectCredentialType = 4; pub const VIR_CRED_PASSPHRASE: virConnectCredentialType = 5; pub const VIR_CRED_ECHOPROMPT: virConnectCredentialType = 6; pub const VIR_CRED_NOECHOPROMPT: virConnectCredentialType = 7; pub const VIR_CRED_REALM: virConnectCredentialType = 8; pub const VIR_CRED_EXTERNAL: virConnectCredentialType = 9; pub type virConnectCredentialType = ::libc::c_uint; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct _virConnectCredential { pub type_: ::libc::c_int, pub prompt: *const ::libc::c_char, pub challenge: *const ::libc::c_char, pub defresult: *const ::libc::c_char, pub result: *mut ::libc::c_char, pub resultlen: ::libc::c_uint, } #[test] fn bindgen_test_layout__virConnectCredential() { const UNINIT: ::std::mem::MaybeUninit<_virConnectCredential> = ::std::mem::MaybeUninit::uninit(); let ptr = UNINIT.as_ptr(); assert_eq!( ::std::mem::size_of::<_virConnectCredential>(), 48usize, concat!("Size of: ", stringify!(_virConnectCredential)) ); assert_eq!( ::std::mem::align_of::<_virConnectCredential>(), 8usize, concat!("Alignment of ", stringify!(_virConnectCredential)) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).type_) as usize - ptr as usize }, 0usize, concat!( "Offset of field: ", stringify!(_virConnectCredential), "::", stringify!(type_) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).prompt) as usize - ptr as usize }, 8usize, concat!( "Offset of field: ", stringify!(_virConnectCredential), "::", stringify!(prompt) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).challenge) as usize - ptr as usize }, 16usize, concat!( "Offset of field: ", stringify!(_virConnectCredential), "::", stringify!(challenge) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).defresult) as usize - ptr as usize }, 24usize, concat!( "Offset of field: ", stringify!(_virConnectCredential), "::", stringify!(defresult) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).result) as usize - ptr as usize }, 32usize, concat!( "Offset of field: ", stringify!(_virConnectCredential), "::", stringify!(result) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).resultlen) as usize - ptr as usize }, 40usize, concat!( "Offset of field: ", stringify!(_virConnectCredential), "::", stringify!(resultlen) ) ); } pub type virConnectCredential = _virConnectCredential; pub type virConnectCredentialPtr = *mut virConnectCredential; pub type virConnectAuthCallbackPtr = ::std::option::Option< unsafe extern "C" fn( cred: virConnectCredentialPtr, ncred: ::libc::c_uint, cbdata: *mut ::libc::c_void, ) -> ::libc::c_int, >; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct _virConnectAuth { pub credtype: *mut ::libc::c_int, pub ncredtype: ::libc::c_uint, pub cb: virConnectAuthCallbackPtr, pub cbdata: *mut ::libc::c_void, } #[test] fn bindgen_test_layout__virConnectAuth() { const UNINIT: ::std::mem::MaybeUninit<_virConnectAuth> = ::std::mem::MaybeUninit::uninit(); let ptr = UNINIT.as_ptr(); assert_eq!( ::std::mem::size_of::<_virConnectAuth>(), 32usize, concat!("Size of: ", stringify!(_virConnectAuth)) ); assert_eq!( ::std::mem::align_of::<_virConnectAuth>(), 8usize, concat!("Alignment of ", stringify!(_virConnectAuth)) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).credtype) as usize - ptr as usize }, 0usize, concat!( "Offset of field: ", stringify!(_virConnectAuth), "::", stringify!(credtype) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).ncredtype) as usize - ptr as usize }, 8usize, concat!( "Offset of field: ", stringify!(_virConnectAuth), "::", stringify!(ncredtype) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).cb) as usize - ptr as usize }, 16usize, concat!( "Offset of field: ", stringify!(_virConnectAuth), "::", stringify!(cb) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).cbdata) as usize - ptr as usize }, 24usize, concat!( "Offset of field: ", stringify!(_virConnectAuth), "::", stringify!(cbdata) ) ); } pub type virConnectAuth = _virConnectAuth; pub type virConnectAuthPtr = *mut virConnectAuth; extern "C" { pub static mut virConnectAuthPtrDefault: virConnectAuthPtr; } extern "C" { pub fn virGetVersion( libVer: *mut ::libc::c_ulong, type_: *const ::libc::c_char, typeVer: *mut ::libc::c_ulong, ) -> ::libc::c_int; } extern "C" { pub fn virInitialize() -> ::libc::c_int; } extern "C" { pub fn virConnectOpen(name: *const ::libc::c_char) -> virConnectPtr; } extern "C" { pub fn virConnectOpenReadOnly(name: *const ::libc::c_char) -> virConnectPtr; } extern "C" { pub fn virConnectOpenAuth( name: *const ::libc::c_char, auth: virConnectAuthPtr, flags: ::libc::c_uint, ) -> virConnectPtr; } extern "C" { pub fn virConnectRef(conn: virConnectPtr) -> ::libc::c_int; } extern "C" { pub fn virConnectClose(conn: virConnectPtr) -> ::libc::c_int; } extern "C" { pub fn virConnectSetIdentity( conn: virConnectPtr, params: virTypedParameterPtr, nparams: ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virConnectGetType(conn: virConnectPtr) -> *const ::libc::c_char; } extern "C" { pub fn virConnectGetVersion(conn: virConnectPtr, hvVer: *mut ::libc::c_ulong) -> ::libc::c_int; } extern "C" { pub fn virConnectGetLibVersion( conn: virConnectPtr, libVer: *mut ::libc::c_ulong, ) -> ::libc::c_int; } extern "C" { pub fn virConnectGetHostname(conn: virConnectPtr) -> *mut ::libc::c_char; } extern "C" { pub fn virConnectGetURI(conn: virConnectPtr) -> *mut ::libc::c_char; } extern "C" { pub fn virConnectGetSysinfo(conn: virConnectPtr, flags: ::libc::c_uint) -> *mut ::libc::c_char; } extern "C" { pub fn virConnectSetKeepAlive( conn: virConnectPtr, interval: ::libc::c_int, count: ::libc::c_uint, ) -> ::libc::c_int; } pub type virConnectCloseFunc = ::std::option::Option< unsafe extern "C" fn(conn: virConnectPtr, reason: ::libc::c_int, opaque: *mut ::libc::c_void), >; extern "C" { pub fn virConnectRegisterCloseCallback( conn: virConnectPtr, cb: virConnectCloseFunc, opaque: *mut ::libc::c_void, freecb: virFreeCallback, ) -> ::libc::c_int; } extern "C" { pub fn virConnectUnregisterCloseCallback( conn: virConnectPtr, cb: virConnectCloseFunc, ) -> ::libc::c_int; } extern "C" { pub fn virConnectGetMaxVcpus( conn: virConnectPtr, type_: *const ::libc::c_char, ) -> ::libc::c_int; } extern "C" { pub fn virNodeGetInfo(conn: virConnectPtr, info: virNodeInfoPtr) -> ::libc::c_int; } extern "C" { pub fn virConnectGetCapabilities(conn: virConnectPtr) -> *mut ::libc::c_char; } extern "C" { pub fn virNodeGetCPUStats( conn: virConnectPtr, cpuNum: ::libc::c_int, params: virNodeCPUStatsPtr, nparams: *mut ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virNodeGetMemoryStats( conn: virConnectPtr, cellNum: ::libc::c_int, params: virNodeMemoryStatsPtr, nparams: *mut ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virNodeGetFreeMemory(conn: virConnectPtr) -> ::libc::c_ulonglong; } extern "C" { pub fn virNodeGetSecurityModel( conn: virConnectPtr, secmodel: virSecurityModelPtr, ) -> ::libc::c_int; } extern "C" { pub fn virNodeSuspendForDuration( conn: virConnectPtr, target: ::libc::c_uint, duration: ::libc::c_ulonglong, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virNodeGetCellsFreeMemory( conn: virConnectPtr, freeMems: *mut ::libc::c_ulonglong, startCell: ::libc::c_int, maxCells: ::libc::c_int, ) -> ::libc::c_int; } extern "C" { pub fn virConnectIsEncrypted(conn: virConnectPtr) -> ::libc::c_int; } extern "C" { pub fn virConnectIsSecure(conn: virConnectPtr) -> ::libc::c_int; } extern "C" { pub fn virConnectIsAlive(conn: virConnectPtr) -> ::libc::c_int; } pub const VIR_CPU_COMPARE_ERROR: virCPUCompareResult = -1; pub const VIR_CPU_COMPARE_INCOMPATIBLE: virCPUCompareResult = 0; pub const VIR_CPU_COMPARE_IDENTICAL: virCPUCompareResult = 1; pub const VIR_CPU_COMPARE_SUPERSET: virCPUCompareResult = 2; pub type virCPUCompareResult = ::libc::c_int; pub const VIR_CONNECT_COMPARE_CPU_FAIL_INCOMPATIBLE: virConnectCompareCPUFlags = 1; pub const VIR_CONNECT_COMPARE_CPU_VALIDATE_XML: virConnectCompareCPUFlags = 2; pub type virConnectCompareCPUFlags = ::libc::c_uint; extern "C" { pub fn virConnectCompareCPU( conn: virConnectPtr, xmlDesc: *const ::libc::c_char, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virConnectCompareHypervisorCPU( conn: virConnectPtr, emulator: *const ::libc::c_char, arch: *const ::libc::c_char, machine: *const ::libc::c_char, virttype: *const ::libc::c_char, xmlCPU: *const ::libc::c_char, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virConnectGetCPUModelNames( conn: virConnectPtr, arch: *const ::libc::c_char, models: *mut *mut *mut ::libc::c_char, flags: ::libc::c_uint, ) -> ::libc::c_int; } pub const VIR_CONNECT_BASELINE_CPU_EXPAND_FEATURES: virConnectBaselineCPUFlags = 1; pub const VIR_CONNECT_BASELINE_CPU_MIGRATABLE: virConnectBaselineCPUFlags = 2; pub type virConnectBaselineCPUFlags = ::libc::c_uint; extern "C" { pub fn virConnectBaselineCPU( conn: virConnectPtr, xmlCPUs: *mut *const ::libc::c_char, ncpus: ::libc::c_uint, flags: ::libc::c_uint, ) -> *mut ::libc::c_char; } extern "C" { pub fn virConnectBaselineHypervisorCPU( conn: virConnectPtr, emulator: *const ::libc::c_char, arch: *const ::libc::c_char, machine: *const ::libc::c_char, virttype: *const ::libc::c_char, xmlCPUs: *mut *const ::libc::c_char, ncpus: ::libc::c_uint, flags: ::libc::c_uint, ) -> *mut ::libc::c_char; } extern "C" { pub fn virNodeGetFreePages( conn: virConnectPtr, npages: ::libc::c_uint, pages: *mut ::libc::c_uint, startcell: ::libc::c_int, cellcount: ::libc::c_uint, counts: *mut ::libc::c_ulonglong, flags: ::libc::c_uint, ) -> ::libc::c_int; } pub const VIR_NODE_ALLOC_PAGES_ADD: virNodeAllocPagesFlags = 0; pub const VIR_NODE_ALLOC_PAGES_SET: virNodeAllocPagesFlags = 1; pub type virNodeAllocPagesFlags = ::libc::c_uint; extern "C" { pub fn virNodeAllocPages( conn: virConnectPtr, npages: ::libc::c_uint, pageSizes: *mut ::libc::c_uint, pageCounts: *mut ::libc::c_ulonglong, startCell: ::libc::c_int, cellCount: ::libc::c_uint, flags: ::libc::c_uint, ) -> ::libc::c_int; } #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct _virDomain { _unused: [u8; 0], } pub type virDomain = _virDomain; pub type virDomainPtr = *mut virDomain; pub const VIR_DOMAIN_NOSTATE: virDomainState = 0; pub const VIR_DOMAIN_RUNNING: virDomainState = 1; pub const VIR_DOMAIN_BLOCKED: virDomainState = 2; pub const VIR_DOMAIN_PAUSED: virDomainState = 3; pub const VIR_DOMAIN_SHUTDOWN: virDomainState = 4; pub const VIR_DOMAIN_SHUTOFF: virDomainState = 5; pub const VIR_DOMAIN_CRASHED: virDomainState = 6; pub const VIR_DOMAIN_PMSUSPENDED: virDomainState = 7; pub type virDomainState = ::libc::c_uint; pub const VIR_DOMAIN_NOSTATE_UNKNOWN: virDomainNostateReason = 0; pub type virDomainNostateReason = ::libc::c_uint; pub const VIR_DOMAIN_RUNNING_UNKNOWN: virDomainRunningReason = 0; pub const VIR_DOMAIN_RUNNING_BOOTED: virDomainRunningReason = 1; pub const VIR_DOMAIN_RUNNING_MIGRATED: virDomainRunningReason = 2; pub const VIR_DOMAIN_RUNNING_RESTORED: virDomainRunningReason = 3; pub const VIR_DOMAIN_RUNNING_FROM_SNAPSHOT: virDomainRunningReason = 4; pub const VIR_DOMAIN_RUNNING_UNPAUSED: virDomainRunningReason = 5; pub const VIR_DOMAIN_RUNNING_MIGRATION_CANCELED: virDomainRunningReason = 6; pub const VIR_DOMAIN_RUNNING_SAVE_CANCELED: virDomainRunningReason = 7; pub const VIR_DOMAIN_RUNNING_WAKEUP: virDomainRunningReason = 8; pub const VIR_DOMAIN_RUNNING_CRASHED: virDomainRunningReason = 9; pub const VIR_DOMAIN_RUNNING_POSTCOPY: virDomainRunningReason = 10; pub const VIR_DOMAIN_RUNNING_POSTCOPY_FAILED: virDomainRunningReason = 11; pub type virDomainRunningReason = ::libc::c_uint; pub const VIR_DOMAIN_BLOCKED_UNKNOWN: virDomainBlockedReason = 0; pub type virDomainBlockedReason = ::libc::c_uint; pub const VIR_DOMAIN_PAUSED_UNKNOWN: virDomainPausedReason = 0; pub const VIR_DOMAIN_PAUSED_USER: virDomainPausedReason = 1; pub const VIR_DOMAIN_PAUSED_MIGRATION: virDomainPausedReason = 2; pub const VIR_DOMAIN_PAUSED_SAVE: virDomainPausedReason = 3; pub const VIR_DOMAIN_PAUSED_DUMP: virDomainPausedReason = 4; pub const VIR_DOMAIN_PAUSED_IOERROR: virDomainPausedReason = 5; pub const VIR_DOMAIN_PAUSED_WATCHDOG: virDomainPausedReason = 6; pub const VIR_DOMAIN_PAUSED_FROM_SNAPSHOT: virDomainPausedReason = 7; pub const VIR_DOMAIN_PAUSED_SHUTTING_DOWN: virDomainPausedReason = 8; pub const VIR_DOMAIN_PAUSED_SNAPSHOT: virDomainPausedReason = 9; pub const VIR_DOMAIN_PAUSED_CRASHED: virDomainPausedReason = 10; pub const VIR_DOMAIN_PAUSED_STARTING_UP: virDomainPausedReason = 11; pub const VIR_DOMAIN_PAUSED_POSTCOPY: virDomainPausedReason = 12; pub const VIR_DOMAIN_PAUSED_POSTCOPY_FAILED: virDomainPausedReason = 13; pub const VIR_DOMAIN_PAUSED_API_ERROR: virDomainPausedReason = 14; pub type virDomainPausedReason = ::libc::c_uint; pub const VIR_DOMAIN_SHUTDOWN_UNKNOWN: virDomainShutdownReason = 0; pub const VIR_DOMAIN_SHUTDOWN_USER: virDomainShutdownReason = 1; pub type virDomainShutdownReason = ::libc::c_uint; pub const VIR_DOMAIN_SHUTOFF_UNKNOWN: virDomainShutoffReason = 0; pub const VIR_DOMAIN_SHUTOFF_SHUTDOWN: virDomainShutoffReason = 1; pub const VIR_DOMAIN_SHUTOFF_DESTROYED: virDomainShutoffReason = 2; pub const VIR_DOMAIN_SHUTOFF_CRASHED: virDomainShutoffReason = 3; pub const VIR_DOMAIN_SHUTOFF_MIGRATED: virDomainShutoffReason = 4; pub const VIR_DOMAIN_SHUTOFF_SAVED: virDomainShutoffReason = 5; pub const VIR_DOMAIN_SHUTOFF_FAILED: virDomainShutoffReason = 6; pub const VIR_DOMAIN_SHUTOFF_FROM_SNAPSHOT: virDomainShutoffReason = 7; pub const VIR_DOMAIN_SHUTOFF_DAEMON: virDomainShutoffReason = 8; pub type virDomainShutoffReason = ::libc::c_uint; pub const VIR_DOMAIN_CRASHED_UNKNOWN: virDomainCrashedReason = 0; pub const VIR_DOMAIN_CRASHED_PANICKED: virDomainCrashedReason = 1; pub type virDomainCrashedReason = ::libc::c_uint; pub const VIR_DOMAIN_PMSUSPENDED_UNKNOWN: virDomainPMSuspendedReason = 0; pub type virDomainPMSuspendedReason = ::libc::c_uint; pub const VIR_DOMAIN_PMSUSPENDED_DISK_UNKNOWN: virDomainPMSuspendedDiskReason = 0; pub type virDomainPMSuspendedDiskReason = ::libc::c_uint; pub const VIR_DOMAIN_CONTROL_OK: virDomainControlState = 0; pub const VIR_DOMAIN_CONTROL_JOB: virDomainControlState = 1; pub const VIR_DOMAIN_CONTROL_OCCUPIED: virDomainControlState = 2; pub const VIR_DOMAIN_CONTROL_ERROR: virDomainControlState = 3; pub type virDomainControlState = ::libc::c_uint; pub const VIR_DOMAIN_CONTROL_ERROR_REASON_NONE: virDomainControlErrorReason = 0; pub const VIR_DOMAIN_CONTROL_ERROR_REASON_UNKNOWN: virDomainControlErrorReason = 1; pub const VIR_DOMAIN_CONTROL_ERROR_REASON_MONITOR: virDomainControlErrorReason = 2; pub const VIR_DOMAIN_CONTROL_ERROR_REASON_INTERNAL: virDomainControlErrorReason = 3; pub type virDomainControlErrorReason = ::libc::c_uint; pub type virDomainControlInfo = _virDomainControlInfo; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct _virDomainControlInfo { pub state: ::libc::c_uint, pub details: ::libc::c_uint, pub stateTime: ::libc::c_ulonglong, } #[test] fn bindgen_test_layout__virDomainControlInfo() { const UNINIT: ::std::mem::MaybeUninit<_virDomainControlInfo> = ::std::mem::MaybeUninit::uninit(); let ptr = UNINIT.as_ptr(); assert_eq!( ::std::mem::size_of::<_virDomainControlInfo>(), 16usize, concat!("Size of: ", stringify!(_virDomainControlInfo)) ); assert_eq!( ::std::mem::align_of::<_virDomainControlInfo>(), 8usize, concat!("Alignment of ", stringify!(_virDomainControlInfo)) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).state) as usize - ptr as usize }, 0usize, concat!( "Offset of field: ", stringify!(_virDomainControlInfo), "::", stringify!(state) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).details) as usize - ptr as usize }, 4usize, concat!( "Offset of field: ", stringify!(_virDomainControlInfo), "::", stringify!(details) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).stateTime) as usize - ptr as usize }, 8usize, concat!( "Offset of field: ", stringify!(_virDomainControlInfo), "::", stringify!(stateTime) ) ); } pub type virDomainControlInfoPtr = *mut virDomainControlInfo; pub const VIR_DOMAIN_AFFECT_CURRENT: virDomainModificationImpact = 0; pub const VIR_DOMAIN_AFFECT_LIVE: virDomainModificationImpact = 1; pub const VIR_DOMAIN_AFFECT_CONFIG: virDomainModificationImpact = 2; pub type virDomainModificationImpact = ::libc::c_uint; pub type virDomainInfo = _virDomainInfo; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct _virDomainInfo { pub state: ::libc::c_uchar, pub maxMem: ::libc::c_ulong, pub memory: ::libc::c_ulong, pub nrVirtCpu: ::libc::c_ushort, pub cpuTime: ::libc::c_ulonglong, } #[test] fn bindgen_test_layout__virDomainInfo() { const UNINIT: ::std::mem::MaybeUninit<_virDomainInfo> = ::std::mem::MaybeUninit::uninit(); let ptr = UNINIT.as_ptr(); assert_eq!( ::std::mem::size_of::<_virDomainInfo>(), 40usize, concat!("Size of: ", stringify!(_virDomainInfo)) ); assert_eq!( ::std::mem::align_of::<_virDomainInfo>(), 8usize, concat!("Alignment of ", stringify!(_virDomainInfo)) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).state) as usize - ptr as usize }, 0usize, concat!( "Offset of field: ", stringify!(_virDomainInfo), "::", stringify!(state) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).maxMem) as usize - ptr as usize }, 8usize, concat!( "Offset of field: ", stringify!(_virDomainInfo), "::", stringify!(maxMem) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).memory) as usize - ptr as usize }, 16usize, concat!( "Offset of field: ", stringify!(_virDomainInfo), "::", stringify!(memory) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).nrVirtCpu) as usize - ptr as usize }, 24usize, concat!( "Offset of field: ", stringify!(_virDomainInfo), "::", stringify!(nrVirtCpu) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).cpuTime) as usize - ptr as usize }, 32usize, concat!( "Offset of field: ", stringify!(_virDomainInfo), "::", stringify!(cpuTime) ) ); } pub type virDomainInfoPtr = *mut virDomainInfo; pub const VIR_DOMAIN_NONE: virDomainCreateFlags = 0; pub const VIR_DOMAIN_START_PAUSED: virDomainCreateFlags = 1; pub const VIR_DOMAIN_START_AUTODESTROY: virDomainCreateFlags = 2; pub const VIR_DOMAIN_START_BYPASS_CACHE: virDomainCreateFlags = 4; pub const VIR_DOMAIN_START_FORCE_BOOT: virDomainCreateFlags = 8; pub const VIR_DOMAIN_START_VALIDATE: virDomainCreateFlags = 16; pub const VIR_DOMAIN_START_RESET_NVRAM: virDomainCreateFlags = 32; pub type virDomainCreateFlags = ::libc::c_uint; extern "C" { pub fn virDomainGetSchedulerParameters( domain: virDomainPtr, params: virTypedParameterPtr, nparams: *mut ::libc::c_int, ) -> ::libc::c_int; } extern "C" { pub fn virDomainGetSchedulerParametersFlags( domain: virDomainPtr, params: virTypedParameterPtr, nparams: *mut ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainSetSchedulerParameters( domain: virDomainPtr, params: virTypedParameterPtr, nparams: ::libc::c_int, ) -> ::libc::c_int; } extern "C" { pub fn virDomainSetSchedulerParametersFlags( domain: virDomainPtr, params: virTypedParameterPtr, nparams: ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } pub type virDomainBlockStatsStruct = _virDomainBlockStats; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct _virDomainBlockStats { pub rd_req: ::libc::c_longlong, pub rd_bytes: ::libc::c_longlong, pub wr_req: ::libc::c_longlong, pub wr_bytes: ::libc::c_longlong, pub errs: ::libc::c_longlong, } #[test] fn bindgen_test_layout__virDomainBlockStats() { const UNINIT: ::std::mem::MaybeUninit<_virDomainBlockStats> = ::std::mem::MaybeUninit::uninit(); let ptr = UNINIT.as_ptr(); assert_eq!( ::std::mem::size_of::<_virDomainBlockStats>(), 40usize, concat!("Size of: ", stringify!(_virDomainBlockStats)) ); assert_eq!( ::std::mem::align_of::<_virDomainBlockStats>(), 8usize, concat!("Alignment of ", stringify!(_virDomainBlockStats)) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).rd_req) as usize - ptr as usize }, 0usize, concat!( "Offset of field: ", stringify!(_virDomainBlockStats), "::", stringify!(rd_req) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).rd_bytes) as usize - ptr as usize }, 8usize, concat!( "Offset of field: ", stringify!(_virDomainBlockStats), "::", stringify!(rd_bytes) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).wr_req) as usize - ptr as usize }, 16usize, concat!( "Offset of field: ", stringify!(_virDomainBlockStats), "::", stringify!(wr_req) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).wr_bytes) as usize - ptr as usize }, 24usize, concat!( "Offset of field: ", stringify!(_virDomainBlockStats), "::", stringify!(wr_bytes) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).errs) as usize - ptr as usize }, 32usize, concat!( "Offset of field: ", stringify!(_virDomainBlockStats), "::", stringify!(errs) ) ); } pub type virDomainBlockStatsPtr = *mut virDomainBlockStatsStruct; pub type virDomainInterfaceStatsStruct = _virDomainInterfaceStats; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct _virDomainInterfaceStats { pub rx_bytes: ::libc::c_longlong, pub rx_packets: ::libc::c_longlong, pub rx_errs: ::libc::c_longlong, pub rx_drop: ::libc::c_longlong, pub tx_bytes: ::libc::c_longlong, pub tx_packets: ::libc::c_longlong, pub tx_errs: ::libc::c_longlong, pub tx_drop: ::libc::c_longlong, } #[test] fn bindgen_test_layout__virDomainInterfaceStats() { const UNINIT: ::std::mem::MaybeUninit<_virDomainInterfaceStats> = ::std::mem::MaybeUninit::uninit(); let ptr = UNINIT.as_ptr(); assert_eq!( ::std::mem::size_of::<_virDomainInterfaceStats>(), 64usize, concat!("Size of: ", stringify!(_virDomainInterfaceStats)) ); assert_eq!( ::std::mem::align_of::<_virDomainInterfaceStats>(), 8usize, concat!("Alignment of ", stringify!(_virDomainInterfaceStats)) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).rx_bytes) as usize - ptr as usize }, 0usize, concat!( "Offset of field: ", stringify!(_virDomainInterfaceStats), "::", stringify!(rx_bytes) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).rx_packets) as usize - ptr as usize }, 8usize, concat!( "Offset of field: ", stringify!(_virDomainInterfaceStats), "::", stringify!(rx_packets) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).rx_errs) as usize - ptr as usize }, 16usize, concat!( "Offset of field: ", stringify!(_virDomainInterfaceStats), "::", stringify!(rx_errs) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).rx_drop) as usize - ptr as usize }, 24usize, concat!( "Offset of field: ", stringify!(_virDomainInterfaceStats), "::", stringify!(rx_drop) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).tx_bytes) as usize - ptr as usize }, 32usize, concat!( "Offset of field: ", stringify!(_virDomainInterfaceStats), "::", stringify!(tx_bytes) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).tx_packets) as usize - ptr as usize }, 40usize, concat!( "Offset of field: ", stringify!(_virDomainInterfaceStats), "::", stringify!(tx_packets) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).tx_errs) as usize - ptr as usize }, 48usize, concat!( "Offset of field: ", stringify!(_virDomainInterfaceStats), "::", stringify!(tx_errs) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).tx_drop) as usize - ptr as usize }, 56usize, concat!( "Offset of field: ", stringify!(_virDomainInterfaceStats), "::", stringify!(tx_drop) ) ); } pub type virDomainInterfaceStatsPtr = *mut virDomainInterfaceStatsStruct; pub const VIR_DOMAIN_MEMORY_STAT_SWAP_IN: virDomainMemoryStatTags = 0; pub const VIR_DOMAIN_MEMORY_STAT_SWAP_OUT: virDomainMemoryStatTags = 1; pub const VIR_DOMAIN_MEMORY_STAT_MAJOR_FAULT: virDomainMemoryStatTags = 2; pub const VIR_DOMAIN_MEMORY_STAT_MINOR_FAULT: virDomainMemoryStatTags = 3; pub const VIR_DOMAIN_MEMORY_STAT_UNUSED: virDomainMemoryStatTags = 4; pub const VIR_DOMAIN_MEMORY_STAT_AVAILABLE: virDomainMemoryStatTags = 5; pub const VIR_DOMAIN_MEMORY_STAT_ACTUAL_BALLOON: virDomainMemoryStatTags = 6; pub const VIR_DOMAIN_MEMORY_STAT_RSS: virDomainMemoryStatTags = 7; pub const VIR_DOMAIN_MEMORY_STAT_USABLE: virDomainMemoryStatTags = 8; pub const VIR_DOMAIN_MEMORY_STAT_LAST_UPDATE: virDomainMemoryStatTags = 9; pub const VIR_DOMAIN_MEMORY_STAT_DISK_CACHES: virDomainMemoryStatTags = 10; pub const VIR_DOMAIN_MEMORY_STAT_HUGETLB_PGALLOC: virDomainMemoryStatTags = 11; pub const VIR_DOMAIN_MEMORY_STAT_HUGETLB_PGFAIL: virDomainMemoryStatTags = 12; pub const VIR_DOMAIN_MEMORY_STAT_NR: virDomainMemoryStatTags = 13; pub type virDomainMemoryStatTags = ::libc::c_uint; pub type virDomainMemoryStatStruct = _virDomainMemoryStat; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct _virDomainMemoryStat { pub tag: ::libc::c_int, pub val: ::libc::c_ulonglong, } #[test] fn bindgen_test_layout__virDomainMemoryStat() { const UNINIT: ::std::mem::MaybeUninit<_virDomainMemoryStat> = ::std::mem::MaybeUninit::uninit(); let ptr = UNINIT.as_ptr(); assert_eq!( ::std::mem::size_of::<_virDomainMemoryStat>(), 16usize, concat!("Size of: ", stringify!(_virDomainMemoryStat)) ); assert_eq!( ::std::mem::align_of::<_virDomainMemoryStat>(), 8usize, concat!("Alignment of ", stringify!(_virDomainMemoryStat)) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).tag) as usize - ptr as usize }, 0usize, concat!( "Offset of field: ", stringify!(_virDomainMemoryStat), "::", stringify!(tag) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).val) as usize - ptr as usize }, 8usize, concat!( "Offset of field: ", stringify!(_virDomainMemoryStat), "::", stringify!(val) ) ); } pub type virDomainMemoryStatPtr = *mut virDomainMemoryStatStruct; pub const VIR_DUMP_CRASH: virDomainCoreDumpFlags = 1; pub const VIR_DUMP_LIVE: virDomainCoreDumpFlags = 2; pub const VIR_DUMP_BYPASS_CACHE: virDomainCoreDumpFlags = 4; pub const VIR_DUMP_RESET: virDomainCoreDumpFlags = 8; pub const VIR_DUMP_MEMORY_ONLY: virDomainCoreDumpFlags = 16; pub type virDomainCoreDumpFlags = ::libc::c_uint; pub const VIR_DOMAIN_CORE_DUMP_FORMAT_RAW: virDomainCoreDumpFormat = 0; pub const VIR_DOMAIN_CORE_DUMP_FORMAT_KDUMP_ZLIB: virDomainCoreDumpFormat = 1; pub const VIR_DOMAIN_CORE_DUMP_FORMAT_KDUMP_LZO: virDomainCoreDumpFormat = 2; pub const VIR_DOMAIN_CORE_DUMP_FORMAT_KDUMP_SNAPPY: virDomainCoreDumpFormat = 3; pub const VIR_DOMAIN_CORE_DUMP_FORMAT_WIN_DMP: virDomainCoreDumpFormat = 4; pub type virDomainCoreDumpFormat = ::libc::c_uint; pub const VIR_MIGRATE_LIVE: virDomainMigrateFlags = 1; pub const VIR_MIGRATE_PEER2PEER: virDomainMigrateFlags = 2; pub const VIR_MIGRATE_TUNNELLED: virDomainMigrateFlags = 4; pub const VIR_MIGRATE_PERSIST_DEST: virDomainMigrateFlags = 8; pub const VIR_MIGRATE_UNDEFINE_SOURCE: virDomainMigrateFlags = 16; pub const VIR_MIGRATE_PAUSED: virDomainMigrateFlags = 32; pub const VIR_MIGRATE_NON_SHARED_DISK: virDomainMigrateFlags = 64; pub const VIR_MIGRATE_NON_SHARED_INC: virDomainMigrateFlags = 128; pub const VIR_MIGRATE_CHANGE_PROTECTION: virDomainMigrateFlags = 256; pub const VIR_MIGRATE_UNSAFE: virDomainMigrateFlags = 512; pub const VIR_MIGRATE_OFFLINE: virDomainMigrateFlags = 1024; pub const VIR_MIGRATE_COMPRESSED: virDomainMigrateFlags = 2048; pub const VIR_MIGRATE_ABORT_ON_ERROR: virDomainMigrateFlags = 4096; pub const VIR_MIGRATE_AUTO_CONVERGE: virDomainMigrateFlags = 8192; pub const VIR_MIGRATE_RDMA_PIN_ALL: virDomainMigrateFlags = 16384; pub const VIR_MIGRATE_POSTCOPY: virDomainMigrateFlags = 32768; pub const VIR_MIGRATE_TLS: virDomainMigrateFlags = 65536; pub const VIR_MIGRATE_PARALLEL: virDomainMigrateFlags = 131072; pub const VIR_MIGRATE_NON_SHARED_SYNCHRONOUS_WRITES: virDomainMigrateFlags = 262144; pub const VIR_MIGRATE_POSTCOPY_RESUME: virDomainMigrateFlags = 524288; pub const VIR_MIGRATE_ZEROCOPY: virDomainMigrateFlags = 1048576; pub type virDomainMigrateFlags = ::libc::c_uint; extern "C" { pub fn virDomainMigrate( domain: virDomainPtr, dconn: virConnectPtr, flags: ::libc::c_ulong, dname: *const ::libc::c_char, uri: *const ::libc::c_char, bandwidth: ::libc::c_ulong, ) -> virDomainPtr; } extern "C" { pub fn virDomainMigrate2( domain: virDomainPtr, dconn: virConnectPtr, dxml: *const ::libc::c_char, flags: ::libc::c_ulong, dname: *const ::libc::c_char, uri: *const ::libc::c_char, bandwidth: ::libc::c_ulong, ) -> virDomainPtr; } extern "C" { pub fn virDomainMigrate3( domain: virDomainPtr, dconn: virConnectPtr, params: virTypedParameterPtr, nparams: ::libc::c_uint, flags: ::libc::c_uint, ) -> virDomainPtr; } extern "C" { pub fn virDomainMigrateToURI( domain: virDomainPtr, duri: *const ::libc::c_char, flags: ::libc::c_ulong, dname: *const ::libc::c_char, bandwidth: ::libc::c_ulong, ) -> ::libc::c_int; } extern "C" { pub fn virDomainMigrateToURI2( domain: virDomainPtr, dconnuri: *const ::libc::c_char, miguri: *const ::libc::c_char, dxml: *const ::libc::c_char, flags: ::libc::c_ulong, dname: *const ::libc::c_char, bandwidth: ::libc::c_ulong, ) -> ::libc::c_int; } extern "C" { pub fn virDomainMigrateToURI3( domain: virDomainPtr, dconnuri: *const ::libc::c_char, params: virTypedParameterPtr, nparams: ::libc::c_uint, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainMigrateGetMaxDowntime( domain: virDomainPtr, downtime: *mut ::libc::c_ulonglong, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainMigrateSetMaxDowntime( domain: virDomainPtr, downtime: ::libc::c_ulonglong, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainMigrateGetCompressionCache( domain: virDomainPtr, cacheSize: *mut ::libc::c_ulonglong, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainMigrateSetCompressionCache( domain: virDomainPtr, cacheSize: ::libc::c_ulonglong, flags: ::libc::c_uint, ) -> ::libc::c_int; } pub const VIR_DOMAIN_MIGRATE_MAX_SPEED_POSTCOPY: virDomainMigrateMaxSpeedFlags = 1; pub type virDomainMigrateMaxSpeedFlags = ::libc::c_uint; extern "C" { pub fn virDomainMigrateSetMaxSpeed( domain: virDomainPtr, bandwidth: ::libc::c_ulong, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainMigrateGetMaxSpeed( domain: virDomainPtr, bandwidth: *mut ::libc::c_ulong, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainMigrateStartPostCopy( domain: virDomainPtr, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virConnectGetDomainCapabilities( conn: virConnectPtr, emulatorbin: *const ::libc::c_char, arch: *const ::libc::c_char, machine: *const ::libc::c_char, virttype: *const ::libc::c_char, flags: ::libc::c_uint, ) -> *mut ::libc::c_char; } extern "C" { pub fn virConnectListDomains( conn: virConnectPtr, ids: *mut ::libc::c_int, maxids: ::libc::c_int, ) -> ::libc::c_int; } extern "C" { pub fn virConnectNumOfDomains(conn: virConnectPtr) -> ::libc::c_int; } extern "C" { pub fn virDomainGetConnect(domain: virDomainPtr) -> virConnectPtr; } extern "C" { pub fn virDomainCreateXML( conn: virConnectPtr, xmlDesc: *const ::libc::c_char, flags: ::libc::c_uint, ) -> virDomainPtr; } extern "C" { pub fn virDomainCreateXMLWithFiles( conn: virConnectPtr, xmlDesc: *const ::libc::c_char, nfiles: ::libc::c_uint, files: *mut ::libc::c_int, flags: ::libc::c_uint, ) -> virDomainPtr; } extern "C" { pub fn virDomainLookupByName(conn: virConnectPtr, name: *const ::libc::c_char) -> virDomainPtr; } extern "C" { pub fn virDomainLookupByID(conn: virConnectPtr, id: ::libc::c_int) -> virDomainPtr; } extern "C" { pub fn virDomainLookupByUUID(conn: virConnectPtr, uuid: *const ::libc::c_uchar) -> virDomainPtr; } extern "C" { pub fn virDomainLookupByUUIDString( conn: virConnectPtr, uuid: *const ::libc::c_char, ) -> virDomainPtr; } pub const VIR_DOMAIN_SHUTDOWN_DEFAULT: virDomainShutdownFlagValues = 0; pub const VIR_DOMAIN_SHUTDOWN_ACPI_POWER_BTN: virDomainShutdownFlagValues = 1; pub const VIR_DOMAIN_SHUTDOWN_GUEST_AGENT: virDomainShutdownFlagValues = 2; pub const VIR_DOMAIN_SHUTDOWN_INITCTL: virDomainShutdownFlagValues = 4; pub const VIR_DOMAIN_SHUTDOWN_SIGNAL: virDomainShutdownFlagValues = 8; pub const VIR_DOMAIN_SHUTDOWN_PARAVIRT: virDomainShutdownFlagValues = 16; pub type virDomainShutdownFlagValues = ::libc::c_uint; extern "C" { pub fn virDomainShutdown(domain: virDomainPtr) -> ::libc::c_int; } extern "C" { pub fn virDomainShutdownFlags(domain: virDomainPtr, flags: ::libc::c_uint) -> ::libc::c_int; } pub const VIR_DOMAIN_REBOOT_DEFAULT: virDomainRebootFlagValues = 0; pub const VIR_DOMAIN_REBOOT_ACPI_POWER_BTN: virDomainRebootFlagValues = 1; pub const VIR_DOMAIN_REBOOT_GUEST_AGENT: virDomainRebootFlagValues = 2; pub const VIR_DOMAIN_REBOOT_INITCTL: virDomainRebootFlagValues = 4; pub const VIR_DOMAIN_REBOOT_SIGNAL: virDomainRebootFlagValues = 8; pub const VIR_DOMAIN_REBOOT_PARAVIRT: virDomainRebootFlagValues = 16; pub type virDomainRebootFlagValues = ::libc::c_uint; extern "C" { pub fn virDomainReboot(domain: virDomainPtr, flags: ::libc::c_uint) -> ::libc::c_int; } extern "C" { pub fn virDomainReset(domain: virDomainPtr, flags: ::libc::c_uint) -> ::libc::c_int; } extern "C" { pub fn virDomainDestroy(domain: virDomainPtr) -> ::libc::c_int; } pub const VIR_DOMAIN_DESTROY_DEFAULT: virDomainDestroyFlagsValues = 0; pub const VIR_DOMAIN_DESTROY_GRACEFUL: virDomainDestroyFlagsValues = 1; pub const VIR_DOMAIN_DESTROY_REMOVE_LOGS: virDomainDestroyFlagsValues = 2; pub type virDomainDestroyFlagsValues = ::libc::c_uint; extern "C" { pub fn virDomainDestroyFlags(domain: virDomainPtr, flags: ::libc::c_uint) -> ::libc::c_int; } extern "C" { pub fn virDomainRef(domain: virDomainPtr) -> ::libc::c_int; } extern "C" { pub fn virDomainFree(domain: virDomainPtr) -> ::libc::c_int; } extern "C" { pub fn virDomainSuspend(domain: virDomainPtr) -> ::libc::c_int; } extern "C" { pub fn virDomainResume(domain: virDomainPtr) -> ::libc::c_int; } extern "C" { pub fn virDomainPMSuspendForDuration( domain: virDomainPtr, target: ::libc::c_uint, duration: ::libc::c_ulonglong, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainPMWakeup(domain: virDomainPtr, flags: ::libc::c_uint) -> ::libc::c_int; } pub const VIR_DOMAIN_SAVE_BYPASS_CACHE: virDomainSaveRestoreFlags = 1; pub const VIR_DOMAIN_SAVE_RUNNING: virDomainSaveRestoreFlags = 2; pub const VIR_DOMAIN_SAVE_PAUSED: virDomainSaveRestoreFlags = 4; pub const VIR_DOMAIN_SAVE_RESET_NVRAM: virDomainSaveRestoreFlags = 8; pub type virDomainSaveRestoreFlags = ::libc::c_uint; extern "C" { pub fn virDomainSave(domain: virDomainPtr, to: *const ::libc::c_char) -> ::libc::c_int; } extern "C" { pub fn virDomainSaveFlags( domain: virDomainPtr, to: *const ::libc::c_char, dxml: *const ::libc::c_char, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainSaveParams( domain: virDomainPtr, params: virTypedParameterPtr, nparams: ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainRestore(conn: virConnectPtr, from: *const ::libc::c_char) -> ::libc::c_int; } extern "C" { pub fn virDomainRestoreFlags( conn: virConnectPtr, from: *const ::libc::c_char, dxml: *const ::libc::c_char, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainRestoreParams( conn: virConnectPtr, params: virTypedParameterPtr, nparams: ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainSaveImageGetXMLDesc( conn: virConnectPtr, file: *const ::libc::c_char, flags: ::libc::c_uint, ) -> *mut ::libc::c_char; } extern "C" { pub fn virDomainSaveImageDefineXML( conn: virConnectPtr, file: *const ::libc::c_char, dxml: *const ::libc::c_char, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainManagedSave(dom: virDomainPtr, flags: ::libc::c_uint) -> ::libc::c_int; } extern "C" { pub fn virDomainHasManagedSaveImage(dom: virDomainPtr, flags: ::libc::c_uint) -> ::libc::c_int; } extern "C" { pub fn virDomainManagedSaveRemove(dom: virDomainPtr, flags: ::libc::c_uint) -> ::libc::c_int; } extern "C" { pub fn virDomainManagedSaveGetXMLDesc( domain: virDomainPtr, flags: ::libc::c_uint, ) -> *mut ::libc::c_char; } extern "C" { pub fn virDomainManagedSaveDefineXML( domain: virDomainPtr, dxml: *const ::libc::c_char, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainCoreDump( domain: virDomainPtr, to: *const ::libc::c_char, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainCoreDumpWithFormat( domain: virDomainPtr, to: *const ::libc::c_char, dumpformat: ::libc::c_uint, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainScreenshot( domain: virDomainPtr, stream: virStreamPtr, screen: ::libc::c_uint, flags: ::libc::c_uint, ) -> *mut ::libc::c_char; } extern "C" { pub fn virDomainGetInfo(domain: virDomainPtr, info: virDomainInfoPtr) -> ::libc::c_int; } extern "C" { pub fn virDomainGetState( domain: virDomainPtr, state: *mut ::libc::c_int, reason: *mut ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainGetCPUStats( domain: virDomainPtr, params: virTypedParameterPtr, nparams: ::libc::c_uint, start_cpu: ::libc::c_int, ncpus: ::libc::c_uint, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainGetControlInfo( domain: virDomainPtr, info: virDomainControlInfoPtr, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainGetSchedulerType( domain: virDomainPtr, nparams: *mut ::libc::c_int, ) -> *mut ::libc::c_char; } extern "C" { pub fn virDomainSetBlkioParameters( domain: virDomainPtr, params: virTypedParameterPtr, nparams: ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainGetBlkioParameters( domain: virDomainPtr, params: virTypedParameterPtr, nparams: *mut ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainSetMemoryParameters( domain: virDomainPtr, params: virTypedParameterPtr, nparams: ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainGetMemoryParameters( domain: virDomainPtr, params: virTypedParameterPtr, nparams: *mut ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } pub const VIR_DOMAIN_MEM_CURRENT: virDomainMemoryModFlags = 0; pub const VIR_DOMAIN_MEM_LIVE: virDomainMemoryModFlags = 1; pub const VIR_DOMAIN_MEM_CONFIG: virDomainMemoryModFlags = 2; pub const VIR_DOMAIN_MEM_MAXIMUM: virDomainMemoryModFlags = 4; pub type virDomainMemoryModFlags = ::libc::c_uint; pub const VIR_DOMAIN_NUMATUNE_MEM_STRICT: virDomainNumatuneMemMode = 0; pub const VIR_DOMAIN_NUMATUNE_MEM_PREFERRED: virDomainNumatuneMemMode = 1; pub const VIR_DOMAIN_NUMATUNE_MEM_INTERLEAVE: virDomainNumatuneMemMode = 2; pub const VIR_DOMAIN_NUMATUNE_MEM_RESTRICTIVE: virDomainNumatuneMemMode = 3; pub type virDomainNumatuneMemMode = ::libc::c_uint; extern "C" { pub fn virDomainSetNumaParameters( domain: virDomainPtr, params: virTypedParameterPtr, nparams: ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainGetNumaParameters( domain: virDomainPtr, params: virTypedParameterPtr, nparams: *mut ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainGetName(domain: virDomainPtr) -> *const ::libc::c_char; } extern "C" { pub fn virDomainGetID(domain: virDomainPtr) -> ::libc::c_uint; } extern "C" { pub fn virDomainGetUUID(domain: virDomainPtr, uuid: *mut ::libc::c_uchar) -> ::libc::c_int; } extern "C" { pub fn virDomainGetUUIDString(domain: virDomainPtr, buf: *mut ::libc::c_char) -> ::libc::c_int; } extern "C" { pub fn virDomainGetOSType(domain: virDomainPtr) -> *mut ::libc::c_char; } extern "C" { pub fn virDomainGetMaxMemory(domain: virDomainPtr) -> ::libc::c_ulong; } extern "C" { pub fn virDomainSetMaxMemory(domain: virDomainPtr, memory: ::libc::c_ulong) -> ::libc::c_int; } extern "C" { pub fn virDomainSetMemory(domain: virDomainPtr, memory: ::libc::c_ulong) -> ::libc::c_int; } extern "C" { pub fn virDomainSetMemoryFlags( domain: virDomainPtr, memory: ::libc::c_ulong, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainSetMemoryStatsPeriod( domain: virDomainPtr, period: ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainGetMaxVcpus(domain: virDomainPtr) -> ::libc::c_int; } extern "C" { pub fn virDomainGetSecurityLabel( domain: virDomainPtr, seclabel: virSecurityLabelPtr, ) -> ::libc::c_int; } pub const VIR_DOMAIN_GET_HOSTNAME_LEASE: virDomainGetHostnameFlags = 1; pub const VIR_DOMAIN_GET_HOSTNAME_AGENT: virDomainGetHostnameFlags = 2; pub type virDomainGetHostnameFlags = ::libc::c_uint; extern "C" { pub fn virDomainGetHostname(domain: virDomainPtr, flags: ::libc::c_uint) -> *mut ::libc::c_char; } extern "C" { pub fn virDomainGetSecurityLabelList( domain: virDomainPtr, seclabels: *mut virSecurityLabelPtr, ) -> ::libc::c_int; } pub const VIR_DOMAIN_METADATA_DESCRIPTION: virDomainMetadataType = 0; pub const VIR_DOMAIN_METADATA_TITLE: virDomainMetadataType = 1; pub const VIR_DOMAIN_METADATA_ELEMENT: virDomainMetadataType = 2; pub type virDomainMetadataType = ::libc::c_uint; extern "C" { pub fn virDomainSetMetadata( domain: virDomainPtr, type_: ::libc::c_int, metadata: *const ::libc::c_char, key: *const ::libc::c_char, uri: *const ::libc::c_char, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainGetMetadata( domain: virDomainPtr, type_: ::libc::c_int, uri: *const ::libc::c_char, flags: ::libc::c_uint, ) -> *mut ::libc::c_char; } pub const VIR_DOMAIN_XML_SECURE: virDomainXMLFlags = 1; pub const VIR_DOMAIN_XML_INACTIVE: virDomainXMLFlags = 2; pub const VIR_DOMAIN_XML_UPDATE_CPU: virDomainXMLFlags = 4; pub const VIR_DOMAIN_XML_MIGRATABLE: virDomainXMLFlags = 8; pub type virDomainXMLFlags = ::libc::c_uint; pub const VIR_DOMAIN_SAVE_IMAGE_XML_SECURE: virDomainSaveImageXMLFlags = 1; pub type virDomainSaveImageXMLFlags = ::libc::c_uint; extern "C" { pub fn virDomainGetXMLDesc(domain: virDomainPtr, flags: ::libc::c_uint) -> *mut ::libc::c_char; } extern "C" { pub fn virConnectDomainXMLFromNative( conn: virConnectPtr, nativeFormat: *const ::libc::c_char, nativeConfig: *const ::libc::c_char, flags: ::libc::c_uint, ) -> *mut ::libc::c_char; } extern "C" { pub fn virConnectDomainXMLToNative( conn: virConnectPtr, nativeFormat: *const ::libc::c_char, domainXml: *const ::libc::c_char, flags: ::libc::c_uint, ) -> *mut ::libc::c_char; } extern "C" { pub fn virDomainBlockStats( dom: virDomainPtr, disk: *const ::libc::c_char, stats: virDomainBlockStatsPtr, size: usize, ) -> ::libc::c_int; } extern "C" { pub fn virDomainBlockStatsFlags( dom: virDomainPtr, disk: *const ::libc::c_char, params: virTypedParameterPtr, nparams: *mut ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainInterfaceStats( dom: virDomainPtr, device: *const ::libc::c_char, stats: virDomainInterfaceStatsPtr, size: usize, ) -> ::libc::c_int; } extern "C" { pub fn virDomainSetInterfaceParameters( dom: virDomainPtr, device: *const ::libc::c_char, params: virTypedParameterPtr, nparams: ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainGetInterfaceParameters( dom: virDomainPtr, device: *const ::libc::c_char, params: virTypedParameterPtr, nparams: *mut ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainBlockPeek( dom: virDomainPtr, disk: *const ::libc::c_char, offset: ::libc::c_ulonglong, size: usize, buffer: *mut ::libc::c_void, flags: ::libc::c_uint, ) -> ::libc::c_int; } pub const VIR_DOMAIN_BLOCK_RESIZE_BYTES: virDomainBlockResizeFlags = 1; pub const VIR_DOMAIN_BLOCK_RESIZE_CAPACITY: virDomainBlockResizeFlags = 2; pub type virDomainBlockResizeFlags = ::libc::c_uint; extern "C" { pub fn virDomainBlockResize( dom: virDomainPtr, disk: *const ::libc::c_char, size: ::libc::c_ulonglong, flags: ::libc::c_uint, ) -> ::libc::c_int; } pub type virDomainBlockInfo = _virDomainBlockInfo; pub type virDomainBlockInfoPtr = *mut virDomainBlockInfo; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct _virDomainBlockInfo { pub capacity: ::libc::c_ulonglong, pub allocation: ::libc::c_ulonglong, pub physical: ::libc::c_ulonglong, } #[test] fn bindgen_test_layout__virDomainBlockInfo() { const UNINIT: ::std::mem::MaybeUninit<_virDomainBlockInfo> = ::std::mem::MaybeUninit::uninit(); let ptr = UNINIT.as_ptr(); assert_eq!( ::std::mem::size_of::<_virDomainBlockInfo>(), 24usize, concat!("Size of: ", stringify!(_virDomainBlockInfo)) ); assert_eq!( ::std::mem::align_of::<_virDomainBlockInfo>(), 8usize, concat!("Alignment of ", stringify!(_virDomainBlockInfo)) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).capacity) as usize - ptr as usize }, 0usize, concat!( "Offset of field: ", stringify!(_virDomainBlockInfo), "::", stringify!(capacity) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).allocation) as usize - ptr as usize }, 8usize, concat!( "Offset of field: ", stringify!(_virDomainBlockInfo), "::", stringify!(allocation) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).physical) as usize - ptr as usize }, 16usize, concat!( "Offset of field: ", stringify!(_virDomainBlockInfo), "::", stringify!(physical) ) ); } extern "C" { pub fn virDomainGetBlockInfo( dom: virDomainPtr, disk: *const ::libc::c_char, info: virDomainBlockInfoPtr, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainMemoryStats( dom: virDomainPtr, stats: virDomainMemoryStatPtr, nr_stats: ::libc::c_uint, flags: ::libc::c_uint, ) -> ::libc::c_int; } pub const VIR_MEMORY_VIRTUAL: virDomainMemoryFlags = 1; pub const VIR_MEMORY_PHYSICAL: virDomainMemoryFlags = 2; pub type virDomainMemoryFlags = ::libc::c_uint; extern "C" { pub fn virDomainMemoryPeek( dom: virDomainPtr, start: ::libc::c_ulonglong, size: usize, buffer: *mut ::libc::c_void, flags: ::libc::c_uint, ) -> ::libc::c_int; } pub const VIR_DOMAIN_DEFINE_VALIDATE: virDomainDefineFlags = 1; pub type virDomainDefineFlags = ::libc::c_uint; extern "C" { pub fn virDomainDefineXML(conn: virConnectPtr, xml: *const ::libc::c_char) -> virDomainPtr; } extern "C" { pub fn virDomainDefineXMLFlags( conn: virConnectPtr, xml: *const ::libc::c_char, flags: ::libc::c_uint, ) -> virDomainPtr; } extern "C" { pub fn virDomainUndefine(domain: virDomainPtr) -> ::libc::c_int; } pub const VIR_DOMAIN_UNDEFINE_MANAGED_SAVE: virDomainUndefineFlagsValues = 1; pub const VIR_DOMAIN_UNDEFINE_SNAPSHOTS_METADATA: virDomainUndefineFlagsValues = 2; pub const VIR_DOMAIN_UNDEFINE_NVRAM: virDomainUndefineFlagsValues = 4; pub const VIR_DOMAIN_UNDEFINE_KEEP_NVRAM: virDomainUndefineFlagsValues = 8; pub const VIR_DOMAIN_UNDEFINE_CHECKPOINTS_METADATA: virDomainUndefineFlagsValues = 16; pub const VIR_DOMAIN_UNDEFINE_TPM: virDomainUndefineFlagsValues = 32; pub const VIR_DOMAIN_UNDEFINE_KEEP_TPM: virDomainUndefineFlagsValues = 64; pub type virDomainUndefineFlagsValues = ::libc::c_uint; extern "C" { pub fn virDomainUndefineFlags(domain: virDomainPtr, flags: ::libc::c_uint) -> ::libc::c_int; } extern "C" { pub fn virConnectNumOfDefinedDomains(conn: virConnectPtr) -> ::libc::c_int; } extern "C" { pub fn virConnectListDefinedDomains( conn: virConnectPtr, names: *mut *mut ::libc::c_char, maxnames: ::libc::c_int, ) -> ::libc::c_int; } pub const VIR_CONNECT_LIST_DOMAINS_ACTIVE: virConnectListAllDomainsFlags = 1; pub const VIR_CONNECT_LIST_DOMAINS_INACTIVE: virConnectListAllDomainsFlags = 2; pub const VIR_CONNECT_LIST_DOMAINS_PERSISTENT: virConnectListAllDomainsFlags = 4; pub const VIR_CONNECT_LIST_DOMAINS_TRANSIENT: virConnectListAllDomainsFlags = 8; pub const VIR_CONNECT_LIST_DOMAINS_RUNNING: virConnectListAllDomainsFlags = 16; pub const VIR_CONNECT_LIST_DOMAINS_PAUSED: virConnectListAllDomainsFlags = 32; pub const VIR_CONNECT_LIST_DOMAINS_SHUTOFF: virConnectListAllDomainsFlags = 64; pub const VIR_CONNECT_LIST_DOMAINS_OTHER: virConnectListAllDomainsFlags = 128; pub const VIR_CONNECT_LIST_DOMAINS_MANAGEDSAVE: virConnectListAllDomainsFlags = 256; pub const VIR_CONNECT_LIST_DOMAINS_NO_MANAGEDSAVE: virConnectListAllDomainsFlags = 512; pub const VIR_CONNECT_LIST_DOMAINS_AUTOSTART: virConnectListAllDomainsFlags = 1024; pub const VIR_CONNECT_LIST_DOMAINS_NO_AUTOSTART: virConnectListAllDomainsFlags = 2048; pub const VIR_CONNECT_LIST_DOMAINS_HAS_SNAPSHOT: virConnectListAllDomainsFlags = 4096; pub const VIR_CONNECT_LIST_DOMAINS_NO_SNAPSHOT: virConnectListAllDomainsFlags = 8192; pub const VIR_CONNECT_LIST_DOMAINS_HAS_CHECKPOINT: virConnectListAllDomainsFlags = 16384; pub const VIR_CONNECT_LIST_DOMAINS_NO_CHECKPOINT: virConnectListAllDomainsFlags = 32768; pub type virConnectListAllDomainsFlags = ::libc::c_uint; extern "C" { pub fn virConnectListAllDomains( conn: virConnectPtr, domains: *mut *mut virDomainPtr, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainCreate(domain: virDomainPtr) -> ::libc::c_int; } extern "C" { pub fn virDomainCreateWithFlags(domain: virDomainPtr, flags: ::libc::c_uint) -> ::libc::c_int; } extern "C" { pub fn virDomainCreateWithFiles( domain: virDomainPtr, nfiles: ::libc::c_uint, files: *mut ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainGetAutostart( domain: virDomainPtr, autostart: *mut ::libc::c_int, ) -> ::libc::c_int; } extern "C" { pub fn virDomainSetAutostart(domain: virDomainPtr, autostart: ::libc::c_int) -> ::libc::c_int; } pub const VIR_VCPU_OFFLINE: virVcpuState = 0; pub const VIR_VCPU_RUNNING: virVcpuState = 1; pub const VIR_VCPU_BLOCKED: virVcpuState = 2; pub type virVcpuState = ::libc::c_uint; pub const VIR_VCPU_INFO_CPU_OFFLINE: virVcpuHostCpuState = -1; pub const VIR_VCPU_INFO_CPU_UNAVAILABLE: virVcpuHostCpuState = -2; pub type virVcpuHostCpuState = ::libc::c_int; pub type virVcpuInfo = _virVcpuInfo; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct _virVcpuInfo { pub number: ::libc::c_uint, pub state: ::libc::c_int, pub cpuTime: ::libc::c_ulonglong, pub cpu: ::libc::c_int, } #[test] fn bindgen_test_layout__virVcpuInfo() { const UNINIT: ::std::mem::MaybeUninit<_virVcpuInfo> = ::std::mem::MaybeUninit::uninit(); let ptr = UNINIT.as_ptr(); assert_eq!( ::std::mem::size_of::<_virVcpuInfo>(), 24usize, concat!("Size of: ", stringify!(_virVcpuInfo)) ); assert_eq!( ::std::mem::align_of::<_virVcpuInfo>(), 8usize, concat!("Alignment of ", stringify!(_virVcpuInfo)) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).number) as usize - ptr as usize }, 0usize, concat!( "Offset of field: ", stringify!(_virVcpuInfo), "::", stringify!(number) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).state) as usize - ptr as usize }, 4usize, concat!( "Offset of field: ", stringify!(_virVcpuInfo), "::", stringify!(state) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).cpuTime) as usize - ptr as usize }, 8usize, concat!( "Offset of field: ", stringify!(_virVcpuInfo), "::", stringify!(cpuTime) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).cpu) as usize - ptr as usize }, 16usize, concat!( "Offset of field: ", stringify!(_virVcpuInfo), "::", stringify!(cpu) ) ); } pub type virVcpuInfoPtr = *mut virVcpuInfo; pub const VIR_DOMAIN_VCPU_CURRENT: virDomainVcpuFlags = 0; pub const VIR_DOMAIN_VCPU_LIVE: virDomainVcpuFlags = 1; pub const VIR_DOMAIN_VCPU_CONFIG: virDomainVcpuFlags = 2; pub const VIR_DOMAIN_VCPU_MAXIMUM: virDomainVcpuFlags = 4; pub const VIR_DOMAIN_VCPU_GUEST: virDomainVcpuFlags = 8; pub const VIR_DOMAIN_VCPU_HOTPLUGGABLE: virDomainVcpuFlags = 16; pub type virDomainVcpuFlags = ::libc::c_uint; extern "C" { pub fn virDomainSetVcpus(domain: virDomainPtr, nvcpus: ::libc::c_uint) -> ::libc::c_int; } extern "C" { pub fn virDomainSetVcpusFlags( domain: virDomainPtr, nvcpus: ::libc::c_uint, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainGetVcpusFlags(domain: virDomainPtr, flags: ::libc::c_uint) -> ::libc::c_int; } extern "C" { pub fn virDomainPinVcpu( domain: virDomainPtr, vcpu: ::libc::c_uint, cpumap: *mut ::libc::c_uchar, maplen: ::libc::c_int, ) -> ::libc::c_int; } extern "C" { pub fn virDomainPinVcpuFlags( domain: virDomainPtr, vcpu: ::libc::c_uint, cpumap: *mut ::libc::c_uchar, maplen: ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainGetVcpuPinInfo( domain: virDomainPtr, ncpumaps: ::libc::c_int, cpumaps: *mut ::libc::c_uchar, maplen: ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainPinEmulator( domain: virDomainPtr, cpumap: *mut ::libc::c_uchar, maplen: ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainGetEmulatorPinInfo( domain: virDomainPtr, cpumaps: *mut ::libc::c_uchar, maplen: ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } pub type virDomainIOThreadInfo = _virDomainIOThreadInfo; pub type virDomainIOThreadInfoPtr = *mut virDomainIOThreadInfo; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct _virDomainIOThreadInfo { pub iothread_id: ::libc::c_uint, pub cpumap: *mut ::libc::c_uchar, pub cpumaplen: ::libc::c_int, } #[test] fn bindgen_test_layout__virDomainIOThreadInfo() { const UNINIT: ::std::mem::MaybeUninit<_virDomainIOThreadInfo> = ::std::mem::MaybeUninit::uninit(); let ptr = UNINIT.as_ptr(); assert_eq!( ::std::mem::size_of::<_virDomainIOThreadInfo>(), 24usize, concat!("Size of: ", stringify!(_virDomainIOThreadInfo)) ); assert_eq!( ::std::mem::align_of::<_virDomainIOThreadInfo>(), 8usize, concat!("Alignment of ", stringify!(_virDomainIOThreadInfo)) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).iothread_id) as usize - ptr as usize }, 0usize, concat!( "Offset of field: ", stringify!(_virDomainIOThreadInfo), "::", stringify!(iothread_id) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).cpumap) as usize - ptr as usize }, 8usize, concat!( "Offset of field: ", stringify!(_virDomainIOThreadInfo), "::", stringify!(cpumap) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).cpumaplen) as usize - ptr as usize }, 16usize, concat!( "Offset of field: ", stringify!(_virDomainIOThreadInfo), "::", stringify!(cpumaplen) ) ); } extern "C" { pub fn virDomainIOThreadInfoFree(info: virDomainIOThreadInfoPtr); } extern "C" { pub fn virDomainGetIOThreadInfo( domain: virDomainPtr, info: *mut *mut virDomainIOThreadInfoPtr, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainPinIOThread( domain: virDomainPtr, iothread_id: ::libc::c_uint, cpumap: *mut ::libc::c_uchar, maplen: ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainAddIOThread( domain: virDomainPtr, iothread_id: ::libc::c_uint, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainDelIOThread( domain: virDomainPtr, iothread_id: ::libc::c_uint, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainSetIOThreadParams( domain: virDomainPtr, iothread_id: ::libc::c_uint, params: virTypedParameterPtr, nparams: ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainGetVcpus( domain: virDomainPtr, info: virVcpuInfoPtr, maxinfo: ::libc::c_int, cpumaps: *mut ::libc::c_uchar, maplen: ::libc::c_int, ) -> ::libc::c_int; } pub const VIR_DOMAIN_DEVICE_MODIFY_CURRENT: virDomainDeviceModifyFlags = 0; pub const VIR_DOMAIN_DEVICE_MODIFY_LIVE: virDomainDeviceModifyFlags = 1; pub const VIR_DOMAIN_DEVICE_MODIFY_CONFIG: virDomainDeviceModifyFlags = 2; pub const VIR_DOMAIN_DEVICE_MODIFY_FORCE: virDomainDeviceModifyFlags = 4; pub type virDomainDeviceModifyFlags = ::libc::c_uint; extern "C" { pub fn virDomainAttachDevice(domain: virDomainPtr, xml: *const ::libc::c_char) -> ::libc::c_int; } extern "C" { pub fn virDomainDetachDevice(domain: virDomainPtr, xml: *const ::libc::c_char) -> ::libc::c_int; } extern "C" { pub fn virDomainAttachDeviceFlags( domain: virDomainPtr, xml: *const ::libc::c_char, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainDetachDeviceFlags( domain: virDomainPtr, xml: *const ::libc::c_char, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainUpdateDeviceFlags( domain: virDomainPtr, xml: *const ::libc::c_char, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainDetachDeviceAlias( domain: virDomainPtr, alias: *const ::libc::c_char, flags: ::libc::c_uint, ) -> ::libc::c_int; } pub type virDomainStatsRecord = _virDomainStatsRecord; pub type virDomainStatsRecordPtr = *mut virDomainStatsRecord; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct _virDomainStatsRecord { pub dom: virDomainPtr, pub params: virTypedParameterPtr, pub nparams: ::libc::c_int, } #[test] fn bindgen_test_layout__virDomainStatsRecord() { const UNINIT: ::std::mem::MaybeUninit<_virDomainStatsRecord> = ::std::mem::MaybeUninit::uninit(); let ptr = UNINIT.as_ptr(); assert_eq!( ::std::mem::size_of::<_virDomainStatsRecord>(), 24usize, concat!("Size of: ", stringify!(_virDomainStatsRecord)) ); assert_eq!( ::std::mem::align_of::<_virDomainStatsRecord>(), 8usize, concat!("Alignment of ", stringify!(_virDomainStatsRecord)) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).dom) as usize - ptr as usize }, 0usize, concat!( "Offset of field: ", stringify!(_virDomainStatsRecord), "::", stringify!(dom) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).params) as usize - ptr as usize }, 8usize, concat!( "Offset of field: ", stringify!(_virDomainStatsRecord), "::", stringify!(params) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).nparams) as usize - ptr as usize }, 16usize, concat!( "Offset of field: ", stringify!(_virDomainStatsRecord), "::", stringify!(nparams) ) ); } pub const VIR_DOMAIN_STATS_STATE: virDomainStatsTypes = 1; pub const VIR_DOMAIN_STATS_CPU_TOTAL: virDomainStatsTypes = 2; pub const VIR_DOMAIN_STATS_BALLOON: virDomainStatsTypes = 4; pub const VIR_DOMAIN_STATS_VCPU: virDomainStatsTypes = 8; pub const VIR_DOMAIN_STATS_INTERFACE: virDomainStatsTypes = 16; pub const VIR_DOMAIN_STATS_BLOCK: virDomainStatsTypes = 32; pub const VIR_DOMAIN_STATS_PERF: virDomainStatsTypes = 64; pub const VIR_DOMAIN_STATS_IOTHREAD: virDomainStatsTypes = 128; pub const VIR_DOMAIN_STATS_MEMORY: virDomainStatsTypes = 256; pub const VIR_DOMAIN_STATS_DIRTYRATE: virDomainStatsTypes = 512; pub const VIR_DOMAIN_STATS_VM: virDomainStatsTypes = 1024; pub type virDomainStatsTypes = ::libc::c_uint; pub const VIR_CONNECT_GET_ALL_DOMAINS_STATS_ACTIVE: virConnectGetAllDomainStatsFlags = 1; pub const VIR_CONNECT_GET_ALL_DOMAINS_STATS_INACTIVE: virConnectGetAllDomainStatsFlags = 2; pub const VIR_CONNECT_GET_ALL_DOMAINS_STATS_PERSISTENT: virConnectGetAllDomainStatsFlags = 4; pub const VIR_CONNECT_GET_ALL_DOMAINS_STATS_TRANSIENT: virConnectGetAllDomainStatsFlags = 8; pub const VIR_CONNECT_GET_ALL_DOMAINS_STATS_RUNNING: virConnectGetAllDomainStatsFlags = 16; pub const VIR_CONNECT_GET_ALL_DOMAINS_STATS_PAUSED: virConnectGetAllDomainStatsFlags = 32; pub const VIR_CONNECT_GET_ALL_DOMAINS_STATS_SHUTOFF: virConnectGetAllDomainStatsFlags = 64; pub const VIR_CONNECT_GET_ALL_DOMAINS_STATS_OTHER: virConnectGetAllDomainStatsFlags = 128; pub const VIR_CONNECT_GET_ALL_DOMAINS_STATS_NOWAIT: virConnectGetAllDomainStatsFlags = 536870912; pub const VIR_CONNECT_GET_ALL_DOMAINS_STATS_BACKING: virConnectGetAllDomainStatsFlags = 1073741824; pub const VIR_CONNECT_GET_ALL_DOMAINS_STATS_ENFORCE_STATS: virConnectGetAllDomainStatsFlags = 2147483648; pub type virConnectGetAllDomainStatsFlags = ::libc::c_uint; extern "C" { pub fn virConnectGetAllDomainStats( conn: virConnectPtr, stats: ::libc::c_uint, retStats: *mut *mut virDomainStatsRecordPtr, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainListGetStats( doms: *mut virDomainPtr, stats: ::libc::c_uint, retStats: *mut *mut virDomainStatsRecordPtr, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainStatsRecordListFree(stats: *mut virDomainStatsRecordPtr); } extern "C" { pub fn virDomainGetPerfEvents( dom: virDomainPtr, params: *mut virTypedParameterPtr, nparams: *mut ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainSetPerfEvents( dom: virDomainPtr, params: virTypedParameterPtr, nparams: ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } pub const VIR_DOMAIN_BLOCK_JOB_TYPE_UNKNOWN: virDomainBlockJobType = 0; pub const VIR_DOMAIN_BLOCK_JOB_TYPE_PULL: virDomainBlockJobType = 1; pub const VIR_DOMAIN_BLOCK_JOB_TYPE_COPY: virDomainBlockJobType = 2; pub const VIR_DOMAIN_BLOCK_JOB_TYPE_COMMIT: virDomainBlockJobType = 3; pub const VIR_DOMAIN_BLOCK_JOB_TYPE_ACTIVE_COMMIT: virDomainBlockJobType = 4; pub const VIR_DOMAIN_BLOCK_JOB_TYPE_BACKUP: virDomainBlockJobType = 5; pub type virDomainBlockJobType = ::libc::c_uint; pub const VIR_DOMAIN_BLOCK_JOB_ABORT_ASYNC: virDomainBlockJobAbortFlags = 1; pub const VIR_DOMAIN_BLOCK_JOB_ABORT_PIVOT: virDomainBlockJobAbortFlags = 2; pub type virDomainBlockJobAbortFlags = ::libc::c_uint; extern "C" { pub fn virDomainBlockJobAbort( dom: virDomainPtr, disk: *const ::libc::c_char, flags: ::libc::c_uint, ) -> ::libc::c_int; } pub const VIR_DOMAIN_BLOCK_JOB_INFO_BANDWIDTH_BYTES: virDomainBlockJobInfoFlags = 1; pub type virDomainBlockJobInfoFlags = ::libc::c_uint; pub type virDomainBlockJobCursor = ::libc::c_ulonglong; pub type virDomainBlockJobInfo = _virDomainBlockJobInfo; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct _virDomainBlockJobInfo { pub type_: ::libc::c_int, pub bandwidth: ::libc::c_ulong, pub cur: virDomainBlockJobCursor, pub end: virDomainBlockJobCursor, } #[test] fn bindgen_test_layout__virDomainBlockJobInfo() { const UNINIT: ::std::mem::MaybeUninit<_virDomainBlockJobInfo> = ::std::mem::MaybeUninit::uninit(); let ptr = UNINIT.as_ptr(); assert_eq!( ::std::mem::size_of::<_virDomainBlockJobInfo>(), 32usize, concat!("Size of: ", stringify!(_virDomainBlockJobInfo)) ); assert_eq!( ::std::mem::align_of::<_virDomainBlockJobInfo>(), 8usize, concat!("Alignment of ", stringify!(_virDomainBlockJobInfo)) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).type_) as usize - ptr as usize }, 0usize, concat!( "Offset of field: ", stringify!(_virDomainBlockJobInfo), "::", stringify!(type_) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).bandwidth) as usize - ptr as usize }, 8usize, concat!( "Offset of field: ", stringify!(_virDomainBlockJobInfo), "::", stringify!(bandwidth) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).cur) as usize - ptr as usize }, 16usize, concat!( "Offset of field: ", stringify!(_virDomainBlockJobInfo), "::", stringify!(cur) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).end) as usize - ptr as usize }, 24usize, concat!( "Offset of field: ", stringify!(_virDomainBlockJobInfo), "::", stringify!(end) ) ); } pub type virDomainBlockJobInfoPtr = *mut virDomainBlockJobInfo; extern "C" { pub fn virDomainGetBlockJobInfo( dom: virDomainPtr, disk: *const ::libc::c_char, info: virDomainBlockJobInfoPtr, flags: ::libc::c_uint, ) -> ::libc::c_int; } pub const VIR_DOMAIN_BLOCK_JOB_SPEED_BANDWIDTH_BYTES: virDomainBlockJobSetSpeedFlags = 1; pub type virDomainBlockJobSetSpeedFlags = ::libc::c_uint; extern "C" { pub fn virDomainBlockJobSetSpeed( dom: virDomainPtr, disk: *const ::libc::c_char, bandwidth: ::libc::c_ulong, flags: ::libc::c_uint, ) -> ::libc::c_int; } pub const VIR_DOMAIN_BLOCK_PULL_BANDWIDTH_BYTES: virDomainBlockPullFlags = 64; pub type virDomainBlockPullFlags = ::libc::c_uint; extern "C" { pub fn virDomainBlockPull( dom: virDomainPtr, disk: *const ::libc::c_char, bandwidth: ::libc::c_ulong, flags: ::libc::c_uint, ) -> ::libc::c_int; } pub const VIR_DOMAIN_BLOCK_REBASE_SHALLOW: virDomainBlockRebaseFlags = 1; pub const VIR_DOMAIN_BLOCK_REBASE_REUSE_EXT: virDomainBlockRebaseFlags = 2; pub const VIR_DOMAIN_BLOCK_REBASE_COPY_RAW: virDomainBlockRebaseFlags = 4; pub const VIR_DOMAIN_BLOCK_REBASE_COPY: virDomainBlockRebaseFlags = 8; pub const VIR_DOMAIN_BLOCK_REBASE_RELATIVE: virDomainBlockRebaseFlags = 16; pub const VIR_DOMAIN_BLOCK_REBASE_COPY_DEV: virDomainBlockRebaseFlags = 32; pub const VIR_DOMAIN_BLOCK_REBASE_BANDWIDTH_BYTES: virDomainBlockRebaseFlags = 64; pub type virDomainBlockRebaseFlags = ::libc::c_uint; extern "C" { pub fn virDomainBlockRebase( dom: virDomainPtr, disk: *const ::libc::c_char, base: *const ::libc::c_char, bandwidth: ::libc::c_ulong, flags: ::libc::c_uint, ) -> ::libc::c_int; } pub const VIR_DOMAIN_BLOCK_COPY_SHALLOW: virDomainBlockCopyFlags = 1; pub const VIR_DOMAIN_BLOCK_COPY_REUSE_EXT: virDomainBlockCopyFlags = 2; pub const VIR_DOMAIN_BLOCK_COPY_TRANSIENT_JOB: virDomainBlockCopyFlags = 4; pub const VIR_DOMAIN_BLOCK_COPY_SYNCHRONOUS_WRITES: virDomainBlockCopyFlags = 8; pub type virDomainBlockCopyFlags = ::libc::c_uint; extern "C" { pub fn virDomainBlockCopy( dom: virDomainPtr, disk: *const ::libc::c_char, destxml: *const ::libc::c_char, params: virTypedParameterPtr, nparams: ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } pub const VIR_DOMAIN_BLOCK_COMMIT_SHALLOW: virDomainBlockCommitFlags = 1; pub const VIR_DOMAIN_BLOCK_COMMIT_DELETE: virDomainBlockCommitFlags = 2; pub const VIR_DOMAIN_BLOCK_COMMIT_ACTIVE: virDomainBlockCommitFlags = 4; pub const VIR_DOMAIN_BLOCK_COMMIT_RELATIVE: virDomainBlockCommitFlags = 8; pub const VIR_DOMAIN_BLOCK_COMMIT_BANDWIDTH_BYTES: virDomainBlockCommitFlags = 16; pub type virDomainBlockCommitFlags = ::libc::c_uint; extern "C" { pub fn virDomainBlockCommit( dom: virDomainPtr, disk: *const ::libc::c_char, base: *const ::libc::c_char, top: *const ::libc::c_char, bandwidth: ::libc::c_ulong, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainSetBlockIoTune( dom: virDomainPtr, disk: *const ::libc::c_char, params: virTypedParameterPtr, nparams: ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainGetBlockIoTune( dom: virDomainPtr, disk: *const ::libc::c_char, params: virTypedParameterPtr, nparams: *mut ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } pub const VIR_DOMAIN_DISK_ERROR_NONE: virDomainDiskErrorCode = 0; pub const VIR_DOMAIN_DISK_ERROR_UNSPEC: virDomainDiskErrorCode = 1; pub const VIR_DOMAIN_DISK_ERROR_NO_SPACE: virDomainDiskErrorCode = 2; pub type virDomainDiskErrorCode = ::libc::c_uint; pub type virDomainDiskError = _virDomainDiskError; pub type virDomainDiskErrorPtr = *mut virDomainDiskError; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct _virDomainDiskError { pub disk: *mut ::libc::c_char, pub error: ::libc::c_int, } #[test] fn bindgen_test_layout__virDomainDiskError() { const UNINIT: ::std::mem::MaybeUninit<_virDomainDiskError> = ::std::mem::MaybeUninit::uninit(); let ptr = UNINIT.as_ptr(); assert_eq!( ::std::mem::size_of::<_virDomainDiskError>(), 16usize, concat!("Size of: ", stringify!(_virDomainDiskError)) ); assert_eq!( ::std::mem::align_of::<_virDomainDiskError>(), 8usize, concat!("Alignment of ", stringify!(_virDomainDiskError)) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).disk) as usize - ptr as usize }, 0usize, concat!( "Offset of field: ", stringify!(_virDomainDiskError), "::", stringify!(disk) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).error) as usize - ptr as usize }, 8usize, concat!( "Offset of field: ", stringify!(_virDomainDiskError), "::", stringify!(error) ) ); } extern "C" { pub fn virDomainGetDiskErrors( dom: virDomainPtr, errors: virDomainDiskErrorPtr, maxerrors: ::libc::c_uint, flags: ::libc::c_uint, ) -> ::libc::c_int; } pub const VIR_KEYCODE_SET_LINUX: virKeycodeSet = 0; pub const VIR_KEYCODE_SET_XT: virKeycodeSet = 1; pub const VIR_KEYCODE_SET_ATSET1: virKeycodeSet = 2; pub const VIR_KEYCODE_SET_ATSET2: virKeycodeSet = 3; pub const VIR_KEYCODE_SET_ATSET3: virKeycodeSet = 4; pub const VIR_KEYCODE_SET_OSX: virKeycodeSet = 5; pub const VIR_KEYCODE_SET_XT_KBD: virKeycodeSet = 6; pub const VIR_KEYCODE_SET_USB: virKeycodeSet = 7; pub const VIR_KEYCODE_SET_WIN32: virKeycodeSet = 8; pub const VIR_KEYCODE_SET_QNUM: virKeycodeSet = 9; pub type virKeycodeSet = ::libc::c_uint; extern "C" { pub fn virDomainSendKey( domain: virDomainPtr, codeset: ::libc::c_uint, holdtime: ::libc::c_uint, keycodes: *mut ::libc::c_uint, nkeycodes: ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } pub const VIR_DOMAIN_PROCESS_SIGNAL_NOP: virDomainProcessSignal = 0; pub const VIR_DOMAIN_PROCESS_SIGNAL_HUP: virDomainProcessSignal = 1; pub const VIR_DOMAIN_PROCESS_SIGNAL_INT: virDomainProcessSignal = 2; pub const VIR_DOMAIN_PROCESS_SIGNAL_QUIT: virDomainProcessSignal = 3; pub const VIR_DOMAIN_PROCESS_SIGNAL_ILL: virDomainProcessSignal = 4; pub const VIR_DOMAIN_PROCESS_SIGNAL_TRAP: virDomainProcessSignal = 5; pub const VIR_DOMAIN_PROCESS_SIGNAL_ABRT: virDomainProcessSignal = 6; pub const VIR_DOMAIN_PROCESS_SIGNAL_BUS: virDomainProcessSignal = 7; pub const VIR_DOMAIN_PROCESS_SIGNAL_FPE: virDomainProcessSignal = 8; pub const VIR_DOMAIN_PROCESS_SIGNAL_KILL: virDomainProcessSignal = 9; pub const VIR_DOMAIN_PROCESS_SIGNAL_USR1: virDomainProcessSignal = 10; pub const VIR_DOMAIN_PROCESS_SIGNAL_SEGV: virDomainProcessSignal = 11; pub const VIR_DOMAIN_PROCESS_SIGNAL_USR2: virDomainProcessSignal = 12; pub const VIR_DOMAIN_PROCESS_SIGNAL_PIPE: virDomainProcessSignal = 13; pub const VIR_DOMAIN_PROCESS_SIGNAL_ALRM: virDomainProcessSignal = 14; pub const VIR_DOMAIN_PROCESS_SIGNAL_TERM: virDomainProcessSignal = 15; pub const VIR_DOMAIN_PROCESS_SIGNAL_STKFLT: virDomainProcessSignal = 16; pub const VIR_DOMAIN_PROCESS_SIGNAL_CHLD: virDomainProcessSignal = 17; pub const VIR_DOMAIN_PROCESS_SIGNAL_CONT: virDomainProcessSignal = 18; pub const VIR_DOMAIN_PROCESS_SIGNAL_STOP: virDomainProcessSignal = 19; pub const VIR_DOMAIN_PROCESS_SIGNAL_TSTP: virDomainProcessSignal = 20; pub const VIR_DOMAIN_PROCESS_SIGNAL_TTIN: virDomainProcessSignal = 21; pub const VIR_DOMAIN_PROCESS_SIGNAL_TTOU: virDomainProcessSignal = 22; pub const VIR_DOMAIN_PROCESS_SIGNAL_URG: virDomainProcessSignal = 23; pub const VIR_DOMAIN_PROCESS_SIGNAL_XCPU: virDomainProcessSignal = 24; pub const VIR_DOMAIN_PROCESS_SIGNAL_XFSZ: virDomainProcessSignal = 25; pub const VIR_DOMAIN_PROCESS_SIGNAL_VTALRM: virDomainProcessSignal = 26; pub const VIR_DOMAIN_PROCESS_SIGNAL_PROF: virDomainProcessSignal = 27; pub const VIR_DOMAIN_PROCESS_SIGNAL_WINCH: virDomainProcessSignal = 28; pub const VIR_DOMAIN_PROCESS_SIGNAL_POLL: virDomainProcessSignal = 29; pub const VIR_DOMAIN_PROCESS_SIGNAL_PWR: virDomainProcessSignal = 30; pub const VIR_DOMAIN_PROCESS_SIGNAL_SYS: virDomainProcessSignal = 31; pub const VIR_DOMAIN_PROCESS_SIGNAL_RT0: virDomainProcessSignal = 32; pub const VIR_DOMAIN_PROCESS_SIGNAL_RT1: virDomainProcessSignal = 33; pub const VIR_DOMAIN_PROCESS_SIGNAL_RT2: virDomainProcessSignal = 34; pub const VIR_DOMAIN_PROCESS_SIGNAL_RT3: virDomainProcessSignal = 35; pub const VIR_DOMAIN_PROCESS_SIGNAL_RT4: virDomainProcessSignal = 36; pub const VIR_DOMAIN_PROCESS_SIGNAL_RT5: virDomainProcessSignal = 37; pub const VIR_DOMAIN_PROCESS_SIGNAL_RT6: virDomainProcessSignal = 38; pub const VIR_DOMAIN_PROCESS_SIGNAL_RT7: virDomainProcessSignal = 39; pub const VIR_DOMAIN_PROCESS_SIGNAL_RT8: virDomainProcessSignal = 40; pub const VIR_DOMAIN_PROCESS_SIGNAL_RT9: virDomainProcessSignal = 41; pub const VIR_DOMAIN_PROCESS_SIGNAL_RT10: virDomainProcessSignal = 42; pub const VIR_DOMAIN_PROCESS_SIGNAL_RT11: virDomainProcessSignal = 43; pub const VIR_DOMAIN_PROCESS_SIGNAL_RT12: virDomainProcessSignal = 44; pub const VIR_DOMAIN_PROCESS_SIGNAL_RT13: virDomainProcessSignal = 45; pub const VIR_DOMAIN_PROCESS_SIGNAL_RT14: virDomainProcessSignal = 46; pub const VIR_DOMAIN_PROCESS_SIGNAL_RT15: virDomainProcessSignal = 47; pub const VIR_DOMAIN_PROCESS_SIGNAL_RT16: virDomainProcessSignal = 48; pub const VIR_DOMAIN_PROCESS_SIGNAL_RT17: virDomainProcessSignal = 49; pub const VIR_DOMAIN_PROCESS_SIGNAL_RT18: virDomainProcessSignal = 50; pub const VIR_DOMAIN_PROCESS_SIGNAL_RT19: virDomainProcessSignal = 51; pub const VIR_DOMAIN_PROCESS_SIGNAL_RT20: virDomainProcessSignal = 52; pub const VIR_DOMAIN_PROCESS_SIGNAL_RT21: virDomainProcessSignal = 53; pub const VIR_DOMAIN_PROCESS_SIGNAL_RT22: virDomainProcessSignal = 54; pub const VIR_DOMAIN_PROCESS_SIGNAL_RT23: virDomainProcessSignal = 55; pub const VIR_DOMAIN_PROCESS_SIGNAL_RT24: virDomainProcessSignal = 56; pub const VIR_DOMAIN_PROCESS_SIGNAL_RT25: virDomainProcessSignal = 57; pub const VIR_DOMAIN_PROCESS_SIGNAL_RT26: virDomainProcessSignal = 58; pub const VIR_DOMAIN_PROCESS_SIGNAL_RT27: virDomainProcessSignal = 59; pub const VIR_DOMAIN_PROCESS_SIGNAL_RT28: virDomainProcessSignal = 60; pub const VIR_DOMAIN_PROCESS_SIGNAL_RT29: virDomainProcessSignal = 61; pub const VIR_DOMAIN_PROCESS_SIGNAL_RT30: virDomainProcessSignal = 62; pub const VIR_DOMAIN_PROCESS_SIGNAL_RT31: virDomainProcessSignal = 63; pub const VIR_DOMAIN_PROCESS_SIGNAL_RT32: virDomainProcessSignal = 64; pub type virDomainProcessSignal = ::libc::c_uint; extern "C" { pub fn virDomainSendProcessSignal( domain: virDomainPtr, pid_value: ::libc::c_longlong, signum: ::libc::c_uint, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainCreateLinux( conn: virConnectPtr, xmlDesc: *const ::libc::c_char, flags: ::libc::c_uint, ) -> virDomainPtr; } pub const VIR_DOMAIN_EVENT_DEFINED: virDomainEventType = 0; pub const VIR_DOMAIN_EVENT_UNDEFINED: virDomainEventType = 1; pub const VIR_DOMAIN_EVENT_STARTED: virDomainEventType = 2; pub const VIR_DOMAIN_EVENT_SUSPENDED: virDomainEventType = 3; pub const VIR_DOMAIN_EVENT_RESUMED: virDomainEventType = 4; pub const VIR_DOMAIN_EVENT_STOPPED: virDomainEventType = 5; pub const VIR_DOMAIN_EVENT_SHUTDOWN: virDomainEventType = 6; pub const VIR_DOMAIN_EVENT_PMSUSPENDED: virDomainEventType = 7; pub const VIR_DOMAIN_EVENT_CRASHED: virDomainEventType = 8; pub type virDomainEventType = ::libc::c_uint; pub const VIR_DOMAIN_EVENT_DEFINED_ADDED: virDomainEventDefinedDetailType = 0; pub const VIR_DOMAIN_EVENT_DEFINED_UPDATED: virDomainEventDefinedDetailType = 1; pub const VIR_DOMAIN_EVENT_DEFINED_RENAMED: virDomainEventDefinedDetailType = 2; pub const VIR_DOMAIN_EVENT_DEFINED_FROM_SNAPSHOT: virDomainEventDefinedDetailType = 3; pub type virDomainEventDefinedDetailType = ::libc::c_uint; pub const VIR_DOMAIN_EVENT_UNDEFINED_REMOVED: virDomainEventUndefinedDetailType = 0; pub const VIR_DOMAIN_EVENT_UNDEFINED_RENAMED: virDomainEventUndefinedDetailType = 1; pub type virDomainEventUndefinedDetailType = ::libc::c_uint; pub const VIR_DOMAIN_EVENT_STARTED_BOOTED: virDomainEventStartedDetailType = 0; pub const VIR_DOMAIN_EVENT_STARTED_MIGRATED: virDomainEventStartedDetailType = 1; pub const VIR_DOMAIN_EVENT_STARTED_RESTORED: virDomainEventStartedDetailType = 2; pub const VIR_DOMAIN_EVENT_STARTED_FROM_SNAPSHOT: virDomainEventStartedDetailType = 3; pub const VIR_DOMAIN_EVENT_STARTED_WAKEUP: virDomainEventStartedDetailType = 4; pub type virDomainEventStartedDetailType = ::libc::c_uint; pub const VIR_DOMAIN_EVENT_SUSPENDED_PAUSED: virDomainEventSuspendedDetailType = 0; pub const VIR_DOMAIN_EVENT_SUSPENDED_MIGRATED: virDomainEventSuspendedDetailType = 1; pub const VIR_DOMAIN_EVENT_SUSPENDED_IOERROR: virDomainEventSuspendedDetailType = 2; pub const VIR_DOMAIN_EVENT_SUSPENDED_WATCHDOG: virDomainEventSuspendedDetailType = 3; pub const VIR_DOMAIN_EVENT_SUSPENDED_RESTORED: virDomainEventSuspendedDetailType = 4; pub const VIR_DOMAIN_EVENT_SUSPENDED_FROM_SNAPSHOT: virDomainEventSuspendedDetailType = 5; pub const VIR_DOMAIN_EVENT_SUSPENDED_API_ERROR: virDomainEventSuspendedDetailType = 6; pub const VIR_DOMAIN_EVENT_SUSPENDED_POSTCOPY: virDomainEventSuspendedDetailType = 7; pub const VIR_DOMAIN_EVENT_SUSPENDED_POSTCOPY_FAILED: virDomainEventSuspendedDetailType = 8; pub type virDomainEventSuspendedDetailType = ::libc::c_uint; pub const VIR_DOMAIN_EVENT_RESUMED_UNPAUSED: virDomainEventResumedDetailType = 0; pub const VIR_DOMAIN_EVENT_RESUMED_MIGRATED: virDomainEventResumedDetailType = 1; pub const VIR_DOMAIN_EVENT_RESUMED_FROM_SNAPSHOT: virDomainEventResumedDetailType = 2; pub const VIR_DOMAIN_EVENT_RESUMED_POSTCOPY: virDomainEventResumedDetailType = 3; pub const VIR_DOMAIN_EVENT_RESUMED_POSTCOPY_FAILED: virDomainEventResumedDetailType = 4; pub type virDomainEventResumedDetailType = ::libc::c_uint; pub const VIR_DOMAIN_EVENT_STOPPED_SHUTDOWN: virDomainEventStoppedDetailType = 0; pub const VIR_DOMAIN_EVENT_STOPPED_DESTROYED: virDomainEventStoppedDetailType = 1; pub const VIR_DOMAIN_EVENT_STOPPED_CRASHED: virDomainEventStoppedDetailType = 2; pub const VIR_DOMAIN_EVENT_STOPPED_MIGRATED: virDomainEventStoppedDetailType = 3; pub const VIR_DOMAIN_EVENT_STOPPED_SAVED: virDomainEventStoppedDetailType = 4; pub const VIR_DOMAIN_EVENT_STOPPED_FAILED: virDomainEventStoppedDetailType = 5; pub const VIR_DOMAIN_EVENT_STOPPED_FROM_SNAPSHOT: virDomainEventStoppedDetailType = 6; pub type virDomainEventStoppedDetailType = ::libc::c_uint; pub const VIR_DOMAIN_EVENT_SHUTDOWN_FINISHED: virDomainEventShutdownDetailType = 0; pub const VIR_DOMAIN_EVENT_SHUTDOWN_GUEST: virDomainEventShutdownDetailType = 1; pub const VIR_DOMAIN_EVENT_SHUTDOWN_HOST: virDomainEventShutdownDetailType = 2; pub type virDomainEventShutdownDetailType = ::libc::c_uint; pub const VIR_DOMAIN_EVENT_PMSUSPENDED_MEMORY: virDomainEventPMSuspendedDetailType = 0; pub const VIR_DOMAIN_EVENT_PMSUSPENDED_DISK: virDomainEventPMSuspendedDetailType = 1; pub type virDomainEventPMSuspendedDetailType = ::libc::c_uint; pub const VIR_DOMAIN_EVENT_CRASHED_PANICKED: virDomainEventCrashedDetailType = 0; pub const VIR_DOMAIN_EVENT_CRASHED_CRASHLOADED: virDomainEventCrashedDetailType = 1; pub type virDomainEventCrashedDetailType = ::libc::c_uint; pub const VIR_DOMAIN_EVENT_MEMORY_FAILURE_RECIPIENT_HYPERVISOR: virDomainMemoryFailureRecipientType = 0; pub const VIR_DOMAIN_EVENT_MEMORY_FAILURE_RECIPIENT_GUEST: virDomainMemoryFailureRecipientType = 1; pub type virDomainMemoryFailureRecipientType = ::libc::c_uint; pub const VIR_DOMAIN_EVENT_MEMORY_FAILURE_ACTION_IGNORE: virDomainMemoryFailureActionType = 0; pub const VIR_DOMAIN_EVENT_MEMORY_FAILURE_ACTION_INJECT: virDomainMemoryFailureActionType = 1; pub const VIR_DOMAIN_EVENT_MEMORY_FAILURE_ACTION_FATAL: virDomainMemoryFailureActionType = 2; pub const VIR_DOMAIN_EVENT_MEMORY_FAILURE_ACTION_RESET: virDomainMemoryFailureActionType = 3; pub type virDomainMemoryFailureActionType = ::libc::c_uint; pub const VIR_DOMAIN_MEMORY_FAILURE_ACTION_REQUIRED: virDomainMemoryFailureFlags = 1; pub const VIR_DOMAIN_MEMORY_FAILURE_RECURSIVE: virDomainMemoryFailureFlags = 2; pub type virDomainMemoryFailureFlags = ::libc::c_uint; pub type virConnectDomainEventCallback = ::std::option::Option< unsafe extern "C" fn( conn: virConnectPtr, dom: virDomainPtr, event: ::libc::c_int, detail: ::libc::c_int, opaque: *mut ::libc::c_void, ) -> ::libc::c_int, >; extern "C" { pub fn virConnectDomainEventRegister( conn: virConnectPtr, cb: virConnectDomainEventCallback, opaque: *mut ::libc::c_void, freecb: virFreeCallback, ) -> ::libc::c_int; } extern "C" { pub fn virConnectDomainEventDeregister( conn: virConnectPtr, cb: virConnectDomainEventCallback, ) -> ::libc::c_int; } extern "C" { pub fn virDomainIsActive(dom: virDomainPtr) -> ::libc::c_int; } extern "C" { pub fn virDomainIsPersistent(dom: virDomainPtr) -> ::libc::c_int; } extern "C" { pub fn virDomainIsUpdated(dom: virDomainPtr) -> ::libc::c_int; } pub const VIR_DOMAIN_JOB_NONE: virDomainJobType = 0; pub const VIR_DOMAIN_JOB_BOUNDED: virDomainJobType = 1; pub const VIR_DOMAIN_JOB_UNBOUNDED: virDomainJobType = 2; pub const VIR_DOMAIN_JOB_COMPLETED: virDomainJobType = 3; pub const VIR_DOMAIN_JOB_FAILED: virDomainJobType = 4; pub const VIR_DOMAIN_JOB_CANCELLED: virDomainJobType = 5; pub type virDomainJobType = ::libc::c_uint; pub type virDomainJobInfo = _virDomainJobInfo; pub type virDomainJobInfoPtr = *mut virDomainJobInfo; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct _virDomainJobInfo { pub type_: ::libc::c_int, pub timeElapsed: ::libc::c_ulonglong, pub timeRemaining: ::libc::c_ulonglong, pub dataTotal: ::libc::c_ulonglong, pub dataProcessed: ::libc::c_ulonglong, pub dataRemaining: ::libc::c_ulonglong, pub memTotal: ::libc::c_ulonglong, pub memProcessed: ::libc::c_ulonglong, pub memRemaining: ::libc::c_ulonglong, pub fileTotal: ::libc::c_ulonglong, pub fileProcessed: ::libc::c_ulonglong, pub fileRemaining: ::libc::c_ulonglong, } #[test] fn bindgen_test_layout__virDomainJobInfo() { const UNINIT: ::std::mem::MaybeUninit<_virDomainJobInfo> = ::std::mem::MaybeUninit::uninit(); let ptr = UNINIT.as_ptr(); assert_eq!( ::std::mem::size_of::<_virDomainJobInfo>(), 96usize, concat!("Size of: ", stringify!(_virDomainJobInfo)) ); assert_eq!( ::std::mem::align_of::<_virDomainJobInfo>(), 8usize, concat!("Alignment of ", stringify!(_virDomainJobInfo)) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).type_) as usize - ptr as usize }, 0usize, concat!( "Offset of field: ", stringify!(_virDomainJobInfo), "::", stringify!(type_) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).timeElapsed) as usize - ptr as usize }, 8usize, concat!( "Offset of field: ", stringify!(_virDomainJobInfo), "::", stringify!(timeElapsed) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).timeRemaining) as usize - ptr as usize }, 16usize, concat!( "Offset of field: ", stringify!(_virDomainJobInfo), "::", stringify!(timeRemaining) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).dataTotal) as usize - ptr as usize }, 24usize, concat!( "Offset of field: ", stringify!(_virDomainJobInfo), "::", stringify!(dataTotal) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).dataProcessed) as usize - ptr as usize }, 32usize, concat!( "Offset of field: ", stringify!(_virDomainJobInfo), "::", stringify!(dataProcessed) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).dataRemaining) as usize - ptr as usize }, 40usize, concat!( "Offset of field: ", stringify!(_virDomainJobInfo), "::", stringify!(dataRemaining) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).memTotal) as usize - ptr as usize }, 48usize, concat!( "Offset of field: ", stringify!(_virDomainJobInfo), "::", stringify!(memTotal) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).memProcessed) as usize - ptr as usize }, 56usize, concat!( "Offset of field: ", stringify!(_virDomainJobInfo), "::", stringify!(memProcessed) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).memRemaining) as usize - ptr as usize }, 64usize, concat!( "Offset of field: ", stringify!(_virDomainJobInfo), "::", stringify!(memRemaining) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).fileTotal) as usize - ptr as usize }, 72usize, concat!( "Offset of field: ", stringify!(_virDomainJobInfo), "::", stringify!(fileTotal) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).fileProcessed) as usize - ptr as usize }, 80usize, concat!( "Offset of field: ", stringify!(_virDomainJobInfo), "::", stringify!(fileProcessed) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).fileRemaining) as usize - ptr as usize }, 88usize, concat!( "Offset of field: ", stringify!(_virDomainJobInfo), "::", stringify!(fileRemaining) ) ); } pub const VIR_DOMAIN_JOB_STATS_COMPLETED: virDomainGetJobStatsFlags = 1; pub const VIR_DOMAIN_JOB_STATS_KEEP_COMPLETED: virDomainGetJobStatsFlags = 2; pub type virDomainGetJobStatsFlags = ::libc::c_uint; extern "C" { pub fn virDomainGetJobInfo(dom: virDomainPtr, info: virDomainJobInfoPtr) -> ::libc::c_int; } extern "C" { pub fn virDomainGetJobStats( domain: virDomainPtr, type_: *mut ::libc::c_int, params: *mut virTypedParameterPtr, nparams: *mut ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainAbortJob(dom: virDomainPtr) -> ::libc::c_int; } pub const VIR_DOMAIN_ABORT_JOB_POSTCOPY: virDomainAbortJobFlagsValues = 1; pub type virDomainAbortJobFlagsValues = ::libc::c_uint; extern "C" { pub fn virDomainAbortJobFlags(dom: virDomainPtr, flags: ::libc::c_uint) -> ::libc::c_int; } pub const VIR_DOMAIN_JOB_OPERATION_UNKNOWN: virDomainJobOperation = 0; pub const VIR_DOMAIN_JOB_OPERATION_START: virDomainJobOperation = 1; pub const VIR_DOMAIN_JOB_OPERATION_SAVE: virDomainJobOperation = 2; pub const VIR_DOMAIN_JOB_OPERATION_RESTORE: virDomainJobOperation = 3; pub const VIR_DOMAIN_JOB_OPERATION_MIGRATION_IN: virDomainJobOperation = 4; pub const VIR_DOMAIN_JOB_OPERATION_MIGRATION_OUT: virDomainJobOperation = 5; pub const VIR_DOMAIN_JOB_OPERATION_SNAPSHOT: virDomainJobOperation = 6; pub const VIR_DOMAIN_JOB_OPERATION_SNAPSHOT_REVERT: virDomainJobOperation = 7; pub const VIR_DOMAIN_JOB_OPERATION_DUMP: virDomainJobOperation = 8; pub const VIR_DOMAIN_JOB_OPERATION_BACKUP: virDomainJobOperation = 9; pub const VIR_DOMAIN_JOB_OPERATION_SNAPSHOT_DELETE: virDomainJobOperation = 10; pub type virDomainJobOperation = ::libc::c_uint; pub type virConnectDomainEventGenericCallback = ::std::option::Option< unsafe extern "C" fn(conn: virConnectPtr, dom: virDomainPtr, opaque: *mut ::libc::c_void), >; pub type virConnectDomainEventRTCChangeCallback = ::std::option::Option< unsafe extern "C" fn( conn: virConnectPtr, dom: virDomainPtr, utcoffset: ::libc::c_longlong, opaque: *mut ::libc::c_void, ), >; pub const VIR_DOMAIN_EVENT_WATCHDOG_NONE: virDomainEventWatchdogAction = 0; pub const VIR_DOMAIN_EVENT_WATCHDOG_PAUSE: virDomainEventWatchdogAction = 1; pub const VIR_DOMAIN_EVENT_WATCHDOG_RESET: virDomainEventWatchdogAction = 2; pub const VIR_DOMAIN_EVENT_WATCHDOG_POWEROFF: virDomainEventWatchdogAction = 3; pub const VIR_DOMAIN_EVENT_WATCHDOG_SHUTDOWN: virDomainEventWatchdogAction = 4; pub const VIR_DOMAIN_EVENT_WATCHDOG_DEBUG: virDomainEventWatchdogAction = 5; pub const VIR_DOMAIN_EVENT_WATCHDOG_INJECTNMI: virDomainEventWatchdogAction = 6; pub type virDomainEventWatchdogAction = ::libc::c_uint; pub type virConnectDomainEventWatchdogCallback = ::std::option::Option< unsafe extern "C" fn( conn: virConnectPtr, dom: virDomainPtr, action: ::libc::c_int, opaque: *mut ::libc::c_void, ), >; pub const VIR_DOMAIN_EVENT_IO_ERROR_NONE: virDomainEventIOErrorAction = 0; pub const VIR_DOMAIN_EVENT_IO_ERROR_PAUSE: virDomainEventIOErrorAction = 1; pub const VIR_DOMAIN_EVENT_IO_ERROR_REPORT: virDomainEventIOErrorAction = 2; pub type virDomainEventIOErrorAction = ::libc::c_uint; pub type virConnectDomainEventIOErrorCallback = ::std::option::Option< unsafe extern "C" fn( conn: virConnectPtr, dom: virDomainPtr, srcPath: *const ::libc::c_char, devAlias: *const ::libc::c_char, action: ::libc::c_int, opaque: *mut ::libc::c_void, ), >; pub type virConnectDomainEventIOErrorReasonCallback = ::std::option::Option< unsafe extern "C" fn( conn: virConnectPtr, dom: virDomainPtr, srcPath: *const ::libc::c_char, devAlias: *const ::libc::c_char, action: ::libc::c_int, reason: *const ::libc::c_char, opaque: *mut ::libc::c_void, ), >; pub const VIR_DOMAIN_EVENT_GRAPHICS_CONNECT: virDomainEventGraphicsPhase = 0; pub const VIR_DOMAIN_EVENT_GRAPHICS_INITIALIZE: virDomainEventGraphicsPhase = 1; pub const VIR_DOMAIN_EVENT_GRAPHICS_DISCONNECT: virDomainEventGraphicsPhase = 2; pub type virDomainEventGraphicsPhase = ::libc::c_uint; pub const VIR_DOMAIN_EVENT_GRAPHICS_ADDRESS_IPV4: virDomainEventGraphicsAddressType = 0; pub const VIR_DOMAIN_EVENT_GRAPHICS_ADDRESS_IPV6: virDomainEventGraphicsAddressType = 1; pub const VIR_DOMAIN_EVENT_GRAPHICS_ADDRESS_UNIX: virDomainEventGraphicsAddressType = 2; pub type virDomainEventGraphicsAddressType = ::libc::c_uint; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct _virDomainEventGraphicsAddress { pub family: ::libc::c_int, pub node: *mut ::libc::c_char, pub service: *mut ::libc::c_char, } #[test] fn bindgen_test_layout__virDomainEventGraphicsAddress() { const UNINIT: ::std::mem::MaybeUninit<_virDomainEventGraphicsAddress> = ::std::mem::MaybeUninit::uninit(); let ptr = UNINIT.as_ptr(); assert_eq!( ::std::mem::size_of::<_virDomainEventGraphicsAddress>(), 24usize, concat!("Size of: ", stringify!(_virDomainEventGraphicsAddress)) ); assert_eq!( ::std::mem::align_of::<_virDomainEventGraphicsAddress>(), 8usize, concat!("Alignment of ", stringify!(_virDomainEventGraphicsAddress)) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).family) as usize - ptr as usize }, 0usize, concat!( "Offset of field: ", stringify!(_virDomainEventGraphicsAddress), "::", stringify!(family) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).node) as usize - ptr as usize }, 8usize, concat!( "Offset of field: ", stringify!(_virDomainEventGraphicsAddress), "::", stringify!(node) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).service) as usize - ptr as usize }, 16usize, concat!( "Offset of field: ", stringify!(_virDomainEventGraphicsAddress), "::", stringify!(service) ) ); } pub type virDomainEventGraphicsAddress = _virDomainEventGraphicsAddress; pub type virDomainEventGraphicsAddressPtr = *mut virDomainEventGraphicsAddress; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct _virDomainEventGraphicsSubjectIdentity { pub type_: *mut ::libc::c_char, pub name: *mut ::libc::c_char, } #[test] fn bindgen_test_layout__virDomainEventGraphicsSubjectIdentity() { const UNINIT: ::std::mem::MaybeUninit<_virDomainEventGraphicsSubjectIdentity> = ::std::mem::MaybeUninit::uninit(); let ptr = UNINIT.as_ptr(); assert_eq!( ::std::mem::size_of::<_virDomainEventGraphicsSubjectIdentity>(), 16usize, concat!( "Size of: ", stringify!(_virDomainEventGraphicsSubjectIdentity) ) ); assert_eq!( ::std::mem::align_of::<_virDomainEventGraphicsSubjectIdentity>(), 8usize, concat!( "Alignment of ", stringify!(_virDomainEventGraphicsSubjectIdentity) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).type_) as usize - ptr as usize }, 0usize, concat!( "Offset of field: ", stringify!(_virDomainEventGraphicsSubjectIdentity), "::", stringify!(type_) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).name) as usize - ptr as usize }, 8usize, concat!( "Offset of field: ", stringify!(_virDomainEventGraphicsSubjectIdentity), "::", stringify!(name) ) ); } pub type virDomainEventGraphicsSubjectIdentity = _virDomainEventGraphicsSubjectIdentity; pub type virDomainEventGraphicsSubjectIdentityPtr = *mut virDomainEventGraphicsSubjectIdentity; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct _virDomainEventGraphicsSubject { pub nidentity: ::libc::c_int, pub identities: virDomainEventGraphicsSubjectIdentityPtr, } #[test] fn bindgen_test_layout__virDomainEventGraphicsSubject() { const UNINIT: ::std::mem::MaybeUninit<_virDomainEventGraphicsSubject> = ::std::mem::MaybeUninit::uninit(); let ptr = UNINIT.as_ptr(); assert_eq!( ::std::mem::size_of::<_virDomainEventGraphicsSubject>(), 16usize, concat!("Size of: ", stringify!(_virDomainEventGraphicsSubject)) ); assert_eq!( ::std::mem::align_of::<_virDomainEventGraphicsSubject>(), 8usize, concat!("Alignment of ", stringify!(_virDomainEventGraphicsSubject)) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).nidentity) as usize - ptr as usize }, 0usize, concat!( "Offset of field: ", stringify!(_virDomainEventGraphicsSubject), "::", stringify!(nidentity) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).identities) as usize - ptr as usize }, 8usize, concat!( "Offset of field: ", stringify!(_virDomainEventGraphicsSubject), "::", stringify!(identities) ) ); } pub type virDomainEventGraphicsSubject = _virDomainEventGraphicsSubject; pub type virDomainEventGraphicsSubjectPtr = *mut virDomainEventGraphicsSubject; pub type virConnectDomainEventGraphicsCallback = ::std::option::Option< unsafe extern "C" fn( conn: virConnectPtr, dom: virDomainPtr, phase: ::libc::c_int, local: *const virDomainEventGraphicsAddress, remote: *const virDomainEventGraphicsAddress, authScheme: *const ::libc::c_char, subject: *const virDomainEventGraphicsSubject, opaque: *mut ::libc::c_void, ), >; pub const VIR_DOMAIN_BLOCK_JOB_COMPLETED: virConnectDomainEventBlockJobStatus = 0; pub const VIR_DOMAIN_BLOCK_JOB_FAILED: virConnectDomainEventBlockJobStatus = 1; pub const VIR_DOMAIN_BLOCK_JOB_CANCELED: virConnectDomainEventBlockJobStatus = 2; pub const VIR_DOMAIN_BLOCK_JOB_READY: virConnectDomainEventBlockJobStatus = 3; pub type virConnectDomainEventBlockJobStatus = ::libc::c_uint; pub type virConnectDomainEventBlockJobCallback = ::std::option::Option< unsafe extern "C" fn( conn: virConnectPtr, dom: virDomainPtr, disk: *const ::libc::c_char, type_: ::libc::c_int, status: ::libc::c_int, opaque: *mut ::libc::c_void, ), >; pub const VIR_DOMAIN_EVENT_DISK_CHANGE_MISSING_ON_START: virConnectDomainEventDiskChangeReason = 0; pub const VIR_DOMAIN_EVENT_DISK_DROP_MISSING_ON_START: virConnectDomainEventDiskChangeReason = 1; pub type virConnectDomainEventDiskChangeReason = ::libc::c_uint; pub type virConnectDomainEventDiskChangeCallback = ::std::option::Option< unsafe extern "C" fn( conn: virConnectPtr, dom: virDomainPtr, oldSrcPath: *const ::libc::c_char, newSrcPath: *const ::libc::c_char, devAlias: *const ::libc::c_char, reason: ::libc::c_int, opaque: *mut ::libc::c_void, ), >; pub const VIR_DOMAIN_EVENT_TRAY_CHANGE_OPEN: virDomainEventTrayChangeReason = 0; pub const VIR_DOMAIN_EVENT_TRAY_CHANGE_CLOSE: virDomainEventTrayChangeReason = 1; pub type virDomainEventTrayChangeReason = ::libc::c_uint; pub type virConnectDomainEventTrayChangeCallback = ::std::option::Option< unsafe extern "C" fn( conn: virConnectPtr, dom: virDomainPtr, devAlias: *const ::libc::c_char, reason: ::libc::c_int, opaque: *mut ::libc::c_void, ), >; pub type virConnectDomainEventPMWakeupCallback = ::std::option::Option< unsafe extern "C" fn( conn: virConnectPtr, dom: virDomainPtr, reason: ::libc::c_int, opaque: *mut ::libc::c_void, ), >; pub type virConnectDomainEventPMSuspendCallback = ::std::option::Option< unsafe extern "C" fn( conn: virConnectPtr, dom: virDomainPtr, reason: ::libc::c_int, opaque: *mut ::libc::c_void, ), >; pub type virConnectDomainEventBalloonChangeCallback = ::std::option::Option< unsafe extern "C" fn( conn: virConnectPtr, dom: virDomainPtr, actual: ::libc::c_ulonglong, opaque: *mut ::libc::c_void, ), >; pub type virConnectDomainEventPMSuspendDiskCallback = ::std::option::Option< unsafe extern "C" fn( conn: virConnectPtr, dom: virDomainPtr, reason: ::libc::c_int, opaque: *mut ::libc::c_void, ), >; pub type virConnectDomainEventDeviceRemovedCallback = ::std::option::Option< unsafe extern "C" fn( conn: virConnectPtr, dom: virDomainPtr, devAlias: *const ::libc::c_char, opaque: *mut ::libc::c_void, ), >; pub type virConnectDomainEventDeviceAddedCallback = ::std::option::Option< unsafe extern "C" fn( conn: virConnectPtr, dom: virDomainPtr, devAlias: *const ::libc::c_char, opaque: *mut ::libc::c_void, ), >; pub type virConnectDomainEventDeviceRemovalFailedCallback = ::std::option::Option< unsafe extern "C" fn( conn: virConnectPtr, dom: virDomainPtr, devAlias: *const ::libc::c_char, opaque: *mut ::libc::c_void, ), >; pub type virConnectDomainEventMetadataChangeCallback = ::std::option::Option< unsafe extern "C" fn( conn: virConnectPtr, dom: virDomainPtr, type_: ::libc::c_int, nsuri: *const ::libc::c_char, opaque: *mut ::libc::c_void, ), >; pub type virConnectDomainEventMigrationIterationCallback = ::std::option::Option< unsafe extern "C" fn( conn: virConnectPtr, dom: virDomainPtr, iteration: ::libc::c_int, opaque: *mut ::libc::c_void, ), >; pub type virConnectDomainEventJobCompletedCallback = ::std::option::Option< unsafe extern "C" fn( conn: virConnectPtr, dom: virDomainPtr, params: virTypedParameterPtr, nparams: ::libc::c_int, opaque: *mut ::libc::c_void, ), >; pub type virConnectDomainEventTunableCallback = ::std::option::Option< unsafe extern "C" fn( conn: virConnectPtr, dom: virDomainPtr, params: virTypedParameterPtr, nparams: ::libc::c_int, opaque: *mut ::libc::c_void, ), >; pub const VIR_CONNECT_DOMAIN_EVENT_AGENT_LIFECYCLE_STATE_CONNECTED: virConnectDomainEventAgentLifecycleState = 1; pub const VIR_CONNECT_DOMAIN_EVENT_AGENT_LIFECYCLE_STATE_DISCONNECTED: virConnectDomainEventAgentLifecycleState = 2; pub type virConnectDomainEventAgentLifecycleState = ::libc::c_uint; pub const VIR_CONNECT_DOMAIN_EVENT_AGENT_LIFECYCLE_REASON_UNKNOWN: virConnectDomainEventAgentLifecycleReason = 0; pub const VIR_CONNECT_DOMAIN_EVENT_AGENT_LIFECYCLE_REASON_DOMAIN_STARTED: virConnectDomainEventAgentLifecycleReason = 1; pub const VIR_CONNECT_DOMAIN_EVENT_AGENT_LIFECYCLE_REASON_CHANNEL: virConnectDomainEventAgentLifecycleReason = 2; pub type virConnectDomainEventAgentLifecycleReason = ::libc::c_uint; pub type virConnectDomainEventAgentLifecycleCallback = ::std::option::Option< unsafe extern "C" fn( conn: virConnectPtr, dom: virDomainPtr, state: ::libc::c_int, reason: ::libc::c_int, opaque: *mut ::libc::c_void, ), >; pub type virConnectDomainEventBlockThresholdCallback = ::std::option::Option< unsafe extern "C" fn( conn: virConnectPtr, dom: virDomainPtr, dev: *const ::libc::c_char, path: *const ::libc::c_char, threshold: ::libc::c_ulonglong, excess: ::libc::c_ulonglong, opaque: *mut ::libc::c_void, ), >; pub type virConnectDomainEventMemoryFailureCallback = ::std::option::Option< unsafe extern "C" fn( conn: virConnectPtr, dom: virDomainPtr, recipient: ::libc::c_int, action: ::libc::c_int, flags: ::libc::c_uint, opaque: *mut ::libc::c_void, ), >; pub type virConnectDomainEventMemoryDeviceSizeChangeCallback = ::std::option::Option< unsafe extern "C" fn( conn: virConnectPtr, dom: virDomainPtr, alias: *const ::libc::c_char, size: ::libc::c_ulonglong, opaque: *mut ::libc::c_void, ), >; pub const VIR_DOMAIN_EVENT_ID_LIFECYCLE: virDomainEventID = 0; pub const VIR_DOMAIN_EVENT_ID_REBOOT: virDomainEventID = 1; pub const VIR_DOMAIN_EVENT_ID_RTC_CHANGE: virDomainEventID = 2; pub const VIR_DOMAIN_EVENT_ID_WATCHDOG: virDomainEventID = 3; pub const VIR_DOMAIN_EVENT_ID_IO_ERROR: virDomainEventID = 4; pub const VIR_DOMAIN_EVENT_ID_GRAPHICS: virDomainEventID = 5; pub const VIR_DOMAIN_EVENT_ID_IO_ERROR_REASON: virDomainEventID = 6; pub const VIR_DOMAIN_EVENT_ID_CONTROL_ERROR: virDomainEventID = 7; pub const VIR_DOMAIN_EVENT_ID_BLOCK_JOB: virDomainEventID = 8; pub const VIR_DOMAIN_EVENT_ID_DISK_CHANGE: virDomainEventID = 9; pub const VIR_DOMAIN_EVENT_ID_TRAY_CHANGE: virDomainEventID = 10; pub const VIR_DOMAIN_EVENT_ID_PMWAKEUP: virDomainEventID = 11; pub const VIR_DOMAIN_EVENT_ID_PMSUSPEND: virDomainEventID = 12; pub const VIR_DOMAIN_EVENT_ID_BALLOON_CHANGE: virDomainEventID = 13; pub const VIR_DOMAIN_EVENT_ID_PMSUSPEND_DISK: virDomainEventID = 14; pub const VIR_DOMAIN_EVENT_ID_DEVICE_REMOVED: virDomainEventID = 15; pub const VIR_DOMAIN_EVENT_ID_BLOCK_JOB_2: virDomainEventID = 16; pub const VIR_DOMAIN_EVENT_ID_TUNABLE: virDomainEventID = 17; pub const VIR_DOMAIN_EVENT_ID_AGENT_LIFECYCLE: virDomainEventID = 18; pub const VIR_DOMAIN_EVENT_ID_DEVICE_ADDED: virDomainEventID = 19; pub const VIR_DOMAIN_EVENT_ID_MIGRATION_ITERATION: virDomainEventID = 20; pub const VIR_DOMAIN_EVENT_ID_JOB_COMPLETED: virDomainEventID = 21; pub const VIR_DOMAIN_EVENT_ID_DEVICE_REMOVAL_FAILED: virDomainEventID = 22; pub const VIR_DOMAIN_EVENT_ID_METADATA_CHANGE: virDomainEventID = 23; pub const VIR_DOMAIN_EVENT_ID_BLOCK_THRESHOLD: virDomainEventID = 24; pub const VIR_DOMAIN_EVENT_ID_MEMORY_FAILURE: virDomainEventID = 25; pub const VIR_DOMAIN_EVENT_ID_MEMORY_DEVICE_SIZE_CHANGE: virDomainEventID = 26; pub type virDomainEventID = ::libc::c_uint; extern "C" { pub fn virConnectDomainEventRegisterAny( conn: virConnectPtr, dom: virDomainPtr, eventID: ::libc::c_int, cb: virConnectDomainEventGenericCallback, opaque: *mut ::libc::c_void, freecb: virFreeCallback, ) -> ::libc::c_int; } extern "C" { pub fn virConnectDomainEventDeregisterAny( conn: virConnectPtr, callbackID: ::libc::c_int, ) -> ::libc::c_int; } pub const VIR_DOMAIN_CONSOLE_FORCE: virDomainConsoleFlags = 1; pub const VIR_DOMAIN_CONSOLE_SAFE: virDomainConsoleFlags = 2; pub type virDomainConsoleFlags = ::libc::c_uint; extern "C" { pub fn virDomainOpenConsole( dom: virDomainPtr, dev_name: *const ::libc::c_char, st: virStreamPtr, flags: ::libc::c_uint, ) -> ::libc::c_int; } pub const VIR_DOMAIN_CHANNEL_FORCE: virDomainChannelFlags = 1; pub type virDomainChannelFlags = ::libc::c_uint; extern "C" { pub fn virDomainOpenChannel( dom: virDomainPtr, name: *const ::libc::c_char, st: virStreamPtr, flags: ::libc::c_uint, ) -> ::libc::c_int; } pub const VIR_DOMAIN_OPEN_GRAPHICS_SKIPAUTH: virDomainOpenGraphicsFlags = 1; pub type virDomainOpenGraphicsFlags = ::libc::c_uint; extern "C" { pub fn virDomainOpenGraphics( dom: virDomainPtr, idx: ::libc::c_uint, fd: ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainOpenGraphicsFD( dom: virDomainPtr, idx: ::libc::c_uint, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainInjectNMI(domain: virDomainPtr, flags: ::libc::c_uint) -> ::libc::c_int; } extern "C" { pub fn virDomainFSTrim( dom: virDomainPtr, mountPoint: *const ::libc::c_char, minimum: ::libc::c_ulonglong, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainFSFreeze( dom: virDomainPtr, mountpoints: *mut *const ::libc::c_char, nmountpoints: ::libc::c_uint, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainFSThaw( dom: virDomainPtr, mountpoints: *mut *const ::libc::c_char, nmountpoints: ::libc::c_uint, flags: ::libc::c_uint, ) -> ::libc::c_int; } pub type virDomainFSInfo = _virDomainFSInfo; pub type virDomainFSInfoPtr = *mut virDomainFSInfo; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct _virDomainFSInfo { pub mountpoint: *mut ::libc::c_char, pub name: *mut ::libc::c_char, pub fstype: *mut ::libc::c_char, pub ndevAlias: usize, pub devAlias: *mut *mut ::libc::c_char, } #[test] fn bindgen_test_layout__virDomainFSInfo() { const UNINIT: ::std::mem::MaybeUninit<_virDomainFSInfo> = ::std::mem::MaybeUninit::uninit(); let ptr = UNINIT.as_ptr(); assert_eq!( ::std::mem::size_of::<_virDomainFSInfo>(), 40usize, concat!("Size of: ", stringify!(_virDomainFSInfo)) ); assert_eq!( ::std::mem::align_of::<_virDomainFSInfo>(), 8usize, concat!("Alignment of ", stringify!(_virDomainFSInfo)) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).mountpoint) as usize - ptr as usize }, 0usize, concat!( "Offset of field: ", stringify!(_virDomainFSInfo), "::", stringify!(mountpoint) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).name) as usize - ptr as usize }, 8usize, concat!( "Offset of field: ", stringify!(_virDomainFSInfo), "::", stringify!(name) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).fstype) as usize - ptr as usize }, 16usize, concat!( "Offset of field: ", stringify!(_virDomainFSInfo), "::", stringify!(fstype) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).ndevAlias) as usize - ptr as usize }, 24usize, concat!( "Offset of field: ", stringify!(_virDomainFSInfo), "::", stringify!(ndevAlias) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).devAlias) as usize - ptr as usize }, 32usize, concat!( "Offset of field: ", stringify!(_virDomainFSInfo), "::", stringify!(devAlias) ) ); } extern "C" { pub fn virDomainFSInfoFree(info: virDomainFSInfoPtr); } extern "C" { pub fn virDomainGetFSInfo( dom: virDomainPtr, info: *mut *mut virDomainFSInfoPtr, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainGetTime( dom: virDomainPtr, seconds: *mut ::libc::c_longlong, nseconds: *mut ::libc::c_uint, flags: ::libc::c_uint, ) -> ::libc::c_int; } pub const VIR_DOMAIN_TIME_SYNC: virDomainSetTimeFlags = 1; pub type virDomainSetTimeFlags = ::libc::c_uint; extern "C" { pub fn virDomainSetTime( dom: virDomainPtr, seconds: ::libc::c_longlong, nseconds: ::libc::c_uint, flags: ::libc::c_uint, ) -> ::libc::c_int; } pub const VIR_DOMAIN_SCHED_FIELD_INT: virSchedParameterType = 1; pub const VIR_DOMAIN_SCHED_FIELD_UINT: virSchedParameterType = 2; pub const VIR_DOMAIN_SCHED_FIELD_LLONG: virSchedParameterType = 3; pub const VIR_DOMAIN_SCHED_FIELD_ULLONG: virSchedParameterType = 4; pub const VIR_DOMAIN_SCHED_FIELD_DOUBLE: virSchedParameterType = 5; pub const VIR_DOMAIN_SCHED_FIELD_BOOLEAN: virSchedParameterType = 6; pub type virSchedParameterType = ::libc::c_uint; pub type virSchedParameter = _virTypedParameter; pub type virSchedParameterPtr = *mut virSchedParameter; pub const VIR_DOMAIN_BLKIO_PARAM_INT: virBlkioParameterType = 1; pub const VIR_DOMAIN_BLKIO_PARAM_UINT: virBlkioParameterType = 2; pub const VIR_DOMAIN_BLKIO_PARAM_LLONG: virBlkioParameterType = 3; pub const VIR_DOMAIN_BLKIO_PARAM_ULLONG: virBlkioParameterType = 4; pub const VIR_DOMAIN_BLKIO_PARAM_DOUBLE: virBlkioParameterType = 5; pub const VIR_DOMAIN_BLKIO_PARAM_BOOLEAN: virBlkioParameterType = 6; pub type virBlkioParameterType = ::libc::c_uint; pub type virBlkioParameter = _virTypedParameter; pub type virBlkioParameterPtr = *mut virBlkioParameter; pub const VIR_DOMAIN_MEMORY_PARAM_INT: virMemoryParameterType = 1; pub const VIR_DOMAIN_MEMORY_PARAM_UINT: virMemoryParameterType = 2; pub const VIR_DOMAIN_MEMORY_PARAM_LLONG: virMemoryParameterType = 3; pub const VIR_DOMAIN_MEMORY_PARAM_ULLONG: virMemoryParameterType = 4; pub const VIR_DOMAIN_MEMORY_PARAM_DOUBLE: virMemoryParameterType = 5; pub const VIR_DOMAIN_MEMORY_PARAM_BOOLEAN: virMemoryParameterType = 6; pub type virMemoryParameterType = ::libc::c_uint; pub type virMemoryParameter = _virTypedParameter; pub type virMemoryParameterPtr = *mut virMemoryParameter; pub const VIR_DOMAIN_INTERFACE_ADDRESSES_SRC_LEASE: virDomainInterfaceAddressesSource = 0; pub const VIR_DOMAIN_INTERFACE_ADDRESSES_SRC_AGENT: virDomainInterfaceAddressesSource = 1; pub const VIR_DOMAIN_INTERFACE_ADDRESSES_SRC_ARP: virDomainInterfaceAddressesSource = 2; pub type virDomainInterfaceAddressesSource = ::libc::c_uint; pub type virDomainIPAddress = _virDomainInterfaceIPAddress; pub type virDomainIPAddressPtr = *mut virDomainIPAddress; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct _virDomainInterfaceIPAddress { pub type_: ::libc::c_int, pub addr: *mut ::libc::c_char, pub prefix: ::libc::c_uint, } #[test] fn bindgen_test_layout__virDomainInterfaceIPAddress() { const UNINIT: ::std::mem::MaybeUninit<_virDomainInterfaceIPAddress> = ::std::mem::MaybeUninit::uninit(); let ptr = UNINIT.as_ptr(); assert_eq!( ::std::mem::size_of::<_virDomainInterfaceIPAddress>(), 24usize, concat!("Size of: ", stringify!(_virDomainInterfaceIPAddress)) ); assert_eq!( ::std::mem::align_of::<_virDomainInterfaceIPAddress>(), 8usize, concat!("Alignment of ", stringify!(_virDomainInterfaceIPAddress)) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).type_) as usize - ptr as usize }, 0usize, concat!( "Offset of field: ", stringify!(_virDomainInterfaceIPAddress), "::", stringify!(type_) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).addr) as usize - ptr as usize }, 8usize, concat!( "Offset of field: ", stringify!(_virDomainInterfaceIPAddress), "::", stringify!(addr) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).prefix) as usize - ptr as usize }, 16usize, concat!( "Offset of field: ", stringify!(_virDomainInterfaceIPAddress), "::", stringify!(prefix) ) ); } pub type virDomainInterface = _virDomainInterface; pub type virDomainInterfacePtr = *mut virDomainInterface; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct _virDomainInterface { pub name: *mut ::libc::c_char, pub hwaddr: *mut ::libc::c_char, pub naddrs: ::libc::c_uint, pub addrs: virDomainIPAddressPtr, } #[test] fn bindgen_test_layout__virDomainInterface() { const UNINIT: ::std::mem::MaybeUninit<_virDomainInterface> = ::std::mem::MaybeUninit::uninit(); let ptr = UNINIT.as_ptr(); assert_eq!( ::std::mem::size_of::<_virDomainInterface>(), 32usize, concat!("Size of: ", stringify!(_virDomainInterface)) ); assert_eq!( ::std::mem::align_of::<_virDomainInterface>(), 8usize, concat!("Alignment of ", stringify!(_virDomainInterface)) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).name) as usize - ptr as usize }, 0usize, concat!( "Offset of field: ", stringify!(_virDomainInterface), "::", stringify!(name) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).hwaddr) as usize - ptr as usize }, 8usize, concat!( "Offset of field: ", stringify!(_virDomainInterface), "::", stringify!(hwaddr) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).naddrs) as usize - ptr as usize }, 16usize, concat!( "Offset of field: ", stringify!(_virDomainInterface), "::", stringify!(naddrs) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).addrs) as usize - ptr as usize }, 24usize, concat!( "Offset of field: ", stringify!(_virDomainInterface), "::", stringify!(addrs) ) ); } extern "C" { pub fn virDomainInterfaceAddresses( dom: virDomainPtr, ifaces: *mut *mut virDomainInterfacePtr, source: ::libc::c_uint, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainInterfaceFree(iface: virDomainInterfacePtr); } pub const VIR_DOMAIN_PASSWORD_ENCRYPTED: virDomainSetUserPasswordFlags = 1; pub type virDomainSetUserPasswordFlags = ::libc::c_uint; extern "C" { pub fn virDomainSetUserPassword( dom: virDomainPtr, user: *const ::libc::c_char, password: *const ::libc::c_char, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainRename( dom: virDomainPtr, new_name: *const ::libc::c_char, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainGetGuestVcpus( domain: virDomainPtr, params: *mut virTypedParameterPtr, nparams: *mut ::libc::c_uint, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainSetGuestVcpus( domain: virDomainPtr, cpumap: *const ::libc::c_char, state: ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainSetVcpu( domain: virDomainPtr, vcpumap: *const ::libc::c_char, state: ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainSetBlockThreshold( domain: virDomainPtr, dev: *const ::libc::c_char, threshold: ::libc::c_ulonglong, flags: ::libc::c_uint, ) -> ::libc::c_int; } pub const VIR_DOMAIN_LIFECYCLE_POWEROFF: virDomainLifecycle = 0; pub const VIR_DOMAIN_LIFECYCLE_REBOOT: virDomainLifecycle = 1; pub const VIR_DOMAIN_LIFECYCLE_CRASH: virDomainLifecycle = 2; pub type virDomainLifecycle = ::libc::c_uint; pub const VIR_DOMAIN_LIFECYCLE_ACTION_DESTROY: virDomainLifecycleAction = 0; pub const VIR_DOMAIN_LIFECYCLE_ACTION_RESTART: virDomainLifecycleAction = 1; pub const VIR_DOMAIN_LIFECYCLE_ACTION_RESTART_RENAME: virDomainLifecycleAction = 2; pub const VIR_DOMAIN_LIFECYCLE_ACTION_PRESERVE: virDomainLifecycleAction = 3; pub const VIR_DOMAIN_LIFECYCLE_ACTION_COREDUMP_DESTROY: virDomainLifecycleAction = 4; pub const VIR_DOMAIN_LIFECYCLE_ACTION_COREDUMP_RESTART: virDomainLifecycleAction = 5; pub type virDomainLifecycleAction = ::libc::c_uint; extern "C" { pub fn virDomainSetLifecycleAction( domain: virDomainPtr, type_: ::libc::c_uint, action: ::libc::c_uint, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainGetLaunchSecurityInfo( domain: virDomainPtr, params: *mut virTypedParameterPtr, nparams: *mut ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainSetLaunchSecurityState( domain: virDomainPtr, params: virTypedParameterPtr, nparams: ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } pub const VIR_DOMAIN_GUEST_INFO_USERS: virDomainGuestInfoTypes = 1; pub const VIR_DOMAIN_GUEST_INFO_OS: virDomainGuestInfoTypes = 2; pub const VIR_DOMAIN_GUEST_INFO_TIMEZONE: virDomainGuestInfoTypes = 4; pub const VIR_DOMAIN_GUEST_INFO_HOSTNAME: virDomainGuestInfoTypes = 8; pub const VIR_DOMAIN_GUEST_INFO_FILESYSTEM: virDomainGuestInfoTypes = 16; pub const VIR_DOMAIN_GUEST_INFO_DISKS: virDomainGuestInfoTypes = 32; pub const VIR_DOMAIN_GUEST_INFO_INTERFACES: virDomainGuestInfoTypes = 64; pub type virDomainGuestInfoTypes = ::libc::c_uint; extern "C" { pub fn virDomainGetGuestInfo( domain: virDomainPtr, types: ::libc::c_uint, params: *mut virTypedParameterPtr, nparams: *mut ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } pub const VIR_DOMAIN_AGENT_RESPONSE_TIMEOUT_BLOCK: virDomainAgentResponseTimeoutValues = -2; pub const VIR_DOMAIN_AGENT_RESPONSE_TIMEOUT_DEFAULT: virDomainAgentResponseTimeoutValues = -1; pub const VIR_DOMAIN_AGENT_RESPONSE_TIMEOUT_NOWAIT: virDomainAgentResponseTimeoutValues = 0; pub type virDomainAgentResponseTimeoutValues = ::libc::c_int; extern "C" { pub fn virDomainAgentSetResponseTimeout( domain: virDomainPtr, timeout: ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } pub const VIR_DOMAIN_BACKUP_BEGIN_REUSE_EXTERNAL: virDomainBackupBeginFlags = 1; pub type virDomainBackupBeginFlags = ::libc::c_uint; extern "C" { pub fn virDomainBackupBegin( domain: virDomainPtr, backupXML: *const ::libc::c_char, checkpointXML: *const ::libc::c_char, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainBackupGetXMLDesc( domain: virDomainPtr, flags: ::libc::c_uint, ) -> *mut ::libc::c_char; } extern "C" { pub fn virDomainAuthorizedSSHKeysGet( domain: virDomainPtr, user: *const ::libc::c_char, keys: *mut *mut *mut ::libc::c_char, flags: ::libc::c_uint, ) -> ::libc::c_int; } pub const VIR_DOMAIN_AUTHORIZED_SSH_KEYS_SET_APPEND: virDomainAuthorizedSSHKeysSetFlags = 1; pub const VIR_DOMAIN_AUTHORIZED_SSH_KEYS_SET_REMOVE: virDomainAuthorizedSSHKeysSetFlags = 2; pub type virDomainAuthorizedSSHKeysSetFlags = ::libc::c_uint; extern "C" { pub fn virDomainAuthorizedSSHKeysSet( domain: virDomainPtr, user: *const ::libc::c_char, keys: *mut *const ::libc::c_char, nkeys: ::libc::c_uint, flags: ::libc::c_uint, ) -> ::libc::c_int; } pub const VIR_DOMAIN_MESSAGE_DEPRECATION: virDomainMessageType = 1; pub const VIR_DOMAIN_MESSAGE_TAINTING: virDomainMessageType = 2; pub type virDomainMessageType = ::libc::c_uint; extern "C" { pub fn virDomainGetMessages( domain: virDomainPtr, msgs: *mut *mut *mut ::libc::c_char, flags: ::libc::c_uint, ) -> ::libc::c_int; } pub const VIR_DOMAIN_DIRTYRATE_UNSTARTED: virDomainDirtyRateStatus = 0; pub const VIR_DOMAIN_DIRTYRATE_MEASURING: virDomainDirtyRateStatus = 1; pub const VIR_DOMAIN_DIRTYRATE_MEASURED: virDomainDirtyRateStatus = 2; pub type virDomainDirtyRateStatus = ::libc::c_uint; pub const VIR_DOMAIN_DIRTYRATE_MODE_PAGE_SAMPLING: virDomainDirtyRateCalcFlags = 0; pub const VIR_DOMAIN_DIRTYRATE_MODE_DIRTY_BITMAP: virDomainDirtyRateCalcFlags = 1; pub const VIR_DOMAIN_DIRTYRATE_MODE_DIRTY_RING: virDomainDirtyRateCalcFlags = 2; pub type virDomainDirtyRateCalcFlags = ::libc::c_uint; extern "C" { pub fn virDomainStartDirtyRateCalc( domain: virDomainPtr, seconds: ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } pub const VIR_DOMAIN_FD_ASSOCIATE_SECLABEL_RESTORE: virDomainFDAssociateFlags = 1; pub const VIR_DOMAIN_FD_ASSOCIATE_SECLABEL_WRITABLE: virDomainFDAssociateFlags = 2; pub type virDomainFDAssociateFlags = ::libc::c_uint; extern "C" { pub fn virDomainFDAssociate( domain: virDomainPtr, name: *const ::libc::c_char, nfds: ::libc::c_uint, fds: *mut ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } pub const VIR_DOMAIN_GRAPHICS_RELOAD_TYPE_ANY: virDomainGraphicsReloadType = 0; pub const VIR_DOMAIN_GRAPHICS_RELOAD_TYPE_VNC: virDomainGraphicsReloadType = 1; pub type virDomainGraphicsReloadType = ::libc::c_uint; extern "C" { pub fn virDomainGraphicsReload( domain: virDomainPtr, type_: ::libc::c_uint, flags: ::libc::c_uint, ) -> ::libc::c_int; } #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct _virDomainCheckpoint { _unused: [u8; 0], } pub type virDomainCheckpoint = _virDomainCheckpoint; pub type virDomainCheckpointPtr = *mut virDomainCheckpoint; extern "C" { pub fn virDomainCheckpointGetName(checkpoint: virDomainCheckpointPtr) -> *const ::libc::c_char; } extern "C" { pub fn virDomainCheckpointGetDomain(checkpoint: virDomainCheckpointPtr) -> virDomainPtr; } extern "C" { pub fn virDomainCheckpointGetConnect(checkpoint: virDomainCheckpointPtr) -> virConnectPtr; } pub const VIR_DOMAIN_CHECKPOINT_CREATE_REDEFINE: virDomainCheckpointCreateFlags = 1; pub const VIR_DOMAIN_CHECKPOINT_CREATE_QUIESCE: virDomainCheckpointCreateFlags = 2; pub const VIR_DOMAIN_CHECKPOINT_CREATE_REDEFINE_VALIDATE: virDomainCheckpointCreateFlags = 4; pub type virDomainCheckpointCreateFlags = ::libc::c_uint; extern "C" { pub fn virDomainCheckpointCreateXML( domain: virDomainPtr, xmlDesc: *const ::libc::c_char, flags: ::libc::c_uint, ) -> virDomainCheckpointPtr; } pub const VIR_DOMAIN_CHECKPOINT_XML_SECURE: virDomainCheckpointXMLFlags = 1; pub const VIR_DOMAIN_CHECKPOINT_XML_NO_DOMAIN: virDomainCheckpointXMLFlags = 2; pub const VIR_DOMAIN_CHECKPOINT_XML_SIZE: virDomainCheckpointXMLFlags = 4; pub type virDomainCheckpointXMLFlags = ::libc::c_uint; extern "C" { pub fn virDomainCheckpointGetXMLDesc( checkpoint: virDomainCheckpointPtr, flags: ::libc::c_uint, ) -> *mut ::libc::c_char; } pub const VIR_DOMAIN_CHECKPOINT_LIST_ROOTS: virDomainCheckpointListFlags = 1; pub const VIR_DOMAIN_CHECKPOINT_LIST_DESCENDANTS: virDomainCheckpointListFlags = 1; pub const VIR_DOMAIN_CHECKPOINT_LIST_TOPOLOGICAL: virDomainCheckpointListFlags = 2; pub const VIR_DOMAIN_CHECKPOINT_LIST_LEAVES: virDomainCheckpointListFlags = 4; pub const VIR_DOMAIN_CHECKPOINT_LIST_NO_LEAVES: virDomainCheckpointListFlags = 8; pub type virDomainCheckpointListFlags = ::libc::c_uint; extern "C" { pub fn virDomainListAllCheckpoints( domain: virDomainPtr, checkpoints: *mut *mut virDomainCheckpointPtr, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainCheckpointListAllChildren( checkpoint: virDomainCheckpointPtr, children: *mut *mut virDomainCheckpointPtr, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainCheckpointLookupByName( domain: virDomainPtr, name: *const ::libc::c_char, flags: ::libc::c_uint, ) -> virDomainCheckpointPtr; } extern "C" { pub fn virDomainCheckpointGetParent( checkpoint: virDomainCheckpointPtr, flags: ::libc::c_uint, ) -> virDomainCheckpointPtr; } pub const VIR_DOMAIN_CHECKPOINT_DELETE_CHILDREN: virDomainCheckpointDeleteFlags = 1; pub const VIR_DOMAIN_CHECKPOINT_DELETE_METADATA_ONLY: virDomainCheckpointDeleteFlags = 2; pub const VIR_DOMAIN_CHECKPOINT_DELETE_CHILDREN_ONLY: virDomainCheckpointDeleteFlags = 4; pub type virDomainCheckpointDeleteFlags = ::libc::c_uint; extern "C" { pub fn virDomainCheckpointDelete( checkpoint: virDomainCheckpointPtr, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainCheckpointRef(checkpoint: virDomainCheckpointPtr) -> ::libc::c_int; } extern "C" { pub fn virDomainCheckpointFree(checkpoint: virDomainCheckpointPtr) -> ::libc::c_int; } #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct _virDomainSnapshot { _unused: [u8; 0], } pub type virDomainSnapshot = _virDomainSnapshot; pub type virDomainSnapshotPtr = *mut virDomainSnapshot; extern "C" { pub fn virDomainSnapshotGetName(snapshot: virDomainSnapshotPtr) -> *const ::libc::c_char; } extern "C" { pub fn virDomainSnapshotGetDomain(snapshot: virDomainSnapshotPtr) -> virDomainPtr; } extern "C" { pub fn virDomainSnapshotGetConnect(snapshot: virDomainSnapshotPtr) -> virConnectPtr; } pub const VIR_DOMAIN_SNAPSHOT_CREATE_REDEFINE: virDomainSnapshotCreateFlags = 1; pub const VIR_DOMAIN_SNAPSHOT_CREATE_CURRENT: virDomainSnapshotCreateFlags = 2; pub const VIR_DOMAIN_SNAPSHOT_CREATE_NO_METADATA: virDomainSnapshotCreateFlags = 4; pub const VIR_DOMAIN_SNAPSHOT_CREATE_HALT: virDomainSnapshotCreateFlags = 8; pub const VIR_DOMAIN_SNAPSHOT_CREATE_DISK_ONLY: virDomainSnapshotCreateFlags = 16; pub const VIR_DOMAIN_SNAPSHOT_CREATE_REUSE_EXT: virDomainSnapshotCreateFlags = 32; pub const VIR_DOMAIN_SNAPSHOT_CREATE_QUIESCE: virDomainSnapshotCreateFlags = 64; pub const VIR_DOMAIN_SNAPSHOT_CREATE_ATOMIC: virDomainSnapshotCreateFlags = 128; pub const VIR_DOMAIN_SNAPSHOT_CREATE_LIVE: virDomainSnapshotCreateFlags = 256; pub const VIR_DOMAIN_SNAPSHOT_CREATE_VALIDATE: virDomainSnapshotCreateFlags = 512; pub type virDomainSnapshotCreateFlags = ::libc::c_uint; extern "C" { pub fn virDomainSnapshotCreateXML( domain: virDomainPtr, xmlDesc: *const ::libc::c_char, flags: ::libc::c_uint, ) -> virDomainSnapshotPtr; } pub const VIR_DOMAIN_SNAPSHOT_XML_SECURE: virDomainSnapshotXMLFlags = 1; pub type virDomainSnapshotXMLFlags = ::libc::c_uint; extern "C" { pub fn virDomainSnapshotGetXMLDesc( snapshot: virDomainSnapshotPtr, flags: ::libc::c_uint, ) -> *mut ::libc::c_char; } pub const VIR_DOMAIN_SNAPSHOT_LIST_ROOTS: virDomainSnapshotListFlags = 1; pub const VIR_DOMAIN_SNAPSHOT_LIST_DESCENDANTS: virDomainSnapshotListFlags = 1; pub const VIR_DOMAIN_SNAPSHOT_LIST_LEAVES: virDomainSnapshotListFlags = 4; pub const VIR_DOMAIN_SNAPSHOT_LIST_NO_LEAVES: virDomainSnapshotListFlags = 8; pub const VIR_DOMAIN_SNAPSHOT_LIST_METADATA: virDomainSnapshotListFlags = 2; pub const VIR_DOMAIN_SNAPSHOT_LIST_NO_METADATA: virDomainSnapshotListFlags = 16; pub const VIR_DOMAIN_SNAPSHOT_LIST_INACTIVE: virDomainSnapshotListFlags = 32; pub const VIR_DOMAIN_SNAPSHOT_LIST_ACTIVE: virDomainSnapshotListFlags = 64; pub const VIR_DOMAIN_SNAPSHOT_LIST_DISK_ONLY: virDomainSnapshotListFlags = 128; pub const VIR_DOMAIN_SNAPSHOT_LIST_INTERNAL: virDomainSnapshotListFlags = 256; pub const VIR_DOMAIN_SNAPSHOT_LIST_EXTERNAL: virDomainSnapshotListFlags = 512; pub const VIR_DOMAIN_SNAPSHOT_LIST_TOPOLOGICAL: virDomainSnapshotListFlags = 1024; pub type virDomainSnapshotListFlags = ::libc::c_uint; extern "C" { pub fn virDomainSnapshotNum(domain: virDomainPtr, flags: ::libc::c_uint) -> ::libc::c_int; } extern "C" { pub fn virDomainSnapshotListNames( domain: virDomainPtr, names: *mut *mut ::libc::c_char, nameslen: ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainListAllSnapshots( domain: virDomainPtr, snaps: *mut *mut virDomainSnapshotPtr, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainSnapshotNumChildren( snapshot: virDomainSnapshotPtr, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainSnapshotListChildrenNames( snapshot: virDomainSnapshotPtr, names: *mut *mut ::libc::c_char, nameslen: ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainSnapshotListAllChildren( snapshot: virDomainSnapshotPtr, snaps: *mut *mut virDomainSnapshotPtr, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainSnapshotLookupByName( domain: virDomainPtr, name: *const ::libc::c_char, flags: ::libc::c_uint, ) -> virDomainSnapshotPtr; } extern "C" { pub fn virDomainHasCurrentSnapshot( domain: virDomainPtr, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainSnapshotCurrent( domain: virDomainPtr, flags: ::libc::c_uint, ) -> virDomainSnapshotPtr; } extern "C" { pub fn virDomainSnapshotGetParent( snapshot: virDomainSnapshotPtr, flags: ::libc::c_uint, ) -> virDomainSnapshotPtr; } extern "C" { pub fn virDomainSnapshotIsCurrent( snapshot: virDomainSnapshotPtr, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainSnapshotHasMetadata( snapshot: virDomainSnapshotPtr, flags: ::libc::c_uint, ) -> ::libc::c_int; } pub const VIR_DOMAIN_SNAPSHOT_REVERT_RUNNING: virDomainSnapshotRevertFlags = 1; pub const VIR_DOMAIN_SNAPSHOT_REVERT_PAUSED: virDomainSnapshotRevertFlags = 2; pub const VIR_DOMAIN_SNAPSHOT_REVERT_FORCE: virDomainSnapshotRevertFlags = 4; pub const VIR_DOMAIN_SNAPSHOT_REVERT_RESET_NVRAM: virDomainSnapshotRevertFlags = 8; pub type virDomainSnapshotRevertFlags = ::libc::c_uint; extern "C" { pub fn virDomainRevertToSnapshot( snapshot: virDomainSnapshotPtr, flags: ::libc::c_uint, ) -> ::libc::c_int; } pub const VIR_DOMAIN_SNAPSHOT_DELETE_CHILDREN: virDomainSnapshotDeleteFlags = 1; pub const VIR_DOMAIN_SNAPSHOT_DELETE_METADATA_ONLY: virDomainSnapshotDeleteFlags = 2; pub const VIR_DOMAIN_SNAPSHOT_DELETE_CHILDREN_ONLY: virDomainSnapshotDeleteFlags = 4; pub type virDomainSnapshotDeleteFlags = ::libc::c_uint; extern "C" { pub fn virDomainSnapshotDelete( snapshot: virDomainSnapshotPtr, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainSnapshotRef(snapshot: virDomainSnapshotPtr) -> ::libc::c_int; } extern "C" { pub fn virDomainSnapshotFree(snapshot: virDomainSnapshotPtr) -> ::libc::c_int; } pub const VIR_EVENT_HANDLE_READABLE: virEventHandleType = 1; pub const VIR_EVENT_HANDLE_WRITABLE: virEventHandleType = 2; pub const VIR_EVENT_HANDLE_ERROR: virEventHandleType = 4; pub const VIR_EVENT_HANDLE_HANGUP: virEventHandleType = 8; pub type virEventHandleType = ::libc::c_uint; pub type virEventHandleCallback = ::std::option::Option< unsafe extern "C" fn( watch: ::libc::c_int, fd: ::libc::c_int, events: ::libc::c_int, opaque: *mut ::libc::c_void, ), >; pub type virEventAddHandleFunc = ::std::option::Option< unsafe extern "C" fn( fd: ::libc::c_int, event: ::libc::c_int, cb: virEventHandleCallback, opaque: *mut ::libc::c_void, ff: virFreeCallback, ) -> ::libc::c_int, >; pub type virEventUpdateHandleFunc = ::std::option::Option; pub type virEventRemoveHandleFunc = ::std::option::Option ::libc::c_int>; pub type virEventTimeoutCallback = ::std::option::Option; pub type virEventAddTimeoutFunc = ::std::option::Option< unsafe extern "C" fn( timeout: ::libc::c_int, cb: virEventTimeoutCallback, opaque: *mut ::libc::c_void, ff: virFreeCallback, ) -> ::libc::c_int, >; pub type virEventUpdateTimeoutFunc = ::std::option::Option; pub type virEventRemoveTimeoutFunc = ::std::option::Option ::libc::c_int>; extern "C" { pub fn virEventRegisterImpl( addHandle: virEventAddHandleFunc, updateHandle: virEventUpdateHandleFunc, removeHandle: virEventRemoveHandleFunc, addTimeout: virEventAddTimeoutFunc, updateTimeout: virEventUpdateTimeoutFunc, removeTimeout: virEventRemoveTimeoutFunc, ); } extern "C" { pub fn virEventRegisterDefaultImpl() -> ::libc::c_int; } extern "C" { pub fn virEventRunDefaultImpl() -> ::libc::c_int; } extern "C" { pub fn virEventAddHandle( fd: ::libc::c_int, events: ::libc::c_int, cb: virEventHandleCallback, opaque: *mut ::libc::c_void, ff: virFreeCallback, ) -> ::libc::c_int; } extern "C" { pub fn virEventUpdateHandle(watch: ::libc::c_int, events: ::libc::c_int); } extern "C" { pub fn virEventRemoveHandle(watch: ::libc::c_int) -> ::libc::c_int; } extern "C" { pub fn virEventAddTimeout( frequency: ::libc::c_int, cb: virEventTimeoutCallback, opaque: *mut ::libc::c_void, ff: virFreeCallback, ) -> ::libc::c_int; } extern "C" { pub fn virEventUpdateTimeout(timer: ::libc::c_int, frequency: ::libc::c_int); } extern "C" { pub fn virEventRemoveTimeout(timer: ::libc::c_int) -> ::libc::c_int; } #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct _virInterface { _unused: [u8; 0], } pub type virInterface = _virInterface; pub type virInterfacePtr = *mut virInterface; extern "C" { pub fn virInterfaceGetConnect(iface: virInterfacePtr) -> virConnectPtr; } extern "C" { pub fn virConnectNumOfInterfaces(conn: virConnectPtr) -> ::libc::c_int; } extern "C" { pub fn virConnectListInterfaces( conn: virConnectPtr, names: *mut *mut ::libc::c_char, maxnames: ::libc::c_int, ) -> ::libc::c_int; } extern "C" { pub fn virConnectNumOfDefinedInterfaces(conn: virConnectPtr) -> ::libc::c_int; } extern "C" { pub fn virConnectListDefinedInterfaces( conn: virConnectPtr, names: *mut *mut ::libc::c_char, maxnames: ::libc::c_int, ) -> ::libc::c_int; } pub const VIR_CONNECT_LIST_INTERFACES_INACTIVE: virConnectListAllInterfacesFlags = 1; pub const VIR_CONNECT_LIST_INTERFACES_ACTIVE: virConnectListAllInterfacesFlags = 2; pub type virConnectListAllInterfacesFlags = ::libc::c_uint; extern "C" { pub fn virConnectListAllInterfaces( conn: virConnectPtr, ifaces: *mut *mut virInterfacePtr, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virInterfaceLookupByName( conn: virConnectPtr, name: *const ::libc::c_char, ) -> virInterfacePtr; } extern "C" { pub fn virInterfaceLookupByMACString( conn: virConnectPtr, mac: *const ::libc::c_char, ) -> virInterfacePtr; } extern "C" { pub fn virInterfaceGetName(iface: virInterfacePtr) -> *const ::libc::c_char; } extern "C" { pub fn virInterfaceGetMACString(iface: virInterfacePtr) -> *const ::libc::c_char; } pub const VIR_INTERFACE_XML_INACTIVE: virInterfaceXMLFlags = 1; pub type virInterfaceXMLFlags = ::libc::c_uint; pub const VIR_INTERFACE_DEFINE_VALIDATE: virInterfaceDefineFlags = 1; pub type virInterfaceDefineFlags = ::libc::c_uint; extern "C" { pub fn virInterfaceGetXMLDesc( iface: virInterfacePtr, flags: ::libc::c_uint, ) -> *mut ::libc::c_char; } extern "C" { pub fn virInterfaceDefineXML( conn: virConnectPtr, xmlDesc: *const ::libc::c_char, flags: ::libc::c_uint, ) -> virInterfacePtr; } extern "C" { pub fn virInterfaceUndefine(iface: virInterfacePtr) -> ::libc::c_int; } extern "C" { pub fn virInterfaceCreate(iface: virInterfacePtr, flags: ::libc::c_uint) -> ::libc::c_int; } extern "C" { pub fn virInterfaceDestroy(iface: virInterfacePtr, flags: ::libc::c_uint) -> ::libc::c_int; } extern "C" { pub fn virInterfaceRef(iface: virInterfacePtr) -> ::libc::c_int; } extern "C" { pub fn virInterfaceFree(iface: virInterfacePtr) -> ::libc::c_int; } extern "C" { pub fn virInterfaceChangeBegin(conn: virConnectPtr, flags: ::libc::c_uint) -> ::libc::c_int; } extern "C" { pub fn virInterfaceChangeCommit(conn: virConnectPtr, flags: ::libc::c_uint) -> ::libc::c_int; } extern "C" { pub fn virInterfaceChangeRollback(conn: virConnectPtr, flags: ::libc::c_uint) -> ::libc::c_int; } extern "C" { pub fn virInterfaceIsActive(iface: virInterfacePtr) -> ::libc::c_int; } pub const VIR_NETWORK_XML_INACTIVE: virNetworkXMLFlags = 1; pub type virNetworkXMLFlags = ::libc::c_uint; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct _virNetwork { _unused: [u8; 0], } pub type virNetwork = _virNetwork; pub type virNetworkPtr = *mut virNetwork; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct _virNetworkPort { _unused: [u8; 0], } pub type virNetworkPort = _virNetworkPort; pub type virNetworkPortPtr = *mut virNetworkPort; extern "C" { pub fn virNetworkGetConnect(network: virNetworkPtr) -> virConnectPtr; } extern "C" { pub fn virConnectNumOfNetworks(conn: virConnectPtr) -> ::libc::c_int; } extern "C" { pub fn virConnectListNetworks( conn: virConnectPtr, names: *mut *mut ::libc::c_char, maxnames: ::libc::c_int, ) -> ::libc::c_int; } extern "C" { pub fn virConnectNumOfDefinedNetworks(conn: virConnectPtr) -> ::libc::c_int; } extern "C" { pub fn virConnectListDefinedNetworks( conn: virConnectPtr, names: *mut *mut ::libc::c_char, maxnames: ::libc::c_int, ) -> ::libc::c_int; } pub const VIR_CONNECT_LIST_NETWORKS_INACTIVE: virConnectListAllNetworksFlags = 1; pub const VIR_CONNECT_LIST_NETWORKS_ACTIVE: virConnectListAllNetworksFlags = 2; pub const VIR_CONNECT_LIST_NETWORKS_PERSISTENT: virConnectListAllNetworksFlags = 4; pub const VIR_CONNECT_LIST_NETWORKS_TRANSIENT: virConnectListAllNetworksFlags = 8; pub const VIR_CONNECT_LIST_NETWORKS_AUTOSTART: virConnectListAllNetworksFlags = 16; pub const VIR_CONNECT_LIST_NETWORKS_NO_AUTOSTART: virConnectListAllNetworksFlags = 32; pub type virConnectListAllNetworksFlags = ::libc::c_uint; extern "C" { pub fn virConnectListAllNetworks( conn: virConnectPtr, nets: *mut *mut virNetworkPtr, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virNetworkLookupByName( conn: virConnectPtr, name: *const ::libc::c_char, ) -> virNetworkPtr; } extern "C" { pub fn virNetworkLookupByUUID( conn: virConnectPtr, uuid: *const ::libc::c_uchar, ) -> virNetworkPtr; } extern "C" { pub fn virNetworkLookupByUUIDString( conn: virConnectPtr, uuid: *const ::libc::c_char, ) -> virNetworkPtr; } pub const VIR_NETWORK_CREATE_VALIDATE: virNetworkCreateFlags = 1; pub type virNetworkCreateFlags = ::libc::c_uint; extern "C" { pub fn virNetworkCreateXML( conn: virConnectPtr, xmlDesc: *const ::libc::c_char, ) -> virNetworkPtr; } extern "C" { pub fn virNetworkCreateXMLFlags( conn: virConnectPtr, xmlDesc: *const ::libc::c_char, flags: ::libc::c_uint, ) -> virNetworkPtr; } pub const VIR_NETWORK_DEFINE_VALIDATE: virNetworkDefineFlags = 1; pub type virNetworkDefineFlags = ::libc::c_uint; extern "C" { pub fn virNetworkDefineXML( conn: virConnectPtr, xmlDesc: *const ::libc::c_char, ) -> virNetworkPtr; } extern "C" { pub fn virNetworkDefineXMLFlags( conn: virConnectPtr, xmlDesc: *const ::libc::c_char, flags: ::libc::c_uint, ) -> virNetworkPtr; } extern "C" { pub fn virNetworkUndefine(network: virNetworkPtr) -> ::libc::c_int; } pub const VIR_NETWORK_UPDATE_COMMAND_NONE: virNetworkUpdateCommand = 0; pub const VIR_NETWORK_UPDATE_COMMAND_MODIFY: virNetworkUpdateCommand = 1; pub const VIR_NETWORK_UPDATE_COMMAND_DELETE: virNetworkUpdateCommand = 2; pub const VIR_NETWORK_UPDATE_COMMAND_ADD_LAST: virNetworkUpdateCommand = 3; pub const VIR_NETWORK_UPDATE_COMMAND_ADD_FIRST: virNetworkUpdateCommand = 4; pub type virNetworkUpdateCommand = ::libc::c_uint; pub const VIR_NETWORK_SECTION_NONE: virNetworkUpdateSection = 0; pub const VIR_NETWORK_SECTION_BRIDGE: virNetworkUpdateSection = 1; pub const VIR_NETWORK_SECTION_DOMAIN: virNetworkUpdateSection = 2; pub const VIR_NETWORK_SECTION_IP: virNetworkUpdateSection = 3; pub const VIR_NETWORK_SECTION_IP_DHCP_HOST: virNetworkUpdateSection = 4; pub const VIR_NETWORK_SECTION_IP_DHCP_RANGE: virNetworkUpdateSection = 5; pub const VIR_NETWORK_SECTION_FORWARD: virNetworkUpdateSection = 6; pub const VIR_NETWORK_SECTION_FORWARD_INTERFACE: virNetworkUpdateSection = 7; pub const VIR_NETWORK_SECTION_FORWARD_PF: virNetworkUpdateSection = 8; pub const VIR_NETWORK_SECTION_PORTGROUP: virNetworkUpdateSection = 9; pub const VIR_NETWORK_SECTION_DNS_HOST: virNetworkUpdateSection = 10; pub const VIR_NETWORK_SECTION_DNS_TXT: virNetworkUpdateSection = 11; pub const VIR_NETWORK_SECTION_DNS_SRV: virNetworkUpdateSection = 12; pub type virNetworkUpdateSection = ::libc::c_uint; pub const VIR_NETWORK_UPDATE_AFFECT_CURRENT: virNetworkUpdateFlags = 0; pub const VIR_NETWORK_UPDATE_AFFECT_LIVE: virNetworkUpdateFlags = 1; pub const VIR_NETWORK_UPDATE_AFFECT_CONFIG: virNetworkUpdateFlags = 2; pub type virNetworkUpdateFlags = ::libc::c_uint; extern "C" { pub fn virNetworkUpdate( network: virNetworkPtr, command: ::libc::c_uint, section: ::libc::c_uint, parentIndex: ::libc::c_int, xml: *const ::libc::c_char, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virNetworkCreate(network: virNetworkPtr) -> ::libc::c_int; } extern "C" { pub fn virNetworkDestroy(network: virNetworkPtr) -> ::libc::c_int; } extern "C" { pub fn virNetworkRef(network: virNetworkPtr) -> ::libc::c_int; } extern "C" { pub fn virNetworkFree(network: virNetworkPtr) -> ::libc::c_int; } extern "C" { pub fn virNetworkGetName(network: virNetworkPtr) -> *const ::libc::c_char; } extern "C" { pub fn virNetworkGetUUID(network: virNetworkPtr, uuid: *mut ::libc::c_uchar) -> ::libc::c_int; } extern "C" { pub fn virNetworkGetUUIDString( network: virNetworkPtr, buf: *mut ::libc::c_char, ) -> ::libc::c_int; } extern "C" { pub fn virNetworkGetXMLDesc( network: virNetworkPtr, flags: ::libc::c_uint, ) -> *mut ::libc::c_char; } extern "C" { pub fn virNetworkGetBridgeName(network: virNetworkPtr) -> *mut ::libc::c_char; } extern "C" { pub fn virNetworkGetAutostart( network: virNetworkPtr, autostart: *mut ::libc::c_int, ) -> ::libc::c_int; } extern "C" { pub fn virNetworkSetAutostart( network: virNetworkPtr, autostart: ::libc::c_int, ) -> ::libc::c_int; } extern "C" { pub fn virNetworkIsActive(net: virNetworkPtr) -> ::libc::c_int; } extern "C" { pub fn virNetworkIsPersistent(net: virNetworkPtr) -> ::libc::c_int; } pub const VIR_NETWORK_EVENT_DEFINED: virNetworkEventLifecycleType = 0; pub const VIR_NETWORK_EVENT_UNDEFINED: virNetworkEventLifecycleType = 1; pub const VIR_NETWORK_EVENT_STARTED: virNetworkEventLifecycleType = 2; pub const VIR_NETWORK_EVENT_STOPPED: virNetworkEventLifecycleType = 3; pub type virNetworkEventLifecycleType = ::libc::c_uint; pub type virConnectNetworkEventLifecycleCallback = ::std::option::Option< unsafe extern "C" fn( conn: virConnectPtr, net: virNetworkPtr, event: ::libc::c_int, detail: ::libc::c_int, opaque: *mut ::libc::c_void, ), >; pub const VIR_NETWORK_EVENT_ID_LIFECYCLE: virNetworkEventID = 0; pub const VIR_NETWORK_EVENT_ID_METADATA_CHANGE: virNetworkEventID = 1; pub type virNetworkEventID = ::libc::c_uint; pub const VIR_IP_ADDR_TYPE_IPV4: virIPAddrType = 0; pub const VIR_IP_ADDR_TYPE_IPV6: virIPAddrType = 1; pub type virIPAddrType = ::libc::c_uint; pub type virNetworkDHCPLease = _virNetworkDHCPLease; pub type virNetworkDHCPLeasePtr = *mut virNetworkDHCPLease; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct _virNetworkDHCPLease { pub iface: *mut ::libc::c_char, pub expirytime: ::libc::c_longlong, pub type_: ::libc::c_int, pub mac: *mut ::libc::c_char, pub iaid: *mut ::libc::c_char, pub ipaddr: *mut ::libc::c_char, pub prefix: ::libc::c_uint, pub hostname: *mut ::libc::c_char, pub clientid: *mut ::libc::c_char, } #[test] fn bindgen_test_layout__virNetworkDHCPLease() { const UNINIT: ::std::mem::MaybeUninit<_virNetworkDHCPLease> = ::std::mem::MaybeUninit::uninit(); let ptr = UNINIT.as_ptr(); assert_eq!( ::std::mem::size_of::<_virNetworkDHCPLease>(), 72usize, concat!("Size of: ", stringify!(_virNetworkDHCPLease)) ); assert_eq!( ::std::mem::align_of::<_virNetworkDHCPLease>(), 8usize, concat!("Alignment of ", stringify!(_virNetworkDHCPLease)) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).iface) as usize - ptr as usize }, 0usize, concat!( "Offset of field: ", stringify!(_virNetworkDHCPLease), "::", stringify!(iface) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).expirytime) as usize - ptr as usize }, 8usize, concat!( "Offset of field: ", stringify!(_virNetworkDHCPLease), "::", stringify!(expirytime) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).type_) as usize - ptr as usize }, 16usize, concat!( "Offset of field: ", stringify!(_virNetworkDHCPLease), "::", stringify!(type_) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).mac) as usize - ptr as usize }, 24usize, concat!( "Offset of field: ", stringify!(_virNetworkDHCPLease), "::", stringify!(mac) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).iaid) as usize - ptr as usize }, 32usize, concat!( "Offset of field: ", stringify!(_virNetworkDHCPLease), "::", stringify!(iaid) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).ipaddr) as usize - ptr as usize }, 40usize, concat!( "Offset of field: ", stringify!(_virNetworkDHCPLease), "::", stringify!(ipaddr) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).prefix) as usize - ptr as usize }, 48usize, concat!( "Offset of field: ", stringify!(_virNetworkDHCPLease), "::", stringify!(prefix) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).hostname) as usize - ptr as usize }, 56usize, concat!( "Offset of field: ", stringify!(_virNetworkDHCPLease), "::", stringify!(hostname) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).clientid) as usize - ptr as usize }, 64usize, concat!( "Offset of field: ", stringify!(_virNetworkDHCPLease), "::", stringify!(clientid) ) ); } extern "C" { pub fn virNetworkDHCPLeaseFree(lease: virNetworkDHCPLeasePtr); } extern "C" { pub fn virNetworkGetDHCPLeases( network: virNetworkPtr, mac: *const ::libc::c_char, leases: *mut *mut virNetworkDHCPLeasePtr, flags: ::libc::c_uint, ) -> ::libc::c_int; } pub type virConnectNetworkEventGenericCallback = ::std::option::Option< unsafe extern "C" fn(conn: virConnectPtr, net: virNetworkPtr, opaque: *mut ::libc::c_void), >; extern "C" { pub fn virConnectNetworkEventRegisterAny( conn: virConnectPtr, net: virNetworkPtr, eventID: ::libc::c_int, cb: virConnectNetworkEventGenericCallback, opaque: *mut ::libc::c_void, freecb: virFreeCallback, ) -> ::libc::c_int; } extern "C" { pub fn virConnectNetworkEventDeregisterAny( conn: virConnectPtr, callbackID: ::libc::c_int, ) -> ::libc::c_int; } extern "C" { pub fn virNetworkPortLookupByUUID( net: virNetworkPtr, uuid: *const ::libc::c_uchar, ) -> virNetworkPortPtr; } extern "C" { pub fn virNetworkPortLookupByUUIDString( net: virNetworkPtr, uuidstr: *const ::libc::c_char, ) -> virNetworkPortPtr; } pub const VIR_NETWORK_PORT_CREATE_RECLAIM: virNetworkPortCreateFlags = 1; pub const VIR_NETWORK_PORT_CREATE_VALIDATE: virNetworkPortCreateFlags = 2; pub type virNetworkPortCreateFlags = ::libc::c_uint; extern "C" { pub fn virNetworkPortCreateXML( net: virNetworkPtr, xmldesc: *const ::libc::c_char, flags: ::libc::c_uint, ) -> virNetworkPortPtr; } extern "C" { pub fn virNetworkPortGetNetwork(port: virNetworkPortPtr) -> virNetworkPtr; } extern "C" { pub fn virNetworkPortGetXMLDesc( port: virNetworkPortPtr, flags: ::libc::c_uint, ) -> *mut ::libc::c_char; } extern "C" { pub fn virNetworkPortGetUUID( port: virNetworkPortPtr, uuid: *mut ::libc::c_uchar, ) -> ::libc::c_int; } extern "C" { pub fn virNetworkPortGetUUIDString( port: virNetworkPortPtr, buf: *mut ::libc::c_char, ) -> ::libc::c_int; } extern "C" { pub fn virNetworkPortSetParameters( port: virNetworkPortPtr, params: virTypedParameterPtr, nparams: ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virNetworkPortGetParameters( port: virNetworkPortPtr, params: *mut virTypedParameterPtr, nparams: *mut ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virNetworkPortDelete(port: virNetworkPortPtr, flags: ::libc::c_uint) -> ::libc::c_int; } extern "C" { pub fn virNetworkListAllPorts( network: virNetworkPtr, ports: *mut *mut virNetworkPortPtr, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virNetworkPortFree(port: virNetworkPortPtr) -> ::libc::c_int; } extern "C" { pub fn virNetworkPortRef(port: virNetworkPortPtr) -> ::libc::c_int; } pub const VIR_NETWORK_METADATA_DESCRIPTION: virNetworkMetadataType = 0; pub const VIR_NETWORK_METADATA_TITLE: virNetworkMetadataType = 1; pub const VIR_NETWORK_METADATA_ELEMENT: virNetworkMetadataType = 2; pub type virNetworkMetadataType = ::libc::c_uint; extern "C" { pub fn virNetworkSetMetadata( network: virNetworkPtr, type_: ::libc::c_int, metadata: *const ::libc::c_char, key: *const ::libc::c_char, uri: *const ::libc::c_char, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virNetworkGetMetadata( network: virNetworkPtr, type_: ::libc::c_int, uri: *const ::libc::c_char, flags: ::libc::c_uint, ) -> *mut ::libc::c_char; } pub type virConnectNetworkEventMetadataChangeCallback = ::std::option::Option< unsafe extern "C" fn( conn: virConnectPtr, net: virNetworkPtr, type_: ::libc::c_int, nsuri: *const ::libc::c_char, opaque: *mut ::libc::c_void, ), >; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct _virNodeDevice { _unused: [u8; 0], } pub type virNodeDevice = _virNodeDevice; pub type virNodeDevicePtr = *mut virNodeDevice; extern "C" { pub fn virNodeNumOfDevices( conn: virConnectPtr, cap: *const ::libc::c_char, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virNodeListDevices( conn: virConnectPtr, cap: *const ::libc::c_char, names: *mut *mut ::libc::c_char, maxnames: ::libc::c_int, flags: ::libc::c_uint, ) -> ::libc::c_int; } pub const VIR_CONNECT_LIST_NODE_DEVICES_CAP_SYSTEM: virConnectListAllNodeDeviceFlags = 1; pub const VIR_CONNECT_LIST_NODE_DEVICES_CAP_PCI_DEV: virConnectListAllNodeDeviceFlags = 2; pub const VIR_CONNECT_LIST_NODE_DEVICES_CAP_USB_DEV: virConnectListAllNodeDeviceFlags = 4; pub const VIR_CONNECT_LIST_NODE_DEVICES_CAP_USB_INTERFACE: virConnectListAllNodeDeviceFlags = 8; pub const VIR_CONNECT_LIST_NODE_DEVICES_CAP_NET: virConnectListAllNodeDeviceFlags = 16; pub const VIR_CONNECT_LIST_NODE_DEVICES_CAP_SCSI_HOST: virConnectListAllNodeDeviceFlags = 32; pub const VIR_CONNECT_LIST_NODE_DEVICES_CAP_SCSI_TARGET: virConnectListAllNodeDeviceFlags = 64; pub const VIR_CONNECT_LIST_NODE_DEVICES_CAP_SCSI: virConnectListAllNodeDeviceFlags = 128; pub const VIR_CONNECT_LIST_NODE_DEVICES_CAP_STORAGE: virConnectListAllNodeDeviceFlags = 256; pub const VIR_CONNECT_LIST_NODE_DEVICES_CAP_FC_HOST: virConnectListAllNodeDeviceFlags = 512; pub const VIR_CONNECT_LIST_NODE_DEVICES_CAP_VPORTS: virConnectListAllNodeDeviceFlags = 1024; pub const VIR_CONNECT_LIST_NODE_DEVICES_CAP_SCSI_GENERIC: virConnectListAllNodeDeviceFlags = 2048; pub const VIR_CONNECT_LIST_NODE_DEVICES_CAP_DRM: virConnectListAllNodeDeviceFlags = 4096; pub const VIR_CONNECT_LIST_NODE_DEVICES_CAP_MDEV_TYPES: virConnectListAllNodeDeviceFlags = 8192; pub const VIR_CONNECT_LIST_NODE_DEVICES_CAP_MDEV: virConnectListAllNodeDeviceFlags = 16384; pub const VIR_CONNECT_LIST_NODE_DEVICES_CAP_CCW_DEV: virConnectListAllNodeDeviceFlags = 32768; pub const VIR_CONNECT_LIST_NODE_DEVICES_CAP_CSS_DEV: virConnectListAllNodeDeviceFlags = 65536; pub const VIR_CONNECT_LIST_NODE_DEVICES_CAP_VDPA: virConnectListAllNodeDeviceFlags = 131072; pub const VIR_CONNECT_LIST_NODE_DEVICES_CAP_AP_CARD: virConnectListAllNodeDeviceFlags = 262144; pub const VIR_CONNECT_LIST_NODE_DEVICES_CAP_AP_QUEUE: virConnectListAllNodeDeviceFlags = 524288; pub const VIR_CONNECT_LIST_NODE_DEVICES_CAP_AP_MATRIX: virConnectListAllNodeDeviceFlags = 1048576; pub const VIR_CONNECT_LIST_NODE_DEVICES_CAP_VPD: virConnectListAllNodeDeviceFlags = 2097152; pub const VIR_CONNECT_LIST_NODE_DEVICES_PERSISTENT: virConnectListAllNodeDeviceFlags = 268435456; pub const VIR_CONNECT_LIST_NODE_DEVICES_TRANSIENT: virConnectListAllNodeDeviceFlags = 536870912; pub const VIR_CONNECT_LIST_NODE_DEVICES_INACTIVE: virConnectListAllNodeDeviceFlags = 1073741824; pub const VIR_CONNECT_LIST_NODE_DEVICES_ACTIVE: virConnectListAllNodeDeviceFlags = 2147483648; pub type virConnectListAllNodeDeviceFlags = ::libc::c_uint; extern "C" { pub fn virConnectListAllNodeDevices( conn: virConnectPtr, devices: *mut *mut virNodeDevicePtr, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virNodeDeviceLookupByName( conn: virConnectPtr, name: *const ::libc::c_char, ) -> virNodeDevicePtr; } extern "C" { pub fn virNodeDeviceLookupSCSIHostByWWN( conn: virConnectPtr, wwnn: *const ::libc::c_char, wwpn: *const ::libc::c_char, flags: ::libc::c_uint, ) -> virNodeDevicePtr; } extern "C" { pub fn virNodeDeviceGetName(dev: virNodeDevicePtr) -> *const ::libc::c_char; } extern "C" { pub fn virNodeDeviceGetParent(dev: virNodeDevicePtr) -> *const ::libc::c_char; } extern "C" { pub fn virNodeDeviceNumOfCaps(dev: virNodeDevicePtr) -> ::libc::c_int; } extern "C" { pub fn virNodeDeviceListCaps( dev: virNodeDevicePtr, names: *mut *mut ::libc::c_char, maxnames: ::libc::c_int, ) -> ::libc::c_int; } pub const VIR_NODE_DEVICE_XML_INACTIVE: virNodeDeviceXMLFlags = 1; pub type virNodeDeviceXMLFlags = ::libc::c_uint; extern "C" { pub fn virNodeDeviceGetXMLDesc( dev: virNodeDevicePtr, flags: ::libc::c_uint, ) -> *mut ::libc::c_char; } extern "C" { pub fn virNodeDeviceRef(dev: virNodeDevicePtr) -> ::libc::c_int; } extern "C" { pub fn virNodeDeviceFree(dev: virNodeDevicePtr) -> ::libc::c_int; } extern "C" { pub fn virNodeDeviceDettach(dev: virNodeDevicePtr) -> ::libc::c_int; } extern "C" { pub fn virNodeDeviceDetachFlags( dev: virNodeDevicePtr, driverName: *const ::libc::c_char, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virNodeDeviceReAttach(dev: virNodeDevicePtr) -> ::libc::c_int; } extern "C" { pub fn virNodeDeviceReset(dev: virNodeDevicePtr) -> ::libc::c_int; } pub const VIR_NODE_DEVICE_CREATE_XML_VALIDATE: virNodeDeviceCreateXMLFlags = 1; pub type virNodeDeviceCreateXMLFlags = ::libc::c_uint; extern "C" { pub fn virNodeDeviceCreateXML( conn: virConnectPtr, xmlDesc: *const ::libc::c_char, flags: ::libc::c_uint, ) -> virNodeDevicePtr; } extern "C" { pub fn virNodeDeviceDestroy(dev: virNodeDevicePtr) -> ::libc::c_int; } pub const VIR_NODE_DEVICE_DEFINE_XML_VALIDATE: virNodeDeviceDefineXMLFlags = 1; pub type virNodeDeviceDefineXMLFlags = ::libc::c_uint; extern "C" { pub fn virNodeDeviceDefineXML( conn: virConnectPtr, xmlDesc: *const ::libc::c_char, flags: ::libc::c_uint, ) -> virNodeDevicePtr; } extern "C" { pub fn virNodeDeviceUndefine(dev: virNodeDevicePtr, flags: ::libc::c_uint) -> ::libc::c_int; } extern "C" { pub fn virNodeDeviceCreate(dev: virNodeDevicePtr, flags: ::libc::c_uint) -> ::libc::c_int; } extern "C" { pub fn virNodeDeviceSetAutostart( dev: virNodeDevicePtr, autostart: ::libc::c_int, ) -> ::libc::c_int; } extern "C" { pub fn virNodeDeviceGetAutostart( dev: virNodeDevicePtr, autostart: *mut ::libc::c_int, ) -> ::libc::c_int; } extern "C" { pub fn virNodeDeviceIsPersistent(dev: virNodeDevicePtr) -> ::libc::c_int; } extern "C" { pub fn virNodeDeviceIsActive(dev: virNodeDevicePtr) -> ::libc::c_int; } pub const VIR_NODE_DEVICE_UPDATE_AFFECT_CURRENT: virNodeDeviceUpdateFlags = 0; pub const VIR_NODE_DEVICE_UPDATE_AFFECT_LIVE: virNodeDeviceUpdateFlags = 1; pub const VIR_NODE_DEVICE_UPDATE_AFFECT_CONFIG: virNodeDeviceUpdateFlags = 2; pub type virNodeDeviceUpdateFlags = ::libc::c_uint; extern "C" { pub fn virNodeDeviceUpdate( dev: virNodeDevicePtr, xmlDesc: *const ::libc::c_char, flags: ::libc::c_uint, ) -> ::libc::c_int; } pub const VIR_NODE_DEVICE_EVENT_ID_LIFECYCLE: virNodeDeviceEventID = 0; pub const VIR_NODE_DEVICE_EVENT_ID_UPDATE: virNodeDeviceEventID = 1; pub type virNodeDeviceEventID = ::libc::c_uint; pub type virConnectNodeDeviceEventGenericCallback = ::std::option::Option< unsafe extern "C" fn(conn: virConnectPtr, dev: virNodeDevicePtr, opaque: *mut ::libc::c_void), >; extern "C" { pub fn virConnectNodeDeviceEventRegisterAny( conn: virConnectPtr, dev: virNodeDevicePtr, eventID: ::libc::c_int, cb: virConnectNodeDeviceEventGenericCallback, opaque: *mut ::libc::c_void, freecb: virFreeCallback, ) -> ::libc::c_int; } extern "C" { pub fn virConnectNodeDeviceEventDeregisterAny( conn: virConnectPtr, callbackID: ::libc::c_int, ) -> ::libc::c_int; } pub const VIR_NODE_DEVICE_EVENT_CREATED: virNodeDeviceEventLifecycleType = 0; pub const VIR_NODE_DEVICE_EVENT_DELETED: virNodeDeviceEventLifecycleType = 1; pub const VIR_NODE_DEVICE_EVENT_DEFINED: virNodeDeviceEventLifecycleType = 2; pub const VIR_NODE_DEVICE_EVENT_UNDEFINED: virNodeDeviceEventLifecycleType = 3; pub type virNodeDeviceEventLifecycleType = ::libc::c_uint; pub type virConnectNodeDeviceEventLifecycleCallback = ::std::option::Option< unsafe extern "C" fn( conn: virConnectPtr, dev: virNodeDevicePtr, event: ::libc::c_int, detail: ::libc::c_int, opaque: *mut ::libc::c_void, ), >; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct _virNWFilter { _unused: [u8; 0], } pub type virNWFilter = _virNWFilter; pub type virNWFilterPtr = *mut virNWFilter; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct _virNWFilterBinding { _unused: [u8; 0], } pub type virNWFilterBinding = _virNWFilterBinding; pub type virNWFilterBindingPtr = *mut virNWFilterBinding; extern "C" { pub fn virConnectNumOfNWFilters(conn: virConnectPtr) -> ::libc::c_int; } extern "C" { pub fn virConnectListNWFilters( conn: virConnectPtr, names: *mut *mut ::libc::c_char, maxnames: ::libc::c_int, ) -> ::libc::c_int; } extern "C" { pub fn virConnectListAllNWFilters( conn: virConnectPtr, filters: *mut *mut virNWFilterPtr, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virNWFilterLookupByName( conn: virConnectPtr, name: *const ::libc::c_char, ) -> virNWFilterPtr; } extern "C" { pub fn virNWFilterLookupByUUID( conn: virConnectPtr, uuid: *const ::libc::c_uchar, ) -> virNWFilterPtr; } extern "C" { pub fn virNWFilterLookupByUUIDString( conn: virConnectPtr, uuid: *const ::libc::c_char, ) -> virNWFilterPtr; } pub const VIR_NWFILTER_DEFINE_VALIDATE: virNWFilterDefineFlags = 1; pub type virNWFilterDefineFlags = ::libc::c_uint; extern "C" { pub fn virNWFilterDefineXML( conn: virConnectPtr, xmlDesc: *const ::libc::c_char, ) -> virNWFilterPtr; } extern "C" { pub fn virNWFilterDefineXMLFlags( conn: virConnectPtr, xmlDesc: *const ::libc::c_char, flags: ::libc::c_uint, ) -> virNWFilterPtr; } extern "C" { pub fn virNWFilterUndefine(nwfilter: virNWFilterPtr) -> ::libc::c_int; } extern "C" { pub fn virNWFilterRef(nwfilter: virNWFilterPtr) -> ::libc::c_int; } extern "C" { pub fn virNWFilterFree(nwfilter: virNWFilterPtr) -> ::libc::c_int; } pub const VIR_NWFILTER_BINDING_CREATE_VALIDATE: virNWFilterBindingCreateFlags = 1; pub type virNWFilterBindingCreateFlags = ::libc::c_uint; extern "C" { pub fn virNWFilterGetName(nwfilter: virNWFilterPtr) -> *const ::libc::c_char; } extern "C" { pub fn virNWFilterGetUUID( nwfilter: virNWFilterPtr, uuid: *mut ::libc::c_uchar, ) -> ::libc::c_int; } extern "C" { pub fn virNWFilterGetUUIDString( nwfilter: virNWFilterPtr, buf: *mut ::libc::c_char, ) -> ::libc::c_int; } extern "C" { pub fn virNWFilterGetXMLDesc( nwfilter: virNWFilterPtr, flags: ::libc::c_uint, ) -> *mut ::libc::c_char; } extern "C" { pub fn virNWFilterBindingLookupByPortDev( conn: virConnectPtr, portdev: *const ::libc::c_char, ) -> virNWFilterBindingPtr; } extern "C" { pub fn virNWFilterBindingGetPortDev(binding: virNWFilterBindingPtr) -> *const ::libc::c_char; } extern "C" { pub fn virNWFilterBindingGetFilterName(binding: virNWFilterBindingPtr) -> *const ::libc::c_char; } extern "C" { pub fn virConnectListAllNWFilterBindings( conn: virConnectPtr, bindings: *mut *mut virNWFilterBindingPtr, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virNWFilterBindingCreateXML( conn: virConnectPtr, xml: *const ::libc::c_char, flags: ::libc::c_uint, ) -> virNWFilterBindingPtr; } extern "C" { pub fn virNWFilterBindingGetXMLDesc( binding: virNWFilterBindingPtr, flags: ::libc::c_uint, ) -> *mut ::libc::c_char; } extern "C" { pub fn virNWFilterBindingDelete(binding: virNWFilterBindingPtr) -> ::libc::c_int; } extern "C" { pub fn virNWFilterBindingRef(binding: virNWFilterBindingPtr) -> ::libc::c_int; } extern "C" { pub fn virNWFilterBindingFree(binding: virNWFilterBindingPtr) -> ::libc::c_int; } #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct _virSecret { _unused: [u8; 0], } pub type virSecret = _virSecret; pub type virSecretPtr = *mut virSecret; pub const VIR_SECRET_USAGE_TYPE_NONE: virSecretUsageType = 0; pub const VIR_SECRET_USAGE_TYPE_VOLUME: virSecretUsageType = 1; pub const VIR_SECRET_USAGE_TYPE_CEPH: virSecretUsageType = 2; pub const VIR_SECRET_USAGE_TYPE_ISCSI: virSecretUsageType = 3; pub const VIR_SECRET_USAGE_TYPE_TLS: virSecretUsageType = 4; pub const VIR_SECRET_USAGE_TYPE_VTPM: virSecretUsageType = 5; pub type virSecretUsageType = ::libc::c_uint; extern "C" { pub fn virSecretGetConnect(secret: virSecretPtr) -> virConnectPtr; } extern "C" { pub fn virConnectNumOfSecrets(conn: virConnectPtr) -> ::libc::c_int; } extern "C" { pub fn virConnectListSecrets( conn: virConnectPtr, uuids: *mut *mut ::libc::c_char, maxuuids: ::libc::c_int, ) -> ::libc::c_int; } pub const VIR_CONNECT_LIST_SECRETS_EPHEMERAL: virConnectListAllSecretsFlags = 1; pub const VIR_CONNECT_LIST_SECRETS_NO_EPHEMERAL: virConnectListAllSecretsFlags = 2; pub const VIR_CONNECT_LIST_SECRETS_PRIVATE: virConnectListAllSecretsFlags = 4; pub const VIR_CONNECT_LIST_SECRETS_NO_PRIVATE: virConnectListAllSecretsFlags = 8; pub type virConnectListAllSecretsFlags = ::libc::c_uint; extern "C" { pub fn virConnectListAllSecrets( conn: virConnectPtr, secrets: *mut *mut virSecretPtr, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virSecretLookupByUUID(conn: virConnectPtr, uuid: *const ::libc::c_uchar) -> virSecretPtr; } extern "C" { pub fn virSecretLookupByUUIDString( conn: virConnectPtr, uuid: *const ::libc::c_char, ) -> virSecretPtr; } extern "C" { pub fn virSecretLookupByUsage( conn: virConnectPtr, usageType: ::libc::c_int, usageID: *const ::libc::c_char, ) -> virSecretPtr; } pub const VIR_SECRET_DEFINE_VALIDATE: virSecretDefineFlags = 1; pub type virSecretDefineFlags = ::libc::c_uint; extern "C" { pub fn virSecretDefineXML( conn: virConnectPtr, xml: *const ::libc::c_char, flags: ::libc::c_uint, ) -> virSecretPtr; } extern "C" { pub fn virSecretGetUUID(secret: virSecretPtr, buf: *mut ::libc::c_uchar) -> ::libc::c_int; } extern "C" { pub fn virSecretGetUUIDString(secret: virSecretPtr, buf: *mut ::libc::c_char) -> ::libc::c_int; } extern "C" { pub fn virSecretGetUsageType(secret: virSecretPtr) -> ::libc::c_int; } extern "C" { pub fn virSecretGetUsageID(secret: virSecretPtr) -> *const ::libc::c_char; } extern "C" { pub fn virSecretGetXMLDesc(secret: virSecretPtr, flags: ::libc::c_uint) -> *mut ::libc::c_char; } extern "C" { pub fn virSecretSetValue( secret: virSecretPtr, value: *const ::libc::c_uchar, value_size: usize, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virSecretGetValue( secret: virSecretPtr, value_size: *mut usize, flags: ::libc::c_uint, ) -> *mut ::libc::c_uchar; } extern "C" { pub fn virSecretUndefine(secret: virSecretPtr) -> ::libc::c_int; } extern "C" { pub fn virSecretRef(secret: virSecretPtr) -> ::libc::c_int; } extern "C" { pub fn virSecretFree(secret: virSecretPtr) -> ::libc::c_int; } pub const VIR_SECRET_EVENT_ID_LIFECYCLE: virSecretEventID = 0; pub const VIR_SECRET_EVENT_ID_VALUE_CHANGED: virSecretEventID = 1; pub type virSecretEventID = ::libc::c_uint; pub type virConnectSecretEventGenericCallback = ::std::option::Option< unsafe extern "C" fn(conn: virConnectPtr, secret: virSecretPtr, opaque: *mut ::libc::c_void), >; extern "C" { pub fn virConnectSecretEventRegisterAny( conn: virConnectPtr, secret: virSecretPtr, eventID: ::libc::c_int, cb: virConnectSecretEventGenericCallback, opaque: *mut ::libc::c_void, freecb: virFreeCallback, ) -> ::libc::c_int; } extern "C" { pub fn virConnectSecretEventDeregisterAny( conn: virConnectPtr, callbackID: ::libc::c_int, ) -> ::libc::c_int; } pub const VIR_SECRET_EVENT_DEFINED: virSecretEventLifecycleType = 0; pub const VIR_SECRET_EVENT_UNDEFINED: virSecretEventLifecycleType = 1; pub type virSecretEventLifecycleType = ::libc::c_uint; pub type virConnectSecretEventLifecycleCallback = ::std::option::Option< unsafe extern "C" fn( conn: virConnectPtr, secret: virSecretPtr, event: ::libc::c_int, detail: ::libc::c_int, opaque: *mut ::libc::c_void, ), >; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct _virStoragePool { _unused: [u8; 0], } pub type virStoragePool = _virStoragePool; pub type virStoragePoolPtr = *mut virStoragePool; pub const VIR_STORAGE_POOL_INACTIVE: virStoragePoolState = 0; pub const VIR_STORAGE_POOL_BUILDING: virStoragePoolState = 1; pub const VIR_STORAGE_POOL_RUNNING: virStoragePoolState = 2; pub const VIR_STORAGE_POOL_DEGRADED: virStoragePoolState = 3; pub const VIR_STORAGE_POOL_INACCESSIBLE: virStoragePoolState = 4; pub type virStoragePoolState = ::libc::c_uint; pub const VIR_STORAGE_POOL_BUILD_NEW: virStoragePoolBuildFlags = 0; pub const VIR_STORAGE_POOL_BUILD_REPAIR: virStoragePoolBuildFlags = 1; pub const VIR_STORAGE_POOL_BUILD_RESIZE: virStoragePoolBuildFlags = 2; pub const VIR_STORAGE_POOL_BUILD_NO_OVERWRITE: virStoragePoolBuildFlags = 4; pub const VIR_STORAGE_POOL_BUILD_OVERWRITE: virStoragePoolBuildFlags = 8; pub type virStoragePoolBuildFlags = ::libc::c_uint; pub const VIR_STORAGE_POOL_DELETE_NORMAL: virStoragePoolDeleteFlags = 0; pub const VIR_STORAGE_POOL_DELETE_ZEROED: virStoragePoolDeleteFlags = 1; pub type virStoragePoolDeleteFlags = ::libc::c_uint; pub const VIR_STORAGE_POOL_CREATE_NORMAL: virStoragePoolCreateFlags = 0; pub const VIR_STORAGE_POOL_CREATE_WITH_BUILD: virStoragePoolCreateFlags = 1; pub const VIR_STORAGE_POOL_CREATE_WITH_BUILD_OVERWRITE: virStoragePoolCreateFlags = 2; pub const VIR_STORAGE_POOL_CREATE_WITH_BUILD_NO_OVERWRITE: virStoragePoolCreateFlags = 4; pub type virStoragePoolCreateFlags = ::libc::c_uint; pub type virStoragePoolInfo = _virStoragePoolInfo; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct _virStoragePoolInfo { pub state: ::libc::c_int, pub capacity: ::libc::c_ulonglong, pub allocation: ::libc::c_ulonglong, pub available: ::libc::c_ulonglong, } #[test] fn bindgen_test_layout__virStoragePoolInfo() { const UNINIT: ::std::mem::MaybeUninit<_virStoragePoolInfo> = ::std::mem::MaybeUninit::uninit(); let ptr = UNINIT.as_ptr(); assert_eq!( ::std::mem::size_of::<_virStoragePoolInfo>(), 32usize, concat!("Size of: ", stringify!(_virStoragePoolInfo)) ); assert_eq!( ::std::mem::align_of::<_virStoragePoolInfo>(), 8usize, concat!("Alignment of ", stringify!(_virStoragePoolInfo)) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).state) as usize - ptr as usize }, 0usize, concat!( "Offset of field: ", stringify!(_virStoragePoolInfo), "::", stringify!(state) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).capacity) as usize - ptr as usize }, 8usize, concat!( "Offset of field: ", stringify!(_virStoragePoolInfo), "::", stringify!(capacity) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).allocation) as usize - ptr as usize }, 16usize, concat!( "Offset of field: ", stringify!(_virStoragePoolInfo), "::", stringify!(allocation) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).available) as usize - ptr as usize }, 24usize, concat!( "Offset of field: ", stringify!(_virStoragePoolInfo), "::", stringify!(available) ) ); } pub type virStoragePoolInfoPtr = *mut virStoragePoolInfo; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct _virStorageVol { _unused: [u8; 0], } pub type virStorageVol = _virStorageVol; pub type virStorageVolPtr = *mut virStorageVol; pub const VIR_STORAGE_VOL_FILE: virStorageVolType = 0; pub const VIR_STORAGE_VOL_BLOCK: virStorageVolType = 1; pub const VIR_STORAGE_VOL_DIR: virStorageVolType = 2; pub const VIR_STORAGE_VOL_NETWORK: virStorageVolType = 3; pub const VIR_STORAGE_VOL_NETDIR: virStorageVolType = 4; pub const VIR_STORAGE_VOL_PLOOP: virStorageVolType = 5; pub type virStorageVolType = ::libc::c_uint; pub const VIR_STORAGE_VOL_DELETE_NORMAL: virStorageVolDeleteFlags = 0; pub const VIR_STORAGE_VOL_DELETE_ZEROED: virStorageVolDeleteFlags = 1; pub const VIR_STORAGE_VOL_DELETE_WITH_SNAPSHOTS: virStorageVolDeleteFlags = 2; pub type virStorageVolDeleteFlags = ::libc::c_uint; pub const VIR_STORAGE_VOL_WIPE_ALG_ZERO: virStorageVolWipeAlgorithm = 0; pub const VIR_STORAGE_VOL_WIPE_ALG_NNSA: virStorageVolWipeAlgorithm = 1; pub const VIR_STORAGE_VOL_WIPE_ALG_DOD: virStorageVolWipeAlgorithm = 2; pub const VIR_STORAGE_VOL_WIPE_ALG_BSI: virStorageVolWipeAlgorithm = 3; pub const VIR_STORAGE_VOL_WIPE_ALG_GUTMANN: virStorageVolWipeAlgorithm = 4; pub const VIR_STORAGE_VOL_WIPE_ALG_SCHNEIER: virStorageVolWipeAlgorithm = 5; pub const VIR_STORAGE_VOL_WIPE_ALG_PFITZNER7: virStorageVolWipeAlgorithm = 6; pub const VIR_STORAGE_VOL_WIPE_ALG_PFITZNER33: virStorageVolWipeAlgorithm = 7; pub const VIR_STORAGE_VOL_WIPE_ALG_RANDOM: virStorageVolWipeAlgorithm = 8; pub const VIR_STORAGE_VOL_WIPE_ALG_TRIM: virStorageVolWipeAlgorithm = 9; pub type virStorageVolWipeAlgorithm = ::libc::c_uint; pub const VIR_STORAGE_VOL_USE_ALLOCATION: virStorageVolInfoFlags = 0; pub const VIR_STORAGE_VOL_GET_PHYSICAL: virStorageVolInfoFlags = 1; pub type virStorageVolInfoFlags = ::libc::c_uint; pub type virStorageVolInfo = _virStorageVolInfo; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct _virStorageVolInfo { pub type_: ::libc::c_int, pub capacity: ::libc::c_ulonglong, pub allocation: ::libc::c_ulonglong, } #[test] fn bindgen_test_layout__virStorageVolInfo() { const UNINIT: ::std::mem::MaybeUninit<_virStorageVolInfo> = ::std::mem::MaybeUninit::uninit(); let ptr = UNINIT.as_ptr(); assert_eq!( ::std::mem::size_of::<_virStorageVolInfo>(), 24usize, concat!("Size of: ", stringify!(_virStorageVolInfo)) ); assert_eq!( ::std::mem::align_of::<_virStorageVolInfo>(), 8usize, concat!("Alignment of ", stringify!(_virStorageVolInfo)) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).type_) as usize - ptr as usize }, 0usize, concat!( "Offset of field: ", stringify!(_virStorageVolInfo), "::", stringify!(type_) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).capacity) as usize - ptr as usize }, 8usize, concat!( "Offset of field: ", stringify!(_virStorageVolInfo), "::", stringify!(capacity) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).allocation) as usize - ptr as usize }, 16usize, concat!( "Offset of field: ", stringify!(_virStorageVolInfo), "::", stringify!(allocation) ) ); } pub type virStorageVolInfoPtr = *mut virStorageVolInfo; pub const VIR_STORAGE_XML_INACTIVE: virStorageXMLFlags = 1; pub type virStorageXMLFlags = ::libc::c_uint; extern "C" { pub fn virStoragePoolGetConnect(pool: virStoragePoolPtr) -> virConnectPtr; } extern "C" { pub fn virConnectGetStoragePoolCapabilities( conn: virConnectPtr, flags: ::libc::c_uint, ) -> *mut ::libc::c_char; } extern "C" { pub fn virConnectNumOfStoragePools(conn: virConnectPtr) -> ::libc::c_int; } extern "C" { pub fn virConnectListStoragePools( conn: virConnectPtr, names: *mut *mut ::libc::c_char, maxnames: ::libc::c_int, ) -> ::libc::c_int; } extern "C" { pub fn virConnectNumOfDefinedStoragePools(conn: virConnectPtr) -> ::libc::c_int; } extern "C" { pub fn virConnectListDefinedStoragePools( conn: virConnectPtr, names: *mut *mut ::libc::c_char, maxnames: ::libc::c_int, ) -> ::libc::c_int; } pub const VIR_CONNECT_LIST_STORAGE_POOLS_INACTIVE: virConnectListAllStoragePoolsFlags = 1; pub const VIR_CONNECT_LIST_STORAGE_POOLS_ACTIVE: virConnectListAllStoragePoolsFlags = 2; pub const VIR_CONNECT_LIST_STORAGE_POOLS_PERSISTENT: virConnectListAllStoragePoolsFlags = 4; pub const VIR_CONNECT_LIST_STORAGE_POOLS_TRANSIENT: virConnectListAllStoragePoolsFlags = 8; pub const VIR_CONNECT_LIST_STORAGE_POOLS_AUTOSTART: virConnectListAllStoragePoolsFlags = 16; pub const VIR_CONNECT_LIST_STORAGE_POOLS_NO_AUTOSTART: virConnectListAllStoragePoolsFlags = 32; pub const VIR_CONNECT_LIST_STORAGE_POOLS_DIR: virConnectListAllStoragePoolsFlags = 64; pub const VIR_CONNECT_LIST_STORAGE_POOLS_FS: virConnectListAllStoragePoolsFlags = 128; pub const VIR_CONNECT_LIST_STORAGE_POOLS_NETFS: virConnectListAllStoragePoolsFlags = 256; pub const VIR_CONNECT_LIST_STORAGE_POOLS_LOGICAL: virConnectListAllStoragePoolsFlags = 512; pub const VIR_CONNECT_LIST_STORAGE_POOLS_DISK: virConnectListAllStoragePoolsFlags = 1024; pub const VIR_CONNECT_LIST_STORAGE_POOLS_ISCSI: virConnectListAllStoragePoolsFlags = 2048; pub const VIR_CONNECT_LIST_STORAGE_POOLS_SCSI: virConnectListAllStoragePoolsFlags = 4096; pub const VIR_CONNECT_LIST_STORAGE_POOLS_MPATH: virConnectListAllStoragePoolsFlags = 8192; pub const VIR_CONNECT_LIST_STORAGE_POOLS_RBD: virConnectListAllStoragePoolsFlags = 16384; pub const VIR_CONNECT_LIST_STORAGE_POOLS_SHEEPDOG: virConnectListAllStoragePoolsFlags = 32768; pub const VIR_CONNECT_LIST_STORAGE_POOLS_GLUSTER: virConnectListAllStoragePoolsFlags = 65536; pub const VIR_CONNECT_LIST_STORAGE_POOLS_ZFS: virConnectListAllStoragePoolsFlags = 131072; pub const VIR_CONNECT_LIST_STORAGE_POOLS_VSTORAGE: virConnectListAllStoragePoolsFlags = 262144; pub const VIR_CONNECT_LIST_STORAGE_POOLS_ISCSI_DIRECT: virConnectListAllStoragePoolsFlags = 524288; pub type virConnectListAllStoragePoolsFlags = ::libc::c_uint; extern "C" { pub fn virConnectListAllStoragePools( conn: virConnectPtr, pools: *mut *mut virStoragePoolPtr, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virConnectFindStoragePoolSources( conn: virConnectPtr, type_: *const ::libc::c_char, srcSpec: *const ::libc::c_char, flags: ::libc::c_uint, ) -> *mut ::libc::c_char; } extern "C" { pub fn virStoragePoolLookupByName( conn: virConnectPtr, name: *const ::libc::c_char, ) -> virStoragePoolPtr; } extern "C" { pub fn virStoragePoolLookupByUUID( conn: virConnectPtr, uuid: *const ::libc::c_uchar, ) -> virStoragePoolPtr; } extern "C" { pub fn virStoragePoolLookupByUUIDString( conn: virConnectPtr, uuid: *const ::libc::c_char, ) -> virStoragePoolPtr; } extern "C" { pub fn virStoragePoolLookupByVolume(vol: virStorageVolPtr) -> virStoragePoolPtr; } extern "C" { pub fn virStoragePoolLookupByTargetPath( conn: virConnectPtr, path: *const ::libc::c_char, ) -> virStoragePoolPtr; } pub const VIR_STORAGE_POOL_DEFINE_VALIDATE: virStoragePoolDefineFlags = 1; pub type virStoragePoolDefineFlags = ::libc::c_uint; extern "C" { pub fn virStoragePoolCreateXML( conn: virConnectPtr, xmlDesc: *const ::libc::c_char, flags: ::libc::c_uint, ) -> virStoragePoolPtr; } extern "C" { pub fn virStoragePoolDefineXML( conn: virConnectPtr, xmlDesc: *const ::libc::c_char, flags: ::libc::c_uint, ) -> virStoragePoolPtr; } extern "C" { pub fn virStoragePoolBuild(pool: virStoragePoolPtr, flags: ::libc::c_uint) -> ::libc::c_int; } extern "C" { pub fn virStoragePoolUndefine(pool: virStoragePoolPtr) -> ::libc::c_int; } extern "C" { pub fn virStoragePoolCreate(pool: virStoragePoolPtr, flags: ::libc::c_uint) -> ::libc::c_int; } extern "C" { pub fn virStoragePoolDestroy(pool: virStoragePoolPtr) -> ::libc::c_int; } extern "C" { pub fn virStoragePoolDelete(pool: virStoragePoolPtr, flags: ::libc::c_uint) -> ::libc::c_int; } extern "C" { pub fn virStoragePoolRef(pool: virStoragePoolPtr) -> ::libc::c_int; } extern "C" { pub fn virStoragePoolFree(pool: virStoragePoolPtr) -> ::libc::c_int; } extern "C" { pub fn virStoragePoolRefresh(pool: virStoragePoolPtr, flags: ::libc::c_uint) -> ::libc::c_int; } extern "C" { pub fn virStoragePoolGetName(pool: virStoragePoolPtr) -> *const ::libc::c_char; } extern "C" { pub fn virStoragePoolGetUUID( pool: virStoragePoolPtr, uuid: *mut ::libc::c_uchar, ) -> ::libc::c_int; } extern "C" { pub fn virStoragePoolGetUUIDString( pool: virStoragePoolPtr, buf: *mut ::libc::c_char, ) -> ::libc::c_int; } extern "C" { pub fn virStoragePoolGetInfo( vol: virStoragePoolPtr, info: virStoragePoolInfoPtr, ) -> ::libc::c_int; } extern "C" { pub fn virStoragePoolGetXMLDesc( pool: virStoragePoolPtr, flags: ::libc::c_uint, ) -> *mut ::libc::c_char; } extern "C" { pub fn virStoragePoolGetAutostart( pool: virStoragePoolPtr, autostart: *mut ::libc::c_int, ) -> ::libc::c_int; } extern "C" { pub fn virStoragePoolSetAutostart( pool: virStoragePoolPtr, autostart: ::libc::c_int, ) -> ::libc::c_int; } extern "C" { pub fn virStoragePoolNumOfVolumes(pool: virStoragePoolPtr) -> ::libc::c_int; } extern "C" { pub fn virStoragePoolListVolumes( pool: virStoragePoolPtr, names: *mut *mut ::libc::c_char, maxnames: ::libc::c_int, ) -> ::libc::c_int; } extern "C" { pub fn virStoragePoolListAllVolumes( pool: virStoragePoolPtr, vols: *mut *mut virStorageVolPtr, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virStorageVolGetConnect(vol: virStorageVolPtr) -> virConnectPtr; } extern "C" { pub fn virStorageVolLookupByName( pool: virStoragePoolPtr, name: *const ::libc::c_char, ) -> virStorageVolPtr; } extern "C" { pub fn virStorageVolLookupByKey( conn: virConnectPtr, key: *const ::libc::c_char, ) -> virStorageVolPtr; } extern "C" { pub fn virStorageVolLookupByPath( conn: virConnectPtr, path: *const ::libc::c_char, ) -> virStorageVolPtr; } extern "C" { pub fn virStorageVolGetName(vol: virStorageVolPtr) -> *const ::libc::c_char; } extern "C" { pub fn virStorageVolGetKey(vol: virStorageVolPtr) -> *const ::libc::c_char; } pub const VIR_STORAGE_VOL_CREATE_PREALLOC_METADATA: virStorageVolCreateFlags = 1; pub const VIR_STORAGE_VOL_CREATE_REFLINK: virStorageVolCreateFlags = 2; pub const VIR_STORAGE_VOL_CREATE_VALIDATE: virStorageVolCreateFlags = 4; pub type virStorageVolCreateFlags = ::libc::c_uint; extern "C" { pub fn virStorageVolCreateXML( pool: virStoragePoolPtr, xmldesc: *const ::libc::c_char, flags: ::libc::c_uint, ) -> virStorageVolPtr; } extern "C" { pub fn virStorageVolCreateXMLFrom( pool: virStoragePoolPtr, xmldesc: *const ::libc::c_char, clonevol: virStorageVolPtr, flags: ::libc::c_uint, ) -> virStorageVolPtr; } pub const VIR_STORAGE_VOL_DOWNLOAD_SPARSE_STREAM: virStorageVolDownloadFlags = 1; pub type virStorageVolDownloadFlags = ::libc::c_uint; extern "C" { pub fn virStorageVolDownload( vol: virStorageVolPtr, stream: virStreamPtr, offset: ::libc::c_ulonglong, length: ::libc::c_ulonglong, flags: ::libc::c_uint, ) -> ::libc::c_int; } pub const VIR_STORAGE_VOL_UPLOAD_SPARSE_STREAM: virStorageVolUploadFlags = 1; pub type virStorageVolUploadFlags = ::libc::c_uint; extern "C" { pub fn virStorageVolUpload( vol: virStorageVolPtr, stream: virStreamPtr, offset: ::libc::c_ulonglong, length: ::libc::c_ulonglong, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virStorageVolDelete(vol: virStorageVolPtr, flags: ::libc::c_uint) -> ::libc::c_int; } extern "C" { pub fn virStorageVolWipe(vol: virStorageVolPtr, flags: ::libc::c_uint) -> ::libc::c_int; } extern "C" { pub fn virStorageVolWipePattern( vol: virStorageVolPtr, algorithm: ::libc::c_uint, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virStorageVolRef(vol: virStorageVolPtr) -> ::libc::c_int; } extern "C" { pub fn virStorageVolFree(vol: virStorageVolPtr) -> ::libc::c_int; } extern "C" { pub fn virStorageVolGetInfo(vol: virStorageVolPtr, info: virStorageVolInfoPtr) -> ::libc::c_int; } extern "C" { pub fn virStorageVolGetInfoFlags( vol: virStorageVolPtr, info: virStorageVolInfoPtr, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virStorageVolGetXMLDesc( pool: virStorageVolPtr, flags: ::libc::c_uint, ) -> *mut ::libc::c_char; } extern "C" { pub fn virStorageVolGetPath(vol: virStorageVolPtr) -> *mut ::libc::c_char; } pub const VIR_STORAGE_VOL_RESIZE_ALLOCATE: virStorageVolResizeFlags = 1; pub const VIR_STORAGE_VOL_RESIZE_DELTA: virStorageVolResizeFlags = 2; pub const VIR_STORAGE_VOL_RESIZE_SHRINK: virStorageVolResizeFlags = 4; pub type virStorageVolResizeFlags = ::libc::c_uint; extern "C" { pub fn virStorageVolResize( vol: virStorageVolPtr, capacity: ::libc::c_ulonglong, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virStoragePoolIsActive(pool: virStoragePoolPtr) -> ::libc::c_int; } extern "C" { pub fn virStoragePoolIsPersistent(pool: virStoragePoolPtr) -> ::libc::c_int; } pub const VIR_STORAGE_POOL_EVENT_ID_LIFECYCLE: virStoragePoolEventID = 0; pub const VIR_STORAGE_POOL_EVENT_ID_REFRESH: virStoragePoolEventID = 1; pub type virStoragePoolEventID = ::libc::c_uint; pub type virConnectStoragePoolEventGenericCallback = ::std::option::Option< unsafe extern "C" fn(conn: virConnectPtr, pool: virStoragePoolPtr, opaque: *mut ::libc::c_void), >; extern "C" { pub fn virConnectStoragePoolEventRegisterAny( conn: virConnectPtr, pool: virStoragePoolPtr, eventID: ::libc::c_int, cb: virConnectStoragePoolEventGenericCallback, opaque: *mut ::libc::c_void, freecb: virFreeCallback, ) -> ::libc::c_int; } extern "C" { pub fn virConnectStoragePoolEventDeregisterAny( conn: virConnectPtr, callbackID: ::libc::c_int, ) -> ::libc::c_int; } pub const VIR_STORAGE_POOL_EVENT_DEFINED: virStoragePoolEventLifecycleType = 0; pub const VIR_STORAGE_POOL_EVENT_UNDEFINED: virStoragePoolEventLifecycleType = 1; pub const VIR_STORAGE_POOL_EVENT_STARTED: virStoragePoolEventLifecycleType = 2; pub const VIR_STORAGE_POOL_EVENT_STOPPED: virStoragePoolEventLifecycleType = 3; pub const VIR_STORAGE_POOL_EVENT_CREATED: virStoragePoolEventLifecycleType = 4; pub const VIR_STORAGE_POOL_EVENT_DELETED: virStoragePoolEventLifecycleType = 5; pub type virStoragePoolEventLifecycleType = ::libc::c_uint; pub type virConnectStoragePoolEventLifecycleCallback = ::std::option::Option< unsafe extern "C" fn( conn: virConnectPtr, pool: virStoragePoolPtr, event: ::libc::c_int, detail: ::libc::c_int, opaque: *mut ::libc::c_void, ), >; pub const VIR_STREAM_NONBLOCK: virStreamFlags = 1; pub type virStreamFlags = ::libc::c_uint; extern "C" { pub fn virStreamNew(conn: virConnectPtr, flags: ::libc::c_uint) -> virStreamPtr; } extern "C" { pub fn virStreamRef(st: virStreamPtr) -> ::libc::c_int; } extern "C" { pub fn virStreamSend( st: virStreamPtr, data: *const ::libc::c_char, nbytes: usize, ) -> ::libc::c_int; } extern "C" { pub fn virStreamRecv( st: virStreamPtr, data: *mut ::libc::c_char, nbytes: usize, ) -> ::libc::c_int; } pub const VIR_STREAM_RECV_STOP_AT_HOLE: virStreamRecvFlagsValues = 1; pub type virStreamRecvFlagsValues = ::libc::c_uint; extern "C" { pub fn virStreamRecvFlags( st: virStreamPtr, data: *mut ::libc::c_char, nbytes: usize, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virStreamSendHole( st: virStreamPtr, length: ::libc::c_longlong, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virStreamRecvHole( arg1: virStreamPtr, length: *mut ::libc::c_longlong, flags: ::libc::c_uint, ) -> ::libc::c_int; } pub type virStreamSourceFunc = ::std::option::Option< unsafe extern "C" fn( st: virStreamPtr, data: *mut ::libc::c_char, nbytes: usize, opaque: *mut ::libc::c_void, ) -> ::libc::c_int, >; extern "C" { pub fn virStreamSendAll( st: virStreamPtr, handler: virStreamSourceFunc, opaque: *mut ::libc::c_void, ) -> ::libc::c_int; } pub type virStreamSourceHoleFunc = ::std::option::Option< unsafe extern "C" fn( st: virStreamPtr, inData: *mut ::libc::c_int, length: *mut ::libc::c_longlong, opaque: *mut ::libc::c_void, ) -> ::libc::c_int, >; pub type virStreamSourceSkipFunc = ::std::option::Option< unsafe extern "C" fn( st: virStreamPtr, length: ::libc::c_longlong, opaque: *mut ::libc::c_void, ) -> ::libc::c_int, >; extern "C" { pub fn virStreamSparseSendAll( st: virStreamPtr, handler: virStreamSourceFunc, holeHandler: virStreamSourceHoleFunc, skipHandler: virStreamSourceSkipFunc, opaque: *mut ::libc::c_void, ) -> ::libc::c_int; } pub type virStreamSinkFunc = ::std::option::Option< unsafe extern "C" fn( st: virStreamPtr, data: *const ::libc::c_char, nbytes: usize, opaque: *mut ::libc::c_void, ) -> ::libc::c_int, >; extern "C" { pub fn virStreamRecvAll( st: virStreamPtr, handler: virStreamSinkFunc, opaque: *mut ::libc::c_void, ) -> ::libc::c_int; } pub type virStreamSinkHoleFunc = ::std::option::Option< unsafe extern "C" fn( st: virStreamPtr, length: ::libc::c_longlong, opaque: *mut ::libc::c_void, ) -> ::libc::c_int, >; extern "C" { pub fn virStreamSparseRecvAll( stream: virStreamPtr, handler: virStreamSinkFunc, holeHandler: virStreamSinkHoleFunc, opaque: *mut ::libc::c_void, ) -> ::libc::c_int; } pub const VIR_STREAM_EVENT_READABLE: virStreamEventType = 1; pub const VIR_STREAM_EVENT_WRITABLE: virStreamEventType = 2; pub const VIR_STREAM_EVENT_ERROR: virStreamEventType = 4; pub const VIR_STREAM_EVENT_HANGUP: virStreamEventType = 8; pub type virStreamEventType = ::libc::c_uint; pub type virStreamEventCallback = ::std::option::Option< unsafe extern "C" fn(stream: virStreamPtr, events: ::libc::c_int, opaque: *mut ::libc::c_void), >; extern "C" { pub fn virStreamEventAddCallback( stream: virStreamPtr, events: ::libc::c_int, cb: virStreamEventCallback, opaque: *mut ::libc::c_void, ff: virFreeCallback, ) -> ::libc::c_int; } extern "C" { pub fn virStreamEventUpdateCallback( stream: virStreamPtr, events: ::libc::c_int, ) -> ::libc::c_int; } extern "C" { pub fn virStreamEventRemoveCallback(stream: virStreamPtr) -> ::libc::c_int; } extern "C" { pub fn virStreamFinish(st: virStreamPtr) -> ::libc::c_int; } extern "C" { pub fn virStreamAbort(st: virStreamPtr) -> ::libc::c_int; } extern "C" { pub fn virStreamFree(st: virStreamPtr) -> ::libc::c_int; } pub const VIR_ERR_NONE: virErrorLevel = 0; pub const VIR_ERR_WARNING: virErrorLevel = 1; pub const VIR_ERR_ERROR: virErrorLevel = 2; pub type virErrorLevel = ::libc::c_uint; pub const VIR_FROM_NONE: virErrorDomain = 0; pub const VIR_FROM_XEN: virErrorDomain = 1; pub const VIR_FROM_XEND: virErrorDomain = 2; pub const VIR_FROM_XENSTORE: virErrorDomain = 3; pub const VIR_FROM_SEXPR: virErrorDomain = 4; pub const VIR_FROM_XML: virErrorDomain = 5; pub const VIR_FROM_DOM: virErrorDomain = 6; pub const VIR_FROM_RPC: virErrorDomain = 7; pub const VIR_FROM_PROXY: virErrorDomain = 8; pub const VIR_FROM_CONF: virErrorDomain = 9; pub const VIR_FROM_QEMU: virErrorDomain = 10; pub const VIR_FROM_NET: virErrorDomain = 11; pub const VIR_FROM_TEST: virErrorDomain = 12; pub const VIR_FROM_REMOTE: virErrorDomain = 13; pub const VIR_FROM_OPENVZ: virErrorDomain = 14; pub const VIR_FROM_XENXM: virErrorDomain = 15; pub const VIR_FROM_STATS_LINUX: virErrorDomain = 16; pub const VIR_FROM_LXC: virErrorDomain = 17; pub const VIR_FROM_STORAGE: virErrorDomain = 18; pub const VIR_FROM_NETWORK: virErrorDomain = 19; pub const VIR_FROM_DOMAIN: virErrorDomain = 20; pub const VIR_FROM_UML: virErrorDomain = 21; pub const VIR_FROM_NODEDEV: virErrorDomain = 22; pub const VIR_FROM_XEN_INOTIFY: virErrorDomain = 23; pub const VIR_FROM_SECURITY: virErrorDomain = 24; pub const VIR_FROM_VBOX: virErrorDomain = 25; pub const VIR_FROM_INTERFACE: virErrorDomain = 26; pub const VIR_FROM_ONE: virErrorDomain = 27; pub const VIR_FROM_ESX: virErrorDomain = 28; pub const VIR_FROM_PHYP: virErrorDomain = 29; pub const VIR_FROM_SECRET: virErrorDomain = 30; pub const VIR_FROM_CPU: virErrorDomain = 31; pub const VIR_FROM_XENAPI: virErrorDomain = 32; pub const VIR_FROM_NWFILTER: virErrorDomain = 33; pub const VIR_FROM_HOOK: virErrorDomain = 34; pub const VIR_FROM_DOMAIN_SNAPSHOT: virErrorDomain = 35; pub const VIR_FROM_AUDIT: virErrorDomain = 36; pub const VIR_FROM_SYSINFO: virErrorDomain = 37; pub const VIR_FROM_STREAMS: virErrorDomain = 38; pub const VIR_FROM_VMWARE: virErrorDomain = 39; pub const VIR_FROM_EVENT: virErrorDomain = 40; pub const VIR_FROM_LIBXL: virErrorDomain = 41; pub const VIR_FROM_LOCKING: virErrorDomain = 42; pub const VIR_FROM_HYPERV: virErrorDomain = 43; pub const VIR_FROM_CAPABILITIES: virErrorDomain = 44; pub const VIR_FROM_URI: virErrorDomain = 45; pub const VIR_FROM_AUTH: virErrorDomain = 46; pub const VIR_FROM_DBUS: virErrorDomain = 47; pub const VIR_FROM_PARALLELS: virErrorDomain = 48; pub const VIR_FROM_DEVICE: virErrorDomain = 49; pub const VIR_FROM_SSH: virErrorDomain = 50; pub const VIR_FROM_LOCKSPACE: virErrorDomain = 51; pub const VIR_FROM_INITCTL: virErrorDomain = 52; pub const VIR_FROM_IDENTITY: virErrorDomain = 53; pub const VIR_FROM_CGROUP: virErrorDomain = 54; pub const VIR_FROM_ACCESS: virErrorDomain = 55; pub const VIR_FROM_SYSTEMD: virErrorDomain = 56; pub const VIR_FROM_BHYVE: virErrorDomain = 57; pub const VIR_FROM_CRYPTO: virErrorDomain = 58; pub const VIR_FROM_FIREWALL: virErrorDomain = 59; pub const VIR_FROM_POLKIT: virErrorDomain = 60; pub const VIR_FROM_THREAD: virErrorDomain = 61; pub const VIR_FROM_ADMIN: virErrorDomain = 62; pub const VIR_FROM_LOGGING: virErrorDomain = 63; pub const VIR_FROM_XENXL: virErrorDomain = 64; pub const VIR_FROM_PERF: virErrorDomain = 65; pub const VIR_FROM_LIBSSH: virErrorDomain = 66; pub const VIR_FROM_RESCTRL: virErrorDomain = 67; pub const VIR_FROM_FIREWALLD: virErrorDomain = 68; pub const VIR_FROM_DOMAIN_CHECKPOINT: virErrorDomain = 69; pub const VIR_FROM_TPM: virErrorDomain = 70; pub const VIR_FROM_BPF: virErrorDomain = 71; pub const VIR_FROM_CH: virErrorDomain = 72; pub type virErrorDomain = ::libc::c_uint; pub type virError = _virError; pub type virErrorPtr = *mut virError; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct _virError { pub code: ::libc::c_int, pub domain: ::libc::c_int, pub message: *mut ::libc::c_char, pub level: virErrorLevel, pub conn: virConnectPtr, pub dom: virDomainPtr, pub str1: *mut ::libc::c_char, pub str2: *mut ::libc::c_char, pub str3: *mut ::libc::c_char, pub int1: ::libc::c_int, pub int2: ::libc::c_int, pub net: virNetworkPtr, } #[test] fn bindgen_test_layout__virError() { const UNINIT: ::std::mem::MaybeUninit<_virError> = ::std::mem::MaybeUninit::uninit(); let ptr = UNINIT.as_ptr(); assert_eq!( ::std::mem::size_of::<_virError>(), 80usize, concat!("Size of: ", stringify!(_virError)) ); assert_eq!( ::std::mem::align_of::<_virError>(), 8usize, concat!("Alignment of ", stringify!(_virError)) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).code) as usize - ptr as usize }, 0usize, concat!( "Offset of field: ", stringify!(_virError), "::", stringify!(code) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).domain) as usize - ptr as usize }, 4usize, concat!( "Offset of field: ", stringify!(_virError), "::", stringify!(domain) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).message) as usize - ptr as usize }, 8usize, concat!( "Offset of field: ", stringify!(_virError), "::", stringify!(message) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).level) as usize - ptr as usize }, 16usize, concat!( "Offset of field: ", stringify!(_virError), "::", stringify!(level) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).conn) as usize - ptr as usize }, 24usize, concat!( "Offset of field: ", stringify!(_virError), "::", stringify!(conn) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).dom) as usize - ptr as usize }, 32usize, concat!( "Offset of field: ", stringify!(_virError), "::", stringify!(dom) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).str1) as usize - ptr as usize }, 40usize, concat!( "Offset of field: ", stringify!(_virError), "::", stringify!(str1) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).str2) as usize - ptr as usize }, 48usize, concat!( "Offset of field: ", stringify!(_virError), "::", stringify!(str2) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).str3) as usize - ptr as usize }, 56usize, concat!( "Offset of field: ", stringify!(_virError), "::", stringify!(str3) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).int1) as usize - ptr as usize }, 64usize, concat!( "Offset of field: ", stringify!(_virError), "::", stringify!(int1) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).int2) as usize - ptr as usize }, 68usize, concat!( "Offset of field: ", stringify!(_virError), "::", stringify!(int2) ) ); assert_eq!( unsafe { ::std::ptr::addr_of!((*ptr).net) as usize - ptr as usize }, 72usize, concat!( "Offset of field: ", stringify!(_virError), "::", stringify!(net) ) ); } pub const VIR_ERR_OK: virErrorNumber = 0; pub const VIR_ERR_INTERNAL_ERROR: virErrorNumber = 1; pub const VIR_ERR_NO_MEMORY: virErrorNumber = 2; pub const VIR_ERR_NO_SUPPORT: virErrorNumber = 3; pub const VIR_ERR_UNKNOWN_HOST: virErrorNumber = 4; pub const VIR_ERR_NO_CONNECT: virErrorNumber = 5; pub const VIR_ERR_INVALID_CONN: virErrorNumber = 6; pub const VIR_ERR_INVALID_DOMAIN: virErrorNumber = 7; pub const VIR_ERR_INVALID_ARG: virErrorNumber = 8; pub const VIR_ERR_OPERATION_FAILED: virErrorNumber = 9; pub const VIR_ERR_GET_FAILED: virErrorNumber = 10; pub const VIR_ERR_POST_FAILED: virErrorNumber = 11; pub const VIR_ERR_HTTP_ERROR: virErrorNumber = 12; pub const VIR_ERR_SEXPR_SERIAL: virErrorNumber = 13; pub const VIR_ERR_NO_XEN: virErrorNumber = 14; pub const VIR_ERR_XEN_CALL: virErrorNumber = 15; pub const VIR_ERR_OS_TYPE: virErrorNumber = 16; pub const VIR_ERR_NO_KERNEL: virErrorNumber = 17; pub const VIR_ERR_NO_ROOT: virErrorNumber = 18; pub const VIR_ERR_NO_SOURCE: virErrorNumber = 19; pub const VIR_ERR_NO_TARGET: virErrorNumber = 20; pub const VIR_ERR_NO_NAME: virErrorNumber = 21; pub const VIR_ERR_NO_OS: virErrorNumber = 22; pub const VIR_ERR_NO_DEVICE: virErrorNumber = 23; pub const VIR_ERR_NO_XENSTORE: virErrorNumber = 24; pub const VIR_ERR_DRIVER_FULL: virErrorNumber = 25; pub const VIR_ERR_CALL_FAILED: virErrorNumber = 26; pub const VIR_ERR_XML_ERROR: virErrorNumber = 27; pub const VIR_ERR_DOM_EXIST: virErrorNumber = 28; pub const VIR_ERR_OPERATION_DENIED: virErrorNumber = 29; pub const VIR_ERR_OPEN_FAILED: virErrorNumber = 30; pub const VIR_ERR_READ_FAILED: virErrorNumber = 31; pub const VIR_ERR_PARSE_FAILED: virErrorNumber = 32; pub const VIR_ERR_CONF_SYNTAX: virErrorNumber = 33; pub const VIR_ERR_WRITE_FAILED: virErrorNumber = 34; pub const VIR_ERR_XML_DETAIL: virErrorNumber = 35; pub const VIR_ERR_INVALID_NETWORK: virErrorNumber = 36; pub const VIR_ERR_NETWORK_EXIST: virErrorNumber = 37; pub const VIR_ERR_SYSTEM_ERROR: virErrorNumber = 38; pub const VIR_ERR_RPC: virErrorNumber = 39; pub const VIR_ERR_GNUTLS_ERROR: virErrorNumber = 40; pub const VIR_WAR_NO_NETWORK: virErrorNumber = 41; pub const VIR_ERR_NO_DOMAIN: virErrorNumber = 42; pub const VIR_ERR_NO_NETWORK: virErrorNumber = 43; pub const VIR_ERR_INVALID_MAC: virErrorNumber = 44; pub const VIR_ERR_AUTH_FAILED: virErrorNumber = 45; pub const VIR_ERR_INVALID_STORAGE_POOL: virErrorNumber = 46; pub const VIR_ERR_INVALID_STORAGE_VOL: virErrorNumber = 47; pub const VIR_WAR_NO_STORAGE: virErrorNumber = 48; pub const VIR_ERR_NO_STORAGE_POOL: virErrorNumber = 49; pub const VIR_ERR_NO_STORAGE_VOL: virErrorNumber = 50; pub const VIR_WAR_NO_NODE: virErrorNumber = 51; pub const VIR_ERR_INVALID_NODE_DEVICE: virErrorNumber = 52; pub const VIR_ERR_NO_NODE_DEVICE: virErrorNumber = 53; pub const VIR_ERR_NO_SECURITY_MODEL: virErrorNumber = 54; pub const VIR_ERR_OPERATION_INVALID: virErrorNumber = 55; pub const VIR_WAR_NO_INTERFACE: virErrorNumber = 56; pub const VIR_ERR_NO_INTERFACE: virErrorNumber = 57; pub const VIR_ERR_INVALID_INTERFACE: virErrorNumber = 58; pub const VIR_ERR_MULTIPLE_INTERFACES: virErrorNumber = 59; pub const VIR_WAR_NO_NWFILTER: virErrorNumber = 60; pub const VIR_ERR_INVALID_NWFILTER: virErrorNumber = 61; pub const VIR_ERR_NO_NWFILTER: virErrorNumber = 62; pub const VIR_ERR_BUILD_FIREWALL: virErrorNumber = 63; pub const VIR_WAR_NO_SECRET: virErrorNumber = 64; pub const VIR_ERR_INVALID_SECRET: virErrorNumber = 65; pub const VIR_ERR_NO_SECRET: virErrorNumber = 66; pub const VIR_ERR_CONFIG_UNSUPPORTED: virErrorNumber = 67; pub const VIR_ERR_OPERATION_TIMEOUT: virErrorNumber = 68; pub const VIR_ERR_MIGRATE_PERSIST_FAILED: virErrorNumber = 69; pub const VIR_ERR_HOOK_SCRIPT_FAILED: virErrorNumber = 70; pub const VIR_ERR_INVALID_DOMAIN_SNAPSHOT: virErrorNumber = 71; pub const VIR_ERR_NO_DOMAIN_SNAPSHOT: virErrorNumber = 72; pub const VIR_ERR_INVALID_STREAM: virErrorNumber = 73; pub const VIR_ERR_ARGUMENT_UNSUPPORTED: virErrorNumber = 74; pub const VIR_ERR_STORAGE_PROBE_FAILED: virErrorNumber = 75; pub const VIR_ERR_STORAGE_POOL_BUILT: virErrorNumber = 76; pub const VIR_ERR_SNAPSHOT_REVERT_RISKY: virErrorNumber = 77; pub const VIR_ERR_OPERATION_ABORTED: virErrorNumber = 78; pub const VIR_ERR_AUTH_CANCELLED: virErrorNumber = 79; pub const VIR_ERR_NO_DOMAIN_METADATA: virErrorNumber = 80; pub const VIR_ERR_MIGRATE_UNSAFE: virErrorNumber = 81; pub const VIR_ERR_OVERFLOW: virErrorNumber = 82; pub const VIR_ERR_BLOCK_COPY_ACTIVE: virErrorNumber = 83; pub const VIR_ERR_OPERATION_UNSUPPORTED: virErrorNumber = 84; pub const VIR_ERR_SSH: virErrorNumber = 85; pub const VIR_ERR_AGENT_UNRESPONSIVE: virErrorNumber = 86; pub const VIR_ERR_RESOURCE_BUSY: virErrorNumber = 87; pub const VIR_ERR_ACCESS_DENIED: virErrorNumber = 88; pub const VIR_ERR_DBUS_SERVICE: virErrorNumber = 89; pub const VIR_ERR_STORAGE_VOL_EXIST: virErrorNumber = 90; pub const VIR_ERR_CPU_INCOMPATIBLE: virErrorNumber = 91; pub const VIR_ERR_XML_INVALID_SCHEMA: virErrorNumber = 92; pub const VIR_ERR_MIGRATE_FINISH_OK: virErrorNumber = 93; pub const VIR_ERR_AUTH_UNAVAILABLE: virErrorNumber = 94; pub const VIR_ERR_NO_SERVER: virErrorNumber = 95; pub const VIR_ERR_NO_CLIENT: virErrorNumber = 96; pub const VIR_ERR_AGENT_UNSYNCED: virErrorNumber = 97; pub const VIR_ERR_LIBSSH: virErrorNumber = 98; pub const VIR_ERR_DEVICE_MISSING: virErrorNumber = 99; pub const VIR_ERR_INVALID_NWFILTER_BINDING: virErrorNumber = 100; pub const VIR_ERR_NO_NWFILTER_BINDING: virErrorNumber = 101; pub const VIR_ERR_INVALID_DOMAIN_CHECKPOINT: virErrorNumber = 102; pub const VIR_ERR_NO_DOMAIN_CHECKPOINT: virErrorNumber = 103; pub const VIR_ERR_NO_DOMAIN_BACKUP: virErrorNumber = 104; pub const VIR_ERR_INVALID_NETWORK_PORT: virErrorNumber = 105; pub const VIR_ERR_NETWORK_PORT_EXIST: virErrorNumber = 106; pub const VIR_ERR_NO_NETWORK_PORT: virErrorNumber = 107; pub const VIR_ERR_NO_HOSTNAME: virErrorNumber = 108; pub const VIR_ERR_CHECKPOINT_INCONSISTENT: virErrorNumber = 109; pub const VIR_ERR_MULTIPLE_DOMAINS: virErrorNumber = 110; pub const VIR_ERR_NO_NETWORK_METADATA: virErrorNumber = 111; pub type virErrorNumber = ::libc::c_uint; pub type virErrorFunc = ::std::option::Option; extern "C" { pub fn virGetLastError() -> virErrorPtr; } extern "C" { pub fn virSaveLastError() -> virErrorPtr; } extern "C" { pub fn virResetLastError(); } extern "C" { pub fn virResetError(err: virErrorPtr); } extern "C" { pub fn virFreeError(err: virErrorPtr); } extern "C" { pub fn virGetLastErrorCode() -> ::libc::c_int; } extern "C" { pub fn virGetLastErrorDomain() -> ::libc::c_int; } extern "C" { pub fn virGetLastErrorMessage() -> *const ::libc::c_char; } extern "C" { pub fn virConnGetLastError(conn: virConnectPtr) -> virErrorPtr; } extern "C" { pub fn virConnResetLastError(conn: virConnectPtr); } extern "C" { pub fn virCopyLastError(to: virErrorPtr) -> ::libc::c_int; } extern "C" { pub fn virDefaultErrorFunc(err: virErrorPtr); } extern "C" { pub fn virSetErrorFunc(userData: *mut ::libc::c_void, handler: virErrorFunc); } extern "C" { pub fn virConnSetErrorFunc( conn: virConnectPtr, userData: *mut ::libc::c_void, handler: virErrorFunc, ); } extern "C" { pub fn virConnCopyLastError(conn: virConnectPtr, to: virErrorPtr) -> ::libc::c_int; } pub const VIR_DOMAIN_QEMU_MONITOR_COMMAND_DEFAULT: virDomainQemuMonitorCommandFlags = 0; pub const VIR_DOMAIN_QEMU_MONITOR_COMMAND_HMP: virDomainQemuMonitorCommandFlags = 1; pub type virDomainQemuMonitorCommandFlags = ::libc::c_uint; extern "C" { pub fn virDomainQemuMonitorCommand( domain: virDomainPtr, cmd: *const ::libc::c_char, result: *mut *mut ::libc::c_char, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainQemuMonitorCommandWithFiles( domain: virDomainPtr, cmd: *const ::libc::c_char, ninfiles: ::libc::c_uint, infiles: *mut ::libc::c_int, noutfiles: *mut ::libc::c_uint, outfiles: *mut *mut ::libc::c_int, result: *mut *mut ::libc::c_char, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virDomainQemuAttach( domain: virConnectPtr, pid_value: ::libc::c_uint, flags: ::libc::c_uint, ) -> virDomainPtr; } pub const VIR_DOMAIN_QEMU_AGENT_COMMAND_MIN: virDomainQemuAgentCommandTimeoutValues = -2; pub const VIR_DOMAIN_QEMU_AGENT_COMMAND_BLOCK: virDomainQemuAgentCommandTimeoutValues = -2; pub const VIR_DOMAIN_QEMU_AGENT_COMMAND_DEFAULT: virDomainQemuAgentCommandTimeoutValues = -1; pub const VIR_DOMAIN_QEMU_AGENT_COMMAND_NOWAIT: virDomainQemuAgentCommandTimeoutValues = 0; pub const VIR_DOMAIN_QEMU_AGENT_COMMAND_SHUTDOWN: virDomainQemuAgentCommandTimeoutValues = 60; pub type virDomainQemuAgentCommandTimeoutValues = ::libc::c_int; extern "C" { pub fn virDomainQemuAgentCommand( domain: virDomainPtr, cmd: *const ::libc::c_char, timeout: ::libc::c_int, flags: ::libc::c_uint, ) -> *mut ::libc::c_char; } pub type virConnectDomainQemuMonitorEventCallback = ::std::option::Option< unsafe extern "C" fn( conn: virConnectPtr, dom: virDomainPtr, event: *const ::libc::c_char, seconds: ::libc::c_longlong, micros: ::libc::c_uint, details: *const ::libc::c_char, opaque: *mut ::libc::c_void, ), >; pub const VIR_CONNECT_DOMAIN_QEMU_MONITOR_EVENT_REGISTER_REGEX: virConnectDomainQemuMonitorEventRegisterFlags = 1; pub const VIR_CONNECT_DOMAIN_QEMU_MONITOR_EVENT_REGISTER_NOCASE: virConnectDomainQemuMonitorEventRegisterFlags = 2; pub type virConnectDomainQemuMonitorEventRegisterFlags = ::libc::c_uint; extern "C" { pub fn virConnectDomainQemuMonitorEventRegister( conn: virConnectPtr, dom: virDomainPtr, event: *const ::libc::c_char, cb: virConnectDomainQemuMonitorEventCallback, opaque: *mut ::libc::c_void, freecb: virFreeCallback, flags: ::libc::c_uint, ) -> ::libc::c_int; } extern "C" { pub fn virConnectDomainQemuMonitorEventDeregister( conn: virConnectPtr, callbackID: ::libc::c_int, ) -> ::libc::c_int; }