From mboxrd@z Thu Jan 1 00:00:00 1970 From: mathieu.desnoyers@efficios.com (Mathieu Desnoyers) Date: Sat, 13 Oct 2012 12:49:40 -0400 Subject: [lttng-dev] [PATCH 4/4] test: remove rcu_defer_register_thread() from test_urcu_lfq In-Reply-To: <1350144514-4132-4-git-send-email-laijs@cn.fujitsu.com> References: <1350144514-4132-1-git-send-email-laijs@cn.fujitsu.com> <1350144514-4132-4-git-send-email-laijs@cn.fujitsu.com> Message-ID: <20121013164940.GH29985@Krystal> * Lai Jiangshan (laijs at cn.fujitsu.com) wrote: > test_urcu_lfq has already switch to call_rcu(), rcu_defer_register_thread() > is unneeded. merged, thanks! Mathieu > > Signed-off-by: Lai Jiangshan > --- > tests/test_urcu_lfq.c | 8 -------- > 1 files changed, 0 insertions(+), 8 deletions(-) > > diff --git a/tests/test_urcu_lfq.c b/tests/test_urcu_lfq.c > index 0fcbf55..1204d92 100644 > --- a/tests/test_urcu_lfq.c > +++ b/tests/test_urcu_lfq.c > @@ -67,7 +67,6 @@ static inline pid_t gettid(void) > #endif > #include > #include > -#include > > static volatile int test_go, test_stop; > > @@ -222,18 +221,12 @@ void free_node_cb(struct rcu_head *head) > void *thr_dequeuer(void *_count) > { > unsigned long long *count = _count; > - int ret; > > printf_verbose("thread_begin %s, thread id : %lx, tid %lu\n", > "dequeuer", pthread_self(), (unsigned long)gettid()); > > set_affinity(); > > - ret = rcu_defer_register_thread(); > - if (ret) { > - printf("Error in rcu_defer_register_thread\n"); > - exit(-1); > - } > rcu_register_thread(); > > while (!test_go) > @@ -264,7 +257,6 @@ void *thr_dequeuer(void *_count) > } > > rcu_unregister_thread(); > - rcu_defer_unregister_thread(); > printf_verbose("dequeuer thread_end, thread id : %lx, tid %lu, " > "dequeues %llu, successful_dequeues %llu\n", > pthread_self(), (unsigned long)gettid(), > -- > 1.7.7.6 > -- Mathieu Desnoyers Operating System Efficiency R&D Consultant EfficiOS Inc. http://www.efficios.com