Home
last modified time | relevance | path

Searched refs:kvm_caps (Results 1 – 9 of 9) sorted by relevance

/linux-6.1.9/arch/x86/kvm/
Dx86.h11 struct kvm_caps { struct
313 extern struct kvm_caps kvm_caps;
319 return (kvm_caps.supported_xcr0 & (XFEATURE_MASK_BNDREGS | XFEATURE_MASK_BNDCSR)) in kvm_mpx_supported()
Ddebugfs.c51 *val = kvm_caps.tsc_scaling_ratio_frac_bits; in vcpu_get_tsc_scaling_frac_bits()
69 if (kvm_caps.has_tsc_control) { in kvm_arch_create_vcpu_debugfs()
Dx86.c90 struct kvm_caps kvm_caps __read_mostly = {
93 EXPORT_SYMBOL_GPL(kvm_caps);
2385 kvm_vcpu_write_tsc_multiplier(vcpu, kvm_caps.default_tsc_scaling_ratio); in set_tsc_khz()
2390 if (!kvm_caps.has_tsc_control) { in set_tsc_khz()
2402 ratio = mul_u64_u32_div(1ULL << kvm_caps.tsc_scaling_ratio_frac_bits, in set_tsc_khz()
2405 if (ratio == 0 || ratio >= kvm_caps.max_tsc_scaling_ratio) { in set_tsc_khz()
2423 kvm_vcpu_write_tsc_multiplier(vcpu, kvm_caps.default_tsc_scaling_ratio); in kvm_set_tsc_khz()
2504 return mul_u64_u64_shr(tsc, ratio, kvm_caps.tsc_scaling_ratio_frac_bits); in __scale_tsc()
2511 if (ratio != kvm_caps.default_tsc_scaling_ratio) in kvm_scale_tsc()
2538 if (l2_multiplier == kvm_caps.default_tsc_scaling_ratio) in kvm_calc_nested_tsc_offset()
[all …]
Dcpuid.c245 return (best->eax | ((u64)best->edx << 32)) & kvm_caps.supported_xcr0; in cpuid_get_supported_xcr0()
963 u64 permitted_xcr0 = kvm_caps.supported_xcr0 & xstate_get_guest_group_perm(); in __do_cpuid_func()
964 u64 permitted_xss = kvm_caps.supported_xss; in __do_cpuid_func()
Dlapic.c1634 if (vcpu->arch.tsc_scaling_ratio == kvm_caps.default_tsc_scaling_ratio) { in __wait_lapic_expire()
/linux-6.1.9/arch/x86/kvm/vmx/
Dvmx.c1813 return kvm_caps.default_tsc_scaling_ratio; in vmx_get_l2_tsc_multiplier()
7703 kvm_caps.supported_xss = 0; in vmx_set_cpu_caps()
7844 if (vcpu->arch.l1_tsc_scaling_ratio != kvm_caps.default_tsc_scaling_ratio && in vmx_set_hv_timer()
7846 kvm_caps.tsc_scaling_ratio_frac_bits, in vmx_set_hv_timer()
8236 kvm_caps.supported_xcr0 &= ~(XFEATURE_MASK_BNDREGS | in hardware_setup()
8309 kvm_caps.has_tsc_control = true; in hardware_setup()
8311 kvm_caps.max_tsc_scaling_ratio = KVM_VMX_TSC_MULTIPLIER_MAX; in hardware_setup()
8312 kvm_caps.tsc_scaling_ratio_frac_bits = 48; in hardware_setup()
8313 kvm_caps.has_bus_lock_exit = cpu_has_vmx_bus_lock_detection(); in hardware_setup()
8314 kvm_caps.has_notify_vmexit = cpu_has_notify_vmexit(); in hardware_setup()
[all …]
Dnested.c2557 if (kvm_caps.has_tsc_control) in prepare_vmcs02()
4774 if (kvm_caps.has_tsc_control) in nested_vmx_vmexit()
/linux-6.1.9/arch/x86/kvm/svm/
Dsvm.c1326 svm->tsc_ratio_msr = kvm_caps.default_tsc_scaling_ratio; in __svm_vcpu_reset()
4854 kvm_caps.supported_xss = 0; in svm_set_cpu_caps()
4930 kvm_caps.supported_xcr0 &= ~(XFEATURE_MASK_BNDREGS | in svm_hardware_setup()
4941 kvm_caps.has_tsc_control = true; in svm_hardware_setup()
4944 kvm_caps.max_tsc_scaling_ratio = SVM_TSC_RATIO_MAX; in svm_hardware_setup()
4945 kvm_caps.tsc_scaling_ratio_frac_bits = 32; in svm_hardware_setup()
Dnested.c664 if (svm->tsc_ratio_msr != kvm_caps.default_tsc_scaling_ratio) { in nested_vmcb02_prepare_control()
1026 if (svm->tsc_ratio_msr != kvm_caps.default_tsc_scaling_ratio) { in nested_svm_vmexit()