KVM: Move prototypes for MMU notifier callbacks to generic code
mainline inclusion from mainline-v5.13-rc1 commit 5f7c292b category: feature bugzilla: https://gitee.com/openeuler/intel-kernel/issues/I7S3VQ CVE: NA Reference: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=5f7c292b8975c9146063abbb91c0b9cdc1a5e9c5 Also, use the common declaration of kvm_unmap_hva_range() for loongarch, instead of a private one. And change the definition for it. Previously, loongarch's version of kvm_unmap_hva_range() defined "bool blockable" as its last parameter(which is not used). But it is wrong. KVM MMU uses "flag" of struct mmu_notifier_range as the argument when it calls kvm_unmap_hva_range(), the arch code should use if (flag & MMU_NOTIFIER_RANGE_BLOCKABLE) inside kvm_unmap_hva_range() when it wanna know if current operation is a blockable one. So just fix the broken syntax for loongarch. ---------------------------------------------------------------------- Move the prototypes for the MMU notifier callbacks out of arch code and into common code. There is no benefit to having each arch replicate the prototypes since any deviation from the invocation in common code will explode. No functional change intended. Signed-off-by:Sean Christopherson <seanjc@google.com> Message-Id: <20210326021957.1424875-9-seanjc@google.com> Signed-off-by:
Paolo Bonzini <pbonzini@redhat.com> conflict: include/trace/events/kvm.h Signed-off-by:
Yu Zhang <yu.c.zhang@linux.intel.com>
Loading
Please sign in to comment