summaryrefslogtreecommitdiff
path: root/arch/microblaze/include/asm
diff options
context:
space:
mode:
authorMichal Simek <monstr@monstr.eu>2009-12-10 16:15:44 +0300
committerMichal Simek <monstr@monstr.eu>2009-12-14 10:44:01 +0300
commit7d241ff0567b9503d79ee775c40927d09b509f83 (patch)
tree8de1af72c5643416ee427edc7e9ff2170e0d73db /arch/microblaze/include/asm
parent6d9e60ce30a1be35491c74df00aaa25d869f8a02 (diff)
downloadlinux-7d241ff0567b9503d79ee775c40927d09b509f83.tar.xz
microblaze: ftrace: Add dynamic trace support
With dynamic function tracer, by default, _mcount is defined as an "empty" function, it returns directly without any more action. When enabling it in user-space, it will jump to a real tracing function(ftrace_caller), and do the real job for us. Differ from the static function tracer, dynamic function tracer provides two functions ftrace_make_call()/ftrace_make_nop() to enable/disable the tracing of some indicated kernel functions(set_ftrace_filter). In the kernel version, there is only one "_mcount" string for every kernel function, so, we just need to match this one in mcount_regex of scripts/recordmcount.pl. For more information please look at code and Documentation/trace folder. Steven ACK that scripts/recordmcount.pl part. Acked-by: Steven Rostedt <rostedt@goodmis.org> Signed-off-by: Michal Simek <monstr@monstr.eu>
Diffstat (limited to 'arch/microblaze/include/asm')
-rw-r--r--arch/microblaze/include/asm/ftrace.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/arch/microblaze/include/asm/ftrace.h b/arch/microblaze/include/asm/ftrace.h
index 22beec58c021..fd2fa2eca62f 100644
--- a/arch/microblaze/include/asm/ftrace.h
+++ b/arch/microblaze/include/asm/ftrace.h
@@ -11,5 +11,16 @@ extern void _mcount(void);
extern void ftrace_call_graph(void);
#endif
+#ifdef CONFIG_DYNAMIC_FTRACE
+/* reloction of mcount call site is the same as the address */
+static inline unsigned long ftrace_call_adjust(unsigned long addr)
+{
+ return addr;
+}
+
+struct dyn_arch_ftrace {
+};
+#endif /* CONFIG_DYNAMIC_FTRACE */
+
#endif /* CONFIG_FUNCTION_TRACER */
#endif /* _ASM_MICROBLAZE_FTRACE */