Lines Matching full:if
41 #if ( configUSE_CO_ROUTINES == 1 )
60 * structure instead holds a pointer to the mutex holder (if any). Map alternative
85 #if ( configUSE_PREEMPTION == 0 )
87 /* If the cooperative scheduler is being used then a yield should not be
91 #if ( configNUMBER_OF_CORES == 1 )
93 #else /* #if ( configNUMBER_OF_CORES == 1 ) */
95 #endif /* #if ( configNUMBER_OF_CORES == 1 ) */
124 #if ( ( configSUPPORT_STATIC_ALLOCATION == 1 ) && ( configSUPPORT_DYNAMIC_ALLOCATION == 1 ) )
125 …uint8_t ucStaticallyAllocated; /**< Set to pdTRUE if the memory used by the queue was statically a…
128 #if ( configUSE_QUEUE_SETS == 1 )
132 #if ( configUSE_TRACE_FACILITY == 1 )
148 #if ( configQUEUE_REGISTRY_SIZE > 0 )
178 * an ISR from removing tasks from the queue event lists. If an ISR finds a
186 * Uses a critical section to determine if there is any data in a queue.
188 * @return pdTRUE if the queue contains no items, otherwise pdFALSE.
193 * Uses a critical section to determine if there is any space in a queue.
195 * @return pdTRUE if there is no space, otherwise pdFALSE;
213 #if ( configUSE_QUEUE_SETS == 1 )
216 * Checks to see if a queue is a member of a queue set, and if so, notifies
237 #if ( configUSE_MUTEXES == 1 )
241 #if ( configUSE_MUTEXES == 1 )
244 * If a task waiting for a mutex causes the mutex holder to inherit a
261 if( ( pxQueue )->cRxLock == queueUNLOCKED ) \
265 if( ( pxQueue )->cTxLock == queueUNLOCKED ) \
280 if( ( UBaseType_t ) ( cTxLock ) < uxNumberOfTasks ) \
295 if( ( UBaseType_t ) ( cRxLock ) < uxNumberOfTasks ) \
313 if( ( pxQueue != NULL ) && in xQueueGenericReset()
327 if( xNewQueue == pdFALSE ) in xQueueGenericReset()
329 /* If there are tasks blocked waiting to read from the queue, then in xQueueGenericReset()
331 * will still be empty. If there are tasks blocked waiting to write to in xQueueGenericReset()
334 if( listLIST_IS_EMPTY( &( pxQueue->xTasksWaitingToSend ) ) == pdFALSE ) in xQueueGenericReset()
336 if( xTaskRemoveFromEventList( &( pxQueue->xTasksWaitingToSend ) ) != pdFALSE ) in xQueueGenericReset()
374 #if ( configSUPPORT_STATIC_ALLOCATION == 1 )
390 if( ( uxQueueLength > ( UBaseType_t ) 0 ) && in xQueueGenericCreateStatic()
393 /* A queue storage area should be provided if the item size is not 0, and in xQueueGenericCreateStatic()
394 * should not be provided if the item size is 0. */ in xQueueGenericCreateStatic()
398 #if ( configASSERT_DEFINED == 1 ) in xQueueGenericCreateStatic()
419 #if ( configSUPPORT_DYNAMIC_ALLOCATION == 1 ) in xQueueGenericCreateStatic()
444 #if ( configSUPPORT_STATIC_ALLOCATION == 1 )
458 #if ( configSUPPORT_DYNAMIC_ALLOCATION == 1 ) in xQueueGenericGetStaticBuffers()
460 /* Check if the queue was statically allocated. */ in xQueueGenericGetStaticBuffers()
461 if( pxQueue->ucStaticallyAllocated == ( uint8_t ) pdTRUE ) in xQueueGenericGetStaticBuffers()
463 if( ppucQueueStorage != NULL ) in xQueueGenericGetStaticBuffers()
482 if( ppucQueueStorage != NULL ) in xQueueGenericGetStaticBuffers()
500 #if ( configSUPPORT_DYNAMIC_ALLOCATION == 1 )
512 if( ( uxQueueLength > ( UBaseType_t ) 0 ) && in xQueueGenericCreate()
528 if( pxNewQueue != NULL ) in xQueueGenericCreate()
535 #if ( configSUPPORT_STATIC_ALLOCATION == 1 ) in xQueueGenericCreate()
576 if( uxItemSize == ( UBaseType_t ) 0 ) in prvInitialiseNewQueue()
596 #if ( configUSE_TRACE_FACILITY == 1 ) in prvInitialiseNewQueue()
602 #if ( configUSE_QUEUE_SETS == 1 ) in prvInitialiseNewQueue()
612 #if ( configUSE_MUTEXES == 1 )
616 if( pxNewQueue != NULL ) in prvInitialiseMutex()
642 #if ( ( configUSE_MUTEXES == 1 ) && ( configSUPPORT_DYNAMIC_ALLOCATION == 1 ) )
662 #if ( ( configUSE_MUTEXES == 1 ) && ( configSUPPORT_STATIC_ALLOCATION == 1 ) )
672 /* Prevent compiler warnings about unused parameters if in xQueueCreateMutexStatic()
687 #if ( ( configUSE_MUTEXES == 1 ) && ( INCLUDE_xSemaphoreGetMutexHolder == 1 ) )
699 * be called directly. Note: This is a good way of determining if the in xQueueGetMutexHolder()
705 if( pxSemaphore->uxQueueType == queueQUEUE_IS_MUTEX ) in xQueueGetMutexHolder()
721 #endif /* if ( ( configUSE_MUTEXES == 1 ) && ( INCLUDE_xSemaphoreGetMutexHolder == 1 ) ) */
724 #if ( ( configUSE_MUTEXES == 1 ) && ( INCLUDE_xSemaphoreGetMutexHolder == 1 ) )
737 if( ( ( Queue_t * ) xSemaphore )->uxQueueType == queueQUEUE_IS_MUTEX ) in xQueueGetMutexHolderFromISR()
751 #endif /* if ( ( configUSE_MUTEXES == 1 ) && ( INCLUDE_xSemaphoreGetMutexHolder == 1 ) ) */
754 #if ( configUSE_RECURSIVE_MUTEXES == 1 )
765 /* If this is the task that holds the mutex then xMutexHolder will not in xQueueGiveMutexRecursive()
766 * change outside of this task. If this task does not hold the mutex then in xQueueGiveMutexRecursive()
768 * this is the only condition we are interested in it does not matter if in xQueueGiveMutexRecursive()
771 if( pxMutex->u.xSemaphore.xMutexHolder == xTaskGetCurrentTaskHandle() ) in xQueueGiveMutexRecursive()
775 /* uxRecursiveCallCount cannot be zero if xMutexHolder is equal to in xQueueGiveMutexRecursive()
783 if( pxMutex->u.xSemaphore.uxRecursiveCallCount == ( UBaseType_t ) 0 ) in xQueueGiveMutexRecursive()
813 #if ( configUSE_RECURSIVE_MUTEXES == 1 )
830 if( pxMutex->u.xSemaphore.xMutexHolder == xTaskGetCurrentTaskHandle() ) in xQueueTakeMutexRecursive()
839 /* pdPASS will only be returned if the mutex was successfully in xQueueTakeMutexRecursive()
842 if( xReturn != pdFAIL ) in xQueueTakeMutexRecursive()
860 #if ( ( configUSE_COUNTING_SEMAPHORES == 1 ) && ( configSUPPORT_STATIC_ALLOCATION == 1 ) )
870 if( ( uxMaxCount != 0U ) && in xQueueCreateCountingSemaphoreStatic()
875 if( xHandle != NULL ) in xQueueCreateCountingSemaphoreStatic()
900 #if ( ( configUSE_COUNTING_SEMAPHORES == 1 ) && ( configSUPPORT_DYNAMIC_ALLOCATION == 1 ) )
909 if( ( uxMaxCount != 0U ) && in xQueueCreateCountingSemaphore()
914 if( xHandle != NULL ) in xQueueCreateCountingSemaphore()
953 #if ( ( INCLUDE_xTaskGetSchedulerState == 1 ) || ( configUSE_TIMERS == 1 ) ) in xQueueGenericSend()
964 * highest priority task wanting to access the queue. If the head item in xQueueGenericSend()
965 * in the queue is to be overwritten then it does not matter if the in xQueueGenericSend()
967 … if( ( pxQueue->uxMessagesWaiting < pxQueue->uxLength ) || ( xCopyPosition == queueOVERWRITE ) ) in xQueueGenericSend()
971 #if ( configUSE_QUEUE_SETS == 1 ) in xQueueGenericSend()
977 if( pxQueue->pxQueueSetContainer != NULL ) in xQueueGenericSend()
979 … if( ( xCopyPosition == queueOVERWRITE ) && ( uxPreviousMessagesWaiting != ( UBaseType_t ) 0 ) ) in xQueueGenericSend()
986 else if( prvNotifyQueueSetContainer( pxQueue ) != pdFALSE ) in xQueueGenericSend()
1000 /* If there was a task waiting for data to arrive on the in xQueueGenericSend()
1002 if( listLIST_IS_EMPTY( &( pxQueue->xTasksWaitingToReceive ) ) == pdFALSE ) in xQueueGenericSend()
1004 … if( xTaskRemoveFromEventList( &( pxQueue->xTasksWaitingToReceive ) ) != pdFALSE ) in xQueueGenericSend()
1017 else if( xYieldRequired != pdFALSE ) in xQueueGenericSend()
1020 * executed if the task was holding multiple mutexes in xQueueGenericSend()
1035 /* If there was a task waiting for data to arrive on the in xQueueGenericSend()
1037 if( listLIST_IS_EMPTY( &( pxQueue->xTasksWaitingToReceive ) ) == pdFALSE ) in xQueueGenericSend()
1039 … if( xTaskRemoveFromEventList( &( pxQueue->xTasksWaitingToReceive ) ) != pdFALSE ) in xQueueGenericSend()
1052 else if( xYieldRequired != pdFALSE ) in xQueueGenericSend()
1055 * executed if the task was holding multiple mutexes and in xQueueGenericSend()
1075 if( xTicksToWait == ( TickType_t ) 0 ) in xQueueGenericSend()
1088 else if( xEntryTimeSet == pdFALSE ) in xQueueGenericSend()
1110 /* Update the timeout state to see if it has expired yet. */ in xQueueGenericSend()
1111 if( xTaskCheckForTimeOut( &xTimeOut, &xTicksToWait ) == pdFALSE ) in xQueueGenericSend()
1113 if( prvIsQueueFull( pxQueue ) != pdFALSE ) in xQueueGenericSend()
1130 if( xTaskResumeAll() == pdFALSE ) in xQueueGenericSend()
1176 * FreeRTOS API functions. If configASSERT() is defined in FreeRTOSConfig.h in xQueueGenericSendFromISR()
1178 * failure if a FreeRTOS API function is called from an interrupt that has been in xQueueGenericSendFromISR()
1188 /* Similar to xQueueGenericSend, except without blocking if there is no room in xQueueGenericSendFromISR()
1195 … if( ( pxQueue->uxMessagesWaiting < pxQueue->uxLength ) || ( xCopyPosition == queueOVERWRITE ) ) in xQueueGenericSendFromISR()
1205 * called here even though the disinherit function does not check if in xQueueGenericSendFromISR()
1209 /* The event list is not altered if the queue is locked. This will in xQueueGenericSendFromISR()
1211 if( cTxLock == queueUNLOCKED ) in xQueueGenericSendFromISR()
1213 #if ( configUSE_QUEUE_SETS == 1 ) in xQueueGenericSendFromISR()
1215 if( pxQueue->pxQueueSetContainer != NULL ) in xQueueGenericSendFromISR()
1217 … if( ( xCopyPosition == queueOVERWRITE ) && ( uxPreviousMessagesWaiting != ( UBaseType_t ) 0 ) ) in xQueueGenericSendFromISR()
1224 else if( prvNotifyQueueSetContainer( pxQueue ) != pdFALSE ) in xQueueGenericSendFromISR()
1229 if( pxHigherPriorityTaskWoken != NULL ) in xQueueGenericSendFromISR()
1245 if( listLIST_IS_EMPTY( &( pxQueue->xTasksWaitingToReceive ) ) == pdFALSE ) in xQueueGenericSendFromISR()
1247 … if( xTaskRemoveFromEventList( &( pxQueue->xTasksWaitingToReceive ) ) != pdFALSE ) in xQueueGenericSendFromISR()
1251 if( pxHigherPriorityTaskWoken != NULL ) in xQueueGenericSendFromISR()
1273 if( listLIST_IS_EMPTY( &( pxQueue->xTasksWaitingToReceive ) ) == pdFALSE ) in xQueueGenericSendFromISR()
1275 … if( xTaskRemoveFromEventList( &( pxQueue->xTasksWaitingToReceive ) ) != pdFALSE ) in xQueueGenericSendFromISR()
1279 if( pxHigherPriorityTaskWoken != NULL ) in xQueueGenericSendFromISR()
1344 * if the item size is not 0. */ in xQueueGiveFromISR()
1347 /* Normally a mutex would not be given from an interrupt, especially if in xQueueGiveFromISR()
1356 * FreeRTOS API functions. If configASSERT() is defined in FreeRTOSConfig.h in xQueueGiveFromISR()
1358 * failure if a FreeRTOS API function is called from an interrupt that has been in xQueueGiveFromISR()
1373 * moved through the queue but it is still valid to see if the queue 'has in xQueueGiveFromISR()
1375 if( uxMessagesWaiting < pxQueue->uxLength ) in xQueueGiveFromISR()
1381 /* A task can only have an inherited priority if it is a mutex in xQueueGiveFromISR()
1382 * holder - and if there is a mutex holder then the mutex cannot be in xQueueGiveFromISR()
1384 * can be assumed there is no mutex holder and no need to determine if in xQueueGiveFromISR()
1389 /* The event list is not altered if the queue is locked. This will in xQueueGiveFromISR()
1391 if( cTxLock == queueUNLOCKED ) in xQueueGiveFromISR()
1393 #if ( configUSE_QUEUE_SETS == 1 ) in xQueueGiveFromISR()
1395 if( pxQueue->pxQueueSetContainer != NULL ) in xQueueGiveFromISR()
1397 if( prvNotifyQueueSetContainer( pxQueue ) != pdFALSE ) in xQueueGiveFromISR()
1402 if( pxHigherPriorityTaskWoken != NULL ) in xQueueGiveFromISR()
1418 if( listLIST_IS_EMPTY( &( pxQueue->xTasksWaitingToReceive ) ) == pdFALSE ) in xQueueGiveFromISR()
1420 … if( xTaskRemoveFromEventList( &( pxQueue->xTasksWaitingToReceive ) ) != pdFALSE ) in xQueueGiveFromISR()
1424 if( pxHigherPriorityTaskWoken != NULL ) in xQueueGiveFromISR()
1446 if( listLIST_IS_EMPTY( &( pxQueue->xTasksWaitingToReceive ) ) == pdFALSE ) in xQueueGiveFromISR()
1448 … if( xTaskRemoveFromEventList( &( pxQueue->xTasksWaitingToReceive ) ) != pdFALSE ) in xQueueGiveFromISR()
1452 if( pxHigherPriorityTaskWoken != NULL ) in xQueueGiveFromISR()
1509 /* The buffer into which data is received can only be NULL if the data size in xQueueReceive()
1513 /* Cannot block if the scheduler is suspended. */ in xQueueReceive()
1514 #if ( ( INCLUDE_xTaskGetSchedulerState == 1 ) || ( configUSE_TIMERS == 1 ) ) in xQueueReceive()
1528 if( uxMessagesWaiting > ( UBaseType_t ) 0 ) in xQueueReceive()
1536 * post to the queue? If so, unblock the highest priority waiting in xQueueReceive()
1538 if( listLIST_IS_EMPTY( &( pxQueue->xTasksWaitingToSend ) ) == pdFALSE ) in xQueueReceive()
1540 if( xTaskRemoveFromEventList( &( pxQueue->xTasksWaitingToSend ) ) != pdFALSE ) in xQueueReceive()
1562 if( xTicksToWait == ( TickType_t ) 0 ) in xQueueReceive()
1573 else if( xEntryTimeSet == pdFALSE ) in xQueueReceive()
1595 /* Update the timeout state to see if it has expired yet. */ in xQueueReceive()
1596 if( xTaskCheckForTimeOut( &xTimeOut, &xTicksToWait ) == pdFALSE ) in xQueueReceive()
1598 /* The timeout has not expired. If the queue is still empty place in xQueueReceive()
1600 if( prvIsQueueEmpty( pxQueue ) != pdFALSE ) in xQueueReceive()
1606 if( xTaskResumeAll() == pdFALSE ) in xQueueReceive()
1625 /* Timed out. If there is no data in the queue exit, otherwise loop in xQueueReceive()
1630 if( prvIsQueueEmpty( pxQueue ) != pdFALSE ) in xQueueReceive()
1653 #if ( configUSE_MUTEXES == 1 ) in xQueueSemaphoreTake()
1666 /* Cannot block if the scheduler is suspended. */ in xQueueSemaphoreTake()
1667 #if ( ( INCLUDE_xTaskGetSchedulerState == 1 ) || ( configUSE_TIMERS == 1 ) ) in xQueueSemaphoreTake()
1683 if( uxSemaphoreCount > ( UBaseType_t ) 0 ) in xQueueSemaphoreTake()
1691 #if ( configUSE_MUTEXES == 1 ) in xQueueSemaphoreTake()
1693 if( pxQueue->uxQueueType == queueQUEUE_IS_MUTEX ) in xQueueSemaphoreTake()
1706 /* Check to see if other tasks are blocked waiting to give the in xQueueSemaphoreTake()
1707 * semaphore, and if so, unblock the highest priority such task. */ in xQueueSemaphoreTake()
1708 if( listLIST_IS_EMPTY( &( pxQueue->xTasksWaitingToSend ) ) == pdFALSE ) in xQueueSemaphoreTake()
1710 if( xTaskRemoveFromEventList( &( pxQueue->xTasksWaitingToSend ) ) != pdFALSE ) in xQueueSemaphoreTake()
1732 if( xTicksToWait == ( TickType_t ) 0 ) in xQueueSemaphoreTake()
1743 else if( xEntryTimeSet == pdFALSE ) in xQueueSemaphoreTake()
1765 /* Update the timeout state to see if it has expired yet. */ in xQueueSemaphoreTake()
1766 if( xTaskCheckForTimeOut( &xTimeOut, &xTicksToWait ) == pdFALSE ) in xQueueSemaphoreTake()
1768 /* A block time is specified and not expired. If the semaphore in xQueueSemaphoreTake()
1772 if( prvIsQueueEmpty( pxQueue ) != pdFALSE ) in xQueueSemaphoreTake()
1776 #if ( configUSE_MUTEXES == 1 ) in xQueueSemaphoreTake()
1778 if( pxQueue->uxQueueType == queueQUEUE_IS_MUTEX ) in xQueueSemaphoreTake()
1791 #endif /* if ( configUSE_MUTEXES == 1 ) */ in xQueueSemaphoreTake()
1796 if( xTaskResumeAll() == pdFALSE ) in xQueueSemaphoreTake()
1819 /* If the semaphore count is 0 exit now as the timeout has in xQueueSemaphoreTake()
1823 if( prvIsQueueEmpty( pxQueue ) != pdFALSE ) in xQueueSemaphoreTake()
1825 #if ( configUSE_MUTEXES == 1 ) in xQueueSemaphoreTake()
1827 /* xInheritanceOccurred could only have be set if in xQueueSemaphoreTake()
1830 if( xInheritanceOccurred != pdFALSE ) in xQueueSemaphoreTake()
1885 /* The buffer into which data is received can only be NULL if the data size in xQueuePeek()
1889 /* Cannot block if the scheduler is suspended. */ in xQueuePeek()
1890 #if ( ( INCLUDE_xTaskGetSchedulerState == 1 ) || ( configUSE_TIMERS == 1 ) ) in xQueuePeek()
1904 if( uxMessagesWaiting > ( UBaseType_t ) 0 ) in xQueuePeek()
1917 /* The data is being left in the queue, so see if there are in xQueuePeek()
1919 if( listLIST_IS_EMPTY( &( pxQueue->xTasksWaitingToReceive ) ) == pdFALSE ) in xQueuePeek()
1921 … if( xTaskRemoveFromEventList( &( pxQueue->xTasksWaitingToReceive ) ) != pdFALSE ) in xQueuePeek()
1944 if( xTicksToWait == ( TickType_t ) 0 ) in xQueuePeek()
1955 else if( xEntryTimeSet == pdFALSE ) in xQueuePeek()
1978 /* Update the timeout state to see if it has expired yet. */ in xQueuePeek()
1979 if( xTaskCheckForTimeOut( &xTimeOut, &xTicksToWait ) == pdFALSE ) in xQueuePeek()
1981 /* Timeout has not expired yet, check to see if there is data in the in xQueuePeek()
1982 * queue now, and if not enter the Blocked state to wait for data. */ in xQueuePeek()
1983 if( prvIsQueueEmpty( pxQueue ) != pdFALSE ) in xQueuePeek()
1989 if( xTaskResumeAll() == pdFALSE ) in xQueuePeek()
2008 /* The timeout has expired. If there is still no data in the queue in xQueuePeek()
2013 if( prvIsQueueEmpty( pxQueue ) != pdFALSE ) in xQueuePeek()
2046 * FreeRTOS API functions. If configASSERT() is defined in FreeRTOSConfig.h in xQueueReceiveFromISR()
2048 * failure if a FreeRTOS API function is called from an interrupt that has been in xQueueReceiveFromISR()
2063 if( uxMessagesWaiting > ( UBaseType_t ) 0 ) in xQueueReceiveFromISR()
2072 /* If the queue is locked the event list will not be modified. in xQueueReceiveFromISR()
2076 if( cRxLock == queueUNLOCKED ) in xQueueReceiveFromISR()
2078 if( listLIST_IS_EMPTY( &( pxQueue->xTasksWaitingToSend ) ) == pdFALSE ) in xQueueReceiveFromISR()
2080 if( xTaskRemoveFromEventList( &( pxQueue->xTasksWaitingToSend ) ) != pdFALSE ) in xQueueReceiveFromISR()
2084 if( pxHigherPriorityTaskWoken != NULL ) in xQueueReceiveFromISR()
2144 * FreeRTOS API functions. If configASSERT() is defined in FreeRTOSConfig.h in xQueuePeekFromISR()
2146 * failure if a FreeRTOS API function is called from an interrupt that has been in xQueuePeekFromISR()
2159 if( pxQueue->uxMessagesWaiting > ( UBaseType_t ) 0 ) in xQueuePeekFromISR()
2251 #if ( configQUEUE_REGISTRY_SIZE > 0 ) in vQueueDelete()
2257 #if ( ( configSUPPORT_DYNAMIC_ALLOCATION == 1 ) && ( configSUPPORT_STATIC_ALLOCATION == 0 ) ) in vQueueDelete()
2267 if( pxQueue->ucStaticallyAllocated == ( uint8_t ) pdFALSE ) in vQueueDelete()
2276 …#else /* if ( ( configSUPPORT_DYNAMIC_ALLOCATION == 1 ) && ( configSUPPORT_STATIC_ALLOCATION == 0 … in vQueueDelete()
2288 #if ( configUSE_TRACE_FACILITY == 1 )
2302 #if ( configUSE_TRACE_FACILITY == 1 )
2317 #if ( configUSE_TRACE_FACILITY == 1 )
2351 #if ( configUSE_MUTEXES == 1 )
2357 /* If a task waiting for a mutex causes the mutex holder to inherit a in prvGetDisinheritPriorityAfterTimeout()
2363 if( listCURRENT_LIST_LENGTH( &( pxQueue->xTasksWaitingToReceive ) ) > 0U ) in prvGetDisinheritPriorityAfterTimeout()
2389 if( pxQueue->uxItemSize == ( UBaseType_t ) 0 ) in prvCopyDataToQueue()
2391 #if ( configUSE_MUTEXES == 1 ) in prvCopyDataToQueue()
2393 if( pxQueue->uxQueueType == queueQUEUE_IS_MUTEX ) in prvCopyDataToQueue()
2406 else if( xPosition == queueSEND_TO_BACK ) in prvCopyDataToQueue()
2411 if( pxQueue->pcWriteTo >= pxQueue->u.xQueue.pcTail ) in prvCopyDataToQueue()
2425 if( pxQueue->u.xQueue.pcReadFrom < pxQueue->pcHead ) in prvCopyDataToQueue()
2434 if( xPosition == queueOVERWRITE ) in prvCopyDataToQueue()
2436 if( uxMessagesWaiting > ( UBaseType_t ) 0 ) in prvCopyDataToQueue()
2464 if( pxQueue->uxItemSize != ( UBaseType_t ) 0 ) in prvCopyDataFromQueue()
2468 if( pxQueue->u.xQueue.pcReadFrom >= pxQueue->u.xQueue.pcTail ) in prvCopyDataFromQueue()
2494 /* See if data was added to the queue while it was locked. */ in prvUnlockQueue()
2499 #if ( configUSE_QUEUE_SETS == 1 ) in prvUnlockQueue()
2501 if( pxQueue->pxQueueSetContainer != NULL ) in prvUnlockQueue()
2503 if( prvNotifyQueueSetContainer( pxQueue ) != pdFALSE ) in prvUnlockQueue()
2520 if( listLIST_IS_EMPTY( &( pxQueue->xTasksWaitingToReceive ) ) == pdFALSE ) in prvUnlockQueue()
2522 … if( xTaskRemoveFromEventList( &( pxQueue->xTasksWaitingToReceive ) ) != pdFALSE ) in prvUnlockQueue()
2543 if( listLIST_IS_EMPTY( &( pxQueue->xTasksWaitingToReceive ) ) == pdFALSE ) in prvUnlockQueue()
2545 … if( xTaskRemoveFromEventList( &( pxQueue->xTasksWaitingToReceive ) ) != pdFALSE ) in prvUnlockQueue()
2577 if( listLIST_IS_EMPTY( &( pxQueue->xTasksWaitingToSend ) ) == pdFALSE ) in prvUnlockQueue()
2579 if( xTaskRemoveFromEventList( &( pxQueue->xTasksWaitingToSend ) ) != pdFALSE ) in prvUnlockQueue()
2608 if( pxQueue->uxMessagesWaiting == ( UBaseType_t ) 0 ) in prvIsQueueEmpty()
2632 if( pxQueue->uxMessagesWaiting == ( UBaseType_t ) 0 ) in xQueueIsQueueEmptyFromISR()
2653 if( pxQueue->uxMessagesWaiting == pxQueue->uxLength ) in prvIsQueueFull()
2677 if( pxQueue->uxMessagesWaiting == pxQueue->uxLength ) in xQueueIsQueueFullFromISR()
2692 #if ( configUSE_CO_ROUTINES == 1 )
2703 /* If the queue is already full we may have to block. A critical section in xQueueCRSend()
2705 * between the check to see if the queue is full and blocking on the queue. */ in xQueueCRSend()
2708 if( prvIsQueueFull( pxQueue ) != pdFALSE ) in xQueueCRSend()
2712 if( xTicksToWait > ( TickType_t ) 0 ) in xQueueCRSend()
2731 if( pxQueue->uxMessagesWaiting < pxQueue->uxLength ) in xQueueCRSend()
2738 if( listLIST_IS_EMPTY( &( pxQueue->xTasksWaitingToReceive ) ) == pdFALSE ) in xQueueCRSend()
2742 * Instead the same pending ready list mechanism is used as if in xQueueCRSend()
2744 … if( xCoRoutineRemoveFromEventList( &( pxQueue->xTasksWaitingToReceive ) ) != pdFALSE ) in xQueueCRSend()
2775 #if ( configUSE_CO_ROUTINES == 1 )
2786 /* If the queue is already empty we may have to block. A critical section in xQueueCRReceive()
2788 * between the check to see if the queue is empty and blocking on the queue. */ in xQueueCRReceive()
2791 if( pxQueue->uxMessagesWaiting == ( UBaseType_t ) 0 ) in xQueueCRReceive()
2795 if( xTicksToWait > ( TickType_t ) 0 ) in xQueueCRReceive()
2818 if( pxQueue->uxMessagesWaiting > ( UBaseType_t ) 0 ) in xQueueCRReceive()
2823 if( pxQueue->u.xQueue.pcReadFrom >= pxQueue->u.xQueue.pcTail ) in xQueueCRReceive()
2838 if( listLIST_IS_EMPTY( &( pxQueue->xTasksWaitingToSend ) ) == pdFALSE ) in xQueueCRReceive()
2842 * Instead the same pending ready list mechanism is used as if in xQueueCRReceive()
2844 … if( xCoRoutineRemoveFromEventList( &( pxQueue->xTasksWaitingToSend ) ) != pdFALSE ) in xQueueCRReceive()
2873 #if ( configUSE_CO_ROUTINES == 1 )
2883 /* Cannot block within an ISR so if there is no space on the queue then in xQueueCRSendFromISR()
2885 if( pxQueue->uxMessagesWaiting < pxQueue->uxLength ) in xQueueCRSendFromISR()
2891 if( xCoRoutinePreviouslyWoken == pdFALSE ) in xQueueCRSendFromISR()
2893 if( listLIST_IS_EMPTY( &( pxQueue->xTasksWaitingToReceive ) ) == pdFALSE ) in xQueueCRSendFromISR()
2895 … if( xCoRoutineRemoveFromEventList( &( pxQueue->xTasksWaitingToReceive ) ) != pdFALSE ) in xQueueCRSendFromISR()
2927 #if ( configUSE_CO_ROUTINES == 1 )
2938 /* We cannot block from an ISR, so check there is data available. If in xQueueCRReceiveFromISR()
2940 if( pxQueue->uxMessagesWaiting > ( UBaseType_t ) 0 ) in xQueueCRReceiveFromISR()
2945 if( pxQueue->u.xQueue.pcReadFrom >= pxQueue->u.xQueue.pcTail ) in xQueueCRReceiveFromISR()
2957 if( ( *pxCoRoutineWoken ) == pdFALSE ) in xQueueCRReceiveFromISR()
2959 if( listLIST_IS_EMPTY( &( pxQueue->xTasksWaitingToSend ) ) == pdFALSE ) in xQueueCRReceiveFromISR()
2961 … if( xCoRoutineRemoveFromEventList( &( pxQueue->xTasksWaitingToSend ) ) != pdFALSE ) in xQueueCRReceiveFromISR()
2995 #if ( configQUEUE_REGISTRY_SIZE > 0 )
3007 if( pcQueueName != NULL ) in vQueueAddToRegistry()
3009 /* See if there is an empty space in the registry. A NULL name denotes in vQueueAddToRegistry()
3013 /* Replace an existing entry if the queue is already in the registry. */ in vQueueAddToRegistry()
3014 if( xQueue == xQueueRegistry[ ux ].xHandle ) in vQueueAddToRegistry()
3020 … else if( ( pxEntryToWrite == NULL ) && ( xQueueRegistry[ ux ].pcQueueName == NULL ) ) in vQueueAddToRegistry()
3031 if( pxEntryToWrite != NULL ) in vQueueAddToRegistry()
3046 #if ( configQUEUE_REGISTRY_SIZE > 0 )
3062 if( xQueueRegistry[ ux ].xHandle == xQueue ) in pcQueueGetName()
3081 #if ( configQUEUE_REGISTRY_SIZE > 0 )
3091 /* See if the handle of the queue being unregistered in actually in the in vQueueUnregisterQueue()
3095 if( xQueueRegistry[ ux ].xHandle == xQueue ) in vQueueUnregisterQueue()
3097 /* Set the name to NULL to show that this slot if free again. */ in vQueueUnregisterQueue()
3101 * appear in the registry twice if it is added, removed, then in vQueueUnregisterQueue()
3118 #if ( configUSE_TIMERS == 1 )
3136 /* Only do anything if there are no messages in the queue. This function in vQueueWaitForMessageRestricted()
3139 * time a yield will be performed. If an item is added to the queue while in vQueueWaitForMessageRestricted()
3144 if( pxQueue->uxMessagesWaiting == ( UBaseType_t ) 0U ) in vQueueWaitForMessageRestricted()
3162 #if ( ( configUSE_QUEUE_SETS == 1 ) && ( configSUPPORT_DYNAMIC_ALLOCATION == 1 ) )
3180 #if ( configUSE_QUEUE_SETS == 1 )
3191 if( ( ( Queue_t * ) xQueueOrSemaphore )->pxQueueSetContainer != NULL ) in xQueueAddToSet()
3196 else if( ( ( Queue_t * ) xQueueOrSemaphore )->uxMessagesWaiting != ( UBaseType_t ) 0 ) in xQueueAddToSet()
3198 /* Cannot add a queue/semaphore to a queue set if there are already in xQueueAddToSet()
3218 #if ( configUSE_QUEUE_SETS == 1 )
3228 if( pxQueueOrSemaphore->pxQueueSetContainer != xQueueSet ) in xQueueRemoveFromSet()
3233 else if( pxQueueOrSemaphore->uxMessagesWaiting != ( UBaseType_t ) 0 ) in xQueueRemoveFromSet()
3259 #if ( configUSE_QUEUE_SETS == 1 )
3278 #if ( configUSE_QUEUE_SETS == 1 )
3296 #if ( configUSE_QUEUE_SETS == 1 )
3311 if( pxQueueSetContainer->uxMessagesWaiting < pxQueueSetContainer->uxLength ) in prvNotifyQueueSetContainer()
3320 if( cTxLock == queueUNLOCKED ) in prvNotifyQueueSetContainer()
3322 … if( listLIST_IS_EMPTY( &( pxQueueSetContainer->xTasksWaitingToReceive ) ) == pdFALSE ) in prvNotifyQueueSetContainer()
3324 … if( xTaskRemoveFromEventList( &( pxQueueSetContainer->xTasksWaitingToReceive ) ) != pdFALSE ) in prvNotifyQueueSetContainer()