aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/signal.c
diff options
context:
space:
mode:
authorOleg Nesterov <oleg@tv-sign.ru>2008-07-25 04:47:41 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2008-07-25 13:53:39 -0400
commit999d9fc1670bc082928b93b11d1f2e0e417d973c (patch)
treee540e7fd2fab970ba2be5e39ac9f8282a373bc24 /kernel/signal.c
parent32ecb1f26dd50eeaac4e3f4dea4541c97848e459 (diff)
coredump: move mm->core_waiters into struct core_state
Move mm->core_waiters into "struct core_state" allocated on stack. This shrinks mm_struct a little bit and allows further changes. This patch mostly does s/core_waiters/core_state. The only essential change is that coredump_wait() must clear mm->core_state before return. The coredump_wait()'s path is uglified and .text grows by 30 bytes, this is fixed by the next patch. Signed-off-by: Oleg Nesterov <oleg@tv-sign.ru> Cc: Roland McGrath <roland@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'kernel/signal.c')
-rw-r--r--kernel/signal.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/kernel/signal.c b/kernel/signal.c
index 39c1706edf03..5c7b7eaa0dc6 100644
--- a/kernel/signal.c
+++ b/kernel/signal.c
@@ -1480,10 +1480,10 @@ static inline int may_ptrace_stop(void)
1480 * is a deadlock situation, and pointless because our tracer 1480 * is a deadlock situation, and pointless because our tracer
1481 * is dead so don't allow us to stop. 1481 * is dead so don't allow us to stop.
1482 * If SIGKILL was already sent before the caller unlocked 1482 * If SIGKILL was already sent before the caller unlocked
1483 * ->siglock we must see ->core_waiters != 0. Otherwise it 1483 * ->siglock we must see ->core_state != NULL. Otherwise it
1484 * is safe to enter schedule(). 1484 * is safe to enter schedule().
1485 */ 1485 */
1486 if (unlikely(current->mm->core_waiters) && 1486 if (unlikely(current->mm->core_state) &&
1487 unlikely(current->mm == current->parent->mm)) 1487 unlikely(current->mm == current->parent->mm))
1488 return 0; 1488 return 0;
1489 1489