Lines Matching refs:nr_vcpus
267 if (!hyp_vm || hyp_vm->nr_vcpus <= vcpu_idx) in pkvm_load_hyp_vcpu()
293 unsigned int nr_vcpus) in unpin_host_vcpus() argument
297 for (i = 0; i < nr_vcpus; i++) in unpin_host_vcpus()
302 unsigned int nr_vcpus) in init_pkvm_hyp_vm() argument
305 hyp_vm->kvm.created_vcpus = nr_vcpus; in init_pkvm_hyp_vm()
397 static size_t pkvm_get_hyp_vm_size(unsigned int nr_vcpus) in pkvm_get_hyp_vm_size() argument
400 size_mul(sizeof(struct pkvm_hyp_vcpu *), nr_vcpus)); in pkvm_get_hyp_vm_size()
471 unsigned int nr_vcpus; in __pkvm_init_vm() local
479 nr_vcpus = READ_ONCE(host_kvm->created_vcpus); in __pkvm_init_vm()
480 if (nr_vcpus < 1) { in __pkvm_init_vm()
485 vm_size = pkvm_get_hyp_vm_size(nr_vcpus); in __pkvm_init_vm()
498 init_pkvm_hyp_vm(host_kvm, hyp_vm, nr_vcpus); in __pkvm_init_vm()
555 idx = hyp_vm->nr_vcpus; in __pkvm_init_vcpu()
566 hyp_vm->nr_vcpus++; in __pkvm_init_vcpu()
619 unpin_host_vcpus(hyp_vm->vcpus, hyp_vm->nr_vcpus); in __pkvm_teardown_vm()
622 for (idx = 0; idx < hyp_vm->nr_vcpus; ++idx) { in __pkvm_teardown_vm()