[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <20130404085740.GA2495@redhat.com>
Date: Thu, 4 Apr 2013 10:57:48 +0200
From: Stanislaw Gruszka <sgruszka@...hat.com>
To: Ingo Molnar <mingo@...nel.org>,
Peter Zijlstra <peterz@...radead.org>
Cc: Frederic Weisbecker <fweisbec@...il.com>,
Oleg Nesterov <oleg@...hat.com>,
Thomas Gleixner <tglx@...utronix.de>,
linux-kernel@...r.kernel.org
Subject: [PATCH 3.9 repost] cputime: Fix accounting on multi-threaded
processes
Recent commit 6fac4829 "cputime: Use accessors to read task cputime
stats" introduced a bug, that make we account many times cputime of
the first thread, instead of cputimes of all threads.
Signed-off-by: Stanislaw Gruszka <sgruszka@...hat.com>
Acked-by: Frederic Weisbecker <fweisbec@...il.com>
---
This patch fixes 3.8 -> 3.9 regression, please apply.
kernel/sched/cputime.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/kernel/sched/cputime.c b/kernel/sched/cputime.c
index ed12cbb..e93cca9 100644
--- a/kernel/sched/cputime.c
+++ b/kernel/sched/cputime.c
@@ -310,7 +310,7 @@ void thread_group_cputime(struct task_struct *tsk, struct task_cputime *times)
t = tsk;
do {
- task_cputime(tsk, &utime, &stime);
+ task_cputime(t, &utime, &stime);
times->utime += utime;
times->stime += stime;
times->sum_exec_runtime += task_sched_runtime(t);
--
1.7.1
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists