From 000b86624a1b4a10fcef3f5b39598f57f2d9d6cd Mon Sep 17 00:00:00 2001 From: Mathieu Desnoyers Date: Tue, 26 Feb 2013 15:16:57 -0500 Subject: [PATCH] Remove direct dependency of probes on urcu-bp The filter feature added a direct dependency of probes providers against urcu-bp .so, while linking them against liblttng-ust should suffice. Fix this by using the tracepoint.h wrapper for rcu_dereference(). Signed-off-by: Mathieu Desnoyers --- include/lttng/ust-tracepoint-event.h | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/include/lttng/ust-tracepoint-event.h b/include/lttng/ust-tracepoint-event.h index 8fea9216..b3fb2d40 100644 --- a/include/lttng/ust-tracepoint-event.h +++ b/include/lttng/ust-tracepoint-event.h @@ -26,8 +26,15 @@ #include #include #include +#include #include +#undef tp_list_for_each_entry_rcu +#define tp_list_for_each_entry_rcu(pos, head, member) \ + for (pos = cds_list_entry(tp_rcu_dereference_bp((head)->next), __typeof__(*pos), member); \ + &pos->member != (head); \ + pos = cds_list_entry(tp_rcu_dereference_bp(pos->member.next), __typeof__(*pos), member)) + /* * TRACEPOINT_EVENT_CLASS declares a class of tracepoints receiving the * same arguments and having the same field layout. @@ -501,7 +508,7 @@ void __event_probe__##_provider##___##_name(_TP_ARGS_DATA_PROTO(_args)) \ \ __event_prepare_filter_stack__##_provider##___##_name(__stackvar.__filter_stack_data, \ _TP_ARGS_DATA_VAR(_args)); \ - cds_list_for_each_entry_rcu(bc_runtime, &__event->bytecode_runtime_head, node) { \ + tp_list_for_each_entry_rcu(bc_runtime, &__event->bytecode_runtime_head, node) { \ if (caa_unlikely(bc_runtime->filter(bc_runtime, \ __stackvar.__filter_stack_data) & LTTNG_FILTER_RECORD_FLAG)) \ __filter_record = 1; \ -- 2.34.1