[PATCH] remove unneeded sig->curr_target recalculation

This patch removes unneeded sig->curr_target recalculation under 'if
(atomic_dec_and_test(&sig->count))' in __exit_signal().

When sig->count == 0 the signal can't be sent to this task and
next_thread(tsk) == tsk anyway.

Signed-off-by: Oleg Nesterov <oleg@tv-sign.ru>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
This commit is contained in:
Oleg Nesterov 2006-01-08 01:03:28 -08:00 committed by Linus Torvalds
parent 08efd10edf
commit 86174cdcb4
1 changed files with 0 additions and 2 deletions

View File

@ -364,8 +364,6 @@ void __exit_signal(struct task_struct *tsk)
posix_cpu_timers_exit(tsk);
if (atomic_dec_and_test(&sig->count)) {
posix_cpu_timers_exit_group(tsk);
if (tsk == sig->curr_target)
sig->curr_target = next_thread(tsk);
tsk->signal = NULL;
__exit_sighand(tsk);
spin_unlock(&sighand->siglock);