Merge branch 'linus' of git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6
[linux-2.6-microblaze.git] / kernel / sched / core.c
index 42d4027..154fd68 100644 (file)
@@ -5192,21 +5192,14 @@ void sched_show_task(struct task_struct *p)
        int ppid;
        unsigned long state = p->state;
 
+       if (!try_get_task_stack(p))
+               return;
        if (state)
                state = __ffs(state) + 1;
        printk(KERN_INFO "%-15.15s %c", p->comm,
                state < sizeof(stat_nam) - 1 ? stat_nam[state] : '?');
-#if BITS_PER_LONG == 32
-       if (state == TASK_RUNNING)
-               printk(KERN_CONT " running  ");
-       else
-               printk(KERN_CONT " %08lx ", thread_saved_pc(p));
-#else
        if (state == TASK_RUNNING)
                printk(KERN_CONT "  running task    ");
-       else
-               printk(KERN_CONT " %016lx ", thread_saved_pc(p));
-#endif
 #ifdef CONFIG_DEBUG_STACK_USAGE
        free = stack_not_used(p);
 #endif
@@ -5221,6 +5214,7 @@ void sched_show_task(struct task_struct *p)
 
        print_worker_info(KERN_INFO, p);
        show_stack(p, NULL);
+       put_task_stack(p);
 }
 
 void show_state_filter(unsigned long state_filter)