Home
last modified time | relevance | path

Searched refs:msgq (Results 1 – 25 of 44) sorted by relevance

12

/Zephyr-Core-3.7.0/kernel/
Dmsg_q.c33 static inline void handle_poll_events(struct k_msgq *msgq, uint32_t state) in handle_poll_events() argument
35 z_handle_obj_poll_events(&msgq->poll_events, state); in handle_poll_events()
39 void k_msgq_init(struct k_msgq *msgq, char *buffer, size_t msg_size, in k_msgq_init() argument
42 msgq->msg_size = msg_size; in k_msgq_init()
43 msgq->max_msgs = max_msgs; in k_msgq_init()
44 msgq->buffer_start = buffer; in k_msgq_init()
45 msgq->buffer_end = buffer + (max_msgs * msg_size); in k_msgq_init()
46 msgq->read_ptr = buffer; in k_msgq_init()
47 msgq->write_ptr = buffer; in k_msgq_init()
48 msgq->used_msgs = 0; in k_msgq_init()
[all …]
/Zephyr-Core-3.7.0/subsys/portability/cmsis_rtos_v2/
Dmsgq.c29 struct cv2_msgq *msgq; in osMessageQueueNew() local
47 if (k_mem_slab_alloc(&cv2_msgq_slab, (void **)&msgq, K_MSEC(100)) == 0) { in osMessageQueueNew()
48 (void)memset(msgq, 0, sizeof(struct cv2_msgq)); in osMessageQueueNew()
59 msgq->pool = k_calloc(msg_count, msg_size); in osMessageQueueNew()
60 if (msgq->pool == NULL) { in osMessageQueueNew()
61 k_mem_slab_free(&cv2_msgq_slab, (void *)msgq); in osMessageQueueNew()
64 msgq->is_dynamic_allocation = TRUE; in osMessageQueueNew()
66 k_mem_slab_free(&cv2_msgq_slab, (void *)msgq); in osMessageQueueNew()
70 msgq->pool = attr->mq_mem; in osMessageQueueNew()
71 msgq->is_dynamic_allocation = FALSE; in osMessageQueueNew()
[all …]
DCMakeLists.txt17 msgq.c
/Zephyr-Core-3.7.0/subsys/portability/cmsis_rtos_v1/
Dcmsis_msgq.c24 k_msgq_init(queue_def->msgq, queue_def->pool, in osMessageCreate()
42 retval = k_msgq_put(queue_def->msgq, (void *)&info, K_NO_WAIT); in osMessagePut()
44 retval = k_msgq_put(queue_def->msgq, (void *)&info, K_FOREVER); in osMessagePut()
46 retval = k_msgq_put(queue_def->msgq, (void *)&info, in osMessagePut()
75 retval = k_msgq_get(queue_def->msgq, &info, K_NO_WAIT); in osMessageGet()
77 retval = k_msgq_get(queue_def->msgq, &info, K_FOREVER); in osMessageGet()
79 retval = k_msgq_get(queue_def->msgq, &info, K_MSEC(millisec)); in osMessageGet()
/Zephyr-Core-3.7.0/include/zephyr/tracing/
Dtracking.h85 #define sys_port_track_k_msgq_purge(msgq) argument
86 #define sys_port_track_k_msgq_peek(msgq, ret) argument
87 #define sys_port_track_k_msgq_init(msgq) \ argument
88 sys_track_k_msgq_init(msgq)
106 void sys_track_k_msgq_init(struct k_msgq *msgq);
141 #define sys_port_track_k_msgq_purge(msgq) argument
142 #define sys_port_track_k_msgq_peek(msgq, ret) argument
143 #define sys_port_track_k_msgq_init(msgq) argument
Dtracing.h1350 #define sys_port_trace_k_msgq_init(msgq) argument
1356 #define sys_port_trace_k_msgq_alloc_init_enter(msgq) argument
1363 #define sys_port_trace_k_msgq_alloc_init_exit(msgq, ret) argument
1369 #define sys_port_trace_k_msgq_cleanup_enter(msgq) argument
1376 #define sys_port_trace_k_msgq_cleanup_exit(msgq, ret) argument
1383 #define sys_port_trace_k_msgq_put_enter(msgq, timeout) argument
1390 #define sys_port_trace_k_msgq_put_blocking(msgq, timeout) argument
1398 #define sys_port_trace_k_msgq_put_exit(msgq, timeout, ret) argument
1405 #define sys_port_trace_k_msgq_get_enter(msgq, timeout) argument
1412 #define sys_port_trace_k_msgq_get_blocking(msgq, timeout) argument
[all …]
/Zephyr-Core-3.7.0/tests/kernel/msgq/msgq_api/src/
Dtest_msgq_fail.c10 extern struct k_msgq msgq;
53 k_msgq_init(&msgq, tbuffer, MSG_SIZE, MSGQ_LEN); in ZTEST()
54 put_fail(&msgq); in ZTEST()
79 k_msgq_init(&msgq, tbuffer, MSG_SIZE, MSGQ_LEN); in ZTEST()
80 get_fail(&msgq); in ZTEST()
Dtest_msgq_attrs.c8 extern struct k_msgq msgq;
51 k_msgq_init(&msgq, tbuffer, MSG_SIZE, MSGQ_LEN); in ZTEST()
52 attrs_get(&msgq); in ZTEST()
Dtest_msgq_purge.c11 extern struct k_msgq msgq;
60 k_msgq_init(&msgq, tbuffer, MSG_SIZE, MSGQ_LEN); in ZTEST()
62 purge_when_put(&msgq); in ZTEST()
Dmain.c27 extern struct k_msgq msgq;
34 k_thread_access_grant(k_current_get(), &kmsgq, &msgq, &end_sema, in msgq_api_setup()
Dtest_msgq_contexts.c12 struct k_msgq msgq; variable
258 k_msgq_init(&msgq, tbuffer, MSG_SIZE, MSGQ_LEN); in ZTEST()
262 msgq_thread(&msgq); in ZTEST()
275 k_msgq_init(&msgq, tbuffer, MSG_SIZE, 2); in ZTEST()
279 ret = k_msgq_put(&msgq, (void *)&data[0], K_FOREVER); in ZTEST()
282 msgq_thread_overflow(&msgq); in ZTEST()
286 zassert_false(msgq.write_ptr == msgq.buffer_start, in ZTEST()
/Zephyr-Core-3.7.0/subsys/tracing/test/
Dtracing_test.h293 #define sys_port_trace_k_msgq_init(msgq) sys_trace_k_msgq_init(msgq) argument
295 #define sys_port_trace_k_msgq_alloc_init_enter(msgq) \ argument
296 sys_trace_k_msgq_alloc_init_enter(msgq, msg_size, max_msgs)
298 #define sys_port_trace_k_msgq_alloc_init_exit(msgq, ret) \ argument
299 sys_trace_k_msgq_alloc_init_exit(msgq, msg_size, max_msgs, ret)
301 #define sys_port_trace_k_msgq_cleanup_enter(msgq) sys_trace_k_msgq_cleanup_enter(msgq) argument
303 #define sys_port_trace_k_msgq_cleanup_exit(msgq, ret) sys_trace_k_msgq_cleanup_exit(msgq, ret) argument
305 #define sys_port_trace_k_msgq_put_enter(msgq, timeout) \ argument
306 sys_trace_k_msgq_put_enter(msgq, data, timeout)
308 #define sys_port_trace_k_msgq_put_blocking(msgq, timeout) \ argument
[all …]
/Zephyr-Core-3.7.0/subsys/tracing/user/
Dtracing_user.h246 #define sys_port_trace_k_msgq_init(msgq) argument
247 #define sys_port_trace_k_msgq_alloc_init_enter(msgq) argument
248 #define sys_port_trace_k_msgq_alloc_init_exit(msgq, ret) argument
249 #define sys_port_trace_k_msgq_cleanup_enter(msgq) argument
250 #define sys_port_trace_k_msgq_cleanup_exit(msgq, ret) argument
251 #define sys_port_trace_k_msgq_put_enter(msgq, timeout) argument
252 #define sys_port_trace_k_msgq_put_blocking(msgq, timeout) argument
253 #define sys_port_trace_k_msgq_put_exit(msgq, timeout, ret) argument
254 #define sys_port_trace_k_msgq_get_enter(msgq, timeout) argument
255 #define sys_port_trace_k_msgq_get_blocking(msgq, timeout) argument
[all …]
/Zephyr-Core-3.7.0/samples/kernel/metairq_dispatch/src/
Dmain.c20 struct k_msgq msgq; member
64 int ret = k_msgq_put(&threads[m.target].msgq, &m, K_NO_WAIT); in metairq_fn()
188 int ret = k_msgq_get(&threads[id].msgq, &m, K_FOREVER); in thread_fn()
236 k_msgq_init(&threads[i].msgq, (char *)threads[i].msgq_buf, in main()
/Zephyr-Core-3.7.0/tests/kernel/obj_tracking/src/
Dmain.c37 struct k_msgq msgq; in ZTEST() local
100 k_msgq_init(&msgq, (char *)msgq_buffer, sizeof(int), 8); in ZTEST()
104 if (list == &msgq || list == &msgq_s) { in ZTEST()
/Zephyr-Core-3.7.0/subsys/tracing/ctf/
Dtracing_ctf.h256 #define sys_port_trace_k_msgq_init(msgq) argument
257 #define sys_port_trace_k_msgq_alloc_init_enter(msgq) argument
258 #define sys_port_trace_k_msgq_alloc_init_exit(msgq, ret) argument
259 #define sys_port_trace_k_msgq_cleanup_enter(msgq) argument
260 #define sys_port_trace_k_msgq_cleanup_exit(msgq, ret) argument
261 #define sys_port_trace_k_msgq_put_enter(msgq, timeout) argument
262 #define sys_port_trace_k_msgq_put_blocking(msgq, timeout) argument
263 #define sys_port_trace_k_msgq_put_exit(msgq, timeout, ret) argument
264 #define sys_port_trace_k_msgq_get_enter(msgq, timeout) argument
265 #define sys_port_trace_k_msgq_get_blocking(msgq, timeout) argument
[all …]
/Zephyr-Core-3.7.0/subsys/tracing/sysview/
Dtracing_sysview.h497 #define sys_port_trace_k_msgq_init(msgq) argument
498 #define sys_port_trace_k_msgq_alloc_init_enter(msgq) argument
499 #define sys_port_trace_k_msgq_alloc_init_exit(msgq, ret) argument
500 #define sys_port_trace_k_msgq_cleanup_enter(msgq) argument
501 #define sys_port_trace_k_msgq_cleanup_exit(msgq, ret) argument
502 #define sys_port_trace_k_msgq_put_enter(msgq, timeout) argument
503 #define sys_port_trace_k_msgq_put_blocking(msgq, timeout) argument
504 #define sys_port_trace_k_msgq_put_exit(msgq, timeout, ret) argument
505 #define sys_port_trace_k_msgq_get_enter(msgq, timeout) argument
506 #define sys_port_trace_k_msgq_get_blocking(msgq, timeout) argument
[all …]
DSYSVIEW_Zephyr.txt64 59 k_msgq_init msgq=%I, buffer=%p, msg_size=%u, max_msgs=%us
65 60 k_msgq_put msgq=%I, data=%p, Timeout=%TimeOut | Returns %ErrCodeMsg
66 61 k_msgq_get msgq=%I, data=%p, Timeout=%TimeOut | Returns %ErrCodeMsg
67 62 k_msgq_cleanup msgq=%I | Returns %ErrCodePosix
68 63 k_msgq_peek msgq=%I, data=%p | Returns %ErrCodeMsg
69 64 k_msgq_purge msgq=%I
/Zephyr-Core-3.7.0/drivers/can/
Dcan_common.c108 struct k_msgq *msgq = (struct k_msgq *)user_data; in can_msgq_put() local
113 __ASSERT_NO_MSG(msgq); in can_msgq_put()
115 ret = k_msgq_put(msgq, frame, K_NO_WAIT); in can_msgq_put()
117 LOG_ERR("Msgq %p overflowed. Frame ID: 0x%x", msgq, frame->id); in can_msgq_put()
121 int z_impl_can_add_rx_filter_msgq(const struct device *dev, struct k_msgq *msgq, in z_impl_can_add_rx_filter_msgq() argument
126 return api->add_rx_filter(dev, can_msgq_put, msgq, filter); in z_impl_can_add_rx_filter_msgq()
DKconfig.rcar19 Defines the array size of the callback/msgq pointers.
Dcan_handlers.c220 struct k_msgq *msgq, in z_vrfy_can_add_rx_filter_msgq() argument
226 K_OOPS(K_SYSCALL_OBJ(msgq, K_OBJ_MSGQ)); in z_vrfy_can_add_rx_filter_msgq()
229 return z_impl_can_add_rx_filter_msgq(dev, msgq, &filter_copy); in z_vrfy_can_add_rx_filter_msgq()
DKconfig.native_linux28 Defines the array size of the callback/msgq pointers.
/Zephyr-Core-3.7.0/subsys/tracing/
Dtracing_tracking.c94 void sys_track_k_msgq_init(struct k_msgq *msgq) in sys_track_k_msgq_init() argument
97 SYS_TRACK_LIST_PREPEND(_track_list_k_msgq, msgq)); in sys_track_k_msgq_init()
/Zephyr-Core-3.7.0/include/zephyr/
Dkernel.h4611 void k_msgq_init(struct k_msgq *msgq, char *buffer, size_t msg_size,
4633 __syscall int k_msgq_alloc_init(struct k_msgq *msgq, size_t msg_size,
4646 int k_msgq_cleanup(struct k_msgq *msgq);
4668 __syscall int k_msgq_put(struct k_msgq *msgq, const void *data, k_timeout_t timeout);
4690 __syscall int k_msgq_get(struct k_msgq *msgq, void *data, k_timeout_t timeout);
4706 __syscall int k_msgq_peek(struct k_msgq *msgq, void *data);
4724 __syscall int k_msgq_peek_at(struct k_msgq *msgq, void *data, uint32_t idx);
4735 __syscall void k_msgq_purge(struct k_msgq *msgq);
4747 __syscall uint32_t k_msgq_num_free_get(struct k_msgq *msgq);
4757 __syscall void k_msgq_get_attrs(struct k_msgq *msgq,
[all …]
/Zephyr-Core-3.7.0/tests/kernel/workq/work_queue/src/
Dmain.c87 struct k_msgq msgq; member
747 k_msgq_put(&triggered_from_msgq_test.msgq, &msg, K_NO_WAIT); in msg_provider_thread()
754 k_msgq_get(&triggered_from_msgq_test.msgq, &msg, K_NO_WAIT); in triggered_from_msgq_work_handler()
768 k_msgq_init(&ctx->msgq, in test_triggered_from_msgq_init()
773 K_POLL_MODE_NOTIFY_ONLY, &ctx->msgq); in test_triggered_from_msgq_init()

12