Re: Linux 2.6.23-rc9 and a heads-up for the 2.6.24 series..

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
From: Mel Gorman
Date: Wednesday, October 3, 2007 - 5:51 am

On (03/10/07 10:21), Ingo Molnar didst pronounce:

Agreed. The less change the better this late in the game.


I included a candidate patch in the last mail but it was shoved down at
the bottom so it could easily have been missed.

==============
Subject: Document profile=sleep requiring CONFIG_SCHEDSTATS

profile=sleep only works if CONFIG_SCHEDSTATS is set. This patch notes the
limitation in Documentation/kernel-parameters.txt and prints a warning at
boot-time if profile=sleep is used without CONFIG_SCHEDSTAT.

Signed-off-by: Mel Gorman <mel@csn.ul.ie>
---
 Documentation/kernel-parameters.txt |    3 ++-
 kernel/profile.c                    |    5 +++++
 2 files changed, 7 insertions(+), 1 deletion(-)

diff -rup -X /usr/src/patchset-0.6/bin//dontdiff linux-2.6.23-rc9-005_ingo_profile_fix/Documentation/kernel-parameters.txt linux-2.6.23-rc9-010_document_profilesleep/Documentation/kernel-parameters.txt
--- linux-2.6.23-rc9-005_ingo_profile_fix/Documentation/kernel-parameters.txt	2007-10-02 04:24:52.000000000 +0100
+++ linux-2.6.23-rc9-010_document_profilesleep/Documentation/kernel-parameters.txt	2007-10-02 16:43:41.000000000 +0100
@@ -1395,7 +1395,8 @@ and is between 256 and 4096 characters. 
 			Param: "schedule" - profile schedule points.
 			Param: <number> - step/bucket size as a power of 2 for
 				statistical time based profiling.
-			Param: "sleep" - profile D-state sleeping (millisecs)
+			Param: "sleep" - profile D-state sleeping (millisecs).
+				Requires CONFIG_SCHEDSTATS
 
 	processor.max_cstate=	[HW,ACPI]
 			Limit processor to maximum C-state
diff -rup -X /usr/src/patchset-0.6/bin//dontdiff linux-2.6.23-rc9-005_ingo_profile_fix/kernel/profile.c linux-2.6.23-rc9-010_document_profilesleep/kernel/profile.c
--- linux-2.6.23-rc9-005_ingo_profile_fix/kernel/profile.c	2007-10-02 04:24:52.000000000 +0100
+++ linux-2.6.23-rc9-010_document_profilesleep/kernel/profile.c	2007-10-02 16:44:50.000000000 +0100
@@ -60,6 +60,7 @@ static int __init profile_setup(char * s
 	int par;
 
 	if (!strncmp(str, sleepstr, strlen(sleepstr))) {
+#ifdef CONFIG_SCHEDSTATS
 		prof_on = SLEEP_PROFILING;
 		if (str[strlen(sleepstr)] == ',')
 			str += strlen(sleepstr) + 1;
@@ -68,6 +69,10 @@ static int __init profile_setup(char * s
 		printk(KERN_INFO
 			"kernel sleep profiling enabled (shift: %ld)\n",
 			prof_shift);
+#else
+		printk(KERN_WARNING
+			"kernel sleep profiling requires CONFIG_SCHEDSTATS\n");
+#endif /* CONFIG_SCHEDSTATS */
 	} else if (!strncmp(str, schedstr, strlen(schedstr))) {
 		prof_on = SCHED_PROFILING;
 		if (str[strlen(schedstr)] == ',')
-- 
Mel Gorman
Part-time Phd Student                          Linux Technology Center
University of Limerick                         IBM Dublin Software Lab
-
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
Linux 2.6.23-rc9 and a heads-up for the 2.6.24 series.., Linus Torvalds, (Mon Oct 1, 8:41 pm)
Re: Linux 2.6.23-rc9 and a heads-up for the 2.6.24 series.., Rafael J. Wysocki, (Tue Oct 2, 1:12 pm)
Re: Linux 2.6.23-rc9 and a heads-up for the 2.6.24 series.., Rafael J. Wysocki, (Tue Oct 2, 1:31 pm)
Re: Linux 2.6.23-rc9 and a heads-up for the 2.6.24 series.., Alistair John Strachan, (Tue Oct 2, 3:51 pm)
Re: Linux 2.6.23-rc9 and a heads-up for the 2.6.24 series.., Glauber de Oliveira ..., (Tue Oct 2, 4:00 pm)
Re: Linux 2.6.23-rc9 and a heads-up for the 2.6.24 series.., Mel Gorman, (Wed Oct 3, 5:51 am)
[patch] net, 9p: build fix with !CONFIG_SYSCTL, Ingo Molnar, (Thu Oct 4, 4:55 am)
[BUG] Linux 2.6.23-rc9 and MAX_ARG_PAGES, Mathieu Chouquet-Str ..., (Thu Oct 4, 10:05 am)
Re: [BUG] Linux 2.6.23-rc9 and MAX_ARG_PAGES, Peter Zijlstra, (Thu Oct 4, 10:17 am)
Re: [BUG] Linux 2.6.23-rc9 and MAX_ARG_PAGES, Linus Torvalds, (Thu Oct 4, 10:27 am)
Re: [BUG] Linux 2.6.23-rc9 and MAX_ARG_PAGES, Mathieu Chouquet-Str ..., (Thu Oct 4, 1:44 pm)
Re: [BUG] Linux 2.6.23-rc9 and MAX_ARG_PAGES, Mathieu Chouquet-Str ..., (Thu Oct 4, 1:47 pm)
Re: [BUG] Linux 2.6.23-rc9 and MAX_ARG_PAGES, Linus Torvalds, (Thu Oct 4, 2:21 pm)
Re: [BUG] Linux 2.6.23-rc9 and MAX_ARG_PAGES, Chuck Ebbert, (Thu Oct 4, 2:50 pm)
Re: [BUG] Linux 2.6.23-rc9 and MAX_ARG_PAGES, Mathieu Chouquet-Str ..., (Thu Oct 4, 2:54 pm)
Re: [BUG] Linux 2.6.23-rc9 and MAX_ARG_PAGES, Mathieu Chouquet-Str ..., (Thu Oct 4, 2:58 pm)
Re: [BUG] Linux 2.6.23-rc9 and MAX_ARG_PAGES, Paul Mackerras, (Thu Oct 4, 3:27 pm)
Re: [BUG] Linux 2.6.23-rc9 and MAX_ARG_PAGES, Linus Torvalds, (Thu Oct 4, 5:12 pm)
Re: [BUG] Linux 2.6.23-rc9 and MAX_ARG_PAGES, Mathieu Chouquet-Str ..., (Thu Oct 4, 8:22 pm)
Re: [BUG] Linux 2.6.23-rc9 and MAX_ARG_PAGES, Peter Zijlstra, (Fri Oct 5, 12:43 am)
Re: [BUG] Linux 2.6.23-rc9 and MAX_ARG_PAGES, Hans-Peter Jansen, (Sat Oct 6, 1:29 am)
Re: [BUG] Linux 2.6.23-rc9 and MAX_ARG_PAGES, Hans-Peter Jansen, (Sat Oct 6, 4:29 am)
Re: [BUG] Linux 2.6.23-rc9 and MAX_ARG_PAGES, Bill Davidsen, (Sat Oct 6, 10:36 am)
Re: Linux 2.6.23-rc9 and a heads-up for the 2.6.24 series.., Alistair John Strachan, (Sun Oct 7, 4:44 pm)