summaryrefslogtreecommitdiffhomepage
path: root/src/compat
diff options
context:
space:
mode:
authorJason A. Donenfeld <Jason@zx2c4.com>2017-11-26 13:44:36 +0100
committerJason A. Donenfeld <Jason@zx2c4.com>2017-11-26 13:44:36 +0100
commitba3c2e815f00e723bddebdf1f5df5adccbbb9b1c (patch)
treea3feacd754efd6cc240362ceee0eb4aa139a19d6 /src/compat
parentf242a4822f364aa606a605a582a718e56db0ca2b (diff)
compat: support 4.15's netlink and barrier changes
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
Diffstat (limited to 'src/compat')
-rw-r--r--src/compat/compat.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/compat/compat.h b/src/compat/compat.h
index fa155d5..16e7923 100644
--- a/src/compat/compat.h
+++ b/src/compat/compat.h
@@ -38,6 +38,7 @@
#define __ro_after_init __read_mostly
#endif
+#include <linux/compiler.h>
#ifndef READ_ONCE
#define READ_ONCE ACCESS_ONCE
#endif
@@ -541,6 +542,11 @@ struct _____dummy_container { char dev; };
#define getnstimeofday64 getnstimeofday
#endif
+#if LINUX_VERSION_CODE < KERNEL_VERSION(4, 15, 0)
+#include <net/genetlink.h>
+#define genl_dump_check_consistent(a, b) genl_dump_check_consistent(a, b, &genl_family)
+#endif
+
/* https://lkml.org/lkml/2017/6/23/790 */
#if IS_ENABLED(CONFIG_NF_CONNTRACK)
#include <linux/ip.h>