Skip to contentSkip to conversation

kvm: compat: define marker_synchronize_unregister on older kernels

PATCH Applied Eduardo Habkost 2 participants 2 messages Jan 6, 2009 – Jan 7, 2009 KVM

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 kvm: compat: define marker_synchronize_unregister on older kernels

marker_synchronize_unregister() is available only on 2.6.28. However, its definition is very simple, so we can define it if it is missing.

This fixes compilation of kvm_trace.c against older kernels.

---
 kernel/external-module-compat-comm.h |    5 +++++
 1 files changed, 5 insertions(+), 0 deletions(-)
kernel/external-module-compat-comm.h +5 -0
index f2343f6..5cb70b0 100644
@@ -699,3 +699,8 @@ static inline void cpumask_clear_cpu(int cpu, cpumask_var_t mask)
 
 #endif
 
+
+/* Macro introduced only on newer kernels: */
+#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,28)
+#define marker_synchronize_unregister() synchronize_sched()
+#endif
Signature · 1 line
1.5.6.rc3.11.g5f54d
Applied
#1 lore raw
Quoted 5 lines · Eduardo Habkost

marker_synchronize_unregister() is available only on 2.6.28. However, its definition is very simple, so we can define it if it is missing.

This fixes compilation of kvm_trace.c against older kernels.

Applied, thanks.

Signature · 1 line
error compiling committee.c: too many arguments to function