diff options
author | Joerg Roedel <joerg.roedel@amd.com> | 2009-08-07 11:49:47 +0200 |
---|---|---|
committer | Avi Kivity <avi@redhat.com> | 2009-09-10 10:46:37 +0300 |
commit | 108768de55949c778bd95b36f3b17e652e59cd5b (patch) | |
tree | dd8120651d7ad6af8c4c2f32b591e30a183dbf6d /arch/x86/kvm/svm.c | |
parent | 26666957a58fab7c8a4a31f1ab24d3bbf4c58c7a (diff) |
KVM: SVM: check for nested VINTR flag in svm_interrupt_allowed
Not checking for this flag breaks any nested hypervisor that does not
set VINTR. So fix it with this patch.
Signed-off-by: Joerg Roedel <joerg.roedel@amd.com>
Signed-off-by: Avi Kivity <avi@redhat.com>
Diffstat (limited to 'arch/x86/kvm/svm.c')
-rw-r--r-- | arch/x86/kvm/svm.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/x86/kvm/svm.c b/arch/x86/kvm/svm.c index 144f2025799f..6610f60b4c96 100644 --- a/arch/x86/kvm/svm.c +++ b/arch/x86/kvm/svm.c @@ -2463,7 +2463,7 @@ static int svm_interrupt_allowed(struct kvm_vcpu *vcpu) return (vmcb->save.rflags & X86_EFLAGS_IF) && !(vmcb->control.int_state & SVM_INTERRUPT_SHADOW_MASK) && gif_set(svm) && - !is_nested(svm); + !(is_nested(svm) && (svm->vcpu.arch.hflags & HF_VINTR_MASK)); } static void enable_irq_window(struct kvm_vcpu *vcpu) |