blob: cf86a5e73815dde6fb2e0fa997b8628555584063 [file] [log] [blame]
H. Peter Anvin1965aae2008-10-22 22:26:29 -07001#ifndef _ASM_X86_STACKTRACE_H
2#define _ASM_X86_STACKTRACE_H
Andi Kleenc0b766f2006-09-26 10:52:34 +02003
Chuck Ebbert0741f4d2006-12-07 02:14:11 +01004extern int kstack_depth_to_print;
5
Frederic Weisbecker0406ca62009-07-01 21:02:09 +02006int x86_is_stack_id(int id, char *name);
7
Andi Kleenc0b766f2006-09-26 10:52:34 +02008/* Generic stack tracer with callbacks */
9
10struct stacktrace_ops {
11 void (*warning)(void *data, char *msg);
12 /* msg must contain %s for the symbol */
13 void (*warning_symbol)(void *data, char *msg, unsigned long symbol);
Arjan van de Venbc850d62008-01-30 13:33:07 +010014 void (*address)(void *data, unsigned long address, int reliable);
Andi Kleenc0b766f2006-09-26 10:52:34 +020015 /* On negative return stop dumping */
16 int (*stack)(void *data, char *name);
17};
18
Arjan van de Venbc850d62008-01-30 13:33:07 +010019void dump_trace(struct task_struct *tsk, struct pt_regs *regs,
20 unsigned long *stack, unsigned long bp,
Jan Beulich9689ba82007-10-17 18:04:37 +020021 const struct stacktrace_ops *ops, void *data);
Andi Kleenc0b766f2006-09-26 10:52:34 +020022
H. Peter Anvin1965aae2008-10-22 22:26:29 -070023#endif /* _ASM_X86_STACKTRACE_H */