On Thu, 2007-09-20 at 15:38 -0500, Rob Landley wrote:
> And so far no behavior has changed.  But now the _fun_ part is, you can add a 
> config symbol for "what is the minimum loglevel I care about?"  Set that as a 
> number from 0-9.  And then you can define the printk to do:
> 
> #define printk(level, str, ...) \
>   do { \
>     if (level < CONFIG_PRINTK_DOICARE) \
>       actual_printk("<" #level ">" str, __VA_ARGS__); \
>   } while(0);
> 
> And viola (however you spell that, I think I'm using the stringed instrument 

> But this doesn't _completely_ eliminate 
> printks, so you can still get the panic() calls and such.  You tweak precisly 
> how much bloat you want, using the granularity information that's already 
> there in the source code...
> Opinions?

I'd rather take the opportunity to convert all the printks to
use pr_<level>.  That way, you can pick'n'choose if you want
arbitrary combinations of KERN_<level> compiled in or not.


-
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/

Reply via email to