diff options
author | Tom Zanussi <tzanussi@gmail.com> | 2009-04-08 04:15:54 -0400 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2009-04-13 18:00:56 -0400 |
commit | eb02ce017dd83985041a7e54c6449f92d53b026f (patch) | |
tree | 7f52a3e92bf3dae1f3c7754a58ab76fb2eceb2e1 /kernel/trace/trace_branch.c | |
parent | 5f77a88b3f8268b11940b51d2e03d26a663ceb90 (diff) |
tracing/filters: use ring_buffer_discard_commit() in filter_check_discard()
This patch changes filter_check_discard() to make use of the new
ring_buffer_discard_commit() function and modifies the current users to
call the old commit function in the non-discard case.
It also introduces a version of filter_check_discard() that uses the
global trace buffer (filter_current_check_discard()) for those cases.
v2 changes:
- fix compile error noticed by Ingo Molnar
Signed-off-by: Tom Zanussi <tzanussi@gmail.com>
Cc: Steven Rostedt <rostedt@goodmis.org>
Cc: fweisbec@gmail.com
LKML-Reference: <1239178554.10295.36.camel@tropicana>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'kernel/trace/trace_branch.c')
-rw-r--r-- | kernel/trace/trace_branch.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/kernel/trace/trace_branch.c b/kernel/trace/trace_branch.c index c95c25d838ef..8e64e604f5a7 100644 --- a/kernel/trace/trace_branch.c +++ b/kernel/trace/trace_branch.c | |||
@@ -74,9 +74,8 @@ probe_likely_condition(struct ftrace_branch_data *f, int val, int expect) | |||
74 | entry->line = f->line; | 74 | entry->line = f->line; |
75 | entry->correct = val == expect; | 75 | entry->correct = val == expect; |
76 | 76 | ||
77 | filter_check_discard(call, entry, event); | 77 | if (!filter_check_discard(call, entry, tr->buffer, event)) |
78 | 78 | ring_buffer_unlock_commit(tr->buffer, event); | |
79 | ring_buffer_unlock_commit(tr->buffer, event); | ||
80 | 79 | ||
81 | out: | 80 | out: |
82 | atomic_dec(&tr->data[cpu]->disabled); | 81 | atomic_dec(&tr->data[cpu]->disabled); |