Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1760924AbYCGKId (ORCPT ); Fri, 7 Mar 2008 05:08:33 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1756409AbYCGKIZ (ORCPT ); Fri, 7 Mar 2008 05:08:25 -0500 Received: from mx3.mail.elte.hu ([157.181.1.138]:41501 "EHLO mx3.mail.elte.hu" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752347AbYCGKIX (ORCPT ); Fri, 7 Mar 2008 05:08:23 -0500 Date: Fri, 7 Mar 2008 11:08:06 +0100 From: Ingo Molnar To: Alan Cox , Jiri Slaby Cc: Linux Kernel Mailing List , "Rafael J. Wysocki" , Linus Torvalds Subject: [patch] drivers/char/esp.c: fix bootup lockup (was: Re: Linux 2.6.25-rc4) Message-ID: <20080307100806.GA4350@elte.hu> References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.17 (2007-11-01) X-ELTE-VirusStatus: clean X-ELTE-SpamScore: -1.5 X-ELTE-SpamLevel: X-ELTE-SpamCheck: no X-ELTE-SpamVersion: ELTE 2.0 X-ELTE-SpamCheck-Details: score=-1.5 required=5.9 tests=BAYES_00 autolearn=no SpamAssassin version=3.2.3 -1.5 BAYES_00 BODY: Bayesian spam probability is 0 to 1% [score: 0.0000] Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1898 Lines: 52 randconfig testing found a bootup lockup in drivers/char/esp.c - find the fix below. Not sure why it became more prominent in 2.6.25-rc4, the bug seems rather old and i've been doing allyesconfig bootups for ages with CONFIG_ESP enabled. -------------> Subject: drivers/char/esp.c: fix bootup lockup From: Ingo Molnar Date: Fri Mar 07 10:47:43 CET 2008 fix this bootup lockup: PM: Adding info for No Bus:ttyP63 ttyP32 at 0x0240 (irq = 0) is an ESP primary port BUG: spinlock lockup on CPU#0, swapper/1, f56dd004 Pid: 1, comm: swapper Not tainted 2.6.25-rc4-sched-devel.git-x86-latest.git #402 [] _raw_spin_lock+0x134/0x140 [] _spin_lock_irqsave+0x5e/0x80 [] ? espserial_init+0x2be/0x6e0 [] espserial_init+0x2be/0x6e0 [] kernel_init+0x83/0x260 [] ? espserial_init+0x0/0x6e0 [] ? restore_nocheck_notrace+0x0/0xe [] ? kernel_init+0x0/0x260 [] ? kernel_init+0x0/0x260 [] kernel_thread_helper+0x7/0x10 ======================= kzalloc() is not the way to initialize spinlocks anymore. Signed-off-by: Ingo Molnar --- drivers/char/esp.c | 1 + 1 file changed, 1 insertion(+) Index: linux/drivers/char/esp.c =================================================================== --- linux.orig/drivers/char/esp.c +++ linux/drivers/char/esp.c @@ -2484,6 +2484,7 @@ static int __init espserial_init(void) return 0; } + spin_lock_init(&info->lock); /* rx_trigger, tx_trigger are needed by autoconfig */ info->config.rx_trigger = rx_trigger; info->config.tx_trigger = tx_trigger; -- 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/