]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/commitdiff
[PATCH] i386: fix dump_stack()
authorChuck Ebbert <76306.1226@compuserve.com>
Thu, 23 Mar 2006 10:59:52 +0000 (02:59 -0800)
committerLinus Torvalds <torvalds@g5.osdl.org>
Thu, 23 Mar 2006 15:38:06 +0000 (07:38 -0800)
i386 has a small bug in the stack dump code where it prints an extra log
level code.  Remove that and fix the alignment of normal stack dump
printout.  Also remove some unnecessary printk() calls.

Signed-off-by: Chuck Ebbert <76306.1226@compuserve.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
arch/i386/kernel/traps.c

index a807a2da581d975006ead13bd120f748d021e9fa..1b7ad4115d81a1ac68e1c34953359c8aa4ce72f5 100644 (file)
@@ -217,19 +217,17 @@ static void show_stack_log_lvl(struct task_struct *task, unsigned long *esp,
        for(i = 0; i < kstack_depth_to_print; i++) {
                if (kstack_end(stack))
                        break;
-               if (i && ((i % 8) == 0)) {
-                       printk("\n");
-                       printk("%s       ", log_lvl);
-               }
+               if (i && ((i % 8) == 0))
+                       printk("\n%s       ", log_lvl);
                printk("%08lx ", *stack++);
        }
-       printk("\n");
-       printk("%sCall Trace:\n", log_lvl);
+       printk("\n%sCall Trace:\n", log_lvl);
        show_trace_log_lvl(task, esp, log_lvl);
 }
 
 void show_stack(struct task_struct *task, unsigned long *esp)
 {
+       printk("       ");
        show_stack_log_lvl(task, esp, "");
 }