]> Pileus Git - ~andy/linux/commit
KVM: Introduce kvm_unmap_hva_range() for kvm_mmu_notifier_invalidate_range_start()
authorTakuya Yoshikawa <yoshikawa.takuya@oss.ntt.co.jp>
Mon, 2 Jul 2012 08:56:33 +0000 (17:56 +0900)
committerMarcelo Tosatti <mtosatti@redhat.com>
Wed, 18 Jul 2012 19:55:04 +0000 (16:55 -0300)
commitb3ae2096974b12c3af2ad1a4e7716b084949867f
tree38ca81ac607cec1c00d6961effb38992577114df
parent84504ef38673fa021b3d8f3da2b79cf878b33315
KVM: Introduce kvm_unmap_hva_range() for kvm_mmu_notifier_invalidate_range_start()

When we tested KVM under memory pressure, with THP enabled on the host,
we noticed that MMU notifier took a long time to invalidate huge pages.

Since the invalidation was done with mmu_lock held, it not only wasted
the CPU but also made the host harder to respond.

This patch mitigates this by using kvm_handle_hva_range().

Signed-off-by: Takuya Yoshikawa <yoshikawa.takuya@oss.ntt.co.jp>
Cc: Alexander Graf <agraf@suse.de>
Cc: Paul Mackerras <paulus@samba.org>
Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
arch/powerpc/include/asm/kvm_host.h
arch/powerpc/kvm/book3s_64_mmu_hv.c
arch/x86/include/asm/kvm_host.h
arch/x86/kvm/mmu.c
virt/kvm/kvm_main.c