/Zephyr-Core-3.6.0/subsys/modem/ |
D | modem_pipe.c | 12 void modem_pipe_init(struct modem_pipe *pipe, void *data, struct modem_pipe_api *api) in modem_pipe_init() argument 14 __ASSERT_NO_MSG(pipe != NULL); in modem_pipe_init() 18 pipe->data = data; in modem_pipe_init() 19 pipe->api = api; in modem_pipe_init() 20 pipe->callback = NULL; in modem_pipe_init() 21 pipe->user_data = NULL; in modem_pipe_init() 22 pipe->state = MODEM_PIPE_STATE_CLOSED; in modem_pipe_init() 23 pipe->receive_ready_pending = false; in modem_pipe_init() 24 pipe->transmit_idle_pending = true; in modem_pipe_init() 26 k_mutex_init(&pipe->lock); in modem_pipe_init() [all …]
|
D | modem_cmux.c | 195 static void modem_cmux_bus_callback(struct modem_pipe *pipe, enum modem_pipe_event event, in modem_cmux_bus_callback() argument 538 modem_pipe_notify_opened(&dlci->pipe); in modem_cmux_on_dlci_frame_ua() 547 modem_pipe_notify_closed(&dlci->pipe); in modem_cmux_on_dlci_frame_ua() 573 modem_pipe_notify_receive_ready(&dlci->pipe); in modem_cmux_on_dlci_frame_uih() 588 modem_pipe_notify_opened(&dlci->pipe); in modem_cmux_on_dlci_frame_sabm() 606 modem_pipe_notify_closed(&dlci->pipe); in modem_cmux_on_dlci_frame_disc() 835 ret = modem_pipe_receive(cmux->pipe, buf, sizeof(buf)); in modem_cmux_receive_handler() 856 modem_pipe_notify_transmit_idle(&dlci->pipe); in modem_cmux_dlci_notify_transmit_idle() 880 ret = modem_pipe_transmit(cmux->pipe, reserved, reserved_size); in modem_cmux_transmit_handler() 1079 modem_pipe_notify_closed(&dlci->pipe); in modem_cmux_dlci_pipes_notify_closed() [all …]
|
D | modem_ppp.c | 312 static void modem_ppp_pipe_callback(struct modem_pipe *pipe, enum modem_pipe_event event, in modem_ppp_pipe_callback() argument 366 ret = modem_pipe_transmit(ppp->pipe, reserved, reserved_size); in modem_ppp_send_handler() 385 ret = modem_pipe_receive(ppp->pipe, ppp->receive_buf, ppp->buf_size); in modem_ppp_process_handler() 468 int modem_ppp_attach(struct modem_ppp *ppp, struct modem_pipe *pipe) in modem_ppp_attach() argument 474 modem_pipe_attach(pipe, modem_ppp_pipe_callback, ppp); in modem_ppp_attach() 475 ppp->pipe = pipe; in modem_ppp_attach() 493 modem_pipe_release(ppp->pipe); in modem_ppp_release() 496 ppp->pipe = NULL; in modem_ppp_release()
|
/Zephyr-Core-3.6.0/kernel/ |
D | pipes.c | 30 static int pipe_get_internal(k_spinlock_key_t key, struct k_pipe *pipe, 39 void k_pipe_init(struct k_pipe *pipe, unsigned char *buffer, size_t size) in k_pipe_init() argument 41 pipe->buffer = buffer; in k_pipe_init() 42 pipe->size = size; in k_pipe_init() 43 pipe->bytes_used = 0U; in k_pipe_init() 44 pipe->read_index = 0U; in k_pipe_init() 45 pipe->write_index = 0U; in k_pipe_init() 46 pipe->lock = (struct k_spinlock){}; in k_pipe_init() 47 z_waitq_init(&pipe->wait_q.writers); in k_pipe_init() 48 z_waitq_init(&pipe->wait_q.readers); in k_pipe_init() [all …]
|
/Zephyr-Core-3.6.0/tests/kernel/pipe/pipe_api/src/ |
D | test_pipe_avail.c | 16 static struct k_pipe pipe = { variable 88 pipe.read_index = 0; in ZTEST() 89 pipe.write_index = 3; in ZTEST() 92 r_avail = k_pipe_read_avail(&pipe); in ZTEST() 95 w_avail = k_pipe_write_avail(&pipe); in ZTEST() 127 pipe.read_index = 3; in ZTEST() 128 pipe.write_index = 0; in ZTEST() 131 r_avail = k_pipe_read_avail(&pipe); in ZTEST() 134 w_avail = k_pipe_write_avail(&pipe); in ZTEST() 170 pipe.read_index = 4; in ZTEST() [all …]
|
D | main.c | 17 extern struct k_pipe pipe, kpipe, khalfpipe, put_get_pipe; 25 k_thread_access_grant(k_current_get(), &pipe, in pipe_api_setup()
|
/Zephyr-Core-3.6.0/include/zephyr/modem/ |
D | pipe.h | 42 typedef void (*modem_pipe_api_callback)(struct modem_pipe *pipe, enum modem_pipe_event event, 88 void modem_pipe_init(struct modem_pipe *pipe, void *data, struct modem_pipe_api *api); 102 int modem_pipe_open(struct modem_pipe *pipe); 115 int modem_pipe_open_async(struct modem_pipe *pipe); 127 void modem_pipe_attach(struct modem_pipe *pipe, modem_pipe_api_callback callback, void *user_data); 140 int modem_pipe_transmit(struct modem_pipe *pipe, const uint8_t *buf, size_t size); 155 int modem_pipe_receive(struct modem_pipe *pipe, uint8_t *buf, size_t size); 162 void modem_pipe_release(struct modem_pipe *pipe); 172 int modem_pipe_close(struct modem_pipe *pipe); 185 int modem_pipe_close_async(struct modem_pipe *pipe); [all …]
|
D | cmux.h | 89 struct modem_pipe pipe; member 123 struct modem_pipe *pipe; member 220 int modem_cmux_attach(struct modem_cmux *cmux, struct modem_pipe *pipe);
|
/Zephyr-Core-3.6.0/tests/benchmarks/app_kernel/src/ |
D | pipe_r.c | 15 int pipeget(struct k_pipe *pipe, enum pipe_options option, 32 int pipe; in piperecvtask() local 39 for (pipe = 0; pipe < 3; pipe++) { in piperecvtask() 41 pipeget(test_pipes[pipe], _ALL_N, getsize, in piperecvtask() 55 for (pipe = 0; pipe < 3; pipe++) { in piperecvtask() 57 pipeget(test_pipes[pipe], _1_TO_N, in piperecvtask() 82 int pipeget(struct k_pipe *pipe, enum pipe_options option, int size, int count, in pipeget() argument 100 ret = k_pipe_get(pipe, data_recv, size2xfer, in pipeget()
|
D | pipe_b.c | 47 int pipeput(struct k_pipe *pipe, enum pipe_options 63 int pipe; in pipe_test() local 93 for (pipe = 0; pipe < 3; pipe++) { in pipe_test() 95 pipeput(test_pipes[pipe], _ALL_N, putsize, putcount, in pipe_test() 96 &puttime[pipe]); in pipe_test() 128 for (pipe = 0; pipe < 3; pipe++) { in pipe_test() 129 pipeput(test_pipes[pipe], _1_TO_N, putsize, in pipe_test() 130 putcount, &puttime[pipe]); in pipe_test() 155 int pipeput(struct k_pipe *pipe, in pipeput() argument 180 ret = k_pipe_put(pipe, data_bench, size2xfer, in pipeput()
|
/Zephyr-Core-3.6.0/scripts/pylib/twister/twisterlib/ |
D | jobserver.py | 84 self._internal_pipe = os.pipe() 142 pipe = [int(x) for x in match.groups()] 144 pipe = None 151 if pipe: 152 rc = fcntl.fcntl(pipe[0], fcntl.F_GETFL) 156 "ignoring GNU make jobserver", pipe[0], rc) 157 pipe = None 158 if pipe: 159 rc = fcntl.fcntl(pipe[1], fcntl.F_GETFL) 163 "ignoring GNU make jobserver", pipe[1], rc) [all …]
|
/Zephyr-Core-3.6.0/doc/kernel/services/data_passing/ |
D | pipes.rst | 6 A :dfn:`pipe` is a kernel object that allows a thread to send a byte stream 17 The pipe can be configured with a ring buffer which holds data that has been 18 sent but not yet received; alternatively, the pipe may have no ring buffer. 20 Any number of pipes can be defined (limited only by available RAM). Each pipe is 23 A pipe has the following key property: 25 * A **size** that indicates the size of the pipe's ring buffer. Note that a 26 size of zero defines a pipe with no ring buffer. 28 A pipe must be initialized before it can be used. The pipe is initially empty. 30 Data is synchronously **sent** either in whole or in part to a pipe by a 34 completed later. Accepted data is either copied to the pipe's ring buffer [all …]
|
/Zephyr-Core-3.6.0/tests/ztest/fail/src/ |
D | main.cpp | 20 auto pipe = popen(FAIL_TARGET_BINARY, "r"); in ZTEST() local 22 zassert_not_null(pipe, "Failed to execute '" FAIL_TARGET_BINARY "'"); in ZTEST() 25 while (!feof(pipe)) { in ZTEST() 26 if (fgets(buffer, ARRAY_SIZE(buffer), pipe) != nullptr) { in ZTEST() 51 auto rc = WEXITSTATUS(pclose(pipe)); in ZTEST()
|
/Zephyr-Core-3.6.0/tests/subsys/modem/backends/uart/src/ |
D | main.c | 33 static struct modem_pipe *pipe; variable 47 static void modem_pipe_callback_handler(struct modem_pipe *pipe, enum modem_pipe_event event, in modem_pipe_callback_handler() argument 122 ret = modem_pipe_transmit(pipe, reserved, transmit_size); in transmit_prng() 137 ret = modem_pipe_receive(pipe, receive_buffer, sizeof(receive_buffer)); in receive_prng() 165 pipe = modem_backend_uart_init(&uart_backend, &config); in test_modem_backend_uart_setup() 166 modem_pipe_attach(pipe, modem_pipe_callback_handler, NULL); in test_modem_backend_uart_setup() 175 __ASSERT_NO_MSG(modem_pipe_open(pipe) == 0); in test_modem_backend_uart_before() 180 __ASSERT_NO_MSG(modem_pipe_close(pipe) == 0); in test_modem_backend_uart_after()
|
/Zephyr-Core-3.6.0/subsys/modem/backends/ |
D | modem_backend_uart.c | 22 modem_pipe_notify_receive_ready(&backend->pipe); in modem_backend_uart_receive_ready_handler() 30 modem_pipe_notify_transmit_idle(&backend->pipe); in modem_backend_uart_transmit_idle_handler() 51 return &backend->pipe; in modem_backend_uart_init() 58 return &backend->pipe; in modem_backend_uart_init()
|
D | modem_backend_tty.c | 45 modem_pipe_notify_receive_ready(&backend->pipe); in modem_backend_tty_routine() 69 modem_pipe_notify_opened(&backend->pipe); in modem_backend_tty_open() 79 modem_pipe_notify_transmit_idle(&backend->pipe); in modem_backend_tty_transmit() 102 modem_pipe_notify_closed(&backend->pipe); in modem_backend_tty_close() 125 modem_pipe_init(&backend->pipe, backend, &modem_backend_tty_api); in modem_backend_tty_init() 126 return &backend->pipe; in modem_backend_tty_init()
|
/Zephyr-Core-3.6.0/subsys/tracing/test/ |
D | tracing_test.h | 342 #define sys_port_trace_k_pipe_init(pipe) sys_trace_k_pipe_init(pipe, buffer, size) argument 343 #define sys_port_trace_k_pipe_cleanup_enter(pipe) sys_trace_k_pipe_cleanup_enter(pipe) argument 344 #define sys_port_trace_k_pipe_cleanup_exit(pipe, ret) sys_trace_k_pipe_cleanup_exit(pipe, ret) argument 345 #define sys_port_trace_k_pipe_alloc_init_enter(pipe) sys_trace_k_pipe_alloc_init_enter(pipe, size) argument 346 #define sys_port_trace_k_pipe_alloc_init_exit(pipe, ret) \ argument 347 sys_trace_k_pipe_alloc_init_exit(pipe, size, ret) 348 #define sys_port_trace_k_pipe_flush_enter(pipe) \ argument 349 sys_trace_k_pipe_flush_enter(pipe) 350 #define sys_port_trace_k_pipe_flush_exit(pipe) \ argument 351 sys_trace_k_pipe_flush_exit(pipe) [all …]
|
/Zephyr-Core-3.6.0/tests/subsys/modem/mock/ |
D | modem_backend_mock.c | 15 modem_pipe_notify_opened(&mock->pipe); in modem_backend_mock_open() 79 modem_pipe_notify_closed(&mock->pipe); in modem_backend_mock_close() 95 modem_pipe_notify_receive_ready(&mock->pipe); in modem_backend_mock_receive_ready_handler() 103 modem_pipe_notify_transmit_idle(&mock->pipe); in modem_backend_mock_transmit_idle_handler() 116 modem_pipe_init(&mock->pipe, mock, &modem_backend_mock_api); in modem_backend_mock_init() 117 return &mock->pipe; in modem_backend_mock_init() 122 return &mock->pipe; in modem_backend_mock_get_pipe()
|
/Zephyr-Core-3.6.0/tests/subsys/modem/modem_pipe/src/ |
D | main.c | 27 struct modem_pipe pipe; member 52 modem_pipe_notify_opened(&backend->pipe); in modem_backend_fake_opened_handler() 62 modem_pipe_notify_opened(&backend->pipe); in modem_backend_fake_open() 76 modem_pipe_notify_transmit_idle(&backend->pipe); in modem_backend_fake_transmit_idle_handler() 88 modem_pipe_notify_transmit_idle(&backend->pipe); in modem_backend_fake_transmit() 112 modem_pipe_notify_closed(&backend->pipe); in modem_backend_fake_closed_handler() 122 modem_pipe_notify_closed(&backend->pipe); in modem_backend_fake_close() 146 modem_pipe_init(&backend->pipe, backend, &modem_backend_fake_api); in modem_backend_fake_init() 147 return &backend->pipe; in modem_backend_fake_init() 180 static void modem_pipe_fake_handler(struct modem_pipe *pipe, enum modem_pipe_event event, in modem_pipe_fake_handler() argument [all …]
|
/Zephyr-Core-3.6.0/include/zephyr/tracing/ |
D | tracing.h | 1540 #define sys_port_trace_k_pipe_init(pipe) argument 1546 #define sys_port_trace_k_pipe_cleanup_enter(pipe) argument 1553 #define sys_port_trace_k_pipe_cleanup_exit(pipe, ret) argument 1559 #define sys_port_trace_k_pipe_alloc_init_enter(pipe) argument 1566 #define sys_port_trace_k_pipe_alloc_init_exit(pipe, ret) argument 1572 #define sys_port_trace_k_pipe_flush_enter(pipe) argument 1578 #define sys_port_trace_k_pipe_flush_exit(pipe) argument 1584 #define sys_port_trace_k_pipe_buffer_flush_enter(pipe) argument 1590 #define sys_port_trace_k_pipe_buffer_flush_exit(pipe) argument 1597 #define sys_port_trace_k_pipe_put_enter(pipe, timeout) argument [all …]
|
D | tracking.h | 76 #define sys_port_track_k_pipe_init(pipe) \ argument 77 sys_track_k_pipe_init(pipe) 105 void sys_track_k_pipe_init(struct k_pipe *pipe); 131 #define sys_port_track_k_pipe_init(pipe) argument
|
/Zephyr-Core-3.6.0/subsys/tracing/user/ |
D | tracing_user.h | 268 #define sys_port_trace_k_pipe_init(pipe) argument 269 #define sys_port_trace_k_pipe_cleanup_enter(pipe) argument 270 #define sys_port_trace_k_pipe_cleanup_exit(pipe, ret) argument 271 #define sys_port_trace_k_pipe_alloc_init_enter(pipe) argument 272 #define sys_port_trace_k_pipe_alloc_init_exit(pipe, ret) argument 273 #define sys_port_trace_k_pipe_flush_enter(pipe) argument 274 #define sys_port_trace_k_pipe_flush_exit(pipe) argument 275 #define sys_port_trace_k_pipe_buffer_flush_enter(pipe) argument 276 #define sys_port_trace_k_pipe_buffer_flush_exit(pipe) argument 277 #define sys_port_trace_k_pipe_put_enter(pipe, timeout) argument [all …]
|
/Zephyr-Core-3.6.0/tests/kernel/pipe/pipe/src/ |
D | test_pipe.c | 728 ZTEST_USER(pipe, test_pipe_on_single_elements) in ZTEST_USER() argument 754 ZTEST_USER(pipe, test_pipe_on_multiple_elements) in ZTEST_USER() argument 772 ZTEST_USER(pipe, test_pipe_forever_wait) in ZTEST_USER() argument 823 ZTEST_USER(pipe, test_pipe_timeout) in ZTEST_USER() argument 841 ZTEST_USER(pipe, test_pipe_get_on_empty_pipe) in ZTEST_USER() argument 854 ZTEST_USER(pipe, test_pipe_forever_timeout) in ZTEST_USER() argument 873 ZTEST_USER(pipe, test_pipe_get_timeout) in ZTEST_USER() argument 885 ZTEST_USER(pipe, test_pipe_get_invalid_size) in ZTEST_USER() argument 904 ZTEST_USER(pipe, test_pipe_get_min_xfer) in ZTEST_USER() argument 927 ZTEST_USER(pipe, test_pipe_put_min_xfer) in ZTEST_USER() argument [all …]
|
/Zephyr-Core-3.6.0/subsys/tracing/ctf/ |
D | tracing_ctf.h | 283 #define sys_port_trace_k_pipe_init(pipe) argument 284 #define sys_port_trace_k_pipe_cleanup_enter(pipe) argument 285 #define sys_port_trace_k_pipe_cleanup_exit(pipe, ret) argument 286 #define sys_port_trace_k_pipe_alloc_init_enter(pipe) argument 287 #define sys_port_trace_k_pipe_alloc_init_exit(pipe, ret) argument 288 #define sys_port_trace_k_pipe_flush_enter(pipe) argument 289 #define sys_port_trace_k_pipe_flush_exit(pipe) argument 290 #define sys_port_trace_k_pipe_buffer_flush_enter(pipe) argument 291 #define sys_port_trace_k_pipe_buffer_flush_exit(pipe) argument 292 #define sys_port_trace_k_pipe_put_enter(pipe, timeout) argument [all …]
|
/Zephyr-Core-3.6.0/tests/kernel/mutex/mutex_error_case/src/ |
D | test_mutex_error.c | 18 static struct k_pipe pipe; variable 75 k_mutex_lock((struct k_mutex *)&pipe, K_NO_WAIT); in tThread_entry_negative() 215 &mutex, &sem, &pipe, &queue); in mutex_api_tests_setup()
|