Home
last modified time | relevance | path

Searched refs:queue (Results 1 – 25 of 218) sorted by relevance

123456789

/Zephyr-latest/kernel/
Dqueue.c58 void z_impl_k_queue_init(struct k_queue *queue) in z_impl_k_queue_init() argument
60 sys_sflist_init(&queue->data_q); in z_impl_k_queue_init()
61 queue->lock = (struct k_spinlock) {}; in z_impl_k_queue_init()
62 z_waitq_init(&queue->wait_q); in z_impl_k_queue_init()
64 sys_dlist_init(&queue->poll_events); in z_impl_k_queue_init()
67 SYS_PORT_TRACING_OBJ_INIT(k_queue, queue); in z_impl_k_queue_init()
69 k_object_init(queue); in z_impl_k_queue_init()
73 static inline void z_vrfy_k_queue_init(struct k_queue *queue) in z_vrfy_k_queue_init() argument
75 K_OOPS(K_SYSCALL_OBJ_NEVER_INIT(queue, K_OBJ_QUEUE)); in z_vrfy_k_queue_init()
76 z_impl_k_queue_init(queue); in z_vrfy_k_queue_init()
[all …]
Dwork.c187 static void queue_flusher_locked(struct k_work_q *queue, in queue_flusher_locked() argument
194 sys_slist_insert(&queue->pending, &work->node, in queue_flusher_locked()
197 sys_slist_prepend(&queue->pending, &flusher->work.node); in queue_flusher_locked()
208 static inline void queue_remove_locked(struct k_work_q *queue, in queue_remove_locked() argument
212 (void)sys_slist_find_and_remove(&queue->pending, &work->node); in queue_remove_locked()
227 static inline bool notify_queue_locked(struct k_work_q *queue) in notify_queue_locked() argument
231 if (queue != NULL) { in notify_queue_locked()
232 rv = z_sched_wake(&queue->notifyq, 0, NULL); in notify_queue_locked()
257 static inline int queue_submit_locked(struct k_work_q *queue, in queue_submit_locked() argument
260 if (queue == NULL) { in queue_submit_locked()
[all …]
/Zephyr-latest/subsys/bluetooth/controller/ll_sw/
Dull_tx_queue.c11 void ull_tx_q_init(struct ull_tx_q *queue) in ull_tx_q_init() argument
13 queue->pause_data = 0U; in ull_tx_q_init()
14 sys_slist_init(&queue->tx_list); in ull_tx_q_init()
15 sys_slist_init(&queue->data_list); in ull_tx_q_init()
18 void ull_tx_q_pause_data(struct ull_tx_q *queue) in ull_tx_q_pause_data() argument
20 queue->pause_data++; in ull_tx_q_pause_data()
23 void ull_tx_q_resume_data(struct ull_tx_q *queue) in ull_tx_q_resume_data() argument
25 if (queue->pause_data > 0) { in ull_tx_q_resume_data()
26 queue->pause_data--; in ull_tx_q_resume_data()
30 if (!queue->pause_data && !sys_slist_is_empty(&queue->data_list)) { in ull_tx_q_resume_data()
[all …]
Dull_tx_queue.h22 void ull_tx_q_init(struct ull_tx_q *queue);
29 void ull_tx_q_pause_data(struct ull_tx_q *queue);
36 void ull_tx_q_resume_data(struct ull_tx_q *queue);
44 void ull_tx_q_enqueue_data(struct ull_tx_q *queue, struct node_tx *tx);
52 void ull_tx_q_enqueue_ctrl(struct ull_tx_q *queue, struct node_tx *tx);
61 struct node_tx *ull_tx_q_peek(struct ull_tx_q *queue);
70 struct node_tx *ull_tx_q_dequeue(struct ull_tx_q *queue);
/Zephyr-latest/samples/arch/smp/pktqueue/src/
Dpktqueue.c10 void phdr_desc_enqueue(struct phdr_desc_queue *queue, struct phdr_desc *desc, in phdr_desc_enqueue() argument
16 if (queue->count == 0) { in phdr_desc_enqueue()
17 queue->head = queue->tail = desc; in phdr_desc_enqueue()
19 queue->tail->next = desc; in phdr_desc_enqueue()
20 queue->tail = desc; in phdr_desc_enqueue()
22 queue->count++; in phdr_desc_enqueue()
30 struct phdr_desc *phdr_desc_dequeue(struct phdr_desc_queue *queue, in phdr_desc_dequeue() argument
36 if (queue->count != 0) { in phdr_desc_dequeue()
37 queue->count--; in phdr_desc_dequeue()
38 return_ptr = queue->head; in phdr_desc_dequeue()
[all …]
/Zephyr-latest/lib/os/
Dp4wq.c79 struct k_p4wq *queue = p0; in p4wq_loop() local
80 k_spinlock_key_t k = k_spin_lock(&queue->lock); in p4wq_loop()
83 struct rbnode *r = rb_get_max(&queue->queue); in p4wq_loop()
89 rb_remove(&queue->queue, r); in p4wq_loop()
91 sys_dlist_append(&queue->active, &w->dlnode); in p4wq_loop()
95 k_spin_unlock(&queue->lock, k); in p4wq_loop()
99 k = k_spin_lock(&queue->lock); in p4wq_loop()
110 z_pend_curr(&queue->lock, k, &queue->waitq, K_FOREVER); in p4wq_loop()
111 k = k_spin_lock(&queue->lock); in p4wq_loop()
126 void k_p4wq_init(struct k_p4wq *queue) in k_p4wq_init() argument
[all …]
/Zephyr-latest/samples/subsys/portability/cmsis_rtos_v1/timer_synchronization/
DREADME.rst11 The main thread creates a preemptive thread which writes message to message queue
32 Wrote to message queue: 5
33 Read from message queue: 5
35 Wrote to message queue: 6
36 Read from message queue: 6
38 Wrote to message queue: 7
39 Read from message queue: 7
41 Wrote to message queue: 8
42 Read from message queue: 8
44 Wrote to message queue: 9
[all …]
/Zephyr-latest/samples/subsys/portability/cmsis_rtos_v2/timer_synchronization/
DREADME.rst11 The main thread creates a preemptive thread which writes message to message queue
32 Wrote to message queue: 5
33 Read from message queue: 5
35 Wrote to message queue: 6
36 Read from message queue: 6
38 Wrote to message queue: 7
39 Read from message queue: 7
41 Wrote to message queue: 8
42 Read from message queue: 8
44 Wrote to message queue: 9
[all …]
/Zephyr-latest/tests/kernel/queue/src/
Dtest_queue_fail.c25 static struct k_queue queue; in ZTEST() local
27 k_queue_init(&queue); in ZTEST()
29 zassert_is_null(k_queue_get(&queue, K_NO_WAIT), NULL); in ZTEST()
30 zassert_is_null(k_queue_get(&queue, TIMEOUT), NULL); in ZTEST()
62 static struct k_queue queue; in ZTEST() local
65 k_queue_init(&queue); in ZTEST()
69 zassert_true(k_queue_append_list(&queue, (uint32_t *)head, in ZTEST()
75 zassert_true(k_queue_append_list(&queue, (uint32_t *)head, in ZTEST()
79 k_queue_init(&queue); in ZTEST()
85 k_thread_create(&tdata, tstack, STACK_SIZE, tThread_entry, &queue, in ZTEST()
[all …]
Dtest_queue_contexts.c17 struct k_queue queue; variable
157 k_queue_init(&queue); in ZTEST()
158 tqueue_thread_thread(&queue); in ZTEST()
181 k_queue_init(&queue); in ZTEST()
182 tqueue_thread_isr(&queue); in ZTEST()
203 k_queue_init(&queue); in ZTEST()
204 tqueue_isr_thread(&queue); in ZTEST()
250 k_queue_init(&queue); in ZTEST()
252 tqueue_get_2threads(&queue); in ZTEST()
310 k_queue_init(&queue); in ZTEST()
[all …]
/Zephyr-latest/include/zephyr/tracing/
Dtracing.h326 #define sys_port_trace_k_work_submit_to_queue_enter(queue, work) argument
334 #define sys_port_trace_k_work_submit_to_queue_exit(queue, work, ret) argument
416 #define sys_port_trace_k_work_queue_init(queue) argument
422 #define sys_port_trace_k_work_queue_start_enter(queue) argument
428 #define sys_port_trace_k_work_queue_start_exit(queue) 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
456 #define sys_port_trace_k_work_queue_drain_enter(queue) argument
463 #define sys_port_trace_k_work_queue_drain_exit(queue, ret) argument
[all …]
Dtracking.h63 #define sys_port_track_k_work_queue_init(queue) argument
71 #define sys_port_track_k_queue_peek_tail(queue, ret) argument
72 #define sys_port_track_k_queue_peek_head(queue, ret) argument
73 #define sys_port_track_k_queue_cancel_wait(queue) argument
74 #define sys_port_track_k_queue_init(queue) \ argument
75 sys_track_k_queue_init(queue)
109 void sys_track_k_queue_init(struct k_queue *queue);
125 #define sys_port_track_k_work_queue_init(queue) argument
131 #define sys_port_track_k_queue_peek_tail(queue, ret) argument
132 #define sys_port_track_k_queue_peek_head(queue, ret) argument
[all …]
/Zephyr-latest/include/zephyr/sys/
Dp4wq.h43 struct k_p4wq *queue; member
70 struct rbtree queue; member
82 struct k_p4wq *queue; member
110 .queue = &name, \
137 .queue = name, \
150 void k_p4wq_init(struct k_p4wq *queue);
164 void k_p4wq_add_thread(struct k_p4wq *queue, struct k_thread *thread,
189 void k_p4wq_submit(struct k_p4wq *queue, struct k_p4wq_work *item);
201 bool k_p4wq_cancel(struct k_p4wq *queue, struct k_p4wq_work *item);
208 void k_p4wq_enable_static_thread(struct k_p4wq *queue, struct k_thread *thread,
/Zephyr-latest/drivers/ethernet/
Deth_sam_gmac.c132 #error Not enough RX buffers to allocate descriptors for each HW queue
246 static int rx_descriptors_init(Gmac *gmac, struct gmac_queue *queue);
247 static void tx_descriptors_init(Gmac *gmac, struct gmac_queue *queue);
248 static int nonpriority_queue_init(Gmac *gmac, struct gmac_queue *queue);
252 struct gmac_queue *queue) in set_receive_buf_queue_pointer() argument
255 if (queue->que_idx == GMAC_QUE_0) { in set_receive_buf_queue_pointer()
256 gmac->GMAC_RBQB = (uint32_t)queue->rx_desc_list.buf; in set_receive_buf_queue_pointer()
258 gmac->GMAC_RBQBAPQ[queue->que_idx - 1] = in set_receive_buf_queue_pointer()
259 (uint32_t)queue->rx_desc_list.buf; in set_receive_buf_queue_pointer()
273 static int priority_queue_init(Gmac *gmac, struct gmac_queue *queue) in priority_queue_init() argument
[all …]
/Zephyr-latest/subsys/tracing/test/
Dtracing_test.h68 #define sys_port_trace_k_work_submit_to_queue_enter(queue, work) argument
69 #define sys_port_trace_k_work_submit_to_queue_exit(queue, work, ret) argument
81 #define sys_port_trace_k_work_queue_init(queue) argument
82 #define sys_port_trace_k_work_queue_start_enter(queue) argument
83 #define sys_port_trace_k_work_queue_start_exit(queue) argument
84 #define sys_port_trace_k_work_queue_stop_enter(queue, timeout) argument
85 #define sys_port_trace_k_work_queue_stop_blocking(queue, timeout) argument
86 #define sys_port_trace_k_work_queue_stop_exit(queue, timeout, ret) argument
87 #define sys_port_trace_k_work_queue_drain_enter(queue) argument
88 #define sys_port_trace_k_work_queue_drain_exit(queue, ret) argument
[all …]
Dtracing_string_format_test.c411 void sys_trace_k_queue_init(struct k_queue *queue) in sys_trace_k_queue_init() argument
413 TRACING_STRING("%s: %p\n", __func__, queue); in sys_trace_k_queue_init()
416 void sys_trace_k_queue_cancel_wait(struct k_queue *queue) in sys_trace_k_queue_cancel_wait() argument
418 TRACING_STRING("%s: %p\n", __func__, queue); in sys_trace_k_queue_cancel_wait()
421 void sys_trace_k_queue_append_enter(struct k_queue *queue, void *data) in sys_trace_k_queue_append_enter() argument
423 TRACING_STRING("%s: %p\n", __func__, queue); in sys_trace_k_queue_append_enter()
426 void sys_trace_k_queue_append_exit(struct k_queue *queue, void *data) in sys_trace_k_queue_append_exit() argument
428 TRACING_STRING("%s: %p\n", __func__, queue); in sys_trace_k_queue_append_exit()
431 void sys_trace_k_queue_queue_insert_enter(struct k_queue *queue, bool alloc, void *data) in sys_trace_k_queue_queue_insert_enter() argument
433 TRACING_STRING("%s: %p\n", __func__, queue); in sys_trace_k_queue_queue_insert_enter()
[all …]
/Zephyr-latest/subsys/tracing/sysview/
Dtracing_sysview.h137 #define sys_port_trace_k_work_submit_to_queue_enter(queue, work) \ argument
138 SEGGER_SYSVIEW_RecordU32x2(TID_WORK_SUBMIT_TO_QUEUE, (uint32_t)(uintptr_t)queue, \
141 #define sys_port_trace_k_work_submit_to_queue_exit(queue, work, ret) \ argument
173 #define sys_port_trace_k_work_queue_init(queue) \ argument
175 (uint32_t)(uintptr_t)queue)
177 #define sys_port_trace_k_work_queue_start_enter(queue) \ argument
178 SEGGER_SYSVIEW_RecordU32(TID_WORK_QUEUE_START, (uint32_t)(uintptr_t)queue)
180 #define sys_port_trace_k_work_queue_start_exit(queue) \ argument
183 #define sys_port_trace_k_work_queue_stop_enter(queue, timeout) \ argument
184 SEGGER_SYSVIEW_RecordU32x2(TID_WORK_QUEUE_STOP, (uint32_t)(uintptr_t)queue, \
[all …]
/Zephyr-latest/subsys/tracing/user/
Dtracing_user.h142 #define sys_port_trace_k_work_submit_to_queue_enter(queue, work) argument
143 #define sys_port_trace_k_work_submit_to_queue_exit(queue, work, ret) argument
155 #define sys_port_trace_k_work_queue_init(queue) argument
156 #define sys_port_trace_k_work_queue_start_enter(queue) argument
157 #define sys_port_trace_k_work_queue_start_exit(queue) 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
161 #define sys_port_trace_k_work_queue_drain_enter(queue) argument
162 #define sys_port_trace_k_work_queue_drain_exit(queue, ret) argument
[all …]
/Zephyr-latest/modules/lvgl/
DKconfig.input14 int "Input pointer queue message count"
18 Size of the pointer message queue buffering input events.
27 int "Input button queue message count"
31 Size of the button message queue buffering input events.
40 int "Input encoder queue message count"
44 Size of the encoder message queue buffering input events.
53 int "Input keypad queue message count"
57 Size of the keypad message queue buffering input events.
/Zephyr-latest/doc/kernel/services/data_passing/
Dmessage_queues.rst6 A :dfn:`message queue` is a kernel object that implements a simple
7 message queue, allowing threads and ISRs to asynchronously send and receive
18 Each message queue is referenced by its memory address.
20 A message queue has the following key properties:
28 A message queue must be initialized before it can be used.
31 A data item can be **sent** to a message queue by a thread or an ISR.
33 if one exists; otherwise the item is copied to the message queue's ring buffer,
35 *must* equal the message queue's data item size.
43 A data item can be **received** from a message queue by a thread.
45 the size of the receiving area *must* equal the message queue's data item size.
[all …]
/Zephyr-latest/lib/posix/options/
DKconfig.mqueue6 bool "POSIX message queue support"
8 This enabled POSIX message queue related APIs.
13 int "Maximum number of messages in a POSIX message queue"
16 Mention maximum number of messages in message queue in POSIX compliant
32 int "Maximum POSIX message queue name size"
36 Mention size of message queue name in number of characters.
/Zephyr-latest/tests/posix/common/src/
Dmqueue.c19 static char queue[16] = "server"; variable
37 mqd = mq_open(queue, O_WRONLY); in sender_thread()
55 mqd = mq_open(queue, O_RDONLY); in receiver_thread()
80 mqd = mq_open(queue, flags, mode, &attrs); in ZTEST()
96 zassert_false(mq_unlink(queue), "Not able to unlink Queue"); in ZTEST()
106 mqd = mq_open(queue, O_RDONLY); in notify_function_basic()
135 mqd = mq_open(queue, flags, mode, &attrs); in ZTEST()
144 zassert_ok(mq_unlink(queue), "Unable to unlink queue"); in ZTEST()
155 mqd = mq_open(queue, O_RDONLY); in notify_function_thread()
184 mqd = mq_open(queue, flags, mode, &attrs); in ZTEST()
[all …]
/Zephyr-latest/subsys/tracing/ctf/
Dtracing_ctf.h77 #define sys_port_trace_k_work_submit_to_queue_enter(queue, work) argument
78 #define sys_port_trace_k_work_submit_to_queue_exit(queue, work, ret) argument
90 #define sys_port_trace_k_work_queue_init(queue) argument
91 #define sys_port_trace_k_work_queue_start_enter(queue) argument
92 #define sys_port_trace_k_work_queue_start_exit(queue) 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
96 #define sys_port_trace_k_work_queue_drain_enter(queue) argument
97 #define sys_port_trace_k_work_queue_drain_exit(queue, ret) argument
[all …]
/Zephyr-latest/drivers/sensor/nuvoton/nuvoton_adc_cmp_npcx/
DKconfig19 bool "NPCX ADC threshold detection uses internal work queue"
21 Threshold detection ISR utilizes system work queue for calling
22 trigger handlers; set this option to use dedicated work queue instead.
27 int "Nuvoton NPCX ADC trheshold detection work queue priority"
34 int "Nuvoton NPCX ADC trheshold detection work queue stack size"
/Zephyr-latest/tests/benchmarks/wait_queues/
DREADME.rst4 A Zehpyr application developer may choose between two different wait queue
5 implementations: dumb and scalable. These two queue implementations perform
11 * Time to add threads of increasing priority to a wait queue
12 * Time to add threads of decreasing priority to a wait queue
13 * Time to remove highest priority thread from a wait queue
14 * Time to remove lowest priority thread from a wait queue

123456789