sysconf(2) DG/UX 4.30 sysconf(2)
NAME
sysconf - Get configurable system variables.
SYNOPSIS
#include <unistd.h>
#include <sys/m88kbcs.h>
long sysconf (name)
int name;
DESCRIPTION
The sysconf() function provides a method for the application
to determine the current value of a configurable system
limit or option (variable).
The name argument represents the system variable to be
queried. The implementation shall support all of the
variables listed in the table "Configurable System
Variables" and may support others. The variables in the
table come from <limits.h> or <unistd.h> (or <time.h> from
the C Standard for {CLK_TCK}), and the symbolic constants,
defined in <unistd.h>, that are the corresponding values
used for name.
Configurable System Variables
Variable name Value
{ARG_MAX} {_SC_ARG_MAX}
{CHILD_MAX} {_SC_CHILD_MAX}
{CLK_TCK} {_SC_CLK_TCK}
{NGROUPS_MAX} {_SC_NGROUPS_MAX}
{OPEN_MAX} {_SC_OPEN_MAX}
{_POSIX_JOB_CONTROL} {_SC_JOB_CONTROL}
{_POSIX_SAVED_IDS} {_SC_SAVED_IDS}
{_POSIX_VERSION} {_SC_VERSION}
The value of {CLK_TCK} is permitted to be evaluated at run-
time by the C Standard (and thus by this standard). The
value returned by sysconf() for {_SC_CLK_TCK} shall be the
same as that returned by {CLK_TCK}.
RETURNS
If name is an invalid value, sysconf() shall return -1. If
the variable corresponding to name is not defined on the
system, sysconf() shall return -1 without changing the value
of errno.
Otherwise, the sysconf() function returns the current
variable value on the system. The value returned shall not
be more restrictive than the corresponding value described
Licensed material--property of copyright holder(s) Page 1
sysconf(2) DG/UX 4.30 sysconf(2)
to the application when it was compiled with the
implementation's <limits.h> or <unistd.h>. The value shall
not change during the lifetime of the calling process.
ERRORS
If any of the following conditions occur, the sysconf()
function shall return -1 and set errno to the corresponding
value:
[EINVAL]
The value of the name argument is invalid.
FILES
unistd.h
sys/m88kbcs.h
COPYRIGHTS
Portions of this text are reprinted from IEEE Std 1003.1-
1988, Portable Operating System Interface for Computer
Environment, copyright © 1988 by the Institute of Electrical
and Electronics Engineers, Inc., with the permission of the
IEEE Standards Department. To purchase IEEE Standards, call
800/678-IEEE.
In the event of a discrepancy between the electronic and the
original printed version, the original version takes
precedence.
STANDARDS
In addition to the configurable system variables listed
above, the following variables are defined in
<sys/m88kbcs.h>:
_SC_BCS_VERSION:
Get version number of 88open BCS to which the
system conforms.
_SC_BCS_VENDOR_STAMP:
Get BCS vendor stamp of the system.
_SC_BCS_SYS_ID:
Get system hardware's unique system ID
number.
_SC_MAXUMEMV: Get maximum user process size, in Kbytes.
_SC_MAXUPROC: Get maximum number of processes per user.
_SC_MAXMSGSZ: Get maximum number of bytes in a message.
_SC_NMSGHDRS: Get maximum number of message headers in
system.
Licensed material--property of copyright holder(s) Page 2
sysconf(2) DG/UX 4.30 sysconf(2)
_SC_SHMMAXSZ: Get maximum size of a shared memory segment.
_SC_SHMMINSZ: Get minimum size of a shared memory segment.
_SC_SHMSEGS: Get maximum number of attached shared memory
segments per process.
_SC_NMSYSSEM: Get total number of semaphores in system.
_SC_MAXSEMVL: Get maximum semaphore value.
_SC_NSEMMAP: Get number of semaphore sets.
_SC_NSEMMSL: Get number of semaphores per set.
_SC_NSHMMNI: Get number of shared memory segments in the
system.
_SC_ITIMER_VIRT:
Determine whether or not system supports a
timer.
_SC_ITIMER_PROF:
Determine whether or not system supports a
profiling timer.
_SC_TIMER_GRAN:
Get granularity (in microseconds) of system's
real-time clock.
_SC_PHYSMEM: Get system's physical memory size, in Kbytes.
_SC_AVAILMEM: Get amount of physical memory available to
user processes, in Kbytes.
_SC_NICE: Determine whether or not nice() process
prioritization is supported on system.
_SC_MEMCTL_UNIT:
Get number of bytes in a memctl() memory
unit.
_SC_SHMLBA: Get number of bytes used as rounding factor
on memory addresses by shmsys().
_SC_SVSTREAMS: Determine whether or not system supports
System V style STREAMS.
_SC_CPUID: Get the value stored in the M88100 Processor
Identification Register.
Licensed material--property of copyright holder(s) Page 3