pxListEnd=listGET_END_MARKER(pxList);/*lint !e826 !e740 !e9087 The mini list structure is used as the list end to save RAM. This is checked and valid. */
constchar*pcQueueGetName(QueueHandle_txQueue)PRIVILEGED_FUNCTION;/*lint !e971 Unqualified char types are allowed for strings and single characters only. */
TaskHandle_txHandle;/* The handle of the task to which the rest of the information in the structure relates. */
constchar*pcTaskName;/* A pointer to the task's name. This value will be invalid if the task was deleted since the structure was populated! *//*lint !e971 Unqualified char types are allowed for strings and single characters only. */
constchar*pcTaskName;/* A pointer to the task's name. This value will be invalid if the task was deleted since the structure was populated! */
UBaseType_txTaskNumber;/* A number unique to the task. */
eTaskStateeCurrentState;/* The state in which the task existed when the structure was populated. */
UBaseType_tuxCurrentPriority;/* The priority at which the task was running (may be inherited) when the structure was populated. */
@ -379,7 +379,7 @@ typedef enum
*/
#if ( configSUPPORT_DYNAMIC_ALLOCATION == 1 )
BaseType_txTaskCreate(TaskFunction_tpxTaskCode,
constchar*constpcName,/*lint !e971 Unqualified char types are allowed for strings and single characters only. */
char*pcTaskGetName(TaskHandle_txTaskToQuery)PRIVILEGED_FUNCTION;/*lint !e971 Unqualified char types are allowed for strings and single characters only. */
TaskHandle_txTaskGetHandle(constchar*pcNameToQuery)PRIVILEGED_FUNCTION;/*lint !e971 Unqualified char types are allowed for strings and single characters only. */
constchar*pcTimerGetName(TimerHandle_txTimer)PRIVILEGED_FUNCTION;/*lint !e971 Unqualified char types are allowed for strings and single characters only. */
pxList->pxIndex=(ListItem_t*)&(pxList->xListEnd);/*lint !e826 !e740 !e9087 The mini list structure is used as the list end to save RAM. This is checked and valid. */
/* The list end next and previous pointers point to itself so we know
*whenthelistisempty.*/
pxList->xListEnd.pxNext=(ListItem_t*)&(pxList->xListEnd);/*lint !e826 !e740 !e9087 The mini list structure is used as the list end to save RAM. This is checked and valid. */
pxList->xListEnd.pxPrevious=(ListItem_t*)&(pxList->xListEnd);/*lint !e826 !e740 !e9087 The mini list structure is used as the list end to save RAM. This is checked and valid. */
for(pxIterator=(ListItem_t*)&(pxList->xListEnd);pxIterator->pxNext->xItemValue<=xValueOfInsertion;pxIterator=pxIterator->pxNext)/*lint !e826 !e740 !e9087 The mini list structure is used as the list end to save RAM. This is checked and valid. *//*lint !e440 The iterator moves to a different value, not xValueOfInsertion. */
pxQueue->u.xQueue.pcTail=pxQueue->pcHead+(pxQueue->uxLength*pxQueue->uxItemSize);/*lint !e9016 Pointer arithmetic allowed on char types, especially when it assists conveying intent. */
pxQueue->u.xQueue.pcReadFrom=pxQueue->pcHead+((pxQueue->uxLength-1U)*pxQueue->uxItemSize);/*lint !e9016 Pointer arithmetic allowed on char types, especially when it assists conveying intent. */
(void)memcpy((void*)pxQueue->pcWriteTo,pvItemToQueue,(size_t)pxQueue->uxItemSize);/*lint !e961 !e418 !e9087 MISRA exception as the casts are only redundant for some ports, plus previous logic ensures a null pointer can only be passed to memcpy() if the copy size is 0. Cast to void required by function signature and safe as no alignment requirement and copy length specified in bytes. */
pxQueue->pcWriteTo+=pxQueue->uxItemSize;/*lint !e9016 Pointer arithmetic on char types ok, especially in this use case where it is the clearest way of conveying intent. */
(void)memcpy((void*)pxQueue->u.xQueue.pcReadFrom,pvItemToQueue,(size_t)pxQueue->uxItemSize);/*lint !e961 !e9087 !e418 MISRA exception as the casts are only redundant for some ports. Cast to void required by function signature and safe as no alignment requirement and copy length specified in bytes. Assert checks null pointer only used when length is 0. */
pxQueue->u.xQueue.pcReadFrom+=pxQueue->uxItemSize;/*lint !e9016 Pointer arithmetic on char types ok, especially in this use case where it is the clearest way of conveying intent. */
if(pxQueue->u.xQueue.pcReadFrom>=pxQueue->u.xQueue.pcTail)/*lint !e946 MISRA exception justified as use of the relational operator is the cleanest solutions. */
(void)memcpy((void*)pvBuffer,(void*)pxQueue->u.xQueue.pcReadFrom,(size_t)pxQueue->uxItemSize);/*lint !e961 !e418 !e9087 MISRA exception as the casts are only redundant for some ports. Also previous logic ensures a null pointer can only be passed to memcpy() when the count is 0. Cast to void required by function signature and safe as no alignment requirement and copy length specified in bytes. */
/* Set configUSE_STATS_FORMATTING_FUNCTIONS to 2 to include the stats formatting
*functionsbutwithoutincludingstdio.hhere.*/
@ -369,7 +368,7 @@ typedef struct tskTaskControlBlock /* The old naming convention is used to
volatileBaseType_txTaskRunState;/**< Used to identify the core the task is running on, if the task is running. Otherwise, identifies the task's state - not running or yielding. */
UBaseType_tuxTaskAttributes;/**< Task's attributes - currently used to identify the idle tasks. */
#endif
charpcTaskName[configMAX_TASK_NAME_LEN];/**< Descriptive name given to the task when created. Facilitates debugging only. *//*lint !e971 Unqualified char types are allowed for strings and single characters only. */
charpcTaskName[configMAX_TASK_NAME_LEN];/**< Descriptive name given to the task when created. Facilitates debugging only. */
#if ( configUSE_TASK_PREEMPTION_DISABLE == 1 )
BaseType_txPreemptionDisable;/**< Used to prevent the task from being preempted. */
@ -416,8 +415,8 @@ typedef struct tskTaskControlBlock /* The old naming convention is used to
/* See the comments in FreeRTOS.h with the definition of
*tskSTATIC_AND_DYNAMIC_ALLOCATION_POSSIBLE.*/
#if ( tskSTATIC_AND_DYNAMIC_ALLOCATION_POSSIBLE != 0 )/*lint !e731 !e9029 Macro has been consolidated for readability reasons. */
uint8_tucStaticallyAllocated;/**< Set to pdTRUE if the task is a statically allocated to ensure no attempt is made to free the memory. */
pxTopOfStack=(StackType_t*)(((portPOINTER_SIZE_TYPE)pxTopOfStack)&(~((portPOINTER_SIZE_TYPE)portBYTE_ALIGNMENT_MASK)));/*lint !e923 !e9033 !e9078 MISRA exception. Avoiding casts between pointers and integers is not practical. Size differences accounted for using portPOINTER_SIZE_TYPE type. Checked by assert(). */
pxTopOfStack=(StackType_t*)((((portPOINTER_SIZE_TYPE)pxTopOfStack)+portBYTE_ALIGNMENT_MASK)&(~((portPOINTER_SIZE_TYPE)portBYTE_ALIGNMENT_MASK)));/*lint !e923 !e9033 !e9078 MISRA exception. Avoiding casts between pointers and integers is not practical. Size differences accounted for using portPOINTER_SIZE_TYPE type. Checked by assert(). */
listSET_LIST_ITEM_VALUE(&(pxNewTCB->xEventListItem),(TickType_t)configMAX_PRIORITIES-(TickType_t)uxPriority);/*lint !e961 MISRA exception as the casts are only redundant for some ports. */
listSET_LIST_ITEM_VALUE(&(pxTCB->xEventListItem),((TickType_t)configMAX_PRIORITIES-(TickType_t)uxNewPriority));/*lint !e961 MISRA exception as the casts are only redundant for some ports. */
if((xNumOfOverflows!=pxTimeOut->xOverflowCount)&&(xConstTickCount>=pxTimeOut->xTimeOnEntering))/*lint !e525 Indentation preferred as is to make code within pre-processor directives clearer. */
elseif(xElapsedTime<*pxTicksToWait)/*lint !e961 Explicit casting is only redundant with some compilers, whereas others require it to prevent integer conversion errors. */
elseif(xElapsedTime<*pxTicksToWait)
{
/* Not a genuine timeout. Adjust parameters for time remaining. */
listSET_LIST_ITEM_VALUE(&(pxMutexHolderTCB->xEventListItem),(TickType_t)configMAX_PRIORITIES-(TickType_t)pxCurrentTCB->uxPriority);/*lint !e961 MISRA exception as the casts are only redundant for some ports. */
/* Reset the event list item value. It cannot be in use for
*anyotherpurposeifthistaskisrunning,anditmustbe
*runningtogivebackthemutex.*/
listSET_LIST_ITEM_VALUE(&(pxTCB->xEventListItem),(TickType_t)configMAX_PRIORITIES-(TickType_t)pxTCB->uxPriority);/*lint !e961 MISRA exception as the casts are only redundant for some ports. */
listSET_LIST_ITEM_VALUE(&(pxTCB->xEventListItem),(TickType_t)configMAX_PRIORITIES-(TickType_t)uxPriorityToUse);/*lint !e961 MISRA exception as the casts are only redundant for some ports. */
pcWriteBuffer+=uxCharsWrittenBySnprintf;/*lint !e9016 Pointer arithmetic ok on char pointers especially as in this case where it best denotes the intent of the code. */
pcWriteBuffer+=uxCharsWrittenBySnprintf;/*lint !e9016 Pointer arithmetic ok on char pointers especially as in this case where it best denotes the intent of the code. */
/* Reset the event list item to its normal value - so it can be used with
*queuesandsemaphores.*/
listSET_LIST_ITEM_VALUE(&(pxCurrentTCB->xEventListItem),((TickType_t)configMAX_PRIORITIES-(TickType_t)pxCurrentTCB->uxPriority));/*lint !e961 MISRA exception as the casts are only redundant for some ports. */
/* The current task must be in a ready list, so there is no need to
*check,andtheportresetmacrocanbecalleddirectly.*/
portRESET_READY_PRIORITY(pxCurrentTCB->uxPriority,uxTopReadyPriority);/*lint !e931 pxCurrentTCB cannot change as it is the calling task. pxCurrentTCB->uxPriority and uxTopReadyPriority cannot change as called with scheduler suspended or in a critical section. */
/* This entire source file will be skipped if the application is not configured
@ -83,7 +82,7 @@
/* The definition of the timers themselves. */
typedefstructtmrTimerControl/* The old naming convention is used to prevent breaking kernel aware debuggers. */
{
constchar*pcTimerName;/**< Text name. This is not used by the kernel, it is included simply to make debugging easier. *//*lint !e971 Unqualified char types are allowed for strings and single characters only. */
constchar*pcTimerName;/**< Text name. This is not used by the kernel, it is included simply to make debugging easier. */
ListItem_txTimerListItem;/**< Standard linked list item as used by all kernel features for event management. */
TickType_txTimerPeriodInTicks;/**< How quickly and often the timer expires. */
void*pvTimerID;/**< An ID to identify the timer. This allows the timer to be identified when the same callback is used for multiple timers. */
@ -135,9 +134,6 @@
}u;
}DaemonTaskMessage_t;
/*lint -save -e956 A manual analysis and inspection has been used to determine
*whichstaticvariablesmustbedeclaredvolatile.*/
/* The list in which active timers are stored. Timers are referenced in expire
/* The timer queue is allocated statically in case
*configSUPPORT_DYNAMIC_ALLOCATIONis0.*/
PRIVILEGED_DATAstaticStaticQueue_txStaticTimerQueue;/*lint !e956 Ok to declare in this manner to prevent additional conditional compilation guards in other locations. */
PRIVILEGED_DATAstaticuint8_tucStaticTimerQueueStorage[(size_t)configTIMER_QUEUE_LENGTH*sizeof(DaemonTaskMessage_t)];/*lint !e956 Ok to declare in this manner to prevent additional conditional compilation guards in other locations. */