Lines Matching full:hv

286 	struct kvm_hv *hv = &kvm->arch.hyperv;  in kvm_hv_syndbg_complete_userspace()  local
289 hv->hv_syndbg.control.status = in kvm_hv_syndbg_complete_userspace()
517 struct kvm_hv *hv = &kvm->arch.hyperv; in get_time_ref_counter() local
525 if (!hv->tsc_ref.tsc_sequence) in get_time_ref_counter()
530 return mul_u64_u64_shr(tsc, hv->tsc_ref.tsc_scale, 64) in get_time_ref_counter()
531 + hv->tsc_ref.tsc_offset; in get_time_ref_counter()
945 struct kvm_hv *hv = &vcpu->kvm->arch.hyperv; in kvm_hv_msr_get_crash_data() local
946 size_t size = ARRAY_SIZE(hv->hv_crash_param); in kvm_hv_msr_get_crash_data()
951 *pdata = hv->hv_crash_param[array_index_nospec(index, size)]; in kvm_hv_msr_get_crash_data()
957 struct kvm_hv *hv = &vcpu->kvm->arch.hyperv; in kvm_hv_msr_get_crash_ctl() local
959 *pdata = hv->hv_crash_ctl; in kvm_hv_msr_get_crash_ctl()
965 struct kvm_hv *hv = &vcpu->kvm->arch.hyperv; in kvm_hv_msr_set_crash_ctl() local
968 hv->hv_crash_ctl = data & HV_CRASH_CTL_CRASH_NOTIFY; in kvm_hv_msr_set_crash_ctl()
972 vcpu_debug(vcpu, "hv crash (0x%llx 0x%llx 0x%llx 0x%llx 0x%llx)\n", in kvm_hv_msr_set_crash_ctl()
973 hv->hv_crash_param[0], in kvm_hv_msr_set_crash_ctl()
974 hv->hv_crash_param[1], in kvm_hv_msr_set_crash_ctl()
975 hv->hv_crash_param[2], in kvm_hv_msr_set_crash_ctl()
976 hv->hv_crash_param[3], in kvm_hv_msr_set_crash_ctl()
977 hv->hv_crash_param[4]); in kvm_hv_msr_set_crash_ctl()
989 struct kvm_hv *hv = &vcpu->kvm->arch.hyperv; in kvm_hv_msr_set_crash_data() local
990 size_t size = ARRAY_SIZE(hv->hv_crash_param); in kvm_hv_msr_set_crash_data()
995 hv->hv_crash_param[array_index_nospec(index, size)] = data; in kvm_hv_msr_set_crash_data()
1071 struct kvm_hv *hv = &kvm->arch.hyperv; in kvm_hv_setup_tsc_page() local
1075 BUILD_BUG_ON(sizeof(tsc_seq) != sizeof(hv->tsc_ref.tsc_sequence)); in kvm_hv_setup_tsc_page()
1078 if (!(hv->hv_tsc_page & HV_X64_MSR_TSC_REFERENCE_ENABLE)) in kvm_hv_setup_tsc_page()
1082 if (!(hv->hv_tsc_page & HV_X64_MSR_TSC_REFERENCE_ENABLE)) in kvm_hv_setup_tsc_page()
1085 gfn = hv->hv_tsc_page >> HV_X64_MSR_TSC_REFERENCE_ADDRESS_SHIFT; in kvm_hv_setup_tsc_page()
1098 hv->tsc_ref.tsc_sequence = 0; in kvm_hv_setup_tsc_page()
1100 &hv->tsc_ref, sizeof(hv->tsc_ref.tsc_sequence))) in kvm_hv_setup_tsc_page()
1103 if (!compute_tsc_page_parameters(hv_clock, &hv->tsc_ref)) in kvm_hv_setup_tsc_page()
1108 if (kvm_write_guest(kvm, gfn_to_gpa(gfn), &hv->tsc_ref, sizeof(hv->tsc_ref))) in kvm_hv_setup_tsc_page()
1121 hv->tsc_ref.tsc_sequence = tsc_seq; in kvm_hv_setup_tsc_page()
1123 &hv->tsc_ref, sizeof(hv->tsc_ref.tsc_sequence)); in kvm_hv_setup_tsc_page()
1132 struct kvm_hv *hv = &kvm->arch.hyperv; in kvm_hv_set_msr_pw() local
1136 hv->hv_guest_os_id = data; in kvm_hv_set_msr_pw()
1138 if (!hv->hv_guest_os_id) in kvm_hv_set_msr_pw()
1139 hv->hv_hypercall &= ~HV_X64_MSR_HYPERCALL_ENABLE; in kvm_hv_set_msr_pw()
1147 if (!hv->hv_guest_os_id) in kvm_hv_set_msr_pw()
1150 hv->hv_hypercall = data; in kvm_hv_set_msr_pw()
1161 hv->hv_hypercall = data; in kvm_hv_set_msr_pw()
1166 hv->hv_tsc_page = data; in kvm_hv_set_msr_pw()
1167 if (hv->hv_tsc_page & HV_X64_MSR_TSC_REFERENCE_ENABLE) in kvm_hv_set_msr_pw()
1183 hv->hv_reenlightenment_control = data; in kvm_hv_set_msr_pw()
1186 hv->hv_tsc_emulation_control = data; in kvm_hv_set_msr_pw()
1189 hv->hv_tsc_emulation_status = data; in kvm_hv_set_msr_pw()
1223 struct kvm_hv *hv = &vcpu->kvm->arch.hyperv; in kvm_hv_set_msr() local
1240 atomic_inc(&hv->num_mismatched_vp_indexes); in kvm_hv_set_msr()
1242 atomic_dec(&hv->num_mismatched_vp_indexes); in kvm_hv_set_msr()
1333 struct kvm_hv *hv = &kvm->arch.hyperv; in kvm_hv_get_msr_pw() local
1337 data = hv->hv_guest_os_id; in kvm_hv_get_msr_pw()
1340 data = hv->hv_hypercall; in kvm_hv_get_msr_pw()
1346 data = hv->hv_tsc_page; in kvm_hv_get_msr_pw()
1358 data = hv->hv_reenlightenment_control; in kvm_hv_get_msr_pw()
1361 data = hv->hv_tsc_emulation_control; in kvm_hv_get_msr_pw()
1364 data = hv->hv_tsc_emulation_status; in kvm_hv_get_msr_pw()
1469 struct kvm_hv *hv = &kvm->arch.hyperv; in sparse_set_to_vcpu_mask() local
1479 if (likely(!atomic_read(&hv->num_mismatched_vp_indexes))) { in sparse_set_to_vcpu_mask()
1904 struct kvm_hv *hv = &kvm->arch.hyperv; in kvm_hv_eventfd_assign() local
1912 mutex_lock(&hv->hv_lock); in kvm_hv_eventfd_assign()
1913 ret = idr_alloc(&hv->conn_to_evt, eventfd, conn_id, conn_id + 1, in kvm_hv_eventfd_assign()
1915 mutex_unlock(&hv->hv_lock); in kvm_hv_eventfd_assign()
1928 struct kvm_hv *hv = &kvm->arch.hyperv; in kvm_hv_eventfd_deassign() local
1931 mutex_lock(&hv->hv_lock); in kvm_hv_eventfd_deassign()
1932 eventfd = idr_remove(&hv->conn_to_evt, conn_id); in kvm_hv_eventfd_deassign()
1933 mutex_unlock(&hv->hv_lock); in kvm_hv_eventfd_deassign()
1991 memcpy(signature, "Linux KVM Hv", 12); in kvm_vcpu_ioctl_get_hv_cpuid()
2000 memcpy(signature, "Hv#1\0\0\0\0\0\0\0\0", 12); in kvm_vcpu_ioctl_get_hv_cpuid()
2080 memcpy(signature, "Linux KVM Hv", 12); in kvm_vcpu_ioctl_get_hv_cpuid()