We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 997224f + 95fa101 commit 018cabbCopy full SHA for 018cabb
arch/x86/kvm/vmx/nested.c
@@ -224,7 +224,7 @@ static inline void nested_release_evmcs(struct kvm_vcpu *vcpu)
224
return;
225
226
kvm_vcpu_unmap(vcpu, &vmx->nested.hv_evmcs_map, true);
227
- vmx->nested.hv_evmcs_vmptr = -1ull;
+ vmx->nested.hv_evmcs_vmptr = 0;
228
vmx->nested.hv_evmcs = NULL;
229
}
230
@@ -1923,7 +1923,8 @@ static int nested_vmx_handle_enlightened_vmptrld(struct kvm_vcpu *vcpu,
1923
if (!nested_enlightened_vmentry(vcpu, &evmcs_gpa))
1924
return 1;
1925
1926
- if (unlikely(evmcs_gpa != vmx->nested.hv_evmcs_vmptr)) {
+ if (unlikely(!vmx->nested.hv_evmcs ||
1927
+ evmcs_gpa != vmx->nested.hv_evmcs_vmptr)) {
1928
if (!vmx->nested.hv_evmcs)
1929
vmx->nested.current_vmptr = -1ull;
1930
0 commit comments