Changeset View
Changeset View
Standalone View
Standalone View
sys/amd64/include/vmm_dev.h
| Show First 20 Lines • Show All 251 Lines • ▼ Show 20 Lines | struct vm_readwrite_kernemu_device { | ||||
| int vcpuid; | int vcpuid; | ||||
| unsigned access_width : 3; | unsigned access_width : 3; | ||||
| unsigned _unused : 29; | unsigned _unused : 29; | ||||
| uint64_t gpa; | uint64_t gpa; | ||||
| uint64_t value; | uint64_t value; | ||||
| }; | }; | ||||
| _Static_assert(sizeof(struct vm_readwrite_kernemu_device) == 24, "ABI"); | _Static_assert(sizeof(struct vm_readwrite_kernemu_device) == 24, "ABI"); | ||||
| struct vm_get_dirty_page_list { | |||||
| uint8_t *page_list; | |||||
| size_t num_pages; | |||||
| uint8_t is_all_dirty; | |||||
| vm_offset_t lowmem_start; | |||||
| vm_offset_t lowmem_end; | |||||
| vm_offset_t highmem_start; | |||||
| vm_offset_t highmem_end; | |||||
| }; | |||||
| enum { | enum { | ||||
| /* general routines */ | /* general routines */ | ||||
| IOCNUM_ABIVERS = 0, | IOCNUM_ABIVERS = 0, | ||||
| IOCNUM_RUN = 1, | IOCNUM_RUN = 1, | ||||
| IOCNUM_SET_CAPABILITY = 2, | IOCNUM_SET_CAPABILITY = 2, | ||||
| IOCNUM_GET_CAPABILITY = 3, | IOCNUM_GET_CAPABILITY = 3, | ||||
| IOCNUM_SUSPEND = 4, | IOCNUM_SUSPEND = 4, | ||||
| IOCNUM_REINIT = 5, | IOCNUM_REINIT = 5, | ||||
| ▲ Show 20 Lines • Show All 72 Lines • ▼ Show 20 Lines | enum { | ||||
| IOCNUM_RTC_READ = 100, | IOCNUM_RTC_READ = 100, | ||||
| IOCNUM_RTC_WRITE = 101, | IOCNUM_RTC_WRITE = 101, | ||||
| IOCNUM_RTC_SETTIME = 102, | IOCNUM_RTC_SETTIME = 102, | ||||
| IOCNUM_RTC_GETTIME = 103, | IOCNUM_RTC_GETTIME = 103, | ||||
| /* checkpoint */ | /* checkpoint */ | ||||
| IOCNUM_SNAPSHOT_REQ = 113, | IOCNUM_SNAPSHOT_REQ = 113, | ||||
| IOCNUM_RESTORE_TIME = 115 | IOCNUM_RESTORE_TIME = 115, | ||||
| IOCNUM_VM_GET_DIRTY_PAGE_LIST = 117, | |||||
| }; | }; | ||||
| #define VM_RUN \ | #define VM_RUN \ | ||||
| _IOWR('v', IOCNUM_RUN, struct vm_run) | _IOWR('v', IOCNUM_RUN, struct vm_run) | ||||
| #define VM_SUSPEND \ | #define VM_SUSPEND \ | ||||
| _IOW('v', IOCNUM_SUSPEND, struct vm_suspend) | _IOW('v', IOCNUM_SUSPEND, struct vm_suspend) | ||||
| #define VM_REINIT \ | #define VM_REINIT \ | ||||
| _IO('v', IOCNUM_REINIT) | _IO('v', IOCNUM_REINIT) | ||||
| ▲ Show 20 Lines • Show All 114 Lines • ▼ Show 20 Lines | |||||
| #define VM_RTC_GETTIME \ | #define VM_RTC_GETTIME \ | ||||
| _IOR('v', IOCNUM_RTC_GETTIME, struct vm_rtc_time) | _IOR('v', IOCNUM_RTC_GETTIME, struct vm_rtc_time) | ||||
| #define VM_RESTART_INSTRUCTION \ | #define VM_RESTART_INSTRUCTION \ | ||||
| _IOW('v', IOCNUM_RESTART_INSTRUCTION, int) | _IOW('v', IOCNUM_RESTART_INSTRUCTION, int) | ||||
| #define VM_SNAPSHOT_REQ \ | #define VM_SNAPSHOT_REQ \ | ||||
| _IOWR('v', IOCNUM_SNAPSHOT_REQ, struct vm_snapshot_meta) | _IOWR('v', IOCNUM_SNAPSHOT_REQ, struct vm_snapshot_meta) | ||||
| #define VM_RESTORE_TIME \ | #define VM_RESTORE_TIME \ | ||||
| _IOWR('v', IOCNUM_RESTORE_TIME, int) | _IOWR('v', IOCNUM_RESTORE_TIME, int) | ||||
| #define VM_GET_DIRTY_PAGE_LIST \ | |||||
| _IOWR('v', IOCNUM_VM_GET_DIRTY_PAGE_LIST, struct vm_get_dirty_page_list) | |||||
| #endif | #endif | ||||