lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <6e95b6f7-44dc-7e48-4e6e-81cf85fc11c6@redhat.com>
Date:   Mon, 20 Dec 2021 10:07:00 +0100
From:   Paolo Bonzini <pbonzini@...hat.com>
To:     Jing Liu <jing2.liu@...el.com>, x86@...nel.org,
        kvm@...r.kernel.org, linux-kernel@...r.kernel.org,
        tglx@...utronix.de, mingo@...hat.com, bp@...en8.de,
        dave.hansen@...ux.intel.com
Cc:     seanjc@...gle.com, jun.nakajima@...el.com, kevin.tian@...el.com,
        jing2.liu@...ux.intel.com, guang.zeng@...el.com,
        wei.w.wang@...el.com, yang.zhong@...el.com
Subject: Re: [PATCH v2 22/23] kvm: x86: Disable interception for IA32_XFD on
 demand

On 12/17/21 16:30, Jing Liu wrote:
> +++ b/arch/x86/kvm/x86.c
> @@ -3686,6 +3686,9 @@ int kvm_set_msr_common(struct kvm_vcpu *vcpu, struct msr_data *msr_info)
>   			return 1;
>   
>   		fpu_update_guest_xfd(&vcpu->arch.guest_fpu, data);
> +
> +		if (data && kvm_x86_ops.set_xfd_passthrough)
> +			static_call(kvm_x86_set_xfd_passthrough)(vcpu);
>   		break;
>   	case MSR_IA32_XFD_ERR:


Please instead add a "case" to vmx_set_msr:

	case MSR_IA32_XFD:
		ret = kvm_set_msr_common(vcpu, msr_info);
		if (!ret && data) {
			vmx_disable_intercept_for_msr(vcpu, MSR_IA32_XFD, MSR_TYPE_RW);
			vcpu->arch.xfd_out_of_sync = true;
		}
		break;

Paolo

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ