Re: [PATCH v2 06/25] KVM: VMX: Defer enabling FRED MSRs save/load until after set CPUID

From: Chao Gao
Date: Fri Apr 19 2024 - 07:03:15 EST


On Wed, Feb 07, 2024 at 09:26:26AM -0800, Xin Li wrote:
>Clear FRED VM entry/exit controls when initializing a vCPU, and set
>these controls only if FRED is enumerated after set CPUID.
>
>FRED VM entry/exit controls need to be set to establish context
>sufficient to support FRED event delivery immediately after VM entry
>and exit. However it is not required to save/load FRED MSRs for
>a non-FRED guest, which aren't supposed to access FRED MSRs.
>
>Signed-off-by: Xin Li <xin3.li@xxxxxxxxx>
>Tested-by: Shan Kang <shan.kang@xxxxxxxxx>

Reviewed-by: Chao Gao <chao.gao@xxxxxxxxx>