xref: /illumos-gate/usr/src/uts/common/sys/sysconfig.h (revision 598f4ceed9327d2d6c2325dd67cae3aa06f7fea6)
1 /*
2  * CDDL HEADER START
3  *
4  * The contents of this file are subject to the terms of the
5  * Common Development and Distribution License (the "License").
6  * You may not use this file except in compliance with the License.
7  *
8  * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9  * or http://www.opensolaris.org/os/licensing.
10  * See the License for the specific language governing permissions
11  * and limitations under the License.
12  *
13  * When distributing Covered Code, include this CDDL HEADER in each
14  * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15  * If applicable, add the following below this CDDL HEADER, with the
16  * fields enclosed by brackets "[]" replaced with your own identifying
17  * information: Portions Copyright [yyyy] [name of copyright owner]
18  *
19  * CDDL HEADER END
20  */
21 /*	Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T	*/
22 /*	  All Rights Reserved  	*/
23 
24 
25 /*
26  * Copyright 2007 Sun Microsystems, Inc.  All rights reserved.
27  * Use is subject to license terms.
28  */
29 
30 #ifndef _SYS_SYSCONFIG_H
31 #define	_SYS_SYSCONFIG_H
32 
33 #pragma ident	"%Z%%M%	%I%	%E% SMI"	/* SVr4.0 1.5 */
34 
35 #ifdef	__cplusplus
36 extern "C" {
37 #endif
38 
39 #ifdef _KERNEL
40 extern int	mach_sysconfig(int);
41 #endif	/* KERNEL */
42 
43 /*
44  * cmd values for _sysconfig system call.
45  * WARNING: This is an undocumented system call,
46  * therefore future compatibility can not
47  * guaranteed.
48  */
49 
50 #define	 UNUSED			1
51 #define	_CONFIG_NGROUPS		2	/* # configured supplemental groups */
52 #define	_CONFIG_CHILD_MAX	3	/* max # of processes per uid session */
53 #define	_CONFIG_OPEN_FILES	4	/* max # of open files per process */
54 #define	_CONFIG_POSIX_VER	5	/* POSIX version */
55 #define	_CONFIG_PAGESIZE	6	/* system page size */
56 #define	_CONFIG_CLK_TCK		7	/* ticks per second */
57 #define	_CONFIG_XOPEN_VER	8
58 
59 /*
60  * NOTE: XOPEN VERSION. This is process dependent. The kernel will return
61  * the default value, currently 3.
62  */
63 
64 #define	_CONFIG_PROF_TCK	10	/* profiling ticks per second */
65 #define	_CONFIG_NPROC_CONF	11	/* processors configured */
66 #define	_CONFIG_NPROC_ONLN	12	/* processors online */
67 
68 /* posix dot4 names */
69 #define	_CONFIG_AIO_LISTIO_MAX	13	/* # of operation in a list I/O call */
70 #define	_CONFIG_AIO_MAX		14	/* # of outstanding async I/O op. */
71 #define	_CONFIG_AIO_PRIO_DELTA_MAX	15 /* amount I/O priority decrease */
72 #define	_CONFIG_DELAYTIMER_MAX	16	/* timer timer expiration overruns */
73 #define	_CONFIG_MQ_OPEN_MAX	17	/* # message queues open per process */
74 #define	_CONFIG_MQ_PRIO_MAX	18	/* # of message priorities supported */
75 #define	_CONFIG_RTSIG_MAX	19	/* # of realtime signal numbers */
76 #define	_CONFIG_SEM_NSEMS_MAX	20	/* No. of semaphore per process */
77 #define	_CONFIG_SEM_VALUE_MAX	21	/* max. value a semaphore may have */
78 #define	_CONFIG_SIGQUEUE_MAX	22	/* # of pending queued signal */
79 #define	_CONFIG_SIGRT_MIN	23	/* first highest-pri realtime signal */
80 #define	_CONFIG_SIGRT_MAX	24	/* last realtime signal */
81 #define	_CONFIG_TIMER_MAX	25	/* # of timers per process */
82 
83 #define	_CONFIG_PHYS_PAGES	26	/* phys mem installed in pages */
84 #define	_CONFIG_AVPHYS_PAGES	27	/* available phys mem in pages */
85 #define	_CONFIG_COHERENCY	28	/* # bytes coherency */
86 #define	_CONFIG_SPLIT_CACHE	29	/* split i and d or not */
87 #define	_CONFIG_ICACHESZ	30	/* icache size in bytes */
88 #define	_CONFIG_DCACHESZ	31	/* dcache size in bytes */
89 #define	_CONFIG_ICACHELINESZ	32	/* linesize bytes */
90 #define	_CONFIG_DCACHELINESZ	33	/* linesize bytes */
91 #define	_CONFIG_ICACHEBLKSZ	34	/* block size bytes */
92 #define	_CONFIG_DCACHEBLKSZ	35	/* block size bytes */
93 #define	_CONFIG_DCACHETBLKSZ	36	/* block size bytes when touched */
94 #define	_CONFIG_ICACHE_ASSOC	37	/* associativity 1, 2, 3 whatever */
95 #define	_CONFIG_DCACHE_ASSOC	38	/* associativity 1, 2, 3 whatever */
96 #define	_CONFIG_MAXPID		42	/* highest PID available */
97 #define	_CONFIG_STACK_PROT	43	/* default stack protection */
98 #define	_CONFIG_NPROC_MAX	44	/* maximum # of processors possible */
99 #define	_CONFIG_CPUID_MAX	45	/* maximum CPU id */
100 
101 /* UNIX 03 names */
102 #define	_CONFIG_SYMLOOP_MAX	46	/* maximum # of symlinks in pathname */
103 
104 #define	_CONFIG_EPHID_MAX	47	/* maximum ephemeral uid */
105 
106 #ifdef	__cplusplus
107 }
108 #endif
109 
110 #endif /* _SYS_SYSCONFIG_H */
111