Subject: Re: hardware monitor device drivers / kernel support (eg. LM78)
To: None <tech-kern@NetBSD.ORG>
From: Ty Sarna <tsarna@endicor.com>
List: tech-kern
Date: 06/03/1998 20:59:48
In article <199806031952.PAA19479@brain.zeus.leitch.com>,
Greg A. Woods <freebsd-hackers@FreeBSD.org, tech-kern@NetBSD.ORG,
        port-i386@NetBSD.ORG, woods@zeus.leitch.com> wrote:
> [[ Please feel free to trim out any cross posting as appropriate, but
> please do include <woods@zeus.leitch.com> in any replies. ]]

I trimmed port-i386... tech-kern seems most appropriate.

> I'm about to embark on adding kernel support for hardware monitoring.

Hooray! I thought about doing this, since the LM78 seems reasonably
simple, but got bogged down in the issues you raise below.

> My preference is to implement this as a virtual filesystem, however in
> structure it would be extremely similar to a sysctl interface, and since
> I've never really liked sysctl in the first place I'm thinking of
> combining these two ideas and simply adding a full sysctl interface to
> kernfs, complete with additional support for what could hopefully be a
> fairly generic hardware monitor "MIB".

This is the problem with sysctl: it really wants to be a filesystem,
IMO, but there is sufficient political opposition I don't think it'll
happen.

In more detail: sysctl really wants to deal with named rather than
numbered things, and wants to do that with more dynamicism than the
current sysctl offers.  We already have a resonably good system for
managing a hierarchichal, named system of things, which can change at
run time (namely, files).  I don't see why it wouldn't be in the best
UN*X traditions to use that existing subsystem for sysctls.  But the
wrong people do :-(