Re: RFC: Adding a hw.features[2] sysctl

From: Igor Mozolevsky <igor_at_hybrid-lab.co.uk>
Date: Mon, 14 Jan 2008 02:49:04 +0000
On 14/01/2008, Peter Wemm <peter_at_wemm.org> wrote:
> On Jan 13, 2008 5:21 PM, Igor Mozolevsky <igor_at_hybrid-lab.co.uk> wrote:
> > On 13/01/2008, Peter Jeremy <peterjeremy_at_optushome.com.au> wrote:
> >
> > > IMHO, no.  Virtually all similar FreeBSD information is exported via
> > > sysctl and this sort of information fits neatly into the existing
> > > MIB tree as either dev.cpu.N.features or hw.cpu.features
> >
> > /dev/sndstat?
>
> That is a special case.  It was an externally defined API that we
> needed to be compatible with. OSS ran on everything from Linux to SVR4
> to FreeBSD at the time.

It's the question of where you really want to do the parsing - would
you rather the programmer had a simple API that they could query and
deal with a boolean result, or would you rather have everyone who
wanted to use the feature write their own parser for whatever (loosely
formatted value; who known when we'll have features3, features4 and so
on) sysctl returned? :-/

Igor
Received on Mon Jan 14 2008 - 01:49:06 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:39:25 UTC