On 09/21/2018 06:56 PM, Wei Yang wrote:
vmx->vcpu.arch.cr0 will be set in vmx_set_cr0().
This patch removes duplicate cr0 set in vmx_vcpu_reset().
Signed-off-by: Wei Yang <richard.weiyang@xxxxxxxxx>
---
arch/x86/kvm/vmx.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/arch/x86/kvm/vmx.c b/arch/x86/kvm/vmx.c
index 1519f030fd73..b1e1d63a4970 100644
--- a/arch/x86/kvm/vmx.c
+++ b/arch/x86/kvm/vmx.c
@@ -6734,7 +6734,6 @@ static void vmx_vcpu_reset(struct kvm_vcpu *vcpu, bool init_event)
vmcs_write16(VIRTUAL_PROCESSOR_ID, vmx->vpid);
cr0 = X86_CR0_NW | X86_CR0_CD | X86_CR0_ET;
- vmx->vcpu.arch.cr0 = cr0;
vmx_set_cr0(vcpu, cr0); /* enter rmode */
vmx_set_cr4(vcpu, 0);
vmx_set_efer(vcpu, 0);
Reviewed-by: Krish Sadhukhan <krish.sadhukhan@xxxxxxxxxx>