Annotation of coherent/f/usr/include.78/sys/shm.h, revision 1.1

1.1     ! root        1: /* (-lgl
        !             2:  *     COHERENT Version 3.0
        !             3:  *     Copyright (c) 1982, 1990 by Mark Williams Company.
        !             4:  *     All rights reserved. May not be copied without permission.
        !             5:  -lgl) */
        !             6: #ifndef __SYS_SHM_H__
        !             7: #define        __SYS_SHM_H__
        !             8: /*
        !             9: **     IPC Shared Memory Facility.
        !            10: */
        !            11: #include <sys/ipc.h>
        !            12: #include <sys/_time.h>
        !            13: 
        !            14: extern int shmfd;              /* file descriptor to access shared memory */
        !            15: 
        !            16: /*
        !            17: **     Permission Definitions.
        !            18: */
        !            19: #define        SHM_R   0400            /* read permission */
        !            20: #define        SHM_W   0200            /* write permission */
        !            21: 
        !            22: /*
        !            23: **     ipc_perm Mode Definitions.
        !            24: */
        !            25: #define        SHM_CLEAR       01000   /* clear segment on next attach */
        !            26: #define        SHM_DEST        02000   /* destroy segment when # attached = 0 */
        !            27: 
        !            28: /*
        !            29: **     Message Operations Flags.
        !            30: */
        !            31: #define        SHM_RDONLY      010000  /* attach read-only (else read-write) */
        !            32: #define SHM_RND                020000  /* round attach address to SHMLBA */
        !            33: 
        !            34: /* 
        !            35:  * Shared memory control operations (are not included in iBCS2)
        !            36:  * COHERENT 4.0.x does not use a swapper.
        !            37:  */
        !            38: #define        SHM_LOCK        3       /* lock shared memory segment in core */
        !            39: #define SHM_UNLOCK     4       /* unlock shared memory segment */
        !            40: 
        !            41: /*
        !            42: **     There is a shared mem id data structure for each segment in the system.
        !            43: */
        !            44: struct shmid_ds {
        !            45:        struct ipc_perm shm_perm;       /* operation permission struct */
        !            46:        int             shm_segsz;      /* segment size */
        !            47: #ifdef _I386
        !            48:        unsigned short  shm_cpid;       /* pid of creator */
        !            49:        unsigned short  shm_lpid;       /* pid of last shmop */
        !            50: #else
        !            51:        unsigned short  shm_lpid;       /* pid of last shmop */
        !            52:        unsigned short  shm_cpid;       /* pid of creator */
        !            53: #endif
        !            54:        unsigned short  shm_nattch;     /* current # attached */
        !            55: #ifndef _I386
        !            56:        unsigned short  shm_cnattch;    /* in memory # attached */
        !            57: #endif
        !            58:        time_t          shm_atime;      /* last shmat time */
        !            59:        time_t          shm_dtime;      /* last shmdt time */
        !            60:        time_t          shm_ctime;      /* last change time */
        !            61: };
        !            62: 
        !            63: /*
        !            64: **     Ioctl Commands issued to Shared Memory Device Driver (on Coherent).
        !            65: */
        !            66: #define        SHMIOC  ('H'<<8)
        !            67: #define        SHMCTL  (SHMIOC+'C')
        !            68: #define        SHMGET  (SHMIOC+'G')
        !            69: #define        SHMAT   (SHMIOC+'A')
        !            70: #define        SHMDT   (SHMIOC+'D')
        !            71: 
        !            72: #endif

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.