lkml.org 
[lkml]   [2008]   [Feb]   [28]   [last100]   RSS Feed
Views: [more markup]  [less markup]  [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
DateThu, 28 Feb 2008 12:50:41 +0100
FromIngo Molnar <>
SubjectRe: 2.6.25-rc2-mm1 - boot hangs on ia64
* KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com> wrote:

> Hi Ingo,> CC'ed Steven Rostedt > > I found the following patch cause regression by bisect.
> > 2.6.25-rc2-mm1:                            doesn't boot
> 2.6.25-rc2-mm1 + revert following patch:   works well
> > but I think it is very strange. runqueue_is_locked() seems simple and 
> have not bug. ;)> > What do you think this problem?

thanks for bisecting it down! Could ia64 have trouble accessing the 
percpu data structures of the scheduler?

does the patch below resolve the hang?

	Ingo

------------------------->
Subject: sched: fix wake_up_klogd()
From: Ingo Molnar <mingo@elte.hu>
Date: Thu Feb 28 12:42:45 CET 2008
on some platforms if we printk too early it might not be safe to call
into the scheduler data structures.

Signed-off-by: Ingo Molnar <mingo@elte.hu>
---
 kernel/printk.c |    5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)
Index: linux/kernel/printk.c
===================================================================
--- linux.orig/kernel/printk.c
+++ linux/kernel/printk.c
@@ -948,7 +948,8 @@ int is_console_locked(void)
 
 void wake_up_klogd(void)
 {
-	if (!oops_in_progress && waitqueue_active(&log_wait))
+	if (!oops_in_progress && waitqueue_active(&log_wait) &&
+						!runqueue_is_locked())
 		wake_up_interruptible(&log_wait);
 }
 
@@ -1000,7 +1001,7 @@ void release_console_sem(void)
 	 * If we try to wake up klogd while printing with the runqueue lock
 	 * held, this will deadlock.
 	 */
-	if (wake_klogd && !runqueue_is_locked())
+	if (wake_klogd)
 		wake_up_klogd();
 }
 EXPORT_SYMBOL(release_console_sem);
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/
\
 
 \ /
  Last update: 2008-02-28 12:53    [from the cache]
©2003-2008