Gitweb:
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=56ba47ddbd5af7918bf1acdbe3deb979d0dcd64b
Commit: 56ba47ddbd5af7918bf1acdbe3deb979d0dcd64b
Parent: 70433389ccfe2719ef5cd539d04172260294f0f5
Author: Avi Kivity <[EMAIL PROTECTED]>
AuthorDate: Wed Nov 7 17:14:18 2007 +0200
Committer: Avi Kivity <[EMAIL PROTECTED]>
CommitDate: Thu Nov 8 12:05:43 2007 +0200
KVM: SVM: Defer nmi processing until switch to host state is complete
If we stgi() too soon, nmis can reach the processor even though interrupts
are disabled, catching it in a half-switched state. Delay the stgi() until
we're done switching.
Signed-off-by: Avi Kivity <[EMAIL PROTECTED]>
---
drivers/kvm/svm.c | 8 ++++----
1 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/drivers/kvm/svm.c b/drivers/kvm/svm.c
index 3910358..7376805 100644
--- a/drivers/kvm/svm.c
+++ b/drivers/kvm/svm.c
@@ -1585,10 +1585,6 @@ static void svm_vcpu_run(struct kvm_vcpu *vcpu, struct
kvm_run *kvm_run)
#endif
: "cc", "memory" );
- local_irq_disable();
-
- stgi();
-
if ((svm->vmcb->save.dr7 & 0xff))
load_db_regs(svm->host_db_regs);
@@ -1605,6 +1601,10 @@ static void svm_vcpu_run(struct kvm_vcpu *vcpu, struct
kvm_run *kvm_run)
reload_tss(vcpu);
+ local_irq_disable();
+
+ stgi();
+
svm->next_rip = 0;
}
-
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at http://vger.kernel.org/majordomo-info.html