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)
6 # Included from sys/types.h
8 # Included from sgidefs.h
19 # Included from sys/bsd_types.h
21 # Included from sys/mkdev.h
33 def major(dev
): return __major(MKDEV_VER
, dev
)
35 def minor(dev
): return __minor(MKDEV_VER
, dev
)
38 # Included from sys/select.h
42 # Included from sys/sema.h
80 def cv_signal(cv
): return cvsema(cv
);
82 def cv_destroy(cv
): return freesema(cv
)
84 def mutex_enter(m
): return psema(m
, PZERO | PNOSTOP
)
86 def mutex_exit(m
): return vsema(m
)
88 def mutex_destroy(m
): return freesema(m
)
90 def MUTEX_HELD(m
): return (ownsema(m
))
92 def MUTEX_HELD(m
): return (1)
96 def rw_exit(r
): return mrunlock(r
)
98 def rw_tryupgrade(r
): return cmrpromote(r
)
100 def rw_downgrade(r
): return mrdemote(r
)
102 def rw_destroy(r
): return mrfree(r
)
104 def RW_WRITE_HELD(r
): return ismrlocked(r
, MR_UPDATE
)
106 def RW_READ_HELD(r
): return ismrlocked(r
, MR_ACCESS
)
109 # Included from sys/splock.h
116 SPLOCK_MAX
= (96*1024)
119 MAX_POOL_SIZE
= 16384
121 DEF_VNODE_POOL
= 1024
123 def ownlock(x
): return 1
125 def splock(x
): return 1
127 def io_splock(x
): return 1
129 def apvsema(x
): return vsema(x
)
131 def apcpsema(x
): return cpsema(x
)
133 def apcvsema(x
): return cvsema(x
)
135 def mp_mrunlock(a
): return mrunlock(a
)
137 def apvsema(x
): return 0
139 def apcpsema(x
): return 1
141 def apcvsema(x
): return 0
143 def mp_mrunlock(a
): return 0
146 # Included from sys/fcntl.h
231 FDIGNPROGRESS
= 0x0004