|
|
coherent
shmctl() COHERENT System Call shmctl()
Control shared-memory operations
#include <sys/shm.h>
sshhmmccttll(_s_h_m_i_d, _c_m_d, _b_u_f)
iinntt _s_h_m_i_d, _c_m_d; ssttrruucctt sshhmmiidd_ddss *_b_u_f;
shmctl provides controls the COHERENT system's shared-memory
facility. cmd specifies the operation to perform, as follows:
IIPPCC_SSTTAATT Place the current value of each member of the data
structure associated with shmid into the structure
pointed to by buf.
IIPPCC_SSEETT Set the value of the following members of the data
structure associated with shmid to the corresponding
value found in the structure pointed to by buf:
shm_perm.uid
shm_perm.gid
shm_perm.mode /* only low 9 bits */
This cmd can be executed only by a process whose ef-
fective user ID equals either that of the superuser or
shm_perm.uid in the data structure associated with
shmid.
IIPPCC_RRMMIIDD Remove the system identifier specified by shmid from
the system and destroy the shared memory segment and
data structure associated with it. This cmd can be ex-
ecuted only by a process whose effective user ID equalS
either that of the superuser or shm_perm.uid in the
data structure associated with shmid.
shmctl fails if any of the following is true:
* shmid is not a valid shared memory identifier shmget sets er-
rno to EEIINNVVAALL.
* cmd is not a valid command (EEIINNVVAALL).
* cmd equals IPC_STAT and operation permission is denied to the
calling process (EEAACCCCEESS).
* cmd equals IPC_RMID or IPC_SET and the effective user iden-
tifier of the calling process does equals neither that of the
superuser nor shm_perm.uid in the data structure associated
with shmid (EEPPEERRMM).
* buf points to an illegal address (EEFFAAUULLTT).
***** Return Value *****
Upon successful completion, shmctl returns zero; otherwise, it
returns -1 and sets errno to an appropriate value.
COHERENT Lexicon Page 1
shmctl() COHERENT System Call shmctl()
***** Files *****
/usr/include/sys/ipc.h
/usr/include/sys/shm.h
/dev/shm
/drv/shm
***** See Also *****
COHERENT system calls, shm, shmget()
***** Notes *****
To improve portability, the COHERENT system implements its
shared-memory functions as a device driver instead of as an ac-
tual system call.
COHERENT Lexicon Page 2
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.