[PATCH] context tracking: conditionalize guest support based onCONFIG_KVM
From: Kevin Hilman
Date: Thu Feb 14 2013 - 13:17:37 EST
So that it can build on !KVM systems too.
Signed-off-by: Kevin Hilman <khilman@xxxxxxxxxx>
---
kernel/context_tracking.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/kernel/context_tracking.c b/kernel/context_tracking.c
index 74f68f4..d9c98dd 100644
--- a/kernel/context_tracking.c
+++ b/kernel/context_tracking.c
@@ -1,5 +1,7 @@
#include <linux/context_tracking.h>
+#if defined(CONFIG_KVM) || defined(CONFIG_KVM_MODULE)
#include <linux/kvm_host.h>
+#endif
#include <linux/rcupdate.h>
#include <linux/sched.h>
#include <linux/hardirq.h>
@@ -62,6 +64,7 @@ void user_exit(void)
local_irq_restore(flags);
}
+#if defined(CONFIG_KVM) || defined(CONFIG_KVM_MODULE)
void guest_enter(void)
{
if (vtime_accounting_enabled())
@@ -79,6 +82,7 @@ void guest_exit(void)
__guest_exit();
}
EXPORT_SYMBOL_GPL(guest_exit);
+#endif
void context_tracking_task_switch(struct task_struct *prev,
struct task_struct *next)
--
1.8.1.2
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/