Thanks for dealing with my acidness in the first patch :)
But what about this one?
On Sat, Oct 06, 2007 at 10:10:01PM +0200, Jan Engelhardt wrote:
>
> Colored kernel message output (2/2)
>
> By popular request, this patch adds per-loglevel coloring.
> The user may set values using vt.printk_color= or by modifying
> the sysfs file in the running system.
>
> Signed-off-by: Jan Engelhardt <[email protected]>
>
> ---
> arch/x86_64/kernel/early_printk.c | 11 +++++++----
> drivers/char/Kconfig | 4 +++-
> drivers/char/vt.c | 32 ++++++++++++++++++++++++--------
> drivers/net/netconsole.c | 3 ++-
> drivers/serial/8250.c | 3 ++-
> drivers/serial/8250_early.c | 3 ++-
> include/linux/console.h | 2 +-
> kernel/printk.c | 12 +++++++-----
> 8 files changed, 48 insertions(+), 22 deletions(-)
Making this amount changes and not thinking about more intelligent
coding of the functionality?
> Index: linux-2.6.23/arch/x86_64/kernel/early_printk.c
> ===================================================================
> --- linux-2.6.23.orig/arch/x86_64/kernel/early_printk.c
> +++ linux-2.6.23/arch/x86_64/kernel/early_printk.c
> @@ -20,7 +20,8 @@
> static int max_ypos = 25, max_xpos = 80;
> static int current_ypos = 25, current_xpos = 0;
>
> -static void early_vga_write(struct console *con, const char *str, unsigned n)
> +static void early_vga_write(struct console *con, const char *str, unsigned n,
> + unsigned int loglevel)
> {
I mean, *write() have nothing to do with loglevels. If they do
(suddenly), then why not to use a char in the *str to make it possible? I
might be wrong, but there are already macros before format strings in
printk().
And this is not `loglevel' thing any more. It's attributes, which can be
used by many other drivers/file systems/schedulers/ what ever, if
developers, like Ingo, will extend printk() output to be more nice in
subsystems they develop.
So, maybe they can be extended, and functionality implemented in the
function bodies (which will be `do { } while (0)' if config is NO), but
*NOT* by passing additional argument to the functions.
___
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
[Index of Archives]
[Kernel Newbies]
[Netfilter]
[Bugtraq]
[Photo]
[Stuff]
[Gimp]
[Yosemite News]
[MIPS Linux]
[ARM Linux]
[Linux Security]
[Linux RAID]
[Video 4 Linux]
[Linux for the blind]
[Linux Resources]