/nrf52832-nimble/rt-thread/components/drivers/src/ |
H A D | dataqueue.c | 23 rt_data_queue_init(struct rt_data_queue *queue, in rt_data_queue_init() argument 26 void (*evt_notify)(struct rt_data_queue *queue, rt_uint32_t event)) in rt_data_queue_init() argument 28 RT_ASSERT(queue != RT_NULL); in rt_data_queue_init() 30 queue->evt_notify = evt_notify; in rt_data_queue_init() 32 queue->size = size; in rt_data_queue_init() 33 queue->lwm = lwm; in rt_data_queue_init() 35 queue->get_index = 0; in rt_data_queue_init() 36 queue->put_index = 0; in rt_data_queue_init() 38 rt_list_init(&(queue->suspended_push_list)); in rt_data_queue_init() 39 rt_list_init(&(queue->suspended_pop_list)); in rt_data_queue_init() [all …]
|
H A D | workqueue.c | 16 rt_inline rt_err_t _workqueue_work_completion(struct rt_workqueue *queue) in _workqueue_work_completion() argument 24 result = rt_sem_trytake(&(queue->sem)); in _workqueue_work_completion() 28 rt_sem_release(&(queue->sem)); in _workqueue_work_completion() 51 struct rt_workqueue* queue; in _workqueue_thread_entry() local 53 queue = (struct rt_workqueue*) parameter; in _workqueue_thread_entry() 54 RT_ASSERT(queue != RT_NULL); in _workqueue_thread_entry() 58 if (rt_list_isempty(&(queue->work_list))) in _workqueue_thread_entry() 67 work = rt_list_entry(queue->work_list.next, struct rt_work, list); in _workqueue_thread_entry() 69 queue->work_current = work; in _workqueue_thread_entry() 76 queue->work_current = RT_NULL; in _workqueue_thread_entry() [all …]
|
H A D | waitqueue.c | 8 * 2018/06/26 Bernard Fix the wait queue issue when wakeup a soon 18 void rt_wqueue_add(rt_wqueue_t *queue, struct rt_wqueue_node *node) in rt_wqueue_add() argument 23 rt_list_insert_before(&(queue->waiting_list), &(node->list)); in rt_wqueue_add() 41 void rt_wqueue_wakeup(rt_wqueue_t *queue, void *key) in rt_wqueue_wakeup() argument 50 queue_list = &(queue->waiting_list); in rt_wqueue_wakeup() 53 /* set wakeup flag in the queue */ in rt_wqueue_wakeup() 54 queue->flag = RT_WQ_FLAG_WAKEUP; in rt_wqueue_wakeup() 77 int rt_wqueue_wait(rt_wqueue_t *queue, int condition, int msec) in rt_wqueue_wait() argument 99 if (queue->flag == RT_WQ_FLAG_WAKEUP) in rt_wqueue_wait() 105 rt_wqueue_add(queue, &__wait); in rt_wqueue_wait() [all …]
|
H A D | ringblk_buf.c | 340 * get a continuous block to queue by given size 357 * @param queue_data_len The max queue data size, and the return size must less then it. 358 * @param queue continuous block queue 360 * @return the block queue data total size 384 /* save the first put status block to queue */ in rt_rbb_blk_queue_get() 427 * get all block length on block queue 429 * @param blk_queue the block queue 449 * return the block queue buffer 451 * @param blk_queue the block queue 453 * @return block queue buffer [all …]
|
/nrf52832-nimble/rt-thread/components/drivers/include/ipc/ |
H A D | dataqueue.h | 22 /* data queue implementation */ 32 struct rt_data_item *queue; member 38 void (*evt_notify)(struct rt_data_queue *queue, rt_uint32_t event); 44 rt_err_t rt_data_queue_init(struct rt_data_queue *queue, 47 void (*evt_notify)(struct rt_data_queue *queue, rt_uint32_t event)); 48 rt_err_t rt_data_queue_push(struct rt_data_queue *queue, 52 rt_err_t rt_data_queue_pop(struct rt_data_queue *queue, 56 rt_err_t rt_data_queue_peak(struct rt_data_queue *queue, 59 void rt_data_queue_reset(struct rt_data_queue *queue);
|
H A D | waitqueue.h | 8 * 2018/06/26 Bernard Fix the wait queue issue when wakeup a soon 35 rt_inline void rt_wqueue_init(rt_wqueue_t *queue) in rt_wqueue_init() argument 37 RT_ASSERT(queue != RT_NULL); in rt_wqueue_init() 39 queue->flag = RT_WQ_FLAG_CLEAN; in rt_wqueue_init() 40 rt_list_init(&(queue->waiting_list)); in rt_wqueue_init() 43 void rt_wqueue_add(rt_wqueue_t *queue, struct rt_wqueue_node *node); 45 int rt_wqueue_wait(rt_wqueue_t *queue, int condition, int timeout); 46 void rt_wqueue_wakeup(rt_wqueue_t *queue, void *key);
|
H A D | workqueue.h | 37 rt_err_t rt_workqueue_destroy(struct rt_workqueue* queue); 38 rt_err_t rt_workqueue_dowork(struct rt_workqueue* queue, struct rt_work* work); 39 rt_err_t rt_workqueue_cancel_work(struct rt_workqueue* queue, struct rt_work* work); 40 rt_err_t rt_workqueue_cancel_work_sync(struct rt_workqueue* queue, struct rt_work* work);
|
/nrf52832-nimble/rt-thread/components/cplusplus/ |
H A D | Queue.h | 21 * The Queue class allow to control, send, receive, or wait for messages. 25 * @param queue_sz maximum number of messages in queue. 28 class Queue 31 /** Create and initialise a message Queue. */ 32 Queue() in Queue() function 37 ~Queue() in ~Queue() 42 /** Put a message in a Queue. 52 /** Get a message or Wait for a message from a Queue.
|
H A D | Mail.h | 24 * @param queue_sz maximum number of messages in queue. 30 /** Create and Initialise Mail queue. */ 41 /** Put a mail in the queue. 57 /** Get a mail from a queue.
|
/nrf52832-nimble/rt-thread/components/CMSIS/RTOS/ |
H A D | cmsis_os.h | 205 /// Message ID identifies the message queue (pointer to a message queue control block). 209 /// Mail ID identifies the mail queue (pointer to a mail queue control block). 256 /// Definition structure for message queue 265 /// Definition structure for mail queue 606 // ==== Message Queue Management Functions ==== 610 /// \brief Create a Message Queue Definition. 611 /// \param name name of the queue. 612 /// \param queue_sz maximum number of messages in the queue. 625 /// \brief Access a Message Queue Definition. 626 /// \param name name of the queue [all …]
|
H A D | cmsis_rtthread.c | 289 // Message Queue Management Public API 291 /// Create and Initialize Message Queue 297 /// Put a Message to a Queue 310 /// Get a Message or Wait for a Message from a Queue 332 // Mail Queue Management Public API 334 /// Create and Initialize mail queue 358 /// Put a mail to a queue 364 /// Get a mail from a queue
|
/nrf52832-nimble/rt-thread/components/drivers/audio/ |
H A D | audio.c | 38 //check repaly queue is empty in _audio_send_replay_frame() 39 if (rt_data_queue_peak(&audio->replay->queue, &frame.data_ptr, &frame.data_size) != RT_EOK) in _audio_send_replay_frame() 41 AUDIO_DBG("TX queue is empty\n"); in _audio_send_replay_frame() 63 rt_data_queue_pop(&audio->replay->queue, &frame.data_ptr, &frame.data_size, RT_WAITING_FOREVER); in _audio_send_replay_frame() 74 while (rt_data_queue_peak(&audio->replay->queue, &frame.data_ptr, &frame.data_size) == RT_EOK) in _audio_flush_replay_frame() 77 … rt_data_queue_pop(&audio->replay->queue, &frame.data_ptr, &frame.data_size, RT_WAITING_FOREVER); in _audio_flush_replay_frame() 136 //init queue for audio replay in _audio_dev_open() 137 …rt_data_queue_init(&replay->queue, CFG_AUDIO_REPLAY_QUEUE_COUNT, CFG_AUDIO_REPLAY_QUEUE_COUNT / 2,… in _audio_dev_open() 207 … while (rt_data_queue_peak(&audio->replay->queue, &frame.data_ptr, &frame.data_size) == RT_EOK) in _audio_dev_close() 210 … rt_data_queue_pop(&audio->replay->queue, &frame.data_ptr, &frame.data_size, RT_WAITING_FOREVER); in _audio_dev_close() [all …]
|
/nrf52832-nimble/packages/NimBLE-latest/porting/nimble/include/os/ |
H A D | queue.h | 29 * @(#)queue.h 8.5 (Berkeley) 8/20/94 30 * $FreeBSD: src/sys/sys/queue.h,v 1.32.2.7 2002/04/17 14:21:02 des Exp $ 52 * implementing a LIFO queue. 54 * A singly-linked tail queue is headed by a pair of pointers, one to the 59 * end of the list. Elements being removed from the head of the tail queue 61 * A singly-linked tail queue may only be traversed in the forward direction. 63 * and few or no removals or for implementing a FIFO queue. 72 * A tail queue is headed by a pair of pointers, one to the head of the 77 * the list. A tail queue may be traversed in either direction. 79 * A circle queue is headed by a pair of pointers, one to the head of the [all …]
|
H A D | os_mbuf.h | 111 * Structure representing a queue of mbufs. 115 /** Event to post when new buffers are available on the queue. */ 241 * Initializes an mqueue. An mqueue is a queue of mbufs that ties to a 242 * particular task's event queue. Mqueues form a helper API around a common 243 * paradigm: wait on an event queue until at least one packet is available, 244 * then process a queue of packets. 246 * When mbufs are available on the queue, an event OS_EVENT_T_MQUEUE_DATA 247 * will be posted to the task's mbuf queue. 260 * Remove and return a single mbuf from the mbuf queue. Does not block. 262 * @param mq The mbuf queue to pull an element off of. [all …]
|
/nrf52832-nimble/rt-thread/src/ |
H A D | ipc.c | 13 * 2006-05-12 Bernard implement mailbox and message queue 19 * 2006-06-07 Bernard fix the message queue send bug 33 * 2011-12-18 Bernard add more parameter checking in message queue 70 * double-queue object (mailbox etc.) contains this kind of list. 126 * - remove the thread from suspend queue of IPC object 127 * - put the thread into system ready queue 1766 * This function will initialize a message queue and put it under control of 1770 * @param name the name of message queue 1774 * @param flag the flag of message queue 1829 * This function will detach a message queue object from resource management [all …]
|
H A D | scheduler.c | 24 * 2018-11-22 Jesven remove the current task from ready queue 25 * add per cpu ready queue 27 * rt_schedule_insert_thread won't insert current task to ready queue 123 * get the highest priority thread in ready queue 303 * with the highest priority level in global ready queue or local ready queue, 415 /* need_insert_from_thread: need to insert from_thread to ready queue */ in rt_schedule() 580 * This function will insert a thread to system ready queue. The state of 581 * thread will be set as READY and remove from suspend queue. 606 /* READY thread, insert to ready queue */ in rt_schedule_insert_thread() 668 /* READY thread, insert to ready queue */ in rt_schedule_insert_thread() [all …]
|
/nrf52832-nimble/rt-thread/tools/ |
H A D | win32spawn.py | 27 import Queue 40 self.queue = Queue.Queue() 114 return self.queue.get(block=block, timeout=timeout) 117 return self.queue.qsize() 167 self.queue.put_nowait(data)
|
/nrf52832-nimble/packages/NimBLE-latest/nimble/host/mesh/src/ |
H A D | friend.c | 32 * to resend the last sent PDU, which sits separately outside of the queue. 87 buf = net_buf_slist_get(&frnd->queue); in discard_buffer() 178 while (!net_buf_slist_is_empty(&frnd->queue)) { in friend_clear() 179 net_buf_unref(net_buf_slist_get(&frnd->queue)); in friend_clear() 185 while (!net_buf_slist_is_empty(&seg->queue)) { in friend_clear() 186 net_buf_unref(net_buf_slist_get(&seg->queue)); in friend_clear() 540 net_buf_slist_put(&frnd->queue, buf); in enqueue_buf() 604 if (net_buf_slist_is_empty(&frnd->queue)) { in bt_mesh_friend_poll() 606 BT_DBG("Enqueued Friend Update to empty queue"); in bt_mesh_friend_poll() 835 BT_WARN("Prohibited Minimum Queue Size in Friend Request"); in bt_mesh_friend_req() [all …]
|
/nrf52832-nimble/rt-thread/components/net/lwip-1.4.1/src/core/ |
H A D | tcp_out.c | 321 LWIP_DEBUGF(TCP_OUTPUT_DEBUG | 3, ("tcp_write: too long queue %"U16_F" (max %"U16_F")\n", in tcp_write_checks() 328 LWIP_ASSERT("tcp_write: pbufs on queue => at least one queue non-empty", in tcp_write_checks() 331 LWIP_ASSERT("tcp_write: no pbufs on queue => both queues empty", in tcp_write_checks() 357 struct tcp_seg *last_unsent = NULL, *seg = NULL, *prev_seg = NULL, *queue = NULL; in tcp_write() local 421 /* Find the tail of the unsent queue. */ in tcp_write() 519 * The new segments are chained together in the local 'queue' in tcp_write() 535 …loc(PBUF_TRANSPORT, seglen + optlen, mss_local, &oversize, pcb, apiflags, queue == NULL)) == NULL)… in tcp_write() 578 * length of the queue exceeds the configured maximum or in tcp_write() 581 …LWIP_DEBUGF(TCP_OUTPUT_DEBUG | 2, ("tcp_write: queue too long %"U16_F" (%"U16_F")\n", queuelen, TC… in tcp_write() 599 if (queue == NULL) { in tcp_write() [all …]
|
/nrf52832-nimble/rt-thread/components/net/lwip-2.0.2/src/core/ |
H A D | tcp_out.c | 334 …LWIP_DEBUGF(TCP_OUTPUT_DEBUG | LWIP_DBG_LEVEL_SEVERE, ("tcp_write: too long queue %"U16_F" (max %"… in tcp_write_checks() 341 LWIP_ASSERT("tcp_write: pbufs on queue => at least one queue non-empty", in tcp_write_checks() 344 LWIP_ASSERT("tcp_write: no pbufs on queue => both queues empty", in tcp_write_checks() 371 struct tcp_seg *last_unsent = NULL, *seg = NULL, *prev_seg = NULL, *queue = NULL; in tcp_write() local 444 /* Find the tail of the unsent queue. */ in tcp_write() 556 * The new segments are chained together in the local 'queue' in tcp_write() 572 …loc(PBUF_TRANSPORT, seglen + optlen, mss_local, &oversize, pcb, apiflags, queue == NULL)) == NULL)… in tcp_write() 619 * length of the queue exceeds the configured maximum or in tcp_write() 622 …LWIP_DEBUGF(TCP_OUTPUT_DEBUG | LWIP_DBG_LEVEL_SERIOUS, ("tcp_write: queue too long %"U16_F" (%d)\n… in tcp_write() 641 if (queue == NULL) { in tcp_write() [all …]
|
/nrf52832-nimble/rt-thread/components/net/lwip-2.0.2/src/core/ipv4/ |
H A D | etharp.c | 93 /** Pointer to queue of pending outgoing packets on this ARP entry. */ 143 * Free a complete queue of etharp entries 174 /* and empty packet queue */ in etharp_free_entry() 177 …LWIP_DEBUGF(ETHARP_DEBUG, ("etharp_free_entry: freeing entry %"U16_F", packet queue %p.\n", (u16_t… in etharp_free_entry() 263 /* oldest entry with packets on queue */ in etharp_find_entry() 372 …TRACE, ("etharp_find_entry: selecting oldest pending entry %"U16_F" (without queue)\n", (u16_t)i)); in etharp_find_entry() 377 …tharp_find_entry: selecting oldest pending entry %"U16_F", freeing packet queue %p\n", (u16_t)i, (… in etharp_find_entry() 474 /* remember remainder of queue */ 476 /* pop first item off the queue */ 480 /* now queue entry can be freed */ [all …]
|
/nrf52832-nimble/rt-thread/components/net/lwip-2.1.0/src/core/ipv4/ |
H A D | etharp.c | 92 /** Pointer to queue of pending outgoing packets on this ARP entry. */ 142 * Free a complete queue of etharp entries 172 /* and empty packet queue */ in etharp_free_entry() 175 …LWIP_DEBUGF(ETHARP_DEBUG, ("etharp_free_entry: freeing entry %"U16_F", packet queue %p.\n", (u16_t… in etharp_free_entry() 261 /* oldest entry with packets on queue */ in etharp_find_entry() 370 …WIP_DBG_TRACE, ("etharp_find_entry: selecting oldest pending entry %d (without queue)\n", (int)i)); in etharp_find_entry() 375 …E, ("etharp_find_entry: selecting oldest pending entry %d, freeing packet queue %p\n", (int)i, (vo… in etharp_find_entry() 472 /* remember remainder of queue */ 474 /* pop first item off the queue */ 478 /* now queue entry can be freed */ [all …]
|
/nrf52832-nimble/rt-thread/components/net/lwip-2.1.0/src/core/ |
H A D | tcp_out.c | 334 …LWIP_DEBUGF(TCP_OUTPUT_DEBUG | LWIP_DBG_LEVEL_SEVERE, ("tcp_write: too long queue %"U16_F" (max %"… in tcp_write_checks() 341 LWIP_ASSERT("tcp_write: pbufs on queue => at least one queue non-empty", in tcp_write_checks() 344 LWIP_ASSERT("tcp_write: no pbufs on queue => both queues empty", in tcp_write_checks() 372 * the queue of outgoing segment is larger than the upper limit defined 373 * in lwipopts.h. The number of bytes available in the output queue can 393 struct tcp_seg *last_unsent = NULL, *seg = NULL, *prev_seg = NULL, *queue = NULL; in tcp_write() local 475 /* Find the tail of the unsent queue. */ in tcp_write() 594 * The new segments are chained together in the local 'queue' in tcp_write() 610 …loc(PBUF_TRANSPORT, seglen + optlen, mss_local, &oversize, pcb, apiflags, queue == NULL)) == NULL)… in tcp_write() 657 * length of the queue exceeds the configured maximum or in tcp_write() [all …]
|
/nrf52832-nimble/rt-thread/components/net/lwip-2.0.2/doc/ |
H A D | NO_SYS_SampleCode.c | 12 /* Put in a queue which is processed in main loop */ in eth_mac_irq() 13 if(!queue_try_put(&queue, p)) { in eth_mac_irq() 14 /* queue is full -> packet loss */ in eth_mac_irq() 92 struct pbuf* p = queue_try_get(&queue); in main()
|
/nrf52832-nimble/rt-thread/components/net/lwip-2.1.0/doc/ |
H A D | NO_SYS_SampleCode.c | 13 /* Put in a queue which is processed in main loop */ in eth_mac_irq() 14 if(!queue_try_put(&queue, p)) { in eth_mac_irq() 15 /* queue is full -> packet loss */ in eth_mac_irq() 97 struct pbuf* p = queue_try_get(&queue); in main()
|