linux/kernel/trace
Steven Rostedt a8fb260805 perf/tracing: Fix regression of perf losing kprobe events
With the addition of the code to shrink the kernel tracepoint
infrastructure, we lost kprobes being traced by perf. The reason
is that I tested if the "tp_event->class->perf_probe" existed before
enabling it. This prevents "ftrace only" events (like the function
trace events) from being enabled by perf.

Unfortunately, kprobe events do not use perf_probe. This causes
kprobes to be missed by perf. To fix this, we add the test to
see if "tp_event->class->reg" exists as well as perf_probe.

Normal trace events have only "perf_probe" but no "reg" function,
and kprobes and syscalls have the "reg" but no "perf_probe".
The ftrace unique events do not have either, so this is a valid
test. If a kprobe or syscall is not to be probed by perf, the
"reg" function is called anyway, and will return a failure and
prevent perf from probing it.

Reported-by: Srikar Dronamraju <srikar@linux.vnet.ibm.com>
Tested-by: Srikar Dronamraju <srikar@linux.vnet.ibm.com>
Acked-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
2010-06-10 20:56:54 -04:00
..
blktrace.c blktrace: Fix new kernel-doc warnings 2010-05-31 09:58:20 +02:00
ftrace.c
Kconfig
kmemtrace.c
Makefile
power-traces.c
ring_buffer.c
ring_buffer_benchmark.c
trace.c
trace.h
trace_boot.c
trace_branch.c
trace_clock.c
trace_entries.h
trace_event_perf.c perf/tracing: Fix regression of perf losing kprobe events 2010-06-10 20:56:54 -04:00
trace_events.c
trace_events_filter.c
trace_export.c
trace_functions.c
trace_functions_graph.c
trace_irqsoff.c
trace_kprobe.c perf_events, trace: Fix probe unregister race 2010-05-31 08:46:09 +02:00
trace_ksym.c
trace_mmiotrace.c
trace_nop.c
trace_output.c
trace_output.h
trace_printk.c
trace_sched_switch.c
trace_sched_wakeup.c
trace_selftest.c
trace_selftest_dynamic.c
trace_stack.c
trace_stat.c
trace_stat.h
trace_syscalls.c perf_events, trace: Fix probe unregister race 2010-05-31 08:46:09 +02:00
trace_sysprof.c
trace_workqueue.c