Re: [patch] printk from userspace

H. Peter Anvin (hpa@zytor.com)
Tue, 13 Aug 2002 21:42:38 -0700


Benjamin LaHaise wrote:
> On Tue, Aug 13, 2002 at 09:26:45PM -0700, Linus Torvalds wrote:
>
>>That said, I like the notion. I've always hated the fact that all the
>>boot-time messages get lost, simply because syslogd hadn't started, and
>>as a result things like fsck ran without any sign afterwards. The kernel
>>log approach saves it all in one place.
>>
>>But /dev/console just sounds potentially _too_ noisy.
>
>
> /dev/kmsg was another suggestion for the name. But please revert the
> yet-another-syscall variant -- having a duplicate way for logging that
> doesn't work with stdio just seems sick to me (sys_syslog should die).
> Something like the following untested code is much better.
>

a) /dev/kmsg bettwe be S_IRUSR|S_IWUSR... reading /{proc,dev}/kmsg
should drain the ring buffer.

b) Hook up the /proc/kmsg read to this thing.

It really needs to be a /dev node, not a /proc node; procfs is likely
*not* to be mounted; however, manifesting a /dev node is easy enough.

-hpa

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