Commit bc19bde7 authored by Greg Kroah-Hartman's avatar Greg Kroah-Hartman Committed by Wentao Guan
Browse files

Revert "KVM: PPC: e500: Mark "struct page" pfn accessed before dropping mmu_lock"

stable inclusion
from stable-v6.6.83
commit e4c6eff5a3b596b62437344e20a2985ac2a23673
category: bugfix
bugzilla: https://gitee.com/openeuler/kernel/issues/IBX1M5

Reference: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=e4c6eff5a3b596b62437344e20a2985ac2a23673

--------------------------------

This reverts commit 59e21c4613b0a46f46eb124984928df46d88ad57 which is
commit 84cf78dcd9d65c45ab73998d4ad50f433d53fb93 upstream.

It should not have been applied.

Link: https://lore.kernel.org/r/CABgObfb5U9zwTQBPkPB=mKu-vMrRspPCm4wfxoQpB+SyAnb5WQ@mail.gmail.com


Reported-by: default avatarPaolo Bonzini <pbonzini@redhat.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
(cherry picked from commit e4c6eff5a3b596b62437344e20a2985ac2a23673)
Signed-off-by: default avatarWentao Guan <guanwentao@uniontech.com>
parent 392b2c83
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -498,9 +498,11 @@ static inline int kvmppc_e500_shadow_map(struct kvmppc_vcpu_e500 *vcpu_e500,
	kvmppc_mmu_flush_icache(pfn);

out:
	spin_unlock(&kvm->mmu_lock);

	/* Drop refcount on page, so that mmu notifiers can clear it */
	kvm_release_pfn_clean(pfn);
	spin_unlock(&kvm->mmu_lock);

	return ret;
}