Add backport for rcu_dereference_rtnl()
Signed-off-by: Hauke Mehrtens <[email protected]>
---
backport/backport-include/linux/rtnetlink.h | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/backport/backport-include/linux/rtnetlink.h
b/backport/backport-include/linux/rtnetlink.h
index 56ba9f6..81540a3 100644
--- a/backport/backport-include/linux/rtnetlink.h
+++ b/backport/backport-include/linux/rtnetlink.h
@@ -7,6 +7,12 @@
rcu_dereference_protected(p, lockdep_rtnl_is_held())
#endif
+#ifndef rcu_dereference_rtnl
+#define rcu_dereference_rtnl(p) \
+ rcu_dereference_check(p, rcu_read_lock_held() || \
+ lockdep_rtnl_is_held())
+#endif
+
#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,34)
#ifdef CONFIG_PROVE_LOCKING
/*
--
1.7.10.4
--
To unsubscribe from this list: send the line "unsubscribe backports" in
the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html