Subject: Re: RFC: /kern/summary
To: Brian C. Grayson <>
From: Perry E. Metzger <>
List: tech-kern
Date: 03/09/1999 19:34:59
"Brian C. Grayson" <> writes:
>   I got no negative responses to my query regarding /kern files,
> so I plan on adding a new file to /kern.

My main comment: right now, for whatever reason, local culture frowns
on kernfs as a required mounted file system.

>       InfoMaxBytes:  an upper limit on the number of bytes
> 	contained in this file (valid until a new kernel is
> 	recompiled, that is, this will be conservative, and not
> 	just a strlen of the _current_ file contents).  This
> 	allows one to do a read() of this amount, and hopefully
> 	grab an atomic snapshot in a single syscall, rather
> 	than reading the first 1024 bytes of the file, then
> 	later reading the second 1024 bytes, leading to bogus
> 	values at the buffer boundary due to the change in stats
> 	between the two calls.

Ew! This totally violates the notion of least surprise. If you open
the file, your instance of it should never change out from under you
until you do something to allow that to happen like closing it.

>   At the end, we should have a ps, top, and xosview that, as an
> option, use only /proc and /kern, and thus no longer need
> recompilation very often at all.

As I note, a lot of people seem to dislike this idea. You should
discuss it more widely before moving forward. Not everyone reads
tech-kern every day.