1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148
|
// SPDX-License-Identifier: MPL-2.0
// (c) Hare authors <https://harelang.org>
// Taken from DragonFly's sys/sysctl.h
export def CTL_MAXNAME: int = 12; // largest number of components supported
export def CTL_SYSCTL: int = 0; // "magic" numbers
export def CTL_KERN: int = 1; // "high kernel": proc, limits
export def CTL_VM: int = 2; // virtual memory
export def CTL_VFS: int = 3; // file system, mount type is next
export def CTL_NET: int = 4; // network, see socket.h
export def CTL_DEBUG: int = 5; // debugging parameters
export def CTL_HW: int = 6; // generic cpu/io
export def CTL_MACHDEP: int = 7; // machine dependent
export def CTL_USER: int = 8; // user-level
export def CTL_P1003_1B: int = 9; // POSIX 1003.1B
export def CTL_LWKT: int = 10; // light weight kernel threads
export def CTL_MAXID: int = 11; // number of valid top-level ids
export def CTL_SYSCTL_DEBUG: int = 0; // printf all nodes
export def CTL_SYSCTL_NAME: int = 1; // string name of OID
export def CTL_SYSCTL_NEXT: int = 2; // next OID
export def CTL_SYSCTL_NAME2OID: int = 3; // int array of name
export def CTL_SYSCTL_OIDFMT: int = 4; // OID's kind and format
export def CTL_SYSCTL_OIDDESCR: int = 5; // OID's description
export def KERN_OSTYPE: int = 1; // string: system version
export def KERN_OSRELEASE: int = 2; // string: system release
export def KERN_OSREV: int = 3; // int: system revision
export def KERN_VERSION: int = 4; // string: compile time info
export def KERN_MAXVNODES: int = 5; // int: max vnodes
export def KERN_MAXPROC: int = 6; // int: max processes
export def KERN_MAXFILES: int = 7; // int: max open files
export def KERN_ARGMAX: int = 8; // int: max arguments to exec
export def KERN_SECURELVL: int = 9; // int: system security level
export def KERN_HOSTNAME: int = 10; // string: hostname
export def KERN_HOSTID: int = 11; // int: host identifier
export def KERN_CLOCKRATE: int = 12; // struct: struct clockrate
export def KERN_VNODE: int = 13; // struct: vnode structures
export def KERN_PROC: int = 14; // struct: process entries
export def KERN_FILE: int = 15; // struct: file entries
export def KERN_UNUSED16: int = 16; // was: node: kernel profiling info
export def KERN_POSIX1: int = 17; // int: POSIX.1 version
export def KERN_NGROUPS: int = 18; // int: # of supplemental group ids
export def KERN_JOB_CONTROL: int = 19; // int: is job control available
export def KERN_SAVED_IDS: int = 20; // int: saved set-user/group-ID
export def KERN_BOOTTIME: int = 21; // struct: time kernel was booted
export def KERN_NISDOMAINNAME: int = 22; // string: YP domain name
export def KERN_UPDATEINTERVAL: int = 23; // int: update process sleep time
export def KERN_OSRELDATE: int = 24; // int: OS release date
export def KERN_NTP_PLL: int = 25; // node: NTP PLL control
export def KERN_BOOTFILE: int = 26; // string: name of booted kernel
export def KERN_MAXFILESPERPROC: int = 27; // int: max open files per proc
export def KERN_MAXPROCPERUID: int = 28; // int: max processes per uid
export def KERN_DUMPDEV: int = 29; // dev_t: device to dump on
export def KERN_IPC: int = 30; // node: anything related to IPC
export def KERN_DUMMY: int = 31; // unused
export def KERN_PS_STRINGS: int = 32; // int: address of PS_STRINGS
export def KERN_USRSTACK: int = 33; // int: address of USRSTACK
export def KERN_LOGSIGEXIT: int = 34; // int: do we log sigexit procs?
export def KERN_IOV_MAX: int = 35; // int: value of UIO_MAXIOV
export def KERN_MAXPOSIXLOCKSPERUID: int= 36; // int: max POSIX locks per uid
export def KERN_STATIC_TLS_EXTRA: int = 37; // int: extra tls space for rtld
export def KERN_MAXID: int = 38; // number of valid kern ids
export def KERN_PROC_ALL: int = 0; // everything
export def KERN_PROC_PID: int = 1; // by process id
export def KERN_PROC_PGRP: int = 2; // by process group id
export def KERN_PROC_SESSION: int = 3; // by session of pid
export def KERN_PROC_TTY: int = 4; // by controlling tty
export def KERN_PROC_UID: int = 5; // by effective uid
export def KERN_PROC_RUID: int = 6; // by real uid
export def KERN_PROC_ARGS: int = 7; // get/set arguments/proctitle
export def KERN_PROC_CWD: int = 8; // get cwd
export def KERN_PROC_PATHNAME: int = 9; // path to executable
export def KERN_PROC_SIGTRAMP: int = 10; // addr[2]: sigtramp addr range
export def KERN_PROC_FLAGMASK: int = 0; // xF0
export def KERN_PROC_FLAG_LWP: int = 0; // x10
export def KERN_PROC_FLAG_LWKT: int = 0; // x20
export def KIPC_MAXSOCKBUF: int = 1; // int: max size of a socket buffer
export def KIPC_SOCKBUF_WASTE: int = 2; // int: wastage factor in sockbuf
export def KIPC_SOMAXCONN: int = 3; // int: max length of connection q
export def KIPC_MAX_LINKHDR: int = 4; // int: max length of link header
export def KIPC_MAX_PROTOHDR: int = 5; // int: max length of network header
export def KIPC_MAX_HDR: int = 6; // int: max total length of headers
export def KIPC_MAX_DATALEN: int = 7; // int: max length of data?
export def KIPC_MBSTAT: int = 8; // struct: mbuf usage statistics
export def KIPC_NMBCLUSTERS: int = 9; // int: maximum mbuf clusters
export def HW_MACHINE: int = 1; // string: machine class
export def HW_MODEL: int = 2; // string: specific machine model
export def HW_NCPU: int = 3; // int: number of cpus
export def HW_BYTEORDER: int = 4; // int: machine byte order
export def HW_PHYSMEM: int = 5; // int: total memory
export def HW_USERMEM: int = 6; // int: non-kernel memory
export def HW_PAGESIZE: int = 7; // int: software page size
export def HW_DISKNAMES: int = 8; // strings: disk drive names
export def HW_DISKSTATS: int = 9; // struct: diskstats[]
export def HW_FLOATINGPT: int = 10; // int: has HW floating point?
export def HW_MACHINE_ARCH: int = 11; // string: machine architecture
export def HW_MACHINE_PLATFORM: int = 12; // string: platform architecture
export def HW_SENSORS: int = 13; // node: hardware sensors
export def HW_MAXID: int = 14; // number of valid hw ids
export def USER_CS_PATH: int = 1; // string: _CS_PATH
export def USER_BC_BASE_MAX: int = 2; // int: BC_BASE_MAX
export def USER_BC_DIM_MAX: int = 3; // int: BC_DIM_MAX
export def USER_BC_SCALE_MAX: int = 4; // int: BC_SCALE_MAX
export def USER_BC_STRING_MAX: int = 5; // int: BC_STRING_MAX
export def USER_COLL_WEIGHTS_MAX: int = 6; // int: COLL_WEIGHTS_MAX
export def USER_EXPR_NEST_MAX: int = 7; // int: EXPR_NEST_MAX
export def USER_LINE_MAX: int = 8; // int: LINE_MAX
export def USER_RE_DUP_MAX: int = 9; // int: RE_DUP_MAX
export def USER_POSIX2_VERSION: int = 10; // int: _POSIX2_VERSION
export def USER_POSIX2_C_BIND: int = 11; // int: _POSIX2_C_BIND
export def USER_POSIX2_C_DEV: int = 12; // int: _POSIX2_C_DEV
export def USER_POSIX2_CHAR_TERM: int = 13; // int: _POSIX2_CHAR_TERM
export def USER_POSIX2_FORT_DEV: int = 14; // int: _POSIX2_FORT_DEV
export def USER_POSIX2_FORT_RUN: int = 15; // int: _POSIX2_FORT_RUN
export def USER_POSIX2_LOCALEDEF: int = 16; // int: _POSIX2_LOCALEDEF
export def USER_POSIX2_SW_DEV: int = 17; // int: _POSIX2_SW_DEV
export def USER_POSIX2_UPE: int = 18; // int: _POSIX2_UPE
export def USER_STREAM_MAX: int = 19; // int: _POSIX2_STREAM_MAX
export def USER_TZNAME_MAX: int = 20; // int: _POSIX2_TZNAME_MAX
export def USER_MAXID: int = 21; // number of valid user ids
export def CTL_P1003_1B_ASYNCHRONOUS_IO: int = 1; // boolean
export def CTL_P1003_1B_MAPPED_FILES: int = 2; // boolean
export def CTL_P1003_1B_MEMLOCK: int = 3; // boolean
export def CTL_P1003_1B_MEMLOCK_RANGE: int = 4; // boolean
export def CTL_P1003_1B_MEMORY_PROTECTION: int = 5; // boolean
export def CTL_P1003_1B_MESSAGE_PASSING: int = 6; // boolean
export def CTL_P1003_1B_PRIORITIZED_IO: int = 7; // boolean
export def CTL_P1003_1B_PRIORITY_SCHEDULING: int = 8; // boolean
export def CTL_P1003_1B_REALTIME_SIGNALS: int = 9; // boolean
export def CTL_P1003_1B_SEMAPHORES: int = 10; // boolean
export def CTL_P1003_1B_FSYNC: int = 11; // boolean
export def CTL_P1003_1B_SHARED_MEMORY_OBJECTS: int = 12; // boolean
export def CTL_P1003_1B_SYNCHRONIZED_IO: int = 13; // boolean
export def CTL_P1003_1B_TIMERS: int = 14; // boolean
export def CTL_P1003_1B_AIO_LISTIO_MAX: int = 15; // int
export def CTL_P1003_1B_AIO_MAX: int = 16; // int
export def CTL_P1003_1B_AIO_PRIO_DELTA_MAX: int = 17; // int
export def CTL_P1003_1B_DELAYTIMER_MAX: int = 18; // int
export def CTL_P1003_1B_UNUSED19: int = 19; // int
export def CTL_P1003_1B_PAGESIZE: int = 20; // int
export def CTL_P1003_1B_RTSIG_MAX: int = 21; // int
export def CTL_P1003_1B_SEM_NSEMS_MAX: int = 22; // int
export def CTL_P1003_1B_UNUSED23: int = 23; // int
export def CTL_P1003_1B_SIGQUEUE_MAX: int = 24; // int
export def CTL_P1003_1B_TIMER_MAX: int = 25; // int
export def CTL_P1003_1B_MAXID: int = 26; //
|