diff options
author | Xiao Guangrong <xiaoguangrong@linux.vnet.ibm.com> | 2012-07-25 23:57:43 -0400 |
---|---|---|
committer | Avi Kivity <avi@redhat.com> | 2012-07-26 04:55:30 -0400 |
commit | 3b2bd2f800ba9488d9ad493216a0c07d71055b56 (patch) | |
tree | 9df3bbb27d9030fe4a06e6f527a8ccce6c291bc7 /arch | |
parent | e9bda6f6f902e6b55d9baceb5523468a048cbe56 (diff) |
KVM: MMU: use kvm_release_pfn_clean to release pfn
The current code depends on the fact that fault_page is the normal page,
however, we will use the error code instead of these dummy pages in the
later patch, so we use kvm_release_pfn_clean to release pfn which will
release the error code properly
Signed-off-by: Xiao Guangrong <xiaoguangrong@linux.vnet.ibm.com>
Signed-off-by: Avi Kivity <avi@redhat.com>
Diffstat (limited to 'arch')
-rw-r--r-- | arch/x86/kvm/mmu.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/x86/kvm/mmu.c b/arch/x86/kvm/mmu.c index 241993443599..a9a20528e700 100644 --- a/arch/x86/kvm/mmu.c +++ b/arch/x86/kvm/mmu.c | |||
@@ -3275,7 +3275,7 @@ static bool try_async_pf(struct kvm_vcpu *vcpu, bool prefault, gfn_t gfn, | |||
3275 | if (!async) | 3275 | if (!async) |
3276 | return false; /* *pfn has correct page already */ | 3276 | return false; /* *pfn has correct page already */ |
3277 | 3277 | ||
3278 | put_page(pfn_to_page(*pfn)); | 3278 | kvm_release_pfn_clean(*pfn); |
3279 | 3279 | ||
3280 | if (!prefault && can_do_async_pf(vcpu)) { | 3280 | if (!prefault && can_do_async_pf(vcpu)) { |
3281 | trace_kvm_try_async_get_page(gva, gfn); | 3281 | trace_kvm_try_async_get_page(gva, gfn); |