Re: [patch 1/6] kmsg: tagged kernel messages.

From: Rusty Russell
Date: Sat Sep 27 2008 - 03:15:49 EST


On Friday 26 September 2008 18:29:34 Martin Schwidefsky wrote:
> On Fri, 2008-09-26 at 14:48 +1000, Rusty Russell wrote:
> > On Friday 26 September 2008 02:28:28 Martin Schwidefsky wrote:
> > > +#define kmsg_emerg(fmt, ...) \
> > > + kmsg_printk_hash(KERN_EMERG, fmt, ##__VA_ARGS__)
> > > +#define kmsg_alert(fmt, ...) \
> > > + kmsg_printk_hash(KERN_ALERT, fmt, ##__VA_ARGS__)
> > > +#define kmsg_crit(fmt, ...) \
> > > + kmsg_printk_hash(KERN_CRIT, fmt, ##__VA_ARGS__)
> > > +#define kmsg_err(fmt, ...) \
> > > + kmsg_printk_hash(KERN_ERR, fmt, ##__VA_ARGS__)
> > > +#define kmsg_warn(fmt, ...) \
> > > + kmsg_printk_hash(KERN_WARNING, fmt, ##__VA_ARGS__)
> > > +#define kmsg_notice(fmt, ...) \
> > > + kmsg_printk_hash(KERN_NOTICE, fmt, ##__VA_ARGS__)
> > > +#define kmsg_info(fmt, ...) \
> > > + kmsg_printk_hash(KERN_INFO, fmt, ##__VA_ARGS__)
> >
> > Now I'm going to be an asshole and ask you to define when each of these
> > levels should be used. Do we need all of them?
>
> These are just the regular printk levels. If your old printk used a
> particular level, have the kmsg_xxx printk use the same level. The
> question about message severity and message documenation are
> independent, aren't they?

Yes, but since it's a new message API, I thought you might have an idea. It's
hard for authors (eg. me) to know which level to use. As a result, levels
currently seem to be chosen randomly.

If you felt inspired to rationalize them, it would let us clean that up as
things moved to kmsg :)

Cheers,
Rusty.
--
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/