diff options
author | Oleg Nesterov <oleg@tv-sign.ru> | 2007-05-08 00:24:01 -0700 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-05-08 11:14:58 -0700 |
commit | 1065d130dddc3241706c50a01ced7b03bcb657be (patch) | |
tree | 86565a17abe3c126c13708207bdca671fbc5bc77 | |
parent | fca3b747795ae24f9667b6c9a69975f9eb98a2c0 (diff) | |
download | linux-stable-1065d130dddc3241706c50a01ced7b03bcb657be.tar.gz linux-stable-1065d130dddc3241706c50a01ced7b03bcb657be.tar.bz2 linux-stable-1065d130dddc3241706c50a01ced7b03bcb657be.zip |
freezer: task->exit_state should be treated as bolean
Except for BUG_ON() checks, we should not use EXIT_XXXX defines outside of
exit/wait paths.
Signed-off-by: Oleg Nesterov <oleg@tv-sign.ru>
Cc: "Rafael J. Wysocki" <rjw@sisk.pl>
Cc: Pavel Machek <pavel@ucw.cz>
Cc: Ingo Molnar <mingo@elte.hu>
Cc: Nick Piggin <nickpiggin@yahoo.com.au>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
-rw-r--r-- | kernel/power/process.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/kernel/power/process.c b/kernel/power/process.c index 0eb5c420e8ed..179529dc3819 100644 --- a/kernel/power/process.c +++ b/kernel/power/process.c @@ -25,10 +25,9 @@ static inline int freezeable(struct task_struct * p) { - if ((p == current) || + if ((p == current) || (p->flags & PF_NOFREEZE) || - (p->exit_state == EXIT_ZOMBIE) || - (p->exit_state == EXIT_DEAD)) + (p->exit_state != 0)) return 0; return 1; } |