diff options
Diffstat (limited to 'arch/x86/kernel/dumpstack.c')
-rw-r--r-- | arch/x86/kernel/dumpstack.c | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/arch/x86/kernel/dumpstack.c b/arch/x86/kernel/dumpstack.c index 1aae78f775fc..1b81839b6c88 100644 --- a/arch/x86/kernel/dumpstack.c +++ b/arch/x86/kernel/dumpstack.c | |||
@@ -37,13 +37,16 @@ print_ftrace_graph_addr(unsigned long addr, void *data, | |||
37 | const struct stacktrace_ops *ops, | 37 | const struct stacktrace_ops *ops, |
38 | struct thread_info *tinfo, int *graph) | 38 | struct thread_info *tinfo, int *graph) |
39 | { | 39 | { |
40 | struct task_struct *task = tinfo->task; | 40 | struct task_struct *task; |
41 | unsigned long ret_addr; | 41 | unsigned long ret_addr; |
42 | int index = task->curr_ret_stack; | 42 | int index; |
43 | 43 | ||
44 | if (addr != (unsigned long)return_to_handler) | 44 | if (addr != (unsigned long)return_to_handler) |
45 | return; | 45 | return; |
46 | 46 | ||
47 | task = tinfo->task; | ||
48 | index = task->curr_ret_stack; | ||
49 | |||
47 | if (!task->ret_stack || index < *graph) | 50 | if (!task->ret_stack || index < *graph) |
48 | return; | 51 | return; |
49 | 52 | ||
@@ -252,7 +255,8 @@ int __kprobes __die(const char *str, struct pt_regs *regs, long err) | |||
252 | unsigned short ss; | 255 | unsigned short ss; |
253 | unsigned long sp; | 256 | unsigned long sp; |
254 | #endif | 257 | #endif |
255 | printk(KERN_EMERG "%s: %04lx [#%d] ", str, err & 0xffff, ++die_counter); | 258 | printk(KERN_DEFAULT |
259 | "%s: %04lx [#%d] ", str, err & 0xffff, ++die_counter); | ||
256 | #ifdef CONFIG_PREEMPT | 260 | #ifdef CONFIG_PREEMPT |
257 | printk("PREEMPT "); | 261 | printk("PREEMPT "); |
258 | #endif | 262 | #endif |
@@ -264,7 +268,7 @@ int __kprobes __die(const char *str, struct pt_regs *regs, long err) | |||
264 | #endif | 268 | #endif |
265 | printk("\n"); | 269 | printk("\n"); |
266 | if (notify_die(DIE_OOPS, str, regs, err, | 270 | if (notify_die(DIE_OOPS, str, regs, err, |
267 | current->thread.trap_no, SIGSEGV) == NOTIFY_STOP) | 271 | current->thread.trap_nr, SIGSEGV) == NOTIFY_STOP) |
268 | return 1; | 272 | return 1; |
269 | 273 | ||
270 | show_registers(regs); | 274 | show_registers(regs); |