From: Xiao Guangrong Date: Thu, 26 Jul 2012 03:57:43 +0000 (+0800) Subject: KVM: MMU: use kvm_release_pfn_clean to release pfn X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=3b2bd2f800ba9488d9ad493216a0c07d71055b56;p=GitHub%2Fmoto-9609%2Fandroid_kernel_motorola_exynos9610.git 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 Signed-off-by: Avi Kivity --- 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, if (!async) return false; /* *pfn has correct page already */ - put_page(pfn_to_page(*pfn)); + kvm_release_pfn_clean(*pfn); if (!prefault && can_do_async_pf(vcpu)) { trace_kvm_try_async_get_page(gva, gfn);