Home
last modified time | relevance | path

Searched refs:sema (Results 1 – 7 of 7) sorted by relevance

/Zephyr-Core-2.7.6/tests/posix/common/src/
Dsemaphore.c14 sem_t sema; variable
24 zassert_equal(sem_post(&sema), 0, "sem_post failed"); in child_func()
59 zassert_equal(sem_init(&sema, 0, (CONFIG_SEM_VALUE_MAX + 1)), -1, in test_posix_semaphore()
63 zassert_equal(sem_init(&sema, 0, 0), 0, "sem_init failed"); in test_posix_semaphore()
71 zassert_equal(sem_getvalue(&sema, &val), 0, NULL); in test_posix_semaphore()
77 zassert_equal(sem_trywait(&sema), -1, NULL); in test_posix_semaphore()
91 zassert_equal(sem_timedwait(&sema, &abstime), 0, NULL); in test_posix_semaphore()
96 zassert_equal(sem_timedwait(&sema, &abstime), -1, NULL); in test_posix_semaphore()
104 zassert_equal(sem_destroy(&sema), 0, "semaphore is not destroyed"); in test_posix_semaphore()
110 zassert_equal(sem_init(&sema, 0, 1), 0, "sem_init failed"); in test_posix_semaphore()
[all …]
/Zephyr-Core-2.7.6/tests/kernel/semaphore/semaphore/src/
Dmain.c16 #define sem_give_from_isr(sema) irq_offload(isr_sem_give, (const void *)sema) argument
17 #define sem_take_from_isr(sema) irq_offload(isr_sem_take, (const void *)sema) argument
64 struct k_sem *sema; member
88 struct k_sem sema, mut_sem; variable
254 expect_k_sem_init_nomsg(&sema, SEM_INIT_VAL, SEM_MAX_VAL, 0); in test_sem_thread2thread()
256 tsema_thread_thread(&sema); in test_sem_thread2thread()
269 expect_k_sem_init_nomsg(&sema, SEM_INIT_VAL, SEM_MAX_VAL, 0); in test_sem_thread2isr()
271 tsema_thread_isr(&sema); in test_sem_thread2isr()
288 expect_k_sem_init_nomsg(&sema, SEM_INIT_VAL, SEM_MAX_VAL, 0); in test_k_sem_init()
290 k_sem_reset(&sema); in test_k_sem_init()
[all …]
/Zephyr-Core-2.7.6/tests/kernel/tickless/tickless_concept/src/
Dmain.c45 K_SEM_DEFINE(sema, 0, NUM_THREAD);
62 k_sem_give(&sema); in thread_tslice()
91 k_sem_take(&sema, K_MSEC(SLEEP_TICKFUL)); in test_tickless_sysclock()
108 k_sem_reset(&sema); in test_tickless_slice()
122 k_sem_take(&sema, K_FOREVER); in test_tickless_slice()
/Zephyr-Core-2.7.6/tests/kernel/sched/schedule_api/src/
Dtest_sched_timeslice_reset.c34 K_SEM_DEFINE(sema, 0, NUM_THREAD);
110 k_sem_give(&sema); in thread_time_slice()
150 k_sem_reset(&sema); in test_slice_reset()
183 k_sem_take(&sema, K_FOREVER); in test_slice_reset()
/Zephyr-Core-2.7.6/tests/net/buf/src/
Dmain.c150 struct k_sem *sema = (struct k_sem *)arg2; in test_3_thread() local
153 k_sem_give(sema); in test_3_thread()
163 k_sem_give(sema); in test_3_thread()
173 static struct k_sem sema; in test_net_buf_3() local
187 k_sem_init(&sema, 0, UINT_MAX); in test_net_buf_3()
191 (k_thread_entry_t) test_3_thread, &fifo, &sema, NULL, in test_net_buf_3()
194 zassert_true(k_sem_take(&sema, TEST_TIMEOUT) == 0, in test_net_buf_3()
199 zassert_true(k_sem_take(&sema, TEST_TIMEOUT) == 0, in test_net_buf_3()
/Zephyr-Core-2.7.6/tests/kernel/smp/src/
Dmain.c38 K_SEM_DEFINE(sema, 0, 1);
/Zephyr-Core-2.7.6/doc/releases/
Drelease-notes-1.13.rst408 * :github:`9067` - Failed tests: posix.sema and posix_checks on em_starterkit_em7d_v22