Home
last modified time | relevance | path

Searched refs:timeout (Results 1 – 25 of 891) sorted by relevance

12345678910>>...36

/Zephyr-latest/subsys/net/ip/
Dnet_timeout.c10 void net_timeout_set(struct net_timeout *timeout, in net_timeout_set() argument
16 timeout->timer_start = now; in net_timeout_set()
22 timeout->wrap_counter = 0; in net_timeout_set()
23 timeout->timer_timeout = 0; in net_timeout_set()
28 timeout->wrap_counter = expire_timeout / in net_timeout_set()
30 timeout->timer_timeout = expire_timeout - in net_timeout_set()
32 (uint64_t)timeout->wrap_counter; in net_timeout_set()
38 if (timeout->timer_timeout == 0U) { in net_timeout_set()
39 timeout->timer_timeout = NET_TIMEOUT_MAX_VALUE; in net_timeout_set()
40 timeout->wrap_counter -= 1; in net_timeout_set()
[all …]
/Zephyr-latest/kernel/
Dkheap.c66 k_timeout_t timeout) in k_heap_aligned_alloc() argument
68 k_timepoint_t end = sys_timepoint_calc(timeout); in k_heap_aligned_alloc()
73 SYS_PORT_TRACING_OBJ_FUNC_ENTER(k_heap, aligned_alloc, heap, timeout); in k_heap_aligned_alloc()
75 __ASSERT(!arch_is_in_isr() || K_TIMEOUT_EQ(timeout, K_NO_WAIT), ""); in k_heap_aligned_alloc()
83 (ret != NULL) || K_TIMEOUT_EQ(timeout, K_NO_WAIT)) { in k_heap_aligned_alloc()
90 SYS_PORT_TRACING_OBJ_FUNC_BLOCKING(k_heap, aligned_alloc, heap, timeout); in k_heap_aligned_alloc()
97 timeout = sys_timepoint_timeout(end); in k_heap_aligned_alloc()
98 (void) z_pend_curr(&heap->lock, key, &heap->wait_q, timeout); in k_heap_aligned_alloc()
102 SYS_PORT_TRACING_OBJ_FUNC_EXIT(k_heap, aligned_alloc, heap, timeout, ret); in k_heap_aligned_alloc()
108 void *k_heap_alloc(struct k_heap *heap, size_t bytes, k_timeout_t timeout) in k_heap_alloc() argument
[all …]
Dnothread.c20 int32_t z_impl_k_sleep(k_timeout_t timeout) in z_impl_k_sleep() argument
27 SYS_PORT_TRACING_FUNC_ENTER(k_thread, sleep, timeout); in z_impl_k_sleep()
30 if (K_TIMEOUT_EQ(timeout, K_FOREVER)) { in z_impl_k_sleep()
33 SYS_PORT_TRACING_FUNC_EXIT(k_thread, sleep, timeout, (int32_t) K_TICKS_FOREVER); in z_impl_k_sleep()
38 ticks = timeout.ticks; in z_impl_k_sleep()
57 SYS_PORT_TRACING_FUNC_EXIT(k_thread, sleep, timeout, ret); in z_impl_k_sleep()
Dtimeout.c100 k_timeout_t timeout) in z_add_timeout() argument
102 if (K_TIMEOUT_EQ(timeout, K_FOREVER)) { in z_add_timeout()
117 (Z_TICK_ABS(timeout.ticks) >= 0)) { in z_add_timeout()
118 k_ticks_t ticks = Z_TICK_ABS(timeout.ticks) - curr_tick; in z_add_timeout()
122 to->dticks = timeout.ticks + 1 + elapsed(); in z_add_timeout()
159 static k_ticks_t timeout_rem(const struct _timeout *timeout) in timeout_rem() argument
165 if (timeout == t) { in timeout_rem()
173 k_ticks_t z_timeout_remaining(const struct _timeout *timeout) in z_timeout_remaining() argument
178 if (!z_is_inactive_timeout(timeout)) { in z_timeout_remaining()
179 ticks = timeout_rem(timeout) - elapsed(); in z_timeout_remaining()
[all …]
Dmailbox.c211 k_timeout_t timeout) in mbox_message_put() argument
228 SYS_PORT_TRACING_OBJ_FUNC_ENTER(k_mbox, message_put, mbox, timeout); in mbox_message_put()
255 SYS_PORT_TRACING_OBJ_FUNC_BLOCKING(k_mbox, message_put, mbox, timeout); in mbox_message_put()
263 SYS_PORT_TRACING_OBJ_FUNC_EXIT(k_mbox, message_put, mbox, timeout, ret); in mbox_message_put()
270 if (K_TIMEOUT_EQ(timeout, K_NO_WAIT)) { in mbox_message_put()
271 SYS_PORT_TRACING_OBJ_FUNC_EXIT(k_mbox, message_put, mbox, timeout, -ENOMSG); in mbox_message_put()
285 SYS_PORT_TRACING_OBJ_FUNC_BLOCKING(k_mbox, message_put, mbox, timeout); in mbox_message_put()
288 int ret = z_pend_curr(&mbox->lock, key, &mbox->tx_msg_queue, timeout); in mbox_message_put()
290 SYS_PORT_TRACING_OBJ_FUNC_EXIT(k_mbox, message_put, mbox, timeout, ret); in mbox_message_put()
296 k_timeout_t timeout) in k_mbox_put() argument
[all …]
/Zephyr-latest/subsys/tracing/test/
Dtracing_test.h23 #define sys_port_trace_k_thread_join_enter(thread, timeout) \ argument
24 sys_trace_k_thread_join_blocking(thread, timeout)
25 #define sys_port_trace_k_thread_join_blocking(thread, timeout) \ argument
26 sys_trace_k_thread_join_blocking(thread, timeout)
27 #define sys_port_trace_k_thread_join_exit(thread, timeout, ret) \ argument
28 sys_trace_k_thread_join_exit(thread, timeout, ret)
29 #define sys_port_trace_k_thread_sleep_enter(timeout) sys_trace_k_thread_sleep_enter(timeout) argument
30 #define sys_port_trace_k_thread_sleep_exit(timeout, ret) sys_trace_k_thread_sleep_exit(timeout, ret) argument
73 #define sys_port_trace_k_work_flush_blocking(work, timeout) argument
84 #define sys_port_trace_k_work_queue_stop_enter(queue, timeout) argument
[all …]
Dtracing_string_format_test.c96 void sys_trace_k_thread_sleep_enter(k_timeout_t timeout) in sys_trace_k_thread_sleep_enter() argument
101 void sys_trace_k_thread_sleep_exit(k_timeout_t timeout, int ret) in sys_trace_k_thread_sleep_exit() argument
177 void sys_trace_k_thread_join_blocking(struct k_thread *thread, k_timeout_t timeout) in sys_trace_k_thread_join_blocking() argument
179 TRACING_STRING("%s %p, timeout: %u\n", __func__, thread, (uint32_t)timeout.ticks); in sys_trace_k_thread_join_blocking()
182 void sys_trace_k_thread_join_exit(struct k_thread *thread, k_timeout_t timeout, int ret) in sys_trace_k_thread_join_exit() argument
184 TRACING_STRING("%s %p, timeout: %u\n", __func__, thread, (uint32_t)timeout.ticks); in sys_trace_k_thread_join_exit()
238 k_timeout_t timeout) in sys_trace_k_condvar_wait_enter() argument
244 k_timeout_t timeout, int ret) in sys_trace_k_condvar_wait_exit() argument
259 void sys_trace_k_sem_take_enter(struct k_sem *sem, k_timeout_t timeout) in sys_trace_k_sem_take_enter() argument
261 TRACING_STRING("%s: %p, timeout: %u\n", __func__, sem, (uint32_t)timeout.ticks); in sys_trace_k_sem_take_enter()
[all …]
/Zephyr-latest/include/zephyr/tracing/
Dtracing.h82 #define sys_port_trace_k_thread_join_enter(thread, timeout) argument
89 #define sys_port_trace_k_thread_join_blocking(thread, timeout) argument
97 #define sys_port_trace_k_thread_join_exit(thread, timeout, ret) argument
103 #define sys_port_trace_k_thread_sleep_enter(timeout) argument
110 #define sys_port_trace_k_thread_sleep_exit(timeout, ret) argument
360 #define sys_port_trace_k_work_flush_blocking(work, timeout) argument
435 #define sys_port_trace_k_work_queue_stop_enter(queue, timeout) argument
442 #define sys_port_trace_k_work_queue_stop_blocking(queue, timeout) argument
450 #define sys_port_trace_k_work_queue_stop_exit(queue, timeout, ret) argument
625 #define sys_port_trace_k_work_poll_submit_to_queue_enter(work_q, work, timeout) argument
[all …]
/Zephyr-latest/lib/os/zvfs/
Dzvfs_poll.c20 int zvfs_poll_internal(struct zvfs_pollfd *fds, int nfds, k_timeout_t timeout) in zvfs_poll_internal() argument
36 end = sys_timepoint_calc(timeout); in zvfs_poll_internal()
64 timeout = K_NO_WAIT; in zvfs_poll_internal()
65 end = sys_timepoint_calc(timeout); in zvfs_poll_internal()
96 if (K_TIMEOUT_EQ(timeout, K_FOREVER)) { in zvfs_poll_internal()
99 poll_timeout = k_ticks_to_ms_floor32(timeout.ticks); in zvfs_poll_internal()
106 timeout = sys_timepoint_timeout(end); in zvfs_poll_internal()
109 ret = k_poll(poll_events, pev - poll_events, timeout); in zvfs_poll_internal()
161 timeout = sys_timepoint_timeout(end); in zvfs_poll_internal()
163 if (K_TIMEOUT_EQ(timeout, K_NO_WAIT)) { in zvfs_poll_internal()
[all …]
/Zephyr-latest/subsys/tracing/user/
Dtracing_user.h107 #define sys_port_trace_k_thread_join_enter(thread, timeout) argument
108 #define sys_port_trace_k_thread_join_blocking(thread, timeout) argument
109 #define sys_port_trace_k_thread_join_exit(thread, timeout, ret) argument
110 #define sys_port_trace_k_thread_sleep_enter(timeout) argument
111 #define sys_port_trace_k_thread_sleep_exit(timeout, ret) argument
147 #define sys_port_trace_k_work_flush_blocking(work, timeout) argument
158 #define sys_port_trace_k_work_queue_stop_enter(queue, timeout) argument
159 #define sys_port_trace_k_work_queue_stop_blocking(queue, timeout) argument
160 #define sys_port_trace_k_work_queue_stop_exit(queue, timeout, ret) argument
187 timeout) argument
[all …]
/Zephyr-latest/tests/net/lib/lwm2m/interop/pytest/
Dtest_blockwise.py30 to = leshan.timeout
32 leshan.timeout = 600
37 lines = dut.readlines_until(regex='app_fw_update: UPDATE', timeout=5.0)
44 leshan.timeout = to
51 to = leshan.timeout
54 leshan.timeout = 1
62 leshan.timeout = 600
67 lines = dut.readlines_until(regex='app_fw_update: UPDATE', timeout=5.0)
74 leshan.timeout = to
82 dut.readlines_until(regex='.*net_lwm2m_rd_client: Update Done', timeout=5.0)
[all …]
Dtest_bootstrap.py36 dut.readlines_until(regex='.*Bootstrap transfer complete', timeout=5.0)
52 dut.readlines_until(regex='.*Registration Done', timeout=5.0)
61 dut.readlines_until(regex='.*Server Initiated Bootstrap', timeout=1)
62 dut.readlines_until(regex='.*Bootstrap transfer complete', timeout=5.0)
63 dut.readlines_until(regex='.*Registration Done', timeout=5.0)
68 dut.readlines_until(regex=r'.*Deregistration success', timeout=5)
70 lines = dut.readlines_until(regex='.*Registration Done', timeout=5.0)
73 dut.readlines_until(regex=r'.*Deregistration success', timeout=5)
77 lines = dut.readlines_until(regex='.*Registration Done', timeout=5.0)
84 dut.readlines_until(regex=r'.*Deregistration success', timeout=5)
[all …]
/Zephyr-latest/include/zephyr/net/
Dnet_offload.h36 static inline int32_t timeout_to_int32(k_timeout_t timeout) in timeout_to_int32() argument
38 if (K_TIMEOUT_EQ(timeout, K_NO_WAIT)) { in timeout_to_int32()
40 } else if (K_TIMEOUT_EQ(timeout, K_FOREVER)) { in timeout_to_int32()
43 return k_ticks_to_ms_floor32(timeout.ticks); in timeout_to_int32()
82 int32_t timeout,
91 int32_t timeout,
99 int32_t timeout,
109 int32_t timeout,
118 int32_t timeout,
239 k_timeout_t timeout, in net_offload_connect() argument
[all …]
Dsocket_select.h50 zsock_fd_set *exceptfds, struct zsock_timeval *timeout) in zsock_select() argument
53 .tv_sec = (timeout == NULL) ? 0 : timeout->tv_sec, in zsock_select()
54 .tv_nsec = (long)((timeout == NULL) ? 0 : timeout->tv_usec * NSEC_PER_USEC)}; in zsock_select()
56 return zvfs_select(nfds, readfds, writefds, exceptfds, (timeout == NULL) ? NULL : &to, in zsock_select()
/Zephyr-latest/subsys/tracing/ctf/
Dtracing_ctf.h31 #define sys_port_trace_k_thread_join_enter(thread, timeout) argument
32 #define sys_port_trace_k_thread_join_blocking(thread, timeout) argument
33 #define sys_port_trace_k_thread_join_exit(thread, timeout, ret) argument
34 #define sys_port_trace_k_thread_sleep_enter(timeout) argument
35 #define sys_port_trace_k_thread_sleep_exit(timeout, ret) argument
82 #define sys_port_trace_k_work_flush_blocking(work, timeout) argument
93 #define sys_port_trace_k_work_queue_stop_enter(queue, timeout) argument
94 #define sys_port_trace_k_work_queue_stop_blocking(queue, timeout) argument
95 #define sys_port_trace_k_work_queue_stop_exit(queue, timeout, ret) argument
122 timeout) argument
[all …]
/Zephyr-latest/subsys/tracing/sysview/
Dtracing_sysview.h41 #define sys_port_trace_k_thread_join_enter(thread, timeout) \ argument
43 (uint32_t)timeout.ticks)
44 #define sys_port_trace_k_thread_join_blocking(thread, timeout) argument
45 #define sys_port_trace_k_thread_join_exit(thread, timeout, ret) \ argument
48 #define sys_port_trace_k_thread_sleep_enter(timeout) \ argument
49 SEGGER_SYSVIEW_RecordU32(TID_SLEEP, (uint32_t)k_ticks_to_ms_floor32(timeout.ticks))
51 #define sys_port_trace_k_thread_sleep_exit(timeout, ret) \ argument
153 #define sys_port_trace_k_work_flush_blocking(work, timeout) argument
183 #define sys_port_trace_k_work_queue_stop_enter(queue, timeout) \ argument
185 (uint32_t)timeout.ticks)
[all …]
/Zephyr-latest/tests/arch/arm64/arm64_gicv3_its/src/
Dmain.c85 unsigned int timeout; in ZTEST() local
94 timeout = ITS_TEST_LOOPS; in ZTEST()
95 while (!last_lpi_irq_num && timeout) { in ZTEST()
96 timeout--; in ZTEST()
108 unsigned int timeout; in ZTEST() local
119 timeout = ITS_TEST_LOOPS; in ZTEST()
120 while (!last_lpi_irq_num && timeout) { in ZTEST()
121 timeout--; in ZTEST()
133 timeout = ITS_TEST_LOOPS; in ZTEST()
134 while (!last_lpi_irq_num && timeout) { in ZTEST()
[all …]
/Zephyr-latest/tests/kernel/fifo/fifo_timeout/src/
Dmain.c45 uint32_t timeout; member
101 static bool is_timeout_in_range(uint32_t start_time, uint32_t timeout) in is_timeout_in_range() argument
109 return timeout <= diff; in is_timeout_in_range()
115 uint32_t timeout = *((uint32_t *)p2); in test_thread_put_timeout() local
117 k_msleep(timeout); in test_thread_put_timeout()
131 packet = k_fifo_get(d->fifo, K_MSEC(d->timeout)); in test_thread_pend_and_timeout()
133 zassert_true(is_timeout_in_range(start_time, d->timeout)); in test_thread_pend_and_timeout()
166 data->q_order, data->timeout, data->fifo); in test_multiple_threads_pending()
177 if (data->timeout > test_data[j].timeout) { in test_multiple_threads_pending()
178 diff_ms = data->timeout - test_data[j].timeout; in test_multiple_threads_pending()
[all …]
/Zephyr-latest/scripts/pylib/pytest-twister-harness/src/twister_harness/helpers/
Dshell.py26 self, device: DeviceAdapter, prompt: str = 'uart:~$', timeout: float | None = None
30 self.base_timeout: float = timeout or device.base_timeout
32 def wait_for_prompt(self, timeout: float | None = None) -> bool:
38 timeout = timeout or self.base_timeout
39 timeout_time = time.time() + timeout
44 line = self._device.readline(timeout=0.5, print_output=False)
54 self, command: str, timeout: float | None = None, print_output: bool = True
62 timeout = timeout or self.base_timeout
72 regex=regex_command, timeout=1.0, print_output=print_output
78 regex=regex_prompt, timeout=timeout, print_output=print_output
/Zephyr-latest/subsys/mgmt/hawkbit/
Dhawkbit_autohandler.c86 enum hawkbit_response hawkbit_autohandler_wait(uint32_t events, k_timeout_t timeout) in hawkbit_autohandler_wait() argument
88 uint32_t ret = k_event_wait(&hawkbit_autohandler_event, events, false, timeout); in hawkbit_autohandler_wait()
103 int hawkbit_autohandler_set_delay(k_timeout_t timeout, bool if_bigger) in hawkbit_autohandler_set_delay() argument
105 if (!if_bigger || timeout.ticks > k_work_delayable_remaining_get(&hawkbit_work_handle)) { in hawkbit_autohandler_set_delay()
108 (uint32_t)(timeout.ticks / CONFIG_SYS_CLOCK_TICKS_PER_SEC) / 3600, in hawkbit_autohandler_set_delay()
109 (uint32_t)((timeout.ticks / CONFIG_SYS_CLOCK_TICKS_PER_SEC) % 3600) / 60, in hawkbit_autohandler_set_delay()
110 (uint32_t)(timeout.ticks / CONFIG_SYS_CLOCK_TICKS_PER_SEC) % 60); in hawkbit_autohandler_set_delay()
111 return k_work_reschedule(&hawkbit_work_handle, timeout); in hawkbit_autohandler_set_delay()
/Zephyr-latest/subsys/net/lib/sntp/
Dsntp_simple.c12 static int sntp_simple_helper(struct sockaddr *addr, socklen_t addr_len, uint32_t timeout, in sntp_simple_helper() argument
26 if (timeout == SYS_FOREVER_MS) { in sntp_simple_helper()
27 deadline = (uint64_t)timeout; in sntp_simple_helper()
29 deadline = k_uptime_get() + (uint64_t)timeout; in sntp_simple_helper()
74 int sntp_simple_addr(struct sockaddr *addr, socklen_t addr_len, uint32_t timeout, in sntp_simple_addr() argument
84 return sntp_simple_helper(addr, addr_len, timeout, ts); in sntp_simple_addr()
87 int sntp_simple(const char *server, uint32_t timeout, struct sntp_time *ts) in sntp_simple() argument
105 res = sntp_simple_helper(addr->ai_addr, addr->ai_addrlen, timeout, ts); in sntp_simple()
/Zephyr-latest/tests/subsys/tracing/tracing_api/src/
Dmain.c123 k_timeout_t timeout = K_MSEC(1); in ZTEST() local
142 sys_trace_k_thread_sleep_enter(timeout); in ZTEST()
143 sys_trace_k_thread_sleep_exit(timeout, ret); in ZTEST()
153 sys_trace_k_thread_join_blocking(&thread, timeout); in ZTEST()
154 sys_trace_k_thread_join_exit(&thread, timeout, ret); in ZTEST()
166 sys_trace_k_condvar_wait_enter(&condvar, &mutex, timeout); in ZTEST()
167 sys_trace_k_condvar_wait_exit(&condvar, &mutex, timeout, ret); in ZTEST()
171 sys_trace_k_sem_take_enter(&sem2, timeout); in ZTEST()
172 sys_trace_k_sem_take_exit(&sem, timeout, ret); in ZTEST()
173 sys_trace_k_sem_take_blocking(&sem, timeout); in ZTEST()
[all …]
/Zephyr-latest/include/zephyr/input/
Dinput.h72 k_timeout_t timeout);
82 k_timeout_t timeout) in input_report_key() argument
84 return input_report(dev, INPUT_EV_KEY, code, !!value, sync, timeout); in input_report_key()
94 k_timeout_t timeout) in input_report_rel() argument
96 return input_report(dev, INPUT_EV_REL, code, value, sync, timeout); in input_report_rel()
106 k_timeout_t timeout) in input_report_abs() argument
108 return input_report(dev, INPUT_EV_ABS, code, value, sync, timeout); in input_report_abs()
/Zephyr-latest/kernel/include/
Dtimeout_q.h31 k_timeout_t timeout);
42 z_init_timeout(&thread_base->timeout); in z_init_thread_timeout()
45 extern void z_thread_timeout(struct _timeout *timeout);
49 z_add_timeout(&thread->base.timeout, z_thread_timeout, ticks); in z_add_thread_timeout()
54 return z_abort_timeout(&thread->base.timeout); in z_abort_thread_timeout()
59 k_ticks_t z_timeout_remaining(const struct _timeout *timeout);
/Zephyr-latest/tests/kernel/mem_heap/k_heap_api/src/
Dtest_kheap_api.c37 k_timeout_t timeout = Z_TIMEOUT_MS(200); in thread_alloc_heap() local
43 p = (char *)k_heap_alloc(&k_heap_test, ALLOC_SIZE_2, timeout); in thread_alloc_heap()
54 k_timeout_t timeout = Z_TIMEOUT_MS(200); in thread_alloc_heap_null() local
60 p = (char *)k_heap_alloc(&k_heap_test, ALLOC_SIZE_2, timeout); in thread_alloc_heap_null()
117 k_timeout_t timeout = Z_TIMEOUT_US(TIMEOUT); in ZTEST() local
118 char *p = (char *)k_heap_alloc(&k_heap_test, ALLOC_SIZE_1, timeout); in ZTEST()
142 k_timeout_t timeout = Z_TIMEOUT_US(TIMEOUT); in ZTEST() local
143 char *p = (char *)k_heap_alloc(&k_heap_test, ALLOC_SIZE_3, timeout); in ZTEST()
168 k_timeout_t timeout = Z_TIMEOUT_US(TIMEOUT); in ZTEST() local
169 char *p = (char *)k_heap_alloc(&k_heap_test, ALLOC_SIZE_1, timeout); in ZTEST()
[all …]

12345678910>>...36