Home
last modified time | relevance | path

Searched full:queue (Results 1 – 25 of 652) sorted by relevance

12345678910>>...27

/Zephyr-latest/kernel/
Dqueue.c10 * @brief dynamic-size QUEUE object.
37 * struct, which is what got put in the queue. Free it and pass in z_queue_node_peek()
48 /* Data was directly placed in the queue, the first word in z_queue_node_peek()
58 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()
[all …]
Dwork.c10 * Second generation work queue implementation
99 * Invoked from a work queue thread.
119 * Invoked from a work queue thread.
176 /* Add a flusher work item to the queue.
180 * Caller must notify queue of pending work.
182 * @param queue queue on which a work item may appear.
184 * queue
187 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()
[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.h8 uint8_t pause_data; /* Data pause state of the tx queue */
18 * @brief Initialize a tx queue.
20 * @param ull_tx_q Address of tx queue.
22 void ull_tx_q_init(struct ull_tx_q *queue);
25 * @brief Pause the data path of a tx queue.
27 * @param ull_tx_q Address of tx queue.
29 void ull_tx_q_pause_data(struct ull_tx_q *queue);
32 * @brief Resume the data path of a tx queue
34 * @param ull_tx_q Address of tx queue.
36 void ull_tx_q_resume_data(struct ull_tx_q *queue);
[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/samples/arch/smp/pktqueue/src/
Dpktqueue.c9 /* Put a packet header in a queue defined in argument */
10 void phdr_desc_enqueue(struct phdr_desc_queue *queue, struct phdr_desc *desc, in phdr_desc_enqueue() argument
13 /* Locking queue */ in phdr_desc_enqueue()
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()
25 /* Unlocking queue */ in phdr_desc_enqueue()
29 /* Take a packet header from queue defined in argument */
[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/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/include/zephyr/sys/
Dp4wq.h17 * P4 Queue handler callback
22 * @brief P4 Queue Work Item
43 struct k_p4wq *queue; member
51 * @brief P4 Queue
53 * Kernel pooled parallel preemptible priority-based work queue
70 struct rbtree queue; member
82 struct k_p4wq *queue; member
89 * @brief Statically initialize a P4 Work Queue
96 * @param n_threads Number of threads in the work queue pool
110 .queue = &name, \
[all …]
Dmpsc_lockfree.h21 * @brief Multiple Producer Single Consumer (MPSC) Lockfree Queue API
22 * @defgroup mpsc_lockfree MPSC Lockfree Queue API
30 * @brief A wait-free intrusive multi producer single consumer (MPSC) queue using
33 * Based on the well known and widely used wait-free MPSC queue described by
38 * An MPSC queue is safe to produce or consume in an ISR with O(1) push/pop.
77 * @brief Queue member
84 * @brief MPSC Queue
93 * @brief Static initializer for a mpsc queue
95 * Since the queue is
97 * @param symbol name of the queue
[all …]
/Zephyr-latest/include/zephyr/tracing/
Dtracing.h322 * @brief Trace submit work to work queue call entry
323 * @param queue Work queue structure
326 #define sys_port_trace_k_work_submit_to_queue_enter(queue, work) argument
329 * @brief Trace submit work to work queue call exit
330 * @param queue Work queue structure
334 #define sys_port_trace_k_work_submit_to_queue_exit(queue, work, ret) argument
337 * @brief Trace submit work to system work queue call entry
343 * @brief Trace submit work to system work queue call exit
407 * @brief Work Queue Tracing APIs
408 * @defgroup subsys_tracing_apis_work_q Work Queue Tracing APIs
[all …]
/Zephyr-latest/tests/kernel/queue/src/
Dtest_queue_contexts.c17 struct k_queue queue; variable
40 /**TESTPOINT: queue append */ in tqueue_append()
45 /**TESTPOINT: queue prepend */ in tqueue_append()
49 /**TESTPOINT: queue append list*/ in tqueue_append()
56 /**TESTPOINT: queue merge slist*/ in tqueue_append()
69 /*get queue data from "queue_prepend"*/ in tqueue_get()
71 /**TESTPOINT: queue get*/ in tqueue_get()
75 /*get queue data from "queue_append"*/ in tqueue_get()
77 /**TESTPOINT: queue get*/ in tqueue_get()
81 /*get queue data from "queue_append_list"*/ in tqueue_get()
[all …]
Dtest_queue_loop.c16 static struct k_queue queue; variable
23 /**TESTPOINT: queue append*/ in tqueue_append()
28 /**TESTPOINT: queue prepend*/ in tqueue_append()
33 /**TESTPOINT: queue find and remove*/ in tqueue_append()
43 /*get queue data from "queue_prepend"*/ in tqueue_get()
45 /**TESTPOINT: queue get*/ in tqueue_get()
50 /*get queue data from "queue_append"*/ in tqueue_get()
52 /**TESTPOINT: queue get*/ in tqueue_get()
60 /*remove queue data from "queue_find_and_remove"*/ in tqueue_find_and_remove()
62 /**TESTPOINT: queue find and remove*/ in tqueue_find_and_remove()
[all …]
Dtest_queue_fail.c25 static struct k_queue queue; in ZTEST() local
27 k_queue_init(&queue); in ZTEST()
28 /**TESTPOINT: queue get returns NULL*/ 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()
38 /* wait the queue for data */ in tThread_entry()
52 * 3. Verify that append list to the queue when a
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()
[all …]
/Zephyr-latest/subsys/bluetooth/controller/util/
Dmemq.c9 * FIFO-style "memory queue" permitting enqueue at tail and dequeue from head.
15 * For a queue to be valid, it must be initialized with an initial link-element.
44 * @brief Initialize a memory queue to be empty and valid.
47 * @param head[out] Head of queue. Will be updated
48 * @param tail[out] Tail of queue. Will be updated
53 /* Head and tail pointer to the initial link - forms an empty queue */ in memq_init()
60 * @brief De-initialize a memory queue to be empty and invalid.
62 * @param head[in,out] Head of queue. Will be updated
63 * @param tail[in,out] Tail of queue. Will be updated
64 * @return Head of queue before invalidation; NULL if queue was empty
[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/tests/posix/common/src/
Dmqueue.c19 static char queue[16] = "server"; variable
37 mqd = mq_open(queue, O_WRONLY); in sender_thread()
44 "unable to close message queue descriptor."); in sender_thread()
55 mqd = mq_open(queue, O_RDONLY); in receiver_thread()
63 "unable to close message queue descriptor."); in receiver_thread()
80 mqd = mq_open(queue, flags, mode, &attrs); in ZTEST()
95 "unable to close message queue descriptor."); 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()
112 zassert_ok(mq_close(mqd), "Unable to close message queue descriptor."); in notify_function_basic()
[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/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 …]
/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/tests/benchmarks/wait_queues/
DREADME.rst1 Wait Queue Measurements
4 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
/Zephyr-latest/samples/subsys/zbus/work_queue/
DREADME.rst1 .. zephyr:code-sample:: zbus-work-queue
2 :name: Work queue
5 Use a work queue to process zbus messages in various ways.
9 …listener callback. It can schedule a job, pushing that to the system work queue. Last, it can wait…
31 I: Sensor msg processed by WORK QUEUE handler dh1: temp = 10, press = 1, humidity = 100
32 I: Sensor msg processed by WORK QUEUE handler dh2: temp = 10, press = 1, humidity = 100
33 I: Sensor msg processed by WORK QUEUE handler dh3: temp = 10, press = 1, humidity = 100
40 I: Sensor msg processed by WORK QUEUE handler dh1: temp = 20, press = 2, humidity = 200
41 I: Sensor msg processed by WORK QUEUE handler dh2: temp = 20, press = 2, humidity = 200
42 I: Sensor msg processed by WORK QUEUE handler dh3: temp = 20, press = 2, humidity = 200
[all …]
/Zephyr-latest/tests/bluetooth/controller/ctrl_tx_queue/src/
Dmain.c39 /* Tx Queue shall be empty */ in ZTEST()
47 * Verify Tx Queue is empty.
68 /* Tx Queue shall be empty */ in ZTEST()
76 * Verify Tx Queue is empty.
97 /* Tx Queue shall be empty */ in ZTEST()
105 * Verify Tx Queue is empty.
131 /* Tx Queue shall be empty */ in ZTEST()
138 * Pause Tx Queue.
141 * Verify Tx Queue is empty.
159 /* Pause Tx Queue */ in ZTEST()
[all …]
/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
254 /* Set Receive Buffer Queue Pointer Register */ in set_receive_buf_queue_pointer()
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()
[all …]

12345678910>>...27