1 #ifndef __XFS_SUPPORT_SV_H__
2 #define __XFS_SUPPORT_SV_H__
4 #include <sys/condvar.h>
7 * Synchronisation variables
9 * parameters "pri", "svf" and "rts" are not (yet?) implemented
13 typedef struct cv sv_t;
15 #define init_sv(sv,type,name,flag) cv_init(sv, name)
16 #define sv_init(sv,flag,name) cv_init(sv, name)
17 /* sv_wait should exit with lock unlocked */
18 #define sv_wait(sv, pri, lock, spl) cv_wait_unlock(sv, lock)
19 #define sv_wait_sig(sv, pri, lock, spl) cv_wait_sig_nolock(sv, lock)
20 #define sv_signal(sv) cv_signal(sv)
21 #define sv_broadcast(sv) cv_broadcast(sv)
22 #define sv_destroy(sv) cv_destroy(sv)
24 #define SV_FIFO 0x0 /* sv_t is FIFO type */
25 #define SV_LIFO 0x2 /* sv_t is LIFO type */
26 #define SV_PRIO 0x4 /* sv_t is PRIO type */
27 #define SV_KEYED 0x6 /* sv_t is KEYED type */
28 #define SV_DEFAULT SV_FIFO
30 #endif /* __XFS_SUPPORT_SV_H__ */