summaryrefslogtreecommitdiffstats
path: root/include/linux/kvm_host.h
diff options
context:
space:
mode:
authorMarc Zyngier2012-06-15 21:07:24 +0200
committerMarcelo Tosatti2012-07-03 19:55:31 +0200
commit36c1ed821bd11fb9a3f99a060b1553c114dc2d07 (patch)
treeb8d7e5e3eaf07218d04e5bbe20a8cd7c119b6508 /include/linux/kvm_host.h
parentKVM: VMX: code clean for vmx_init() (diff)
downloadkernel-qcow2-linux-36c1ed821bd11fb9a3f99a060b1553c114dc2d07.tar.gz
kernel-qcow2-linux-36c1ed821bd11fb9a3f99a060b1553c114dc2d07.tar.xz
kernel-qcow2-linux-36c1ed821bd11fb9a3f99a060b1553c114dc2d07.zip
KVM: Guard mmu_notifier specific code with CONFIG_MMU_NOTIFIER
In order to avoid compilation failure when KVM is not compiled in, guard the mmu_notifier specific sections with both CONFIG_MMU_NOTIFIER and KVM_ARCH_WANT_MMU_NOTIFIER, like it is being done in the rest of the KVM code. Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> Signed-off-by: Christoffer Dall <c.dall@virtualopensystems.com> Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
Diffstat (limited to 'include/linux/kvm_host.h')
-rw-r--r--include/linux/kvm_host.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/include/linux/kvm_host.h b/include/linux/kvm_host.h
index c7f77876c9b3..e3c86f8c86c9 100644
--- a/include/linux/kvm_host.h
+++ b/include/linux/kvm_host.h
@@ -306,7 +306,7 @@ struct kvm {
struct hlist_head irq_ack_notifier_list;
#endif
-#ifdef KVM_ARCH_WANT_MMU_NOTIFIER
+#if defined(CONFIG_MMU_NOTIFIER) && defined(KVM_ARCH_WANT_MMU_NOTIFIER)
struct mmu_notifier mmu_notifier;
unsigned long mmu_notifier_seq;
long mmu_notifier_count;
@@ -780,7 +780,7 @@ struct kvm_stats_debugfs_item {
extern struct kvm_stats_debugfs_item debugfs_entries[];
extern struct dentry *kvm_debugfs_dir;
-#ifdef KVM_ARCH_WANT_MMU_NOTIFIER
+#if defined(CONFIG_MMU_NOTIFIER) && defined(KVM_ARCH_WANT_MMU_NOTIFIER)
static inline int mmu_notifier_retry(struct kvm_vcpu *vcpu, unsigned long mmu_seq)
{
if (unlikely(vcpu->kvm->mmu_notifier_count))