Repository : ssh://git@open-mesh.org/batman-adv
On branch : next
commit 80e3bf8ffad6114ae89d4551e46c8b5069def969 Author: Antonio Quartulli ordex@autistici.org Date: Sat Mar 16 12:49:18 2013 +0100
batman-adv: add RCU compat code for kernel < 2.6.37
In linux version < 2.6.37 hlist_first_rcu() and hlist_next_rcu() do not exist and therefore they need to be backported.
Signed-off-by: Antonio Quartulli ordex@autistici.org Signed-off-by: Marek Lindner lindner_marek@yahoo.de
80e3bf8ffad6114ae89d4551e46c8b5069def969 compat.h | 6 ++++++ 1 file changed, 6 insertions(+)
diff --git a/compat.h b/compat.h index e1c6cd2..a71be7d 100644 --- a/compat.h +++ b/compat.h @@ -129,6 +129,12 @@ static inline int batadv_param_set_copystring(const char *val,
#endif /* < KERNEL_VERSION(2, 6, 36) */
+#if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 37) + +#define hlist_first_rcu(head) (*((struct hlist_node __rcu **)(&(head)->first))) +#define hlist_next_rcu(node) (*((struct hlist_node __rcu **)(&(node)->next))) + +#endif /* < KERNEL_VERSION(2, 6, 37) */
#if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 39)