linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] oops_in_progress is unlikely()
@ 2003-09-07  6:42 Mitchell Blank Jr
  2003-09-07 22:13 ` Dave Jones
  0 siblings, 1 reply; 15+ messages in thread
From: Mitchell Blank Jr @ 2003-09-07  6:42 UTC (permalink / raw)
  To: Andrew Morton; +Cc: linux-kernel

Andrew - thanks for applying my last patch; thought you might be interested
in this trivial one too.  Patch is versus 2.6.0-test4-bk8, I expect it
will also apply against current -mm.

-Mitch

diff -urN -X dontdiff linux-2.6.0-test4bk8-VIRGIN/drivers/char/vt.c linux-2.6.0-test4bk8mnb1/drivers/char/vt.c
--- linux-2.6.0-test4bk8-VIRGIN/drivers/char/vt.c	2003-07-13 20:37:27.000000000 -0700
+++ linux-2.6.0-test4bk8mnb1/drivers/char/vt.c	2003-09-06 13:52:58.000000000 -0700
@@ -2179,7 +2179,7 @@
 	}
 	set_cursor(currcons);
 
-	if (!oops_in_progress)
+	if (likely(!oops_in_progress))
 		poke_blanked_console();
 
 quit:
diff -urN -X dontdiff linux-2.6.0-test4bk8-VIRGIN/drivers/parisc/led.c linux-2.6.0-test4bk8mnb1/drivers/parisc/led.c
--- linux-2.6.0-test4bk8-VIRGIN/drivers/parisc/led.c	2003-07-27 12:57:39.000000000 -0700
+++ linux-2.6.0-test4bk8mnb1/drivers/parisc/led.c	2003-09-06 13:53:18.000000000 -0700
@@ -488,7 +488,7 @@
 	}
 
 	/* blink all LEDs twice a second if we got an Oops (HPMC) */
-	if (oops_in_progress) {
+	if (unlikely(oops_in_progress)) {
 		currentleds = (count_HZ<=(HZ/2)) ? 0 : 0xff;
 	}
 	
diff -urN -X dontdiff linux-2.6.0-test4bk8-VIRGIN/kernel/printk.c linux-2.6.0-test4bk8mnb1/kernel/printk.c
--- linux-2.6.0-test4bk8-VIRGIN/kernel/printk.c	2003-07-13 20:39:24.000000000 -0700
+++ linux-2.6.0-test4bk8mnb1/kernel/printk.c	2003-09-06 13:53:50.000000000 -0700
@@ -400,7 +400,7 @@
 	static char printk_buf[1024];
 	static int log_level_unknown = 1;
 
-	if (oops_in_progress) {
+	if (unlikely(oops_in_progress)) {
 		/* If a crash is occurring, make sure we can't deadlock */
 		spin_lock_init(&logbuf_lock);
 		/* And make sure that we print immediately */

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

end of thread, other threads:[~2003-09-12  5:04 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-09-07  6:42 [PATCH] oops_in_progress is unlikely() Mitchell Blank Jr
2003-09-07 22:13 ` Dave Jones
2003-09-10 14:20   ` Pavel Machek
2003-09-10 14:23     ` Dave Jones
2003-09-10 15:29       ` Pavel Machek
2003-09-10 16:07         ` Richard B. Johnson
2003-09-10 18:31           ` Jamie Lokier
2003-09-10 18:58             ` Richard B. Johnson
2003-09-10 19:02               ` Pavel Machek
2003-09-10 20:12               ` Jamie Lokier
2003-09-10 20:32                 ` Richard B. Johnson
2003-09-10 21:27                   ` Pavel Machek
2003-09-10 21:52                     ` Jamie Lokier
2003-09-10 21:46                   ` Jamie Lokier
2003-09-12  5:12     ` Mitchell Blank Jr

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).