[PATCH] exit,stats: /* obey this comment */

From: Rik van Riel
Date: Thu Apr 23 2015 - 17:18:09 EST


There is a helpful comment in do_exit() that states we sync the
mm's RSS info before statistics gathering.

The function that does the statistics gathering is called right
above that comment.

Change the code to obey the comment.

Signed-off-by: Rik van Riel <riel@xxxxxxxxxx>
---
kernel/exit.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/kernel/exit.c b/kernel/exit.c
index 22fcc05dec40..8a87bb43dbd0 100644
--- a/kernel/exit.c
+++ b/kernel/exit.c
@@ -711,10 +711,10 @@ void do_exit(long code)
current->comm, task_pid_nr(current),
preempt_count());

- acct_update_integrals(tsk);
/* sync mm's RSS info before statistics gathering */
if (tsk->mm)
sync_mm_rss(tsk->mm);
+ acct_update_integrals(tsk);
group_dead = atomic_dec_and_test(&tsk->signal->live);
if (group_dead) {
hrtimer_cancel(&tsk->signal->real_timer);

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/