Add rcu_read_ongoing() API to each urcu flavor
[urcu.git] / urcu-flavor.h
index e46c9a19beb73538a4274973a958e0b8546ea75e..c04f1db78ba1e113a7ff85e9d8552cfe08b342c8 100644 (file)
@@ -30,6 +30,7 @@ extern "C" {
 struct rcu_flavor_struct {
        void (*read_lock)(void);
        void (*read_unlock)(void);
+       int (*read_ongoing)(void);
        void (*read_quiescent_state)(void);
        void (*update_call_rcu)(struct rcu_head *head,
                                void (*func)(struct rcu_head *head));
@@ -42,10 +43,11 @@ struct rcu_flavor_struct {
        void (*unregister_thread)(void);
 };
 
-#define DEFINE_RCU_FLAVOR(                           \
-const struct rcu_flavor_struct rcu_flavor = {          \
+#define DEFINE_RCU_FLAVOR(x)                           \
+const struct rcu_flavor_struct x = {                   \
        .read_lock              = rcu_read_lock,        \
        .read_unlock            = rcu_read_unlock,      \
+       .read_ongoing           = rcu_read_ongoing,     \
        .read_quiescent_state   = rcu_quiescent_state,  \
        .update_call_rcu        = call_rcu,             \
        .update_synchronize_rcu = synchronize_rcu,      \
@@ -54,7 +56,7 @@ const struct rcu_flavor_struct rcu_flavor = {         \
        .thread_online          = rcu_thread_online,    \
        .register_thread        = rcu_register_thread,  \
        .unregister_thread      = rcu_unregister_thread,\
-};
+}
 
 extern const struct rcu_flavor_struct rcu_flavor;
 
This page took 0.022956 seconds and 4 git commands to generate.