Skip to content

Commit

Permalink
i386/kvm: Do not sync nested state during runtime
Browse files Browse the repository at this point in the history
Writing the nested state e.g. after a vmport access can invalidate
important parts of the kernel-internal state, and it is not needed as
well. So leave this out from KVM_PUT_RUNTIME_STATE.

Suggested-by: Paolo Bonzini <pbonzini@redhat.com>
Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
Message-Id: <bdd53f40-4e60-f3ae-7ec6-162198214953@siemens.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
  • Loading branch information
jan-kiszka authored and bonzini committed Jul 24, 2019
1 parent 9c5aad8 commit bec7156
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions target/i386/kvm.c
Expand Up @@ -3563,12 +3563,12 @@ int kvm_arch_put_registers(CPUState *cpu, int level)

assert(cpu_is_stopped(cpu) || qemu_cpu_is_self(cpu));

ret = kvm_put_nested_state(x86_cpu);
if (ret < 0) {
return ret;
}

if (level >= KVM_PUT_RESET_STATE) {
ret = kvm_put_nested_state(x86_cpu);
if (ret < 0) {
return ret;
}

ret = kvm_put_msr_feature_control(x86_cpu);
if (ret < 0) {
return ret;
Expand Down

0 comments on commit bec7156

Please sign in to comment.