2
0
mirror of https://github.com/edk2-porting/linux-next.git synced 2024-12-23 04:34:11 +08:00
linux-next/kernel/trace
Steven Rostedt 7104f300c5 ftrace: type cast filter+verifier
The mmiotrace map had a bug that would typecast the entry from
the trace to the wrong type. That is a known danger of C typecasts,
there's absolutely zero checking done on them.

Help that problem a bit by using a GCC extension to implement a
type filter that restricts the types that a trace record can be
cast into, and by adding a dynamic check (in debug mode) to verify
the type of the entry.

This patch adds a macro to assign all entries of ftrace using the type
of the variable and checking the entry id. The typecasts are now done
in the macro for only those types that it knows about, which should
be all the types that are allowed to be read from the tracer.

Signed-off-by: Steven Rostedt <srostedt@redhat.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
2008-10-14 10:39:07 +02:00
..
ftrace.c ftrace: warn on failure to disable mcount callers 2008-10-14 10:38:11 +02:00
Kconfig tracing: unified trace buffer 2008-10-14 10:38:54 +02:00
Makefile tracing: unified trace buffer 2008-10-14 10:38:54 +02:00
ring_buffer.c ring_buffer: implement new locking 2008-10-14 10:39:05 +02:00
trace_boot.c tracing/ftrace: adapt the boot tracer to the new print_line type 2008-10-14 10:39:03 +02:00
trace_functions.c ftrace: make work with new ring buffer 2008-10-14 10:38:57 +02:00
trace_irqsoff.c ftrace: make work with new ring buffer 2008-10-14 10:38:57 +02:00
trace_mmiotrace.c ftrace: type cast filter+verifier 2008-10-14 10:39:07 +02:00
trace_nop.c ftrace: make work with new ring buffer 2008-10-14 10:38:57 +02:00
trace_sched_switch.c ftrace: make work with new ring buffer 2008-10-14 10:38:57 +02:00
trace_sched_wakeup.c ftrace: make work with new ring buffer 2008-10-14 10:38:57 +02:00
trace_selftest_dynamic.c ftrace: fix dynamic ftrace selftest 2008-05-23 21:13:23 +02:00
trace_selftest.c ftrace: make work with new ring buffer 2008-10-14 10:38:57 +02:00
trace_stack.c ftrace: stack trace add indexes 2008-10-14 10:36:28 +02:00
trace_sysprof.c ftrace: make work with new ring buffer 2008-10-14 10:38:57 +02:00
trace.c ftrace: type cast filter+verifier 2008-10-14 10:39:07 +02:00
trace.h ftrace: type cast filter+verifier 2008-10-14 10:39:07 +02:00