aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/exit.c
diff options
context:
space:
mode:
Diffstat (limited to 'kernel/exit.c')
-rw-r--r--kernel/exit.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/kernel/exit.c b/kernel/exit.c
index 3c2cf91defa7..9852ed8c2988 100644
--- a/kernel/exit.c
+++ b/kernel/exit.c
@@ -25,6 +25,7 @@
25#include <linux/mount.h> 25#include <linux/mount.h>
26#include <linux/proc_fs.h> 26#include <linux/proc_fs.h>
27#include <linux/mempolicy.h> 27#include <linux/mempolicy.h>
28#include <linux/taskstats_kern.h>
28#include <linux/delayacct.h> 29#include <linux/delayacct.h>
29#include <linux/cpuset.h> 30#include <linux/cpuset.h>
30#include <linux/syscalls.h> 31#include <linux/syscalls.h>
@@ -844,6 +845,7 @@ static void exit_notify(struct task_struct *tsk)
844fastcall NORET_TYPE void do_exit(long code) 845fastcall NORET_TYPE void do_exit(long code)
845{ 846{
846 struct task_struct *tsk = current; 847 struct task_struct *tsk = current;
848 struct taskstats *tidstats, *tgidstats;
847 int group_dead; 849 int group_dead;
848 850
849 profile_task_exit(tsk); 851 profile_task_exit(tsk);
@@ -882,6 +884,8 @@ fastcall NORET_TYPE void do_exit(long code)
882 current->comm, current->pid, 884 current->comm, current->pid,
883 preempt_count()); 885 preempt_count());
884 886
887 taskstats_exit_alloc(&tidstats, &tgidstats);
888
885 acct_update_integrals(tsk); 889 acct_update_integrals(tsk);
886 if (tsk->mm) { 890 if (tsk->mm) {
887 update_hiwater_rss(tsk->mm); 891 update_hiwater_rss(tsk->mm);
@@ -901,7 +905,10 @@ fastcall NORET_TYPE void do_exit(long code)
901#endif 905#endif
902 if (unlikely(tsk->audit_context)) 906 if (unlikely(tsk->audit_context))
903 audit_free(tsk); 907 audit_free(tsk);
908 taskstats_exit_send(tsk, tidstats, tgidstats);
909 taskstats_exit_free(tidstats, tgidstats);
904 delayacct_tsk_exit(tsk); 910 delayacct_tsk_exit(tsk);
911
905 exit_mm(tsk); 912 exit_mm(tsk);
906 913
907 if (group_dead) 914 if (group_dead)