From mboxrd@z Thu Jan 1 00:00:00 1970 From: Takashi Iwai Subject: Re: today's linux-next fails to boot Date: Tue, 15 Jul 2008 13:06:58 +0200 Message-ID: References: <4877400B.1000400@gmail.com> <487C074E.8080309@gmail.com> Mime-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: QUOTED-PRINTABLE Return-path: Received: from ns2.suse.de ([195.135.220.15]:45206 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754938AbYGOLG7 (ORCPT ); Tue, 15 Jul 2008 07:06:59 -0400 In-Reply-To: <487C074E.8080309@gmail.com> Sender: linux-next-owner@vger.kernel.org List-ID: To: =?ISO-8859-1?Q?Fr=E9d=E9ric?= Weisbecker Cc: =?ISO-8859-1?Q?T=F6r=F6k?= Edwin , Bernhard Walle , linux-next@vger.kernel.org, Linux Kernel At Tue, 15 Jul 2008 04:11:26 +0200, =46r=E9d=E9ric Weisbecker wrote: >=20 > T=F6r=F6k Edwin a =E9crit : > > Hi, > > > > Today's linux-next tree (commit > > 93847083e4791567931bd17c039cc35881cdad29) fails to boot: > > [built with gcc-4.2.4-3] > > > > BUG: Int 14: CR2 b0049dea > > EDI 00000082 ESI 00000000 EBP c059be88 ESP c059be5c > > EBX f000ec62 EDX 0000000e ECX c0595480 EAX f000ec62 > > err 00000000 EIP c0181ca0 CS 00000060 flg 00010082 > > Stack: 00000040 c06a2ba0 000080d0 c0595480 c0000f19c c000f180 c05= 81120 > > c059bea8 > > c02bf19b 00000000 00000080 c059beb8 c0000f194 c000f180 000= 0000a > > c059beb8 > > c03a1059 00000000 00000000 c059bed8 c05c4c7c 0009efff 000= 00000 > > c04f4df4 > > > > I get this as soon as I boot from grub2, strangely the error messag= e is > > at the bottom of the screen, and I can't see the full message (scro= lling > > won't work). > > > > The last kernel I built & booted was 2.6.26-rc8 from Linus's tree. = I > > will try to built&boot 2.6.26-rc9, and then bisect. > > > > This happens on 32-bit Dell Inspiron 6400 (Intel Core Duo T2300 @1.= 66 > > Ghz CPU), Intel ICH-7 chipset, and a seagate SATA drive.=20 > > I will provide full hardware details once I bisected the problem. > > > > Meanwhile, if somebody has an idea as to what is wrong? > > > > Best regards, > > --Edwin > > -- > > To unsubscribe from this list: send the line "unsubscribe linux-ker= nel" 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/ > > =20 >=20 > I got the same problem on an x86-PC and after looking at the stack, t= he=20 > problem comes from firmware_map_add_early() in drivers/firmware/memma= p.c >=20 > The backtrace is the following: >=20 > kzalloc() > verify_dynamic_kobject_allocation() > kobject_init() > firmware_map_add_entry() > firmware_map_add_early() > e820_reserve_resources() > setup_arch() (in x86) >=20 > The problem is that verify_dynamic_kobject_allocation() calls kzalloc= =20 > assuming that kmem_cache_init() has already been called. But it's not= =20 > the case and it's too soon to call the kmalloc/kzalloc functions. >=20 > I don't know what is the real problem: the fact that kobject_init is=20 > called too soon or verify_dynamic_kobject_allocation() which calls=20 > kzalloc without making any assumption about its current context. >=20 > So here is just a patch to temporarily disable=20 > verify_dynamic_kobject_allocation() This function just checks the san= ity=20 > of the code. Confirmed that this fixes the boot problem on my machine, too. (It explains why this happens only on x86-32...) Added Bernhard to Cc. Maybe we should defer firmware_map_add*()? thanks, Takashi > [2 disable_verify_dyn_kobject.diff ] > --- a/lib/kobject.c 2008-07-15 02:55:08.000000000 +0200 > +++ b/lib/kobject.c 2008-07-15 04:01:10.000000000 +0200 > @@ -335,7 +335,6 @@ > "object, something is seriously wrong.\n", kobj); > dump_stack(); > } > - verify_dynamic_kobject_allocation(kobj); > =20 > kobject_init_internal(kobj); > kobj->ktype =3D ktype;