public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] add "notime" boot option
@ 2007-05-22 19:09 Randy Dunlap
  2007-05-22 19:40 ` Dave Jones
                   ` (2 more replies)
  0 siblings, 3 replies; 18+ messages in thread
From: Randy Dunlap @ 2007-05-22 19:09 UTC (permalink / raw)
  To: lkml; +Cc: akpm

From: Randy Dunlap <randy.dunlap@oracle.com>

Add "notime" boot option to prevent timing data from being printed on
each printk message line.

We've seen a few cases of 'time' data locking problems (possibly
involving netconsole or net drivers).  If a kernel is built with
CONFIG_PRINTK_TIME=y, it may have a boot locking hang.  Booting
with "notime" may (i.e., could) prevent the lock hang and allow the
kernel to boot successfully, without requiring a kernel rebuild.

Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
---
 Documentation/kernel-parameters.txt |    2 ++
 kernel/printk.c                     |   10 +++++++++-
 2 files changed, 11 insertions(+), 1 deletion(-)

--- linux-2622-rc2.orig/Documentation/kernel-parameters.txt
+++ linux-2622-rc2/Documentation/kernel-parameters.txt
@@ -1227,6 +1227,8 @@ and is between 256 and 4096 characters. 
 
 	nosync		[HW,M68K] Disables sync negotiation for all devices.
 
+	notime		Do not print timing data on each printk message line.
+
 	notsc		[BUGS=IA-32] Disable Time Stamp Counter
 
 	nousb		[USB] Disable the USB subsystem
--- linux-2622-rc2.orig/kernel/printk.c
+++ linux-2622-rc2/kernel/printk.c
@@ -458,9 +458,17 @@ static int __init printk_time_setup(char
 	printk_time = 1;
 	return 1;
 }
-
 __setup("time", printk_time_setup);
 
+static int __init printk_notime_setup(char *str)
+{
+	if (*str)
+		return 0;
+	printk_time = 0;
+	return 1;
+}
+__setup("notime", printk_notime_setup);
+
 __attribute__((weak)) unsigned long long printk_clock(void)
 {
 	return sched_clock();

^ permalink raw reply	[flat|nested] 18+ messages in thread

end of thread, other threads:[~2007-05-30 18:39 UTC | newest]

Thread overview: 18+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-05-22 19:09 [PATCH] add "notime" boot option Randy Dunlap
2007-05-22 19:40 ` Dave Jones
2007-05-22 20:00   ` Randy Dunlap
2007-05-23 11:03 ` Michael Tokarev
2007-05-23 17:04   ` Randy Dunlap
2007-05-23 19:15     ` Rene Herman
2007-05-23 20:55       ` Randy Dunlap
2007-05-24  4:54         ` Rene Herman
2007-05-24  5:08           ` Randy Dunlap
2007-05-24  5:11             ` Rene Herman
2007-05-24  6:29               ` Rene Herman
2007-05-24 16:13 ` Jan Engelhardt
2007-05-24 16:24   ` Randy Dunlap
2007-05-24 16:33     ` Jan Engelhardt
2007-05-25  0:15       ` [PATCH] use printk.time option, drop time/notime Randy Dunlap
2007-05-29 20:07         ` Andrew Morton
2007-05-29 21:28           ` Jan Engelhardt
2007-05-30 18:37           ` [PATCH v3] add printk.time option, deprecate 'time' Randy Dunlap

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox