Lines Matching refs:cw
77 struct cond_wait *cw = arg; in wake_all_timeout() local
78 EVLOCK_LOCK(cw->lock, 0); in wake_all_timeout()
79 EVTHREAD_COND_BROADCAST(cw->cond); in wake_all_timeout()
80 EVLOCK_UNLOCK(cw->lock, 0); in wake_all_timeout()
87 struct cond_wait *cw = arg; in wake_one_timeout() local
88 EVLOCK_LOCK(cw->lock, 0); in wake_one_timeout()
89 EVTHREAD_COND_SIGNAL(cw->cond); in wake_one_timeout()
90 EVLOCK_UNLOCK(cw->lock, 0); in wake_one_timeout()
101 struct cond_wait cw; in basic_thread() local
106 EVTHREAD_ALLOC_LOCK(cw.lock, 0); in basic_thread()
107 EVTHREAD_ALLOC_COND(cw.cond); in basic_thread()
108 assert(cw.lock); in basic_thread()
109 assert(cw.cond); in basic_thread()
111 evtimer_assign(&ev, base, wake_all_timeout, &cw); in basic_thread()
118 EVLOCK_LOCK(cw.lock, 0); in basic_thread()
123 assert(EVTHREAD_COND_WAIT(cw.cond, cw.lock) == 0); in basic_thread()
124 EVLOCK_UNLOCK(cw.lock, 0); in basic_thread()
137 EVTHREAD_FREE_LOCK(cw.lock, 0); in basic_thread()
138 EVTHREAD_FREE_COND(cw.cond); in basic_thread()