diff options
author | Mel Gorman <mel@csn.ul.ie> | 2007-10-24 18:23:50 +0200 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2007-10-24 18:23:50 +0200 |
commit | b3da2a73ff5a2953a4ad8ebbf0aa7e6965ff9de2 (patch) | |
tree | 43583e5f492a48c56f9537006c8f806d570b0d84 /kernel/profile.c | |
parent | 838225b48edc971620cbeb292034dabd2b0d7d1d (diff) | |
download | op-kernel-dev-b3da2a73ff5a2953a4ad8ebbf0aa7e6965ff9de2.zip op-kernel-dev-b3da2a73ff5a2953a4ad8ebbf0aa7e6965ff9de2.tar.gz |
sched: 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>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'kernel/profile.c')
-rw-r--r-- | kernel/profile.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/kernel/profile.c b/kernel/profile.c index 631b75c..5e95330 100644 --- a/kernel/profile.c +++ b/kernel/profile.c @@ -60,6 +60,7 @@ static int __init profile_setup(char * str) 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 * str) 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)] == ',') |