RE: [PATCH] cleanup legacy console_print function

From: Anirban Sinha
Date: Mon Sep 14 2009 - 13:18:44 EST



>On Fri, 11 Sep 2009, Anirban Sinha wrote:
>>
>> - console_print(text); \
>> - console_print("\n"); \
>> + printk(KERN_EMERG "%s", text); \
>> + printk(KERN_EMERG "\n"); \
>
>Just clean it up to be
>
> printk(KERN_EMERG "%s\n", text);
>
>instead while at it.
>
>> #define TRACE_CHR(chr) \
>> { \
>> if(dtlk_trace) \
>> - console_print(chr); \
>> + printk(KERN_EMERG "%c", chr); \
>
>That can't be right. The translation is to use "%s", not "%c".

Better still, for both the above cases, I will simply remove those macro
definitions. They are enclosed within {#if0 #endif}, so no code could
possibly be using it. If anyone has any strong reasons for keeping it
still, please raise your voice now.

Cheers,

Ani

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