diff options
Diffstat (limited to 'kernel/exit.c')
-rw-r--r-- | kernel/exit.c | 16 |
1 files changed, 6 insertions, 10 deletions
diff --git a/kernel/exit.c b/kernel/exit.c index 80137a5d9467..30fcdf16737a 100644 --- a/kernel/exit.c +++ b/kernel/exit.c | |||
@@ -40,7 +40,6 @@ | |||
40 | #include <linux/cn_proc.h> | 40 | #include <linux/cn_proc.h> |
41 | #include <linux/mutex.h> | 41 | #include <linux/mutex.h> |
42 | #include <linux/futex.h> | 42 | #include <linux/futex.h> |
43 | #include <linux/compat.h> | ||
44 | #include <linux/pipe_fs_i.h> | 43 | #include <linux/pipe_fs_i.h> |
45 | #include <linux/audit.h> /* for audit_free() */ | 44 | #include <linux/audit.h> /* for audit_free() */ |
46 | #include <linux/resource.h> | 45 | #include <linux/resource.h> |
@@ -141,6 +140,11 @@ static void __exit_signal(struct task_struct *tsk) | |||
141 | if (sig) { | 140 | if (sig) { |
142 | flush_sigqueue(&sig->shared_pending); | 141 | flush_sigqueue(&sig->shared_pending); |
143 | taskstats_tgid_free(sig); | 142 | taskstats_tgid_free(sig); |
143 | /* | ||
144 | * Make sure ->signal can't go away under rq->lock, | ||
145 | * see account_group_exec_runtime(). | ||
146 | */ | ||
147 | task_rq_unlock_wait(tsk); | ||
144 | __cleanup_signal(sig); | 148 | __cleanup_signal(sig); |
145 | } | 149 | } |
146 | } | 150 | } |
@@ -1054,14 +1058,6 @@ NORET_TYPE void do_exit(long code) | |||
1054 | exit_itimers(tsk->signal); | 1058 | exit_itimers(tsk->signal); |
1055 | } | 1059 | } |
1056 | acct_collect(code, group_dead); | 1060 | acct_collect(code, group_dead); |
1057 | #ifdef CONFIG_FUTEX | ||
1058 | if (unlikely(tsk->robust_list)) | ||
1059 | exit_robust_list(tsk); | ||
1060 | #ifdef CONFIG_COMPAT | ||
1061 | if (unlikely(tsk->compat_robust_list)) | ||
1062 | compat_exit_robust_list(tsk); | ||
1063 | #endif | ||
1064 | #endif | ||
1065 | if (group_dead) | 1061 | if (group_dead) |
1066 | tty_audit_exit(); | 1062 | tty_audit_exit(); |
1067 | if (unlikely(tsk->audit_context)) | 1063 | if (unlikely(tsk->audit_context)) |
@@ -1325,10 +1321,10 @@ static int wait_task_zombie(struct task_struct *p, int options, | |||
1325 | * group, which consolidates times for all threads in the | 1321 | * group, which consolidates times for all threads in the |
1326 | * group including the group leader. | 1322 | * group including the group leader. |
1327 | */ | 1323 | */ |
1324 | thread_group_cputime(p, &cputime); | ||
1328 | spin_lock_irq(&p->parent->sighand->siglock); | 1325 | spin_lock_irq(&p->parent->sighand->siglock); |
1329 | psig = p->parent->signal; | 1326 | psig = p->parent->signal; |
1330 | sig = p->signal; | 1327 | sig = p->signal; |
1331 | thread_group_cputime(p, &cputime); | ||
1332 | psig->cutime = | 1328 | psig->cutime = |
1333 | cputime_add(psig->cutime, | 1329 | cputime_add(psig->cutime, |
1334 | cputime_add(cputime.utime, | 1330 | cputime_add(cputime.utime, |