Home | History | Annotate | Download | only in plat-irix5
      1 # Generated by h2py from /usr/include/sys/file.h
      2 from warnings import warnpy3k
      3 warnpy3k("the FILE module has been removed in Python 3.0", stacklevel=2)
      4 del warnpy3k
      5 
      6 # Included from sys/types.h
      7 
      8 # Included from sgidefs.h
      9 _MIPS_ISA_MIPS1 = 1
     10 _MIPS_ISA_MIPS2 = 2
     11 _MIPS_ISA_MIPS3 = 3
     12 _MIPS_ISA_MIPS4 = 4
     13 _MIPS_SIM_ABI32 = 1
     14 _MIPS_SIM_NABI32 = 2
     15 _MIPS_SIM_ABI64 = 3
     16 P_MYID = (-1)
     17 P_MYHOSTID = (-1)
     18 
     19 # Included from sys/bsd_types.h
     20 
     21 # Included from sys/mkdev.h
     22 ONBITSMAJOR = 7
     23 ONBITSMINOR = 8
     24 OMAXMAJ = 0x7f
     25 OMAXMIN = 0xff
     26 NBITSMAJOR = 14
     27 NBITSMINOR = 18
     28 MAXMAJ = 0x1ff
     29 MAXMIN = 0x3ffff
     30 OLDDEV = 0
     31 NEWDEV = 1
     32 MKDEV_VER = NEWDEV
     33 def major(dev): return __major(MKDEV_VER, dev)
     34 
     35 def minor(dev): return __minor(MKDEV_VER, dev)
     36 
     37 
     38 # Included from sys/select.h
     39 FD_SETSIZE = 1024
     40 NBBY = 8
     41 
     42 # Included from sys/sema.h
     43 HP_NOPOLICY = 0
     44 HP_ADDOFF = 1
     45 HP_MULOFF = 2
     46 SEMA_NAMSZ = 8
     47 SEMA_NOHIST = 0x1
     48 SEMA_LIFO = 0x2
     49 SEMA_MUTEX = 0x4
     50 SEMA_METER = 0x8
     51 SEMAOP_PSEMA = 1
     52 SEMAOP_VSEMA = 2
     53 SEMAOP_CPSEMA = 3
     54 SEMAOP_CVSEMA = 4
     55 SEMAOP_WSEMA = 5
     56 SEMAOP_UNSEMA = 6
     57 SEMAOP_INIT = 7
     58 SEMAOP_FREE = 8
     59 SSOP_PHIT = 1
     60 SSOP_PSLP = 2
     61 SSOP_PWAKE = 6
     62 SSOP_PRESIG = 7
     63 SSOP_POSTSIG = 8
     64 SSOP_VNOWAKE = 3
     65 SSOP_VWAKE = 4
     66 SSOP_CPHIT = 1
     67 SSOP_CPMISS = 5
     68 SSOP_CVNOWAKE = 3
     69 SSOP_CVWAKE = 4
     70 SSOP_WMISS = 5
     71 SSOP_WWAKE = 4
     72 SSOP_RMV = 9
     73 TZERO = 10
     74 SEMA_NOP = 0
     75 SEMA_WAKE = 1
     76 SEMA_VSEMA = 2
     77 SEMA_SPINOP = 3
     78 MR_ACCESS = 0x1
     79 MR_UPDATE = 0x2
     80 def cv_signal(cv): return cvsema(cv);
     81 
     82 def cv_destroy(cv): return freesema(cv)
     83 
     84 def mutex_enter(m): return psema(m, PZERO | PNOSTOP)
     85 
     86 def mutex_exit(m): return vsema(m)
     87 
     88 def mutex_destroy(m): return freesema(m)
     89 
     90 def MUTEX_HELD(m): return (ownsema(m))
     91 
     92 def MUTEX_HELD(m): return (1)
     93 
     94 RW_READER = MR_ACCESS
     95 RW_WRITER = MR_UPDATE
     96 def rw_exit(r): return mrunlock(r)
     97 
     98 def rw_tryupgrade(r): return cmrpromote(r)
     99 
    100 def rw_downgrade(r): return mrdemote(r)
    101 
    102 def rw_destroy(r): return mrfree(r)
    103 
    104 def RW_WRITE_HELD(r): return ismrlocked(r, MR_UPDATE)
    105 
    106 def RW_READ_HELD(r): return ismrlocked(r, MR_ACCESS)
    107 
    108 
    109 # Included from sys/splock.h
    110 SPLOCKNAMSIZ = 8
    111 SPLOCK_NONE = 0
    112 SPLOCK_SOFT = 1
    113 SPLOCK_HARD = 2
    114 OWNER_NONE = -1
    115 MAP_LOCKID = 0
    116 SPLOCK_MAX = (96*1024)
    117 SPLOCK_MAX = 32768
    118 MIN_POOL_SIZE = 256
    119 MAX_POOL_SIZE = 16384
    120 DEF_SEMA_POOL = 8192
    121 DEF_VNODE_POOL = 1024
    122 DEF_FILE_POOL = 1024
    123 def ownlock(x): return 1
    124 
    125 def splock(x): return 1
    126 
    127 def io_splock(x): return 1
    128 
    129 def apvsema(x): return vsema(x)
    130 
    131 def apcpsema(x): return cpsema(x)
    132 
    133 def apcvsema(x): return cvsema(x)
    134 
    135 def mp_mrunlock(a): return mrunlock(a)
    136 
    137 def apvsema(x): return 0
    138 
    139 def apcpsema(x): return 1
    140 
    141 def apcvsema(x): return 0
    142 
    143 def mp_mrunlock(a): return 0
    144 
    145 
    146 # Included from sys/fcntl.h
    147 FNDELAY = 0x04
    148 FAPPEND = 0x08
    149 FSYNC = 0x10
    150 FNONBLOCK = 0x80
    151 FASYNC = 0x1000
    152 FNONBLK = FNONBLOCK
    153 FDIRECT = 0x8000
    154 FCREAT = 0x0100
    155 FTRUNC = 0x0200
    156 FEXCL = 0x0400
    157 FNOCTTY = 0x0800
    158 O_RDONLY = 0
    159 O_WRONLY = 1
    160 O_RDWR = 2
    161 O_NDELAY = 0x04
    162 O_APPEND = 0x08
    163 O_SYNC = 0x10
    164 O_NONBLOCK = 0x80
    165 O_DIRECT = 0x8000
    166 O_CREAT = 0x100
    167 O_TRUNC = 0x200
    168 O_EXCL = 0x400
    169 O_NOCTTY = 0x800
    170 F_DUPFD = 0
    171 F_GETFD = 1
    172 F_SETFD = 2
    173 F_GETFL = 3
    174 F_SETFL = 4
    175 F_GETLK = 14
    176 F_SETLK = 6
    177 F_SETLKW = 7
    178 F_CHKFL = 8
    179 F_ALLOCSP = 10
    180 F_FREESP = 11
    181 F_SETBSDLK = 12
    182 F_SETBSDLKW = 13
    183 F_DIOINFO = 30
    184 F_FSGETXATTR = 31
    185 F_FSSETXATTR = 32
    186 F_GETLK64 = 33
    187 F_SETLK64 = 34
    188 F_SETLKW64 = 35
    189 F_ALLOCSP64 = 36
    190 F_FREESP64 = 37
    191 F_GETBMAP = 38
    192 F_FSSETDM = 39
    193 F_RSETLK = 20
    194 F_RGETLK = 21
    195 F_RSETLKW = 22
    196 F_GETOWN = 23
    197 F_SETOWN = 24
    198 F_O_GETLK = 5
    199 F_O_GETOWN = 10
    200 F_O_SETOWN = 11
    201 F_RDLCK = 01
    202 F_WRLCK = 02
    203 F_UNLCK = 03
    204 O_ACCMODE = 3
    205 FD_CLOEXEC = 1
    206 FD_NODUP_FORK = 4
    207 FMASK = 0x90FF
    208 FOPEN = 0xFFFFFFFF
    209 FREAD = 0x01
    210 FWRITE = 0x02
    211 FNDELAY = 0x04
    212 FAPPEND = 0x08
    213 FSYNC = 0x10
    214 FNONBLOCK = 0x80
    215 FASYNC = 0x1000
    216 FNONBLK = FNONBLOCK
    217 FDIRECT = 0x8000
    218 FCREAT = 0x0100
    219 FTRUNC = 0x0200
    220 FEXCL = 0x0400
    221 FNOCTTY = 0x0800
    222 IRIX4_FASYNC = 0x40
    223 FMARK = 0x4000
    224 FDEFER = 0x2000
    225 FINPROGRESS = 0x0400
    226 FINVIS = 0x0100
    227 FNMFS = 0x2000
    228 FCLOSEXEC = 001
    229 FDSHD = 0x0001
    230 FDNOMARK = 0x0002
    231 FDIGNPROGRESS = 0x0004
    232 LOCK_SH = 1
    233 LOCK_EX = 2
    234 LOCK_NB = 4
    235 LOCK_UN = 8
    236 F_OK = 0
    237 X_OK = 1
    238 W_OK = 2
    239 R_OK = 4
    240 L_SET = 0
    241 L_INCR = 1
    242 L_XTND = 2
    243