[PATCH] Fix delay accounting regression

!MAILaRCHIVE_VOTE_RePLACE
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
To: Ingo Molnar <mingo@...>
Cc: Balbir Singh <balbir@...>, Peter Zijlstra <a.p.zijlstra@...>, Andrew Morton <akpm@...>, Linux Kernel Mailing List <linux-kernel@...>
Date: Friday, November 2, 2007 - 10:22 am

Fix the delay accounting regression introduced by commit
75d4ef16a6aa84f708188bada182315f80aab6fa. rq no longer has sched_info
data associated with it. task_struct sched_info structure is used by delay
accounting to provide back statistics to user space.

Signed-off-by: Balbir Singh <balbir@linux.vnet.ibm.com>
---

 kernel/sched_stats.h |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff -puN kernel/sched_stats.h~delayacct-define-bug kernel/sched_stats.h
--- linux-2.6-latest/kernel/sched_stats.h~delayacct-define-bug	2007-11-02 19:02:07.000000000 +0530
+++ linux-2.6-latest-balbir/kernel/sched_stats.h	2007-11-02 19:51:30.000000000 +0530
@@ -127,7 +127,7 @@ rq_sched_info_depart(struct rq *rq, unsi
 # define schedstat_set(var, val)	do { } while (0)
 #endif
 
-#ifdef CONFIG_SCHEDSTATS
+#if defined(CONFIG_SCHEDSTATS) || defined(CONFIG_TASK_DELAY_ACCT)
 /*
  * Called when a process is dequeued from the active array and given
  * the cpu.  We should note that with the exception of interactive
@@ -231,5 +231,5 @@ sched_info_switch(struct task_struct *pr
 #else
 #define sched_info_queued(t)		do { } while (0)
 #define sched_info_switch(t, next)	do { } while (0)
-#endif /* CONFIG_SCHEDSTATS */
+#endif /* CONFIG_SCHEDSTATS || CONFIG_TASK_DELAY_ACCT */
 
_

-- 
	Warm Regards,
	Balbir Singh
	Linux Technology Center
	IBM, ISTL
-
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
[PATCH] Fix delay accounting regression, Balbir Singh, (Fri Nov 2, 10:22 am)
Re: [PATCH] Fix delay accounting regression, Ingo Molnar, (Fri Nov 2, 11:53 am)
Re: [PATCH] Fix delay accounting regression, Balbir Singh, (Fri Nov 2, 12:55 pm)
Re: [PATCH] Fix delay accounting regression, Ingo Molnar, (Sat Nov 3, 4:33 am)
Re: [PATCH] Fix delay accounting regression, Balbir Singh, (Fri Nov 2, 12:35 pm)
Re: [PATCH] Fix delay accounting regression, Guillaume Chazarain, (Fri Nov 2, 12:05 pm)