xref: /linux/arch/microblaze/include/asm/ftrace.h (revision 7d241ff0567b9503d79ee775c40927d09b509f83)
12fd7c761SMichal Simek #ifndef _ASM_MICROBLAZE_FTRACE
22fd7c761SMichal Simek #define _ASM_MICROBLAZE_FTRACE
36c149fd7SMichal Simek 
42fd7c761SMichal Simek #ifdef CONFIG_FUNCTION_TRACER
52fd7c761SMichal Simek 
62fd7c761SMichal Simek #define MCOUNT_ADDR		((long)(_mcount))
72fd7c761SMichal Simek #define MCOUNT_INSN_SIZE	8 /* sizeof mcount call */
82fd7c761SMichal Simek 
92fd7c761SMichal Simek #ifndef __ASSEMBLY__
102fd7c761SMichal Simek extern void _mcount(void);
112fd7c761SMichal Simek extern void ftrace_call_graph(void);
122fd7c761SMichal Simek #endif
132fd7c761SMichal Simek 
14*7d241ff0SMichal Simek #ifdef CONFIG_DYNAMIC_FTRACE
15*7d241ff0SMichal Simek /* reloction of mcount call site is the same as the address */
16*7d241ff0SMichal Simek static inline unsigned long ftrace_call_adjust(unsigned long addr)
17*7d241ff0SMichal Simek {
18*7d241ff0SMichal Simek 	return addr;
19*7d241ff0SMichal Simek }
20*7d241ff0SMichal Simek 
21*7d241ff0SMichal Simek struct dyn_arch_ftrace {
22*7d241ff0SMichal Simek };
23*7d241ff0SMichal Simek #endif /* CONFIG_DYNAMIC_FTRACE */
24*7d241ff0SMichal Simek 
252fd7c761SMichal Simek #endif /* CONFIG_FUNCTION_TRACER */
262fd7c761SMichal Simek #endif /* _ASM_MICROBLAZE_FTRACE */
27