Home
last modified time | relevance | path

Searched refs:sem_wait (Results 1 – 25 of 146) sorted by relevance

123456

/third_party/ltp/testcases/open_posix_testsuite/functional/semaphores/
Dsem_sleepingbarber.c37 sem_wait(&print); \
57 if (-1 == sem_wait(&lock)) { in barbers()
69 if (-1 == sem_wait(&customer)) { in barbers()
73 if (-1 == sem_wait(&lock)) { in barbers()
104 if (-1 == sem_wait(&lock)) { in customers()
121 if (-1 == sem_wait(&barber)) { in customers()
Dsem_conpro.c44 if (-1 == sem_wait(&buf->occupied)) { in producer()
48 if (-1 == sem_wait(&buf->lock)) { in producer()
74 if (-1 == sem_wait(&buf->empty)) { in consumer()
78 if (-1 == sem_wait(&buf->lock)) { in consumer()
Dsem_readerwriter.c51 if (-1 == sem_wait(&r_lock)) { in reader()
58 if (-1 == sem_wait(&w_lock)) { in reader()
69 if (-1 == sem_wait(&r_lock)) { in reader()
95 if (-1 == sem_wait(&w_lock)) { in writer()
Dsem_philosopher.c78 if (-1 == sem_wait(&lock)) { in philosopher()
88 if (-1 == sem_wait(&ph[PhID])) { in philosopher()
94 if (-1 == sem_wait(&lock)) { in philosopher()
/third_party/musl/src/thread/
Dsynccall.c29 sem_wait(&target_sem); in handler()
36 sem_wait(&target_sem); in handler()
89 sem_wait(&caller_sem); in __synccall()
98 sem_wait(&caller_sem); in __synccall()
112 sem_wait(&caller_sem); in __synccall()
/third_party/ltp/testcases/open_posix_testsuite/stress/semaphores/
Dmulti_con_pro.c49 if (-1 == sem_wait(&buf->full)) { in producer()
58 if (-1 == sem_wait(&buf->lock)) { in producer()
76 if (-1 == sem_wait(&buf->full)) { in producer()
85 if (-1 == sem_wait(&buf->lock)) { in producer()
114 if (-1 == sem_wait(&buf->empty)) { in consumer()
118 if (-1 == sem_wait(&buf->lock)) { in consumer()
/third_party/NuttX/drivers/pipes/
Dpipe_common.c86 ret = sem_wait(sem); in pipecommon_semtake()
185 ret = sem_wait(&dev->d_bfsem); in pipecommon_open()
254 ret = sem_wait(&dev->d_rdsem); in pipecommon_open()
402 ret = sem_wait(&dev->d_bfsem); in pipecommon_read()
431 ret = sem_wait(&dev->d_rdsem); in pipecommon_read()
433 if (ret < 0 || (ret = sem_wait(&dev->d_bfsem)) < 0) in pipecommon_read()
500 sem_wait(&dev->d_rdsem); in pipecommon_read()
505 ret = sem_wait(&dev->d_rdsem); in pipecommon_read()
511 ret = sem_wait(&dev->d_bfsem); in pipecommon_read()
591 ret = sem_wait(&dev->d_bfsem); in pipecommon_write()
Dpipe.c119 ret = sem_wait(&g_pipesem); in pipe_free()
174 (void)sem_wait(&g_pipesem); in pipe_unlink()
254 ret = sem_wait(&g_pipesem); in pipe()
342 (void)sem_wait(&g_pipesem); in pipe()
/third_party/musl/libc-test/src/functional/
Dsem_init.c35 T(sem_wait(s)); in many_waiters()
36 T(sem_wait(s)); in many_waiters()
37 T(sem_wait(s)); in many_waiters()
61 T(sem_wait(&s)); in single_thread()
Dpthread_cancel-points.c35 TESTR(sem_wait(&sem_test), "waiting on semaphore in the canceled thread"); in execute_sem_wait()
50 while (sem_wait(&sem_test)); in run_test()
117 while (sem_wait(&sem_seq)); in run_execute()
/third_party/ltp/testcases/open_posix_testsuite/conformance/interfaces/sem_post/
D8-1.c101 sem_wait(sem_1); in child_fn()
103 if (sem_wait(sem) == -1) { in child_fn()
152 if (sem_wait(sem) == -1) { in main()
/third_party/ltp/testcases/open_posix_testsuite/conformance/interfaces/sem_wait/
D7-1.c49 if (sem_wait(mysemp) == -1) { in main()
69 sem_wait(mysemp); in main()
/third_party/ltp/testcases/open_posix_testsuite/conformance/interfaces/pthread_mutex_init/
D3-2.c155 if ((ret = sem_wait(&semB))) { in unlock_issue()
235 if ((ret = sem_wait(&semA))) { in main()
287 if ((ret = sem_wait(&semA))) { in main()
D1-2.c149 if ((ret = sem_wait(&semB))) { in unlock_issue()
242 if ((ret = sem_wait(&semA))) { in main()
294 if ((ret = sem_wait(&semA))) { in main()
/third_party/ltp/testcases/open_posix_testsuite/conformance/interfaces/sem_init/
D3-1.c36 sem_wait(&psem); in producer()
48 sem_wait(&csem); in consumer()
/third_party/ltp/testcases/open_posix_testsuite/conformance/interfaces/sem_destroy/
D3-1.c73 sem_wait(&psem); in producer()
85 sem_wait(&csem); in consumer()
/third_party/ltp/testcases/open_posix_testsuite/conformance/interfaces/pthread_mutex_lock/
D3-1.c109 if ((ret = sem_wait(thearg->sem))) { in sendsig()
266 ret = sem_wait(&semsync); in threaded()
311 ret = sem_wait(&semsync2); in main()
D4-1.c196 if ((ret = sem_wait(&sem))) { in main()
209 if ((ret = sem_wait(&sem))) { in main()
/third_party/ltp/testcases/kernel/syscalls/move_pages/
Dmove_pages03.c101 if (sem_wait(&sem[SEM_PARENT_TEST]) == -1) in child()
162 if (sem_wait(&sem[SEM_CHILD_SETUP]) == -1) in main()
Dmove_pages11.c102 if (sem_wait(&sem[SEM_PARENT_TEST]) == -1) in child()
164 if (sem_wait(&sem[SEM_CHILD_SETUP]) == -1) in main()
Dmove_pages05.c102 if (sem_wait(&sem[SEM_PARENT_TEST]) == -1) in child()
169 if (sem_wait(&sem[SEM_CHILD_SETUP]) == -1) in main()
/third_party/ltp/testcases/open_posix_testsuite/conformance/interfaces/sigaction/templates/
Dtemplate_16-1.in28 * The test fails if the sem_wait function returns EINTR
31 This test uses sem_wait to check if EINTR is returned. As the function is not required to
107 ret = sem_wait( &sem );
117 UNRESOLVED( errno, "sem_wait failed" );
/third_party/ltp/testcases/open_posix_testsuite/conformance/interfaces/pthread_cond_wait/
D2-3.c125 ret = sem_wait(&(data.semB)); in clnp2()
368 ret = sem_wait(&(data.semA)); in main()
397 ret = sem_wait(&(data.semA)); in main()
/third_party/musl/libc-test/src/regression/
Dpthread_cancel-sem_wait.c20 while (sem_wait(&sem1)); in wait_cancel()
28 sem_wait(&sem2); in start_sem_wait()
/third_party/ltp/testcases/open_posix_testsuite/conformance/interfaces/pthread_cond_timedwait/
D2-6.c102 ret = sem_wait(&(data.semB)); in clnp2()
365 ret = sem_wait(&(data.semA)); in main()
394 ret = sem_wait(&(data.semA)); in main()

123456