diff options
author | Frederic Weisbecker <fweisbec@gmail.com> | 2008-10-02 11:26:05 (GMT) |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2008-10-14 08:39:12 (GMT) |
commit | 5601020feb0c3010e9e3e0131e9697ac6a06777b (patch) | |
tree | 99d1a70dbf3bba2b5ae1007c4828c28e6480214a /include/linux/ftrace.h | |
parent | cb5ab74204a6e2579d1119bf1348eb806526b12b (diff) | |
download | linux-fsl-qoriq-5601020feb0c3010e9e3e0131e9697ac6a06777b.tar.xz |
tracing/fastboot: get the initcall name before it disappears
After some initcall traces, some initcall names may be inconsistent.
That's because these functions will disappear from the .init section
and also their name from the symbols table.
So we have to copy the name of the function in a buffer large enough
during the trace appending. It is not costly for the ring_buffer because
the number of initcall entries is commonly not really large.
Signed-off-by: Frederic Weisbecker <fweisbec@gmail.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'include/linux/ftrace.h')
-rw-r--r-- | include/linux/ftrace.h | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/include/linux/ftrace.h b/include/linux/ftrace.h index 4455490..e672e51 100644 --- a/include/linux/ftrace.h +++ b/include/linux/ftrace.h @@ -7,6 +7,7 @@ #include <linux/fs.h> #include <linux/init.h> #include <linux/types.h> +#include <linux/kallsyms.h> extern int ftrace_enabled; extern int @@ -213,7 +214,7 @@ ftrace_init_module(unsigned long *start, unsigned long *end) { } struct boot_trace { pid_t caller; - initcall_t func; + char func[KSYM_NAME_LEN]; int result; unsigned long long duration; ktime_t calltime; @@ -221,10 +222,10 @@ struct boot_trace { }; #ifdef CONFIG_BOOT_TRACER -extern void trace_boot(struct boot_trace *it); +extern void trace_boot(struct boot_trace *it, initcall_t fn); extern void start_boot_trace(void); #else -static inline void trace_boot(struct boot_trace *it) { } +static inline void trace_boot(struct boot_trace *it, initcall_t fn) { } static inline void start_boot_trace(void) { } #endif |