Commit Graph

8 Commits

Author SHA1 Message Date
martin
a6bab1a764 Allow architectures to define a macro PROC_MACHINE_ARCH(P) and
PROC_MACHINE_ARCH32(P) to override the value for sysctl hw.machine_arch
(native and netbsd32 commpat resp.).

Use these for arm and mips instead of the (not working, noisy, in case
of arm) sysctl override and #ifdef __mips__ in architecture neutral
code.
2017-10-31 12:37:23 +00:00
pooka
7cc60ed4d8 Move a bunch of sysctl nodes from init_sysctl (kitchen sink sysctl file)
to init_sysctl_base (only base kernel defs).  Main motivation was to
fix sysconf(_SC_NPROCESSORS) for Rumprun.  As reported by neeraj on irc,
it returned -1 before this fix, so we were doing imaginary computing.
2015-08-25 14:52:31 +00:00
pooka
21ff215384 hw nodes do not go under the kern tree, so add new init routine for them 2015-08-25 14:32:34 +00:00
justin
7de47d8d6f Missing includes for some architectures 2015-07-07 13:07:10 +00:00
justin
034bfbdba3 Move hw.machine and hw.machine_arch sysctls to base so rump can use them
This allows uname(3) and uname(1) to work on rump kernels.
2015-07-07 12:38:02 +00:00
pooka
4f6fb3bf35 Ensure that the top level sysctl nodes (kern, vfs, net, ...) exist before
the sysctl link sets are processed, and remove redundancy.

Shaves >13kB off of an amd64 GENERIC, not to mention >1k duplicate
lines of code.
2014-02-25 18:30:08 +00:00
justin
69dd91d347 Add kern.{ostype,osrelease,osrevision,version} kern.domainname,
kern.rawpartition sysctl support to rump kernel.
Moved the sysctl support that is shared between rump and normal
kernels to init_sysctl_base.c as rump cannot use init_sysctl.c
in order to avoid code duplication. Agreed with pooka@.
2014-02-25 01:02:42 +00:00
pooka
41c00db98c Chop init_sysctl into base nodes (init_sysctl_base.c) and the
kitchen sink (init_sysctl.c).  Further surgery may be needed down
the line.
2009-09-16 15:03:56 +00:00