aboutsummaryrefslogtreecommitdiffstats
path: root/arch/x86/kvm/mmu.c
diff options
context:
space:
mode:
authorAvi Kivity <avi@redhat.com>2010-11-22 10:53:26 -0500
committerAvi Kivity <avi@redhat.com>2011-01-12 04:29:59 -0500
commitab9ae3138789afacd133a9c4b3d7a3f1578e25c7 (patch)
tree27c81b48c395dffd2049b37bafef940573ae6841 /arch/x86/kvm/mmu.c
parent35d3d4a1dd2c1ffd6f2481f6d8ad6c358bb22f07 (diff)
KVM: Push struct x86_exception info the various gva_to_gpa variants
Signed-off-by: Avi Kivity <avi@redhat.com> Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
Diffstat (limited to 'arch/x86/kvm/mmu.c')
-rw-r--r--arch/x86/kvm/mmu.c13
1 files changed, 7 insertions, 6 deletions
diff --git a/arch/x86/kvm/mmu.c b/arch/x86/kvm/mmu.c
index 53ff31f3dc6..9ce041469a8 100644
--- a/arch/x86/kvm/mmu.c
+++ b/arch/x86/kvm/mmu.c
@@ -2567,18 +2567,19 @@ void kvm_mmu_sync_roots(struct kvm_vcpu *vcpu)
2567} 2567}
2568 2568
2569static gpa_t nonpaging_gva_to_gpa(struct kvm_vcpu *vcpu, gva_t vaddr, 2569static gpa_t nonpaging_gva_to_gpa(struct kvm_vcpu *vcpu, gva_t vaddr,
2570 u32 access, u32 *error) 2570 u32 access, struct x86_exception *exception)
2571{ 2571{
2572 if (error) 2572 if (exception)
2573 *error = 0; 2573 exception->error_code = 0;
2574 return vaddr; 2574 return vaddr;
2575} 2575}
2576 2576
2577static gpa_t nonpaging_gva_to_gpa_nested(struct kvm_vcpu *vcpu, gva_t vaddr, 2577static gpa_t nonpaging_gva_to_gpa_nested(struct kvm_vcpu *vcpu, gva_t vaddr,
2578 u32 access, u32 *error) 2578 u32 access,
2579 struct x86_exception *exception)
2579{ 2580{
2580 if (error) 2581 if (exception)
2581 *error = 0; 2582 exception->error_code = 0;
2582 return vcpu->arch.nested_mmu.translate_gpa(vcpu, vaddr, access); 2583 return vcpu->arch.nested_mmu.translate_gpa(vcpu, vaddr, access);
2583} 2584}
2584 2585