mirror of
https://git.yoctoproject.org/meta-ti
synced 2026-07-17 06:48:07 +00:00
189ce92b4c
Signed-off-by: Koen Kooi <koen@dominion.thruhere.net> Signed-off-by: Denys Dmytriyenko <denys@ti.com>
37 lines
1.3 KiB
Diff
37 lines
1.3 KiB
Diff
From c997d0a009e5eb7b372287c13fc9eaba901533e8 Mon Sep 17 00:00:00 2001
|
|
From: Nadav Har'El <nyh@math.technion.ac.il>
|
|
Date: Tue, 6 Mar 2012 16:39:22 +0200
|
|
Subject: [PATCH 004/117] KVM: nVMX: Fix erroneous exception bitmap check
|
|
|
|
(cherry picked from commit 9587190107d0c0cbaccbf7bf6b0245d29095a9ae)
|
|
|
|
The code which checks whether to inject a pagefault to L1 or L2 (in
|
|
nested VMX) was wrong, incorrect in how it checked the PF_VECTOR bit.
|
|
Thanks to Dan Carpenter for spotting this.
|
|
|
|
Signed-off-by: Nadav Har'El <nyh@il.ibm.com>
|
|
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
|
|
Signed-off-by: Avi Kivity <avi@redhat.com>
|
|
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
|
|
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
|
|
---
|
|
arch/x86/kvm/vmx.c | 2 +-
|
|
1 file changed, 1 insertion(+), 1 deletion(-)
|
|
|
|
diff --git a/arch/x86/kvm/vmx.c b/arch/x86/kvm/vmx.c
|
|
index 4ea7678..7ac5993 100644
|
|
--- a/arch/x86/kvm/vmx.c
|
|
+++ b/arch/x86/kvm/vmx.c
|
|
@@ -1677,7 +1677,7 @@ static int nested_pf_handled(struct kvm_vcpu *vcpu)
|
|
struct vmcs12 *vmcs12 = get_vmcs12(vcpu);
|
|
|
|
/* TODO: also check PFEC_MATCH/MASK, not just EB.PF. */
|
|
- if (!(vmcs12->exception_bitmap & PF_VECTOR))
|
|
+ if (!(vmcs12->exception_bitmap & (1u << PF_VECTOR)))
|
|
return 0;
|
|
|
|
nested_vmx_vmexit(vcpu);
|
|
--
|
|
1.7.9.5
|
|
|