/linux/tools/testing/selftests/kvm/include/ |
A D | kvm_util.h | 147 void vm_vcpu_add(struct kvm_vm *vm, uint32_t vcpuid); 177 void vcpu_run(struct kvm_vm *vm, uint32_t vcpuid); 178 int _vcpu_run(struct kvm_vm *vm, uint32_t vcpuid); 179 int vcpu_get_fd(struct kvm_vm *vm, uint32_t vcpuid); 209 void vcpu_sregs_get(struct kvm_vm *vm, uint32_t vcpuid, 211 void vcpu_sregs_set(struct kvm_vm *vm, uint32_t vcpuid, 213 int _vcpu_sregs_set(struct kvm_vm *vm, uint32_t vcpuid, 215 void vcpu_fpu_get(struct kvm_vm *vm, uint32_t vcpuid, 217 void vcpu_fpu_set(struct kvm_vm *vm, uint32_t vcpuid, 222 void vcpu_events_get(struct kvm_vm *vm, uint32_t vcpuid, [all …]
|
/linux/tools/testing/selftests/kvm/lib/ |
A D | kvm_util.c | 375 uint32_t vcpuid = vcpuids ? vcpuids[i] : i; in vm_create_with_vcpus() local 395 (uint32_t []){ vcpuid }); in vm_create_default() 553 if (vcpu->id == vcpuid) in vcpu_find() 1128 vcpu = vcpu_find(vm, vcpuid); in vm_vcpu_add() 1134 vcpuid, vcpu->id, vcpu->state); in vm_vcpu_add() 1139 vcpu->id = vcpuid; in vm_vcpu_add() 1150 "vcpu id: %u errno: %i", vcpuid, errno); in vm_vcpu_add() 1509 struct vcpu *vcpu = vcpu_find(vm, vcpuid); in vcpu_state() 1531 int ret = _vcpu_run(vm, vcpuid); in vcpu_run() 1870 ret = _vcpu_ioctl(vm, vcpuid, cmd, arg); in vcpu_ioctl() [all …]
|
A D | kvm_util_internal.h | 72 struct vcpu *vcpu_find(struct kvm_vm *vm, uint32_t vcpuid);
|
/linux/tools/testing/selftests/kvm/lib/aarch64/ |
A D | processor.c | 229 vcpu_ioctl(vm, vcpuid, KVM_ARM_VCPU_INIT, init); in aarch64_vcpu_setup() 238 get_reg(vm, vcpuid, KVM_ARM64_SYS_REG(SYS_TCR_EL1), &tcr_el1); in aarch64_vcpu_setup() 277 set_reg(vm, vcpuid, KVM_ARM64_SYS_REG(SYS_TCR_EL1), tcr_el1); in aarch64_vcpu_setup() 280 set_reg(vm, vcpuid, KVM_ARM64_SYS_REG(SYS_TPIDR_EL1), vcpuid); in aarch64_vcpu_setup() 287 get_reg(vm, vcpuid, ARM64_CORE_REG(regs.pstate), &pstate); in vcpu_dump() 288 get_reg(vm, vcpuid, ARM64_CORE_REG(regs.pc), &pc); in vcpu_dump() 303 vm_vcpu_add(vm, vcpuid); in aarch64_vcpu_add_default() 304 aarch64_vcpu_setup(vm, vcpuid, init); in aarch64_vcpu_add_default() 312 aarch64_vcpu_add_default(vm, vcpuid, NULL, guest_code); in vm_vcpu_add_default() 326 set_reg(vm, vcpuid, ARM64_CORE_REG(regs.regs[i]), in vcpu_args_set() [all …]
|
/linux/tools/testing/selftests/kvm/lib/x86_64/ |
A D | processor.c | 308 vcpu_sregs_get(vm, vcpuid, &sregs); in _vm_get_page_table_entry() 626 vcpu_sregs_get(vm, vcpuid, &sregs); in vcpu_setup() 650 vcpu_sregs_set(vm, vcpuid, &sregs); in vcpu_setup() 662 vm_vcpu_add(vm, vcpuid); in vm_vcpu_add_default() 664 vcpu_setup(vm, vcpuid); in vm_vcpu_add_default() 667 vcpu_regs_get(vm, vcpuid, ®s); in vm_vcpu_add_default() 671 vcpu_regs_set(vm, vcpuid, ®s); in vm_vcpu_add_default() 980 vcpu_regs_get(vm, vcpuid, ®s); in vcpu_args_set() 1000 vcpu_regs_set(vm, vcpuid, ®s); in vcpu_args_set() 1012 vcpu_regs_get(vm, vcpuid, ®s); in vcpu_dump() [all …]
|
/linux/tools/testing/selftests/kvm/lib/s390x/ |
A D | processor.c | 172 vm_vcpu_add(vm, vcpuid); in vm_vcpu_add_default() 175 vcpu_regs_get(vm, vcpuid, ®s); in vm_vcpu_add_default() 177 vcpu_regs_set(vm, vcpuid, ®s); in vm_vcpu_add_default() 179 vcpu_sregs_get(vm, vcpuid, &sregs); in vm_vcpu_add_default() 182 vcpu_sregs_set(vm, vcpuid, &sregs); in vm_vcpu_add_default() 184 run = vcpu_state(vm, vcpuid); in vm_vcpu_add_default() 189 void vcpu_args_set(struct kvm_vm *vm, uint32_t vcpuid, unsigned int num, ...) in vcpu_args_set() argument 200 vcpu_regs_get(vm, vcpuid, ®s); in vcpu_args_set() 205 vcpu_regs_set(vm, vcpuid, ®s); in vcpu_args_set() 211 struct vcpu *vcpu = vcpu_find(vm, vcpuid); in vcpu_dump() [all …]
|
/linux/tools/testing/selftests/kvm/include/x86_64/ |
A D | processor.h | 352 struct kvm_x86_state *vcpu_save_state(struct kvm_vm *vm, uint32_t vcpuid); 353 void vcpu_load_state(struct kvm_vm *vm, uint32_t vcpuid, 360 struct kvm_cpuid2 *vcpu_get_cpuid(struct kvm_vm *vm, uint32_t vcpuid); 361 void vcpu_set_cpuid(struct kvm_vm *vm, uint32_t vcpuid, 373 uint64_t vcpu_get_msr(struct kvm_vm *vm, uint32_t vcpuid, uint64_t msr_index); 374 int _vcpu_set_msr(struct kvm_vm *vm, uint32_t vcpuid, uint64_t msr_index, 376 void vcpu_set_msr(struct kvm_vm *vm, uint32_t vcpuid, uint64_t msr_index, 396 void vcpu_init_descriptor_tables(struct kvm_vm *vm, uint32_t vcpuid); 400 uint64_t vm_get_page_table_entry(struct kvm_vm *vm, int vcpuid, uint64_t vaddr); 401 void vm_set_page_table_entry(struct kvm_vm *vm, int vcpuid, uint64_t vaddr, [all …]
|
/linux/tools/testing/selftests/kvm/ |
A D | steal_time.c | 85 static void steal_time_dump(struct kvm_vm *vm, uint32_t vcpuid) in steal_time_dump() argument 87 struct kvm_steal_time *st = addr_gva2hva(vm, (ulong)st_gva[vcpuid]); in steal_time_dump() 90 pr_info("VCPU%d:\n", vcpuid); in steal_time_dump() 206 static void steal_time_dump(struct kvm_vm *vm, uint32_t vcpuid) in steal_time_dump() argument 208 struct st_time *st = addr_gva2hva(vm, (ulong)st_gva[vcpuid]); in steal_time_dump() 210 pr_info("VCPU%d:\n", vcpuid); in steal_time_dump() 234 static void run_vcpu(struct kvm_vm *vm, uint32_t vcpuid) in run_vcpu() argument 238 vcpu_args_set(vm, vcpuid, 1, vcpuid); in run_vcpu() 240 vcpu_ioctl(vm, vcpuid, KVM_RUN, NULL); in run_vcpu() 242 switch (get_ucall(vm, vcpuid, &uc)) { in run_vcpu() [all …]
|
A D | dirty_log_test.c | 674 static struct kvm_vm *create_vm(enum vm_guest_mode mode, uint32_t vcpuid, in create_vm() argument 688 vm_vcpu_add_default(vm, vcpuid, guest_code); in create_vm()
|
/linux/tools/testing/selftests/kvm/x86_64/ |
A D | set_boot_cpu_id.c | 50 static void run_vcpu(struct kvm_vm *vm, uint32_t vcpuid) in run_vcpu() argument 57 vcpu_run(vm, vcpuid); in run_vcpu() 59 switch (get_ucall(vm, vcpuid, &uc)) { in run_vcpu() 78 exit_reason_str(vcpu_state(vm, vcpuid)->exit_reason)); in run_vcpu() 99 static void add_x86_vcpu(struct kvm_vm *vm, uint32_t vcpuid, bool bsp_code) in add_x86_vcpu() argument 102 vm_vcpu_add_default(vm, vcpuid, guest_bsp_vcpu); in add_x86_vcpu() 104 vm_vcpu_add_default(vm, vcpuid, guest_not_bsp_vcpu); in add_x86_vcpu()
|
A D | tsc_msrs_test.c | 69 static void run_vcpu(struct kvm_vm *vm, uint32_t vcpuid, int stage) in run_vcpu() argument 73 vcpu_args_set(vm, vcpuid, 1, vcpuid); in run_vcpu() 75 vcpu_ioctl(vm, vcpuid, KVM_RUN, NULL); in run_vcpu() 77 switch (get_ucall(vm, vcpuid, &uc)) { in run_vcpu() 91 exit_reason_str(vcpu_state(vm, vcpuid)->exit_reason)); in run_vcpu()
|
A D | get_cpuid_test.c | 121 static void run_vcpu(struct kvm_vm *vm, uint32_t vcpuid, int stage) in run_vcpu() argument 125 _vcpu_run(vm, vcpuid); in run_vcpu() 127 switch (get_ucall(vm, vcpuid, &uc)) { in run_vcpu() 141 exit_reason_str(vcpu_state(vm, vcpuid)->exit_reason)); in run_vcpu()
|
/linux/tools/testing/selftests/kvm/include/aarch64/ |
A D | processor.h | 50 static inline void get_reg(struct kvm_vm *vm, uint32_t vcpuid, uint64_t id, uint64_t *addr) in get_reg() argument 55 vcpu_ioctl(vm, vcpuid, KVM_GET_ONE_REG, ®); in get_reg() 58 static inline void set_reg(struct kvm_vm *vm, uint32_t vcpuid, uint64_t id, uint64_t val) in set_reg() argument 63 vcpu_ioctl(vm, vcpuid, KVM_SET_ONE_REG, ®); in set_reg() 66 void aarch64_vcpu_setup(struct kvm_vm *vm, uint32_t vcpuid, struct kvm_vcpu_init *init); 67 void aarch64_vcpu_add_default(struct kvm_vm *vm, uint32_t vcpuid, 117 void vcpu_init_descriptor_tables(struct kvm_vm *vm, uint32_t vcpuid);
|
/linux/tools/testing/selftests/kvm/aarch64/ |
A D | arch_timer.c | 80 uint32_t vcpuid; member 223 uint32_t vcpuid = vcpu->vcpuid; in test_vcpu_run() local 224 struct test_vcpu_shared_data *shared_data = &vcpu_shared_data[vcpuid]; in test_vcpu_run() 226 vcpu_run(vm, vcpuid); in test_vcpu_run() 230 set_bit(vcpuid, vcpu_done_map); in test_vcpu_run() 233 switch (get_ucall(vm, vcpuid, &uc)) { in test_vcpu_run() 241 uc.args[2], uc.args[3], uc.args[4], vcpuid, in test_vcpu_run() 277 pr_debug("Migrating vCPU: %u to pCPU: %u\n", vcpu->vcpuid, new_pcpu); in test_migrate_vcpu() 285 vcpu->vcpuid, new_pcpu, ret); in test_migrate_vcpu() 379 test_vcpu[i].vcpuid = i; in test_vm_create()
|
A D | vgic_init.c | 55 static int run_vcpu(struct kvm_vm *vm, uint32_t vcpuid) in run_vcpu() argument 58 int ret = _vcpu_ioctl(vm, vcpuid, KVM_RUN, NULL); in run_vcpu()
|
A D | get-reg-list.c | 375 static void finalize_vcpu(struct kvm_vm *vm, uint32_t vcpuid, struct vcpu_config *c) in finalize_vcpu() argument 383 vcpu_ioctl(vm, vcpuid, KVM_ARM_VCPU_FINALIZE, &feature); in finalize_vcpu()
|
/linux/include/xen/arm/ |
A D | hypercall.h | 55 int HYPERVISOR_vcpu_op(int cmd, int vcpuid, void *extra_args);
|
/linux/arch/x86/include/asm/xen/ |
A D | hypercall.h | 462 HYPERVISOR_vcpu_op(int cmd, int vcpuid, void *extra_args) in HYPERVISOR_vcpu_op() argument 464 return _hypercall3(int, vcpu_op, cmd, vcpuid, extra_args); in HYPERVISOR_vcpu_op()
|
/linux/arch/x86/kvm/ |
A D | trace.h | 1417 TP_PROTO(u32 vmid, u32 vcpuid), 1418 TP_ARGS(vmid, vcpuid), 1422 __field(u32, vcpuid) 1427 __entry->vcpuid = vcpuid; 1431 __entry->vmid, __entry->vcpuid)
|
/linux/arch/powerpc/kvm/ |
A D | book3s_hv.c | 481 unsigned long vcpuid, unsigned long vpa) in do_h_register_vpa() argument 491 tvcpu = kvmppc_find_vcpu(kvm, vcpuid); in do_h_register_vpa()
|