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] [day] [month] [year] [list]
Date:	Mon, 17 Dec 2007 16:22:21 -0800
From:	"H. Peter Anvin" <hpa@...or.com>
To:	Alan Cox <alan@...rguk.ukuu.org.uk>
CC:	Jan Engelhardt <jengelh@...putergmbh.de>,
	Parag Warudkar <parag.warudkar@...il.com>, devzero@....de,
	Matt.Domsch@...l.com, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] [RFC] be more verbose when probing EDD

Alan Cox wrote:
>> Does printk support escape sequences? The last time I tried
>> printk("\e[1;35m omg ponies \e[0m"); that did not went too successful.
> 
> It should handle \r correctly. If not that is easy to fix.
> 
> Escape codes are bad and should not be used - you may have a serial
> console and not be on a Linux console

It's not printk(), or the console, that's the issue...
Consider logging to a file, which is quite common.

Dumping formatting characters in there is a bit evil.

Instead of using \r and overwrite, something like

Testing foo... ok

printk(KERN_INFO "Testing foo... ");
foo();
printk("ok\n");

... really is a lot better.  We used to do that a lot more.

	-hpa
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ