]> granicus.if.org Git - ipset/commitdiff
Protect definition of RCU_INIT_POINTER in compatibility header file
authorJozsef Kadlecsik <kadlec@blackhole.kfki.hu>
Mon, 19 Oct 2015 17:58:35 +0000 (19:58 +0200)
committerJozsef Kadlecsik <kadlec@blackhole.kfki.hu>
Mon, 19 Oct 2015 17:58:35 +0000 (19:58 +0200)
Nikolay Borisov reported that in 3.12.47 RCU_INIT_POINTER is redefined
in ip_set_compat.h.in due to not protecting it individually.

kernel/include/linux/netfilter/ipset/ip_set_compat.h.in

index 8c0b34672e7fe6d3ac943389d2d0e6bb0ca8c4da..aa93c2cb6d3fda65ab23e4756674433031366db1 100644 (file)
 
 #ifndef __rcu
 #define        __rcu
+#ifndef RCU_INIT_POINTER
 #define RCU_INIT_POINTER(p, v) \
        do { \
                p = v; \
        } while (0)
+#endif
 #else
 
 #ifndef RCU_INITIALIZER
 #define RCU_INITIALIZER(v)     (typeof(*(v)) __force __rcu *)(v)
+#endif
+#ifndef RCU_INIT_POINTER
 #define RCU_INIT_POINTER(p, v) \
        do { \
                p = RCU_INITIALIZER(v); \