Commit fd9afbd5 authored by Ben Collins's avatar Ben Collins

[SPARC64]: Enable KALLSYMS, use print_symbol().

parent cb707d7d
......@@ -924,6 +924,13 @@ config DEBUG_SPINLOCK
best used in conjunction with the NMI watchdog so that spinlock
deadlocks are also debuggable.
config KALLSYMS
bool "Load all symbols for debugging/ksymoops"
help
Say Y here to let the kernel print out symbolic crash information and
symbolic stack backtraces. This increases the size of the kernel
somewhat, as all symbols have to be loaded into the kernel image.
config DEBUG_SPINLOCK_SLEEP
bool "Sleep-inside-spinlock checking"
help
......
......@@ -16,6 +16,7 @@
#include <linux/errno.h>
#include <linux/sched.h>
#include <linux/kernel.h>
#include <linux/kallsyms.h>
#include <linux/mm.h>
#include <linux/smp.h>
#include <linux/smp_lock.h>
......@@ -284,6 +285,7 @@ void __show_regs(struct pt_regs * regs)
#endif
printk("TSTATE: %016lx TPC: %016lx TNPC: %016lx Y: %08x %s\n", regs->tstate,
regs->tpc, regs->tnpc, regs->y, print_tainted());
print_symbol("TPC: <%s>\n", regs->tpc);
printk("g0: %016lx g1: %016lx g2: %016lx g3: %016lx\n",
regs->u_regs[0], regs->u_regs[1], regs->u_regs[2],
regs->u_regs[3]);
......
......@@ -12,6 +12,7 @@
#include <linux/config.h>
#include <linux/sched.h> /* for jiffies */
#include <linux/kernel.h>
#include <linux/kallsyms.h>
#include <linux/signal.h>
#include <linux/smp.h>
#include <linux/smp_lock.h>
......@@ -1644,7 +1645,9 @@ void die_if_kernel(char *str, struct pt_regs *regs)
(char *) rw < ((char *) current)
+ sizeof (union thread_union) &&
!(((unsigned long) rw) & 0x7)) {
printk("Caller[%016lx]\n", rw->ins[7]);
printk("Caller[%016lx]", rw->ins[7]);
print_symbol(": %s\n", rw->ins[7]);
printk("\n");
lastrw = rw;
rw = (struct reg_window *)
(rw->ins[6] + STACK_BIAS);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment