lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Wed, 23 Sep 2009 18:13:13 -0500
From:	Jason Wessel <jason.wessel@...driver.com>
To:	Linus Torvalds <torvalds@...ux-foundation.org>
CC:	Ingo Molnar <mingo@...e.hu>, Len Brown <lenb@...nel.org>,
	Greg KH <gregkh@...e.de>,
	Andrew Morton <akpm@...ux-foundation.org>,
	linux-kernel@...r.kernel.org, linux-usb@...r.kernel.org
Subject: Re: [origin tree boot hang] [PATCH] Revert "early_printk:Allowmorethan
 one early console"

Linus Torvalds wrote:
> On Wed, 23 Sep 2009, Jason Wessel wrote:
>   
>> Perhaps you will consider adding this patch to your tree?   It fixes the
>> specific case you mentioned.  It will still allow the board to boot and
>> instead of crashing, print a warning on the second instance.
>>     
>
> Ugh. This looks totally bogus.
>
> Why don't you just add CON_REGISTERED to the console flags, and do
>
> 	/* Already registered? */
> 	if (early_console->flags & CON_REGISTERED)
> 		return;
> 	early_console->flags |= CON_REGISTERED;
>
> there instead? That whole "loop over existing consoles to check their 
> names" looks silly and broken, and you're already playing with the flags 
> in there (CON_BOOT).
>   

Seems reasonable to me.  We don't even have to add a new flag, because
we already have the index set to != -1 when the console registration
succeeds.

Here is the revised patch.

Jason.



View attachment "0001-early_printk-Protect-against-using-the-same-device-t.patch" of type "text/x-diff" (1145 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ