[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <tip-feae3203d711db0a9965300ee6d592257fdaae4f@git.kernel.org>
Date: Thu, 26 Nov 2009 09:55:30 GMT
From: tip-bot for Mike Travis <travis@....com>
To: linux-tip-commits@...r.kernel.org
Cc: mingo@...hat.com, rusty@...tcorp.com.au, fweisbec@...il.com,
yhlu.kernel@...il.com, rostedt@...dmis.org, gregkh@...e.de,
heiko.carstens@...ibm.com, tglx@...utronix.de, rientjes@...gle.com,
linux-kernel@...r.kernel.org, hpa@...or.com, andi@...stfloor.org,
travis@....com, seto.hidetoshi@...fujitsu.com,
rdunlap@...otime.net, rdreier@...co.com, steiner@....com,
tj@...nel.org, mingo@...e.hu
Subject: [tip:timers/core] timers, init: Limit the number of per cpu calibration bootup messages
Commit-ID: feae3203d711db0a9965300ee6d592257fdaae4f
Gitweb: http://git.kernel.org/tip/feae3203d711db0a9965300ee6d592257fdaae4f
Author: Mike Travis <travis@....com>
AuthorDate: Tue, 17 Nov 2009 18:22:13 -0600
Committer: Ingo Molnar <mingo@...e.hu>
CommitDate: Thu, 26 Nov 2009 10:18:42 +0100
timers, init: Limit the number of per cpu calibration bootup messages
Limit the number of per cpu calibration messages by only
printing out results for the first cpu to boot.
Also, don't print "CPUx is down" as this is expected, and we
don't need 4096 reminders... ;-)
Signed-off-by: Mike Travis <travis@....com>
Cc: Heiko Carstens <heiko.carstens@...ibm.com>
Cc: Roland Dreier <rdreier@...co.com>
Cc: Randy Dunlap <rdunlap@...otime.net>
Cc: Tejun Heo <tj@...nel.org>
Cc: Andi Kleen <andi@...stfloor.org>
Cc: Greg Kroah-Hartman <gregkh@...e.de>
Cc: Yinghai Lu <yhlu.kernel@...il.com>
Cc: David Rientjes <rientjes@...gle.com>
Cc: Steven Rostedt <rostedt@...dmis.org>
Cc: Rusty Russell <rusty@...tcorp.com.au>
Cc: Hidetoshi Seto <seto.hidetoshi@...fujitsu.com>
Cc: Jack Steiner <steiner@....com>
Cc: Frederic Weisbecker <fweisbec@...il.com>
LKML-Reference: <20091118002219.889552000@...atraz.americas.sgi.com>
Signed-off-by: Ingo Molnar <mingo@...e.hu>
---
init/calibrate.c | 24 +++++++++++++++---------
kernel/cpu.c | 5 ++---
2 files changed, 17 insertions(+), 12 deletions(-)
diff --git a/init/calibrate.c b/init/calibrate.c
index a379c90..6eb48e5 100644
--- a/init/calibrate.c
+++ b/init/calibrate.c
@@ -123,23 +123,26 @@ void __cpuinit calibrate_delay(void)
{
unsigned long ticks, loopbit;
int lps_precision = LPS_PREC;
+ static bool printed;
if (preset_lpj) {
loops_per_jiffy = preset_lpj;
- printk(KERN_INFO
- "Calibrating delay loop (skipped) preset value.. ");
- } else if ((smp_processor_id() == 0) && lpj_fine) {
+ if (!printed)
+ pr_info("Calibrating delay loop (skipped) "
+ "preset value.. ");
+ } else if ((!printed) && lpj_fine) {
loops_per_jiffy = lpj_fine;
- printk(KERN_INFO
- "Calibrating delay loop (skipped), "
+ pr_info("Calibrating delay loop (skipped), "
"value calculated using timer frequency.. ");
} else if ((loops_per_jiffy = calibrate_delay_direct()) != 0) {
- printk(KERN_INFO
- "Calibrating delay using timer specific routine.. ");
+ if (!printed)
+ pr_info("Calibrating delay using timer "
+ "specific routine.. ");
} else {
loops_per_jiffy = (1<<12);
- printk(KERN_INFO "Calibrating delay loop... ");
+ if (!printed)
+ pr_info("Calibrating delay loop... ");
while ((loops_per_jiffy <<= 1) != 0) {
/* wait for "start of" clock tick */
ticks = jiffies;
@@ -170,7 +173,10 @@ void __cpuinit calibrate_delay(void)
loops_per_jiffy &= ~loopbit;
}
}
- printk(KERN_CONT "%lu.%02lu BogoMIPS (lpj=%lu)\n",
+ if (!printed)
+ pr_cont("%lu.%02lu BogoMIPS (lpj=%lu)\n",
loops_per_jiffy/(500000/HZ),
(loops_per_jiffy/(5000/HZ)) % 100, loops_per_jiffy);
+
+ printed = true;
}
diff --git a/kernel/cpu.c b/kernel/cpu.c
index 6ba0f1e..7c4e271 100644
--- a/kernel/cpu.c
+++ b/kernel/cpu.c
@@ -392,10 +392,9 @@ int disable_nonboot_cpus(void)
if (cpu == first_cpu)
continue;
error = _cpu_down(cpu, 1);
- if (!error) {
+ if (!error)
cpumask_set_cpu(cpu, frozen_cpus);
- printk("CPU%d is down\n", cpu);
- } else {
+ else {
printk(KERN_ERR "Error taking CPU%d down: %d\n",
cpu, error);
break;
--
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