From: Peter Zijlstra Date: Fri, 21 May 2010 13:13:59 +0000 (+0200) Subject: perf, trace: Remove superfluous rcu_read_lock() X-Git-Tag: MMI-PSA29.97-13-9~22061^2~224 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=8ed92280be013180e24c84456ab6babcb07037cc;p=GitHub%2FMotorolaMobilityLLC%2Fkernel-slsi.git perf, trace: Remove superfluous rcu_read_lock() __DO_TRACE() already calls the callbacks under rcu_read_lock_sched(), which is sufficient for our needs, avoid doing it again. Signed-off-by: Peter Zijlstra Cc: Steven Rostedt Cc: Frederic Weisbecker LKML-Reference: Signed-off-by: Ingo Molnar --- diff --git a/kernel/perf_event.c b/kernel/perf_event.c index 4bd3b597bcca..b39bec346e80 100644 --- a/kernel/perf_event.c +++ b/kernel/perf_event.c @@ -4613,12 +4613,10 @@ void perf_tp_event(u64 addr, u64 count, void *record, int entry_size, perf_sample_data_init(&data, addr); data.raw = &raw; - rcu_read_lock(); hlist_for_each_entry_rcu(event, node, head, hlist_entry) { if (perf_tp_event_match(event, &data, regs)) perf_swevent_add(event, count, 1, &data, regs); } - rcu_read_unlock(); perf_swevent_put_recursion_context(rctx); }