Thread (3 messages) 3 messages, 3 authors, 2012-08-02

Re: [PATCH] MIPS: oops when show backtrace of all active cpu

From: Fan Du <hidden>
Date: 2012-08-02 04:42:11
Also in: lkml


On 2012年08月02日 12:18, Kevin Cernekee wrote:
On Wed, Aug 1, 2012 at 8:31 PM, Fan Du[off-list ref]  wrote:
quoted
show_backtrace must have an valid task when calling unwind_stack,
so fix it by checking first.
[...]
quoted
--- a/arch/mips/kernel/traps.c
+++ b/arch/mips/kernel/traps.c
@@ -151,6 +151,10 @@ static void show_backtrace(struct task_struct *task, const struct pt_regs *regs)
                 show_raw_backtrace(sp);
                 return;
         }
+
+       if (task == NULL)
+               task = current;
+
         printk("Call Trace:\n");
         do {
                 print_ip_sym(pc);
FYI, a slightly different version of this change was accepted:

https://patchwork.linux-mips.org/patch/3524/
Oh, Looks like I'm late :)
thanks anyway.


-- 

Love each day!
--fan
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help