aboutsummaryrefslogtreecommitdiffstats
path: root/arch/x86/kvm/x86.c
diff options
context:
space:
mode:
authorGleb Natapov <gleb@qumranet.com>2008-09-22 07:28:53 -0400
committerAvi Kivity <avi@redhat.com>2008-10-15 08:25:09 -0400
commitaf2152f5457448bd90cb019c108e0a85e716fdbe (patch)
tree49d04ee98da457e29be09b3143361212b982f898 /arch/x86/kvm/x86.c
parent9ea1de4ea4b04d5132eb74917ecea77dda13ce76 (diff)
KVM: don't enter guest after SIPI was received by a CPU
The vcpu should process pending SIPI message before entering guest mode again. kvm_arch_vcpu_runnable() returns true if the vcpu is in SIPI state, so we can't call it here. Signed-off-by: Gleb Natapov <gleb@qumranet.com> Signed-off-by: Avi Kivity <avi@redhat.com>
Diffstat (limited to 'arch/x86/kvm/x86.c')
-rw-r--r--arch/x86/kvm/x86.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/x86/kvm/x86.c b/arch/x86/kvm/x86.c
index 1b738cb02831..08edeabf15e6 100644
--- a/arch/x86/kvm/x86.c
+++ b/arch/x86/kvm/x86.c
@@ -3233,7 +3233,7 @@ static int __vcpu_run(struct kvm_vcpu *vcpu, struct kvm_run *kvm_run)
3233 3233
3234 r = 1; 3234 r = 1;
3235 while (r > 0) { 3235 while (r > 0) {
3236 if (kvm_arch_vcpu_runnable(vcpu)) 3236 if (vcpu->arch.mp_state == KVM_MP_STATE_RUNNABLE)
3237 r = vcpu_enter_guest(vcpu, kvm_run); 3237 r = vcpu_enter_guest(vcpu, kvm_run);
3238 else { 3238 else {
3239 up_read(&vcpu->kvm->slots_lock); 3239 up_read(&vcpu->kvm->slots_lock);