sh: Use the generalized stacktrace ops
Copy the stacktrace ops code from x86 and provide a central function for use by functions that need to dump a callstack. Signed-off-by: Matt Fleming <matt@console-pimps.org> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
This commit is contained in:

gecommit door
Paul Mundt

bovenliggende
922b0dc59b
commit
4e14dfc722
@@ -858,30 +858,6 @@ void __init trap_init(void)
|
||||
per_cpu_trap_init();
|
||||
}
|
||||
|
||||
void show_trace(struct task_struct *tsk, unsigned long *sp,
|
||||
struct pt_regs *regs)
|
||||
{
|
||||
unsigned long addr;
|
||||
|
||||
if (regs && user_mode(regs))
|
||||
return;
|
||||
|
||||
printk("\nCall trace:\n");
|
||||
|
||||
while (!kstack_end(sp)) {
|
||||
addr = *sp++;
|
||||
if (kernel_text_address(addr))
|
||||
print_ip_sym(addr);
|
||||
}
|
||||
|
||||
printk("\n");
|
||||
|
||||
if (!tsk)
|
||||
tsk = current;
|
||||
|
||||
debug_show_held_locks(tsk);
|
||||
}
|
||||
|
||||
void show_stack(struct task_struct *tsk, unsigned long *sp)
|
||||
{
|
||||
unsigned long stack;
|
||||
|
Verwijs in nieuw issue
Block a user