Skip to contentSkip to conversation

timers: local_clock() is defined in linux/sched.h in kernel below v4.11

PATCH In review René van Dorst 2 participants 2 messages Jun 13, 2019

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 timers: local_clock() is defined in linux/sched.h in kernel below v4.11

Fixes 7a79457255d5 ("global: switch to local_clock()")
---
 src/timers.h | 4 ++++
 1 file changed, 4 insertions(+)
src/timers.h +4 -0
index ef1205690915..3af326056f3d 100644
@@ -6,7 +6,11 @@
 #ifndef _WG_TIMERS_H
 #define _WG_TIMERS_H
 
+#if LINUX_VERSION_CODE < KERNEL_VERSION(4, 11, 0)
+#include <linux/sched.h>
+#else
 #include <linux/sched/clock.h>
+#endif
 
 struct wg_peer;
 
Signature · 6 lines
2.20.1

_______________________________________________
WireGuard mailing list
[email protected]
https://lists.zx2c4.com/mailman/listinfo/wireguard