Home
last modified time | relevance | path

Searched refs:vmfd (Results 1 – 5 of 5) sorted by relevance

/openbmc/qemu/target/riscv/kvm/
H A Dkvm-cpu.c874 int vmfd; member
884 int kvmfd = -1, vmfd = -1, cpufd = -1; in kvm_riscv_create_scratch_vcpu() local
891 vmfd = ioctl(kvmfd, KVM_CREATE_VM, 0); in kvm_riscv_create_scratch_vcpu()
892 } while (vmfd == -1 && errno == EINTR); in kvm_riscv_create_scratch_vcpu()
893 if (vmfd < 0) { in kvm_riscv_create_scratch_vcpu()
896 cpufd = ioctl(vmfd, KVM_CREATE_VCPU, 0); in kvm_riscv_create_scratch_vcpu()
902 scratch->vmfd = vmfd; in kvm_riscv_create_scratch_vcpu()
911 if (vmfd >= 0) { in kvm_riscv_create_scratch_vcpu()
912 close(vmfd); in kvm_riscv_create_scratch_vcpu()
924 close(scratch->vmfd); in kvm_riscv_destroy_scratch_vcpu()
/openbmc/qemu/include/sysemu/
H A Dkvm_int.h109 int vmfd; member
H A Dkvm.h314 bool kvm_device_supported(int vmfd, uint64_t type);
/openbmc/qemu/target/arm/
H A Dkvm.c105 int ret = 0, kvmfd = -1, vmfd = -1, cpufd = -1; in kvm_arm_create_scratch_host_vcpu() local
117 vmfd = ioctl(kvmfd, KVM_CREATE_VM, max_vm_pa_size); in kvm_arm_create_scratch_host_vcpu()
118 } while (vmfd == -1 && errno == EINTR); in kvm_arm_create_scratch_host_vcpu()
119 if (vmfd < 0) { in kvm_arm_create_scratch_host_vcpu()
122 cpufd = ioctl(vmfd, KVM_CREATE_VCPU, 0); in kvm_arm_create_scratch_host_vcpu()
135 ret = ioctl(vmfd, KVM_ARM_PREFERRED_TARGET, &preferred); in kvm_arm_create_scratch_host_vcpu()
175 fdarray[1] = vmfd; in kvm_arm_create_scratch_host_vcpu()
184 if (vmfd >= 0) { in kvm_arm_create_scratch_host_vcpu()
185 close(vmfd); in kvm_arm_create_scratch_host_vcpu()
/openbmc/qemu/accel/kvm/
H A Dkvm-all.c2573 s->vmfd = ret; in kvm_init()
2736 if (s->vmfd >= 0) { in kvm_init()
2737 close(s->vmfd); in kvm_init()
3260 ret = ioctl(s->vmfd, type, arg); in kvm_vm_ioctl()
3655 bool kvm_device_supported(int vmfd, uint64_t type) in kvm_device_supported() argument
3663 if (ioctl(vmfd, KVM_CHECK_EXTENSION, KVM_CAP_DEVICE_CTRL) <= 0) { in kvm_device_supported()
3667 return (ioctl(vmfd, KVM_CREATE_DEVICE, &create_dev) >= 0); in kvm_device_supported()
3869 s->vmfd = -1; in kvm_accel_instance_init()