Rev 2085 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 2085 | Rev 2106 | ||
---|---|---|---|
Line 42... | Line 42... | ||
42 | 42 | ||
43 | typedef struct { |
43 | typedef struct { |
44 | waitq_t wq; |
44 | waitq_t wq; |
45 | } condvar_t; |
45 | } condvar_t; |
46 | 46 | ||
47 | #define condvar_wait(cv,mtx) \ |
47 | #define condvar_wait(cv, mtx) \ |
48 | _condvar_wait_timeout((cv),(mtx),SYNCH_NO_TIMEOUT,SYNCH_FLAGS_NONE) |
48 | _condvar_wait_timeout((cv), (mtx), SYNCH_NO_TIMEOUT, SYNCH_FLAGS_NONE) |
49 | #define condvar_wait_timeout(cv,mtx,usec) \ |
49 | #define condvar_wait_timeout(cv, mtx, usec) \ |
50 | _condvar_wait_timeout((cv),(mtx),(usec),SYNCH_FLAGS_NONE) |
50 | _condvar_wait_timeout((cv), (mtx), (usec), SYNCH_FLAGS_NONE) |
51 | 51 | ||
52 | extern void condvar_initialize(condvar_t *cv); |
52 | extern void condvar_initialize(condvar_t *cv); |
53 | extern void condvar_signal(condvar_t *cv); |
53 | extern void condvar_signal(condvar_t *cv); |
54 | extern void condvar_broadcast(condvar_t *cv); |
54 | extern void condvar_broadcast(condvar_t *cv); |
55 | extern int _condvar_wait_timeout(condvar_t *cv, mutex_t *mtx, uint32_t usec, int flags); |
55 | extern int _condvar_wait_timeout(condvar_t *cv, mutex_t *mtx, uint32_t usec, |
- | 56 | int flags); |
|
56 | 57 | ||
57 | #endif |
58 | #endif |
58 | 59 | ||
59 | /** @} |
60 | /** @} |
60 | */ |
61 | */ |