Subject: port specific machdep sysctl definitions
To: None <port-mips@netbsd.org>
From: Jeff Smith <jeffs@geocast.com>
List: port-mips
Date: 07/11/2000 10:14:33
All:

Our product at geocast has a number of specific sysctls we use for
tweaking things that are part of the main platform code.  They don't
really belong in a driver.  Using sysctl is also great as it allows
them to be accessed from the command line.

Last night I changed mips/include/cpu.h to not define the machdep
sysctl defines if they have already been defined by machine/cpu.h.

This seems fairly clean to me.  The big problem is if you touch
use this feature you break binary compatability (sysctl command,
potentially other commands that use sysctl) with other like
endian MIPS ports.

For our concern, this doesn't bother us, but I can see how it
would bother other mips users working on multiple platforms.

I'm looking for others opinions on how to handle this.  As I see
I can:
        1) Leave it as is, with an additional comment that if you
           override you will not be user land compatible.
        2) Add our sysctls to the mips cpu.h.  Ports that do
           not use them will not implement them.  This is
           what Simon Burge requested.
        3) Live with merging this file in geocasts tree.  We
           are really trying to sync up so we can participate
           more.

The sysctls we've added are:

        CPU_LED                 - controls system led
        CPU_DBGPROM             - prom type system is running.
        CPU_WATCH_PERIOD        - time between watchdog timeouts
        CPU_WATCH_UPDATE        - update watchdog timer
        CPU_APPL_START          - system application has started
        CPU_APPL_OK             - system application is ok
        CPU_BOOT_ALTROOT        - boot alternate / partition
        CPU_BOARDINFO           - board revision information

Comments?

jeffs