diff options
author | Xiao Guangrong <xiaoguangrong@linux.vnet.ibm.com> | 2012-07-17 09:54:11 -0400 |
---|---|---|
committer | Marcelo Tosatti <mtosatti@redhat.com> | 2012-07-19 20:15:25 -0400 |
commit | 903816fa4d016e20ec71a1a97700cfcdda115580 (patch) | |
tree | c7208520a6de2f0170ce181517d3ea9479eb2eb7 /arch | |
parent | 86fde74cf5b829627b37ca86322acfdd99b524b8 (diff) |
KVM: using get_fault_pfn to get the fault pfn
Using get_fault_pfn to cleanup the code
Signed-off-by: Xiao Guangrong <xiaoguangrong@linux.vnet.ibm.com>
Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
Diffstat (limited to 'arch')
-rw-r--r-- | arch/x86/kvm/mmu.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/arch/x86/kvm/mmu.c b/arch/x86/kvm/mmu.c index 685a48557389..f85cc21ae95d 100644 --- a/arch/x86/kvm/mmu.c +++ b/arch/x86/kvm/mmu.c | |||
@@ -2513,10 +2513,8 @@ static pfn_t pte_prefetch_gfn_to_pfn(struct kvm_vcpu *vcpu, gfn_t gfn, | |||
2513 | unsigned long hva; | 2513 | unsigned long hva; |
2514 | 2514 | ||
2515 | slot = gfn_to_memslot_dirty_bitmap(vcpu, gfn, no_dirty_log); | 2515 | slot = gfn_to_memslot_dirty_bitmap(vcpu, gfn, no_dirty_log); |
2516 | if (!slot) { | 2516 | if (!slot) |
2517 | get_page(fault_page); | 2517 | return get_fault_pfn(); |
2518 | return page_to_pfn(fault_page); | ||
2519 | } | ||
2520 | 2518 | ||
2521 | hva = gfn_to_hva_memslot(slot, gfn); | 2519 | hva = gfn_to_hva_memslot(slot, gfn); |
2522 | 2520 | ||