Lines Matching refs:id

259 void mpp_thread_set_status(MppThread *thread, MppThreadStatus status, MppThreadSignalId id)  in mpp_thread_set_status()  argument
261 assert(id < THREAD_SIGNAL_BUTT); in mpp_thread_set_status()
262 thread->thd_status[id] = status; in mpp_thread_set_status()
265 MppThreadStatus mpp_thread_get_status(MppThread *thread, MppThreadSignalId id) in mpp_thread_get_status() argument
267 assert(id < THREAD_SIGNAL_BUTT); in mpp_thread_get_status()
268 return thread->thd_status[id]; in mpp_thread_get_status()
271 void mpp_thread_lock(MppThread *thread, MppThreadSignalId id) in mpp_thread_lock() argument
273 assert(id < THREAD_SIGNAL_BUTT); in mpp_thread_lock()
274 mpp_mutex_cond_lock(&thread->mutex_cond[id]); in mpp_thread_lock()
277 void mpp_thread_unlock(MppThread *thread, MppThreadSignalId id) in mpp_thread_unlock() argument
279 assert(id < THREAD_SIGNAL_BUTT); in mpp_thread_unlock()
280 mpp_mutex_cond_unlock(&thread->mutex_cond[id]); in mpp_thread_unlock()
283 void mpp_thread_wait(MppThread *thread, MppThreadSignalId id) in mpp_thread_wait() argument
285 assert(id < THREAD_SIGNAL_BUTT); in mpp_thread_wait()
286 MppThreadStatus status = thread->thd_status[id]; in mpp_thread_wait()
287 thread->thd_status[id] = MPP_THREAD_WAITING; in mpp_thread_wait()
288 mpp_mutex_cond_wait(&thread->mutex_cond[id]); in mpp_thread_wait()
290 if (thread->thd_status[id] == MPP_THREAD_WAITING) in mpp_thread_wait()
291 thread->thd_status[id] = status; in mpp_thread_wait()
294 void mpp_thread_signal(MppThread *thread, MppThreadSignalId id) in mpp_thread_signal() argument
296 assert(id < THREAD_SIGNAL_BUTT); in mpp_thread_signal()
297 mpp_mutex_cond_signal(&thread->mutex_cond[id]); in mpp_thread_signal()