summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--arch/parisc/kernel/process.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/arch/parisc/kernel/process.c b/arch/parisc/kernel/process.c
index 0dd3847f494..355664812b8 100644
--- a/arch/parisc/kernel/process.c
+++ b/arch/parisc/kernel/process.c
@@ -381,6 +381,10 @@ get_wchan(struct task_struct *p)
struct unwind_frame_info info;
unsigned long ip;
int count = 0;
+
+ if (!p || p == current || p->state == TASK_RUNNING)
+ return 0;
+
/*
* These bracket the sleeping functions..
*/