36 #define MPU_WRAPPERS_INCLUDED_FROM_API_FILE 48 #undef MPU_WRAPPERS_INCLUDED_FROM_API_FILE 52 #if ( configUSE_STATS_FORMATTING_FUNCTIONS == 1 ) 60 #if( configUSE_PREEMPTION == 0 ) 63 #define taskYIELD_IF_USING_PREEMPTION() 65 #define taskYIELD_IF_USING_PREEMPTION() portYIELD_WITHIN_API() 69 #define taskNOT_WAITING_NOTIFICATION ( ( uint8_t ) 0 ) 70 #define taskWAITING_NOTIFICATION ( ( uint8_t ) 1 ) 71 #define taskNOTIFICATION_RECEIVED ( ( uint8_t ) 2 ) 77 #define tskSTACK_FILL_BYTE ( 0xa5U ) 96 #define tskSTATIC_AND_DYNAMIC_ALLOCATION_POSSIBLE ( ( configSUPPORT_STATIC_ALLOCATION == 1 ) && ( configSUPPORT_DYNAMIC_ALLOCATION == 1 ) ) 97 #define tskDYNAMICALLY_ALLOCATED_STACK_AND_TCB ( ( uint8_t ) 0 ) 98 #define tskSTATICALLY_ALLOCATED_STACK_ONLY ( ( uint8_t ) 1 ) 99 #define tskSTATICALLY_ALLOCATED_STACK_AND_TCB ( ( uint8_t ) 2 ) 104 #if( ( configCHECK_FOR_STACK_OVERFLOW > 1 ) || ( configUSE_TRACE_FACILITY == 1 ) || ( INCLUDE_uxTaskGetStackHighWaterMark == 1 ) ) 105 #define tskSET_NEW_STACKS_TO_KNOWN_VALUE 1 107 #define tskSET_NEW_STACKS_TO_KNOWN_VALUE 0 113 #define tskBLOCKED_CHAR ( 'B' ) 114 #define tskREADY_CHAR ( 'R' ) 115 #define tskDELETED_CHAR ( 'D' ) 116 #define tskSUSPENDED_CHAR ( 'S' ) 122 #ifdef portREMOVE_STATIC_QUALIFIER 128 #ifndef configIDLE_TASK_NAME 129 #define configIDLE_TASK_NAME "IDLE" 132 #if ( configUSE_PORT_OPTIMISED_TASK_SELECTION == 0 ) 140 #define taskRECORD_READY_PRIORITY( uxPriority ) \ 142 if( ( uxPriority ) > uxTopReadyPriority ) \ 144 uxTopReadyPriority = ( uxPriority ); \ 150 #define taskSELECT_HIGHEST_PRIORITY_TASK() \ 152 UBaseType_t uxTopPriority = uxTopReadyPriority; \ 155 while( listLIST_IS_EMPTY( &( pxReadyTasksLists[ uxTopPriority ] ) ) ) \ 157 configASSERT( uxTopPriority ); \ 163 listGET_OWNER_OF_NEXT_ENTRY( pxCurrentTCB, &( pxReadyTasksLists[ uxTopPriority ] ) ); \ 164 uxTopReadyPriority = uxTopPriority; \ 172 #define taskRESET_READY_PRIORITY( uxPriority ) 173 #define portRESET_READY_PRIORITY( uxPriority, uxTopReadyPriority ) 182 #define taskRECORD_READY_PRIORITY( uxPriority ) portRECORD_READY_PRIORITY( uxPriority, uxTopReadyPriority ) 186 #define taskSELECT_HIGHEST_PRIORITY_TASK() \ 188 UBaseType_t uxTopPriority; \ 191 portGET_HIGHEST_PRIORITY( uxTopPriority, uxTopReadyPriority ); \ 192 configASSERT( listCURRENT_LIST_LENGTH( &( pxReadyTasksLists[ uxTopPriority ] ) ) > 0 ); \ 193 listGET_OWNER_OF_NEXT_ENTRY( pxCurrentTCB, &( pxReadyTasksLists[ uxTopPriority ] ) ); \ 201 #define taskRESET_READY_PRIORITY( uxPriority ) \ 203 if( listCURRENT_LIST_LENGTH( &( pxReadyTasksLists[ ( uxPriority ) ] ) ) == ( UBaseType_t ) 0 ) \ 205 portRESET_READY_PRIORITY( ( uxPriority ), ( uxTopReadyPriority ) ); \ 215 #define taskSWITCH_DELAYED_LISTS() \ 220 configASSERT( ( listLIST_IS_EMPTY( pxDelayedTaskList ) ) ); \ 222 pxTemp = pxDelayedTaskList; \ 223 pxDelayedTaskList = pxOverflowDelayedTaskList; \ 224 pxOverflowDelayedTaskList = pxTemp; \ 226 prvResetNextTaskUnblockTime(); \ 235 #define prvAddTaskToReadyList( pxTCB ) \ 236 traceMOVED_TASK_TO_READY_STATE( pxTCB ); \ 237 taskRECORD_READY_PRIORITY( ( pxTCB )->uxPriority ); \ 238 vListInsertEnd( &( pxReadyTasksLists[ ( pxTCB )->uxPriority ] ), &( ( pxTCB )->xStateListItem ) ); \ 239 tracePOST_MOVED_TASK_TO_READY_STATE( pxTCB ) 248 #define prvGetTCBFromHandle( pxHandle ) ( ( ( pxHandle ) == NULL ) ? ( TCB_t * ) pxCurrentTCB : ( TCB_t * ) ( pxHandle ) ) 258 #if( configUSE_16_BIT_TICKS == 1 ) 259 #define taskEVENT_LIST_ITEM_VALUE_IN_USE 0x8000U 261 #define taskEVENT_LIST_ITEM_VALUE_IN_USE 0x80000000UL 273 #if ( portUSING_MPU_WRAPPERS == 1 ) 274 xMPU_SETTINGS xMPUSettings;
283 #if ( ( portSTACK_GROWTH > 0 ) || ( configRECORD_STACK_HIGH_ADDRESS == 1 ) ) 287 #if ( portCRITICAL_NESTING_IN_TCB == 1 ) 291 #if ( configUSE_TRACE_FACILITY == 1 ) 296 #if ( configUSE_MUTEXES == 1 ) 301 #if ( configUSE_APPLICATION_TASK_TAG == 1 ) 305 #if( configNUM_THREAD_LOCAL_STORAGE_POINTERS > 0 ) 309 #if( configGENERATE_RUN_TIME_STATS == 1 ) 310 uint32_t ulRunTimeCounter;
313 #if ( configUSE_NEWLIB_REENTRANT == 1 ) 321 struct _reent xNewLib_reent;
324 #if( configUSE_TASK_NOTIFICATIONS == 1 ) 325 volatile uint32_t ulNotifiedValue;
326 volatile uint8_t ucNotifyState;
331 #if( tskSTATIC_AND_DYNAMIC_ALLOCATION_POSSIBLE != 0 ) 332 uint8_t ucStaticallyAllocated;
335 #if( INCLUDE_xTaskAbortDelay == 1 ) 336 uint8_t ucDelayAborted;
358 #if( INCLUDE_vTaskDelete == 1 ) 365 #if ( INCLUDE_vTaskSuspend == 1 ) 393 #if ( configGENERATE_RUN_TIME_STATS == 1 ) 405 #if( configCHECK_FOR_STACK_OVERFLOW > 0 ) 411 #if( configUSE_TICK_HOOK > 0 ) 417 #if( configSUPPORT_STATIC_ALLOCATION == 1 ) 419 extern void vApplicationGetIdleTaskMemory(
StaticTask_t **ppxIdleTaskTCBBuffer,
StackType_t **ppxIdleTaskStackBuffer, uint32_t *pulIdleTaskStackSize );
430 #if ( INCLUDE_vTaskSuspend == 1 ) 462 #if ( INCLUDE_vTaskDelete == 1 ) 489 #if ( configUSE_TRACE_FACILITY == 1 ) 499 #if ( INCLUDE_xTaskGetHandle == 1 ) 510 #if ( ( configUSE_TRACE_FACILITY == 1 ) || ( INCLUDE_uxTaskGetStackHighWaterMark == 1 ) ) 512 static uint16_t prvTaskCheckFreeStackSpace(
const uint8_t * pucStackByte )
PRIVILEGED_FUNCTION;
525 #if ( configUSE_TICKLESS_IDLE != 0 ) 537 #if ( ( configUSE_TRACE_FACILITY == 1 ) && ( configUSE_STATS_FORMATTING_FUNCTIONS > 0 ) ) 552 const char *
const pcName,
553 const uint32_t ulStackDepth,
554 void *
const pvParameters,
571 #ifdef FREERTOS_TASKS_C_ADDITIONS_INIT 579 #if( configSUPPORT_STATIC_ALLOCATION == 1 ) 582 const char *
const pcName,
583 const uint32_t ulStackDepth,
584 void *
const pvParameters,
595 #if( configASSERT_DEFINED == 1 ) 606 if( ( pxTaskBuffer !=
NULL ) && ( puxStackBuffer !=
NULL ) )
610 pxNewTCB = (
TCB_t * ) pxTaskBuffer;
613 #if( tskSTATIC_AND_DYNAMIC_ALLOCATION_POSSIBLE != 0 ) 621 prvInitialiseNewTask( pxTaskCode, pcName, ulStackDepth, pvParameters, uxPriority, &xReturn, pxNewTCB,
NULL );
635 #if( ( portUSING_MPU_WRAPPERS == 1 ) && ( configSUPPORT_STATIC_ALLOCATION == 1 ) ) 650 pxNewTCB = (
TCB_t * ) pxTaskDefinition->pxTaskBuffer;
663 prvInitialiseNewTask( pxTaskDefinition->
pvTaskCode,
668 pxCreatedTask, pxNewTCB,
681 #if( ( portUSING_MPU_WRAPPERS == 1 ) && ( configSUPPORT_DYNAMIC_ALLOCATION == 1 ) ) 697 if( pxNewTCB !=
NULL )
702 #if( configSUPPORT_STATIC_ALLOCATION == 1 ) 711 prvInitialiseNewTask( pxTaskDefinition->
pvTaskCode,
716 pxCreatedTask, pxNewTCB,
730 #if( configSUPPORT_DYNAMIC_ALLOCATION == 1 ) 733 const char *
const pcName,
735 void *
const pvParameters,
745 #if( portSTACK_GROWTH > 0 ) 752 if( pxNewTCB !=
NULL )
774 if( pxStack !=
NULL )
779 if( pxNewTCB !=
NULL )
798 if( pxNewTCB !=
NULL )
800 #if( tskSTATIC_AND_DYNAMIC_ALLOCATION_POSSIBLE != 0 ) 808 prvInitialiseNewTask( pxTaskCode, pcName, ( uint32_t ) usStackDepth, pvParameters, uxPriority, pxCreatedTask, pxNewTCB,
NULL );
824 const char *
const pcName,
825 const uint32_t ulStackDepth,
826 void *
const pvParameters,
835 #if( portUSING_MPU_WRAPPERS == 1 ) 846 uxPriority &= ~portPRIVILEGE_BIT;
850 #if( tskSET_NEW_STACKS_TO_KNOWN_VALUE == 1 ) 861 #if( portSTACK_GROWTH < 0 ) 863 pxTopOfStack = pxNewTCB->
pxStack + ( ulStackDepth - ( uint32_t ) 1 );
869 #if( configRECORD_STACK_HIGH_ADDRESS == 1 ) 879 pxTopOfStack = pxNewTCB->
pxStack;
886 pxNewTCB->pxEndOfStack = pxNewTCB->
pxStack + ( ulStackDepth - ( uint32_t ) 1 );
898 if( pcName[ x ] == 0x00 )
924 #if ( configUSE_MUTEXES == 1 ) 927 pxNewTCB->uxMutexesHeld = 0;
942 #if ( portCRITICAL_NESTING_IN_TCB == 1 ) 948 #if ( configUSE_APPLICATION_TASK_TAG == 1 ) 950 pxNewTCB->pxTaskTag =
NULL;
954 #if ( configGENERATE_RUN_TIME_STATS == 1 ) 956 pxNewTCB->ulRunTimeCounter = 0UL;
960 #if ( portUSING_MPU_WRAPPERS == 1 ) 962 vPortStoreTaskMPUSettings( &( pxNewTCB->xMPUSettings ), xRegions, pxNewTCB->
pxStack, ulStackDepth );
971 #if( configNUM_THREAD_LOCAL_STORAGE_POINTERS != 0 ) 975 pxNewTCB->pvThreadLocalStoragePointers[ x ] =
NULL;
980 #if ( configUSE_TASK_NOTIFICATIONS == 1 ) 982 pxNewTCB->ulNotifiedValue = 0;
987 #if ( configUSE_NEWLIB_REENTRANT == 1 ) 990 _REENT_INIT_PTR( ( &( pxNewTCB->xNewLib_reent ) ) );
994 #if( INCLUDE_xTaskAbortDelay == 1 ) 996 pxNewTCB->ucDelayAborted =
pdFALSE;
1004 #if( portUSING_MPU_WRAPPERS == 1 ) 1014 if( (
void * ) pxCreatedTask !=
NULL )
1076 #if ( configUSE_TRACE_FACILITY == 1 ) 1110 #if ( INCLUDE_vTaskDelete == 1 ) 1160 ++uxDeletedTasksWaitingCleanUp;
1172 prvDeleteTCB( pxTCB );
1202 #if ( INCLUDE_vTaskDelayUntil == 1 ) 1220 xTimeToWake = *pxPreviousWakeTime + xTimeIncrement;
1222 if( xConstTickCount < *pxPreviousWakeTime )
1229 if( ( xTimeToWake < *pxPreviousWakeTime ) && ( xTimeToWake > xConstTickCount ) )
1243 if( ( xTimeToWake < *pxPreviousWakeTime ) || ( xTimeToWake > xConstTickCount ) )
1254 *pxPreviousWakeTime = xTimeToWake;
1273 if( xAlreadyYielded ==
pdFALSE )
1286 #if ( INCLUDE_vTaskDelay == 1 ) 1318 if( xAlreadyYielded ==
pdFALSE )
1331 #if( ( INCLUDE_eTaskGetState == 1 ) || ( configUSE_TRACE_FACILITY == 1 ) ) 1337 const TCB_t *
const pxTCB = (
TCB_t * ) xTask;
1361 #if ( INCLUDE_vTaskSuspend == 1 ) 1362 else if( pxStateList == &xSuspendedTaskList )
1378 #if ( INCLUDE_vTaskDelete == 1 ) 1379 else if( ( pxStateList == &xTasksWaitingTermination ) || ( pxStateList ==
NULL ) )
1402 #if ( INCLUDE_uxTaskPriorityGet == 1 ) 1424 #if ( INCLUDE_uxTaskPriorityGet == 1 ) 1464 #if ( INCLUDE_vTaskPrioritySet == 1 ) 1469 UBaseType_t uxCurrentBasePriority, uxPriorityUsedOnEntry;
1472 configASSERT( ( uxNewPriority < configMAX_PRIORITIES ) );
1475 if( uxNewPriority >= (
UBaseType_t ) configMAX_PRIORITIES )
1492 #if ( configUSE_MUTEXES == 1 ) 1494 uxCurrentBasePriority = pxTCB->uxBasePriority;
1502 if( uxCurrentBasePriority != uxNewPriority )
1506 if( uxNewPriority > uxCurrentBasePriority )
1548 #if ( configUSE_MUTEXES == 1 ) 1552 if( pxTCB->uxBasePriority == pxTCB->
uxPriority )
1562 pxTCB->uxBasePriority = uxNewPriority;
1608 if( xYieldRequired !=
pdFALSE )
1619 ( void ) uxPriorityUsedOnEntry;
1628 #if ( INCLUDE_vTaskSuspend == 1 ) 1665 #if( configUSE_TASK_NOTIFICATIONS == 1 ) 1729 #if ( INCLUDE_vTaskSuspend == 1 ) 1734 const TCB_t *
const pxTCB = (
TCB_t * ) xTask;
1775 #if ( INCLUDE_vTaskSuspend == 1 ) 1779 TCB_t *
const pxTCB = (
TCB_t * ) xTaskToResume;
1790 if( prvTaskIsTaskSuspended( pxTCB ) !=
pdFALSE )
1829 #if ( ( INCLUDE_xTaskResumeFromISR == 1 ) && ( INCLUDE_vTaskSuspend == 1 ) ) 1834 TCB_t *
const pxTCB = (
TCB_t * ) xTaskToResume;
1859 if( prvTaskIsTaskSuspended( pxTCB ) !=
pdFALSE )
1895 return xYieldRequired;
1906 #if( configSUPPORT_STATIC_ALLOCATION == 1 ) 1910 uint32_t ulIdleTaskStackSize;
1914 vApplicationGetIdleTaskMemory( &pxIdleTaskTCBBuffer, &pxIdleTaskStackBuffer, &ulIdleTaskStackSize );
1917 ulIdleTaskStackSize,
1920 pxIdleTaskStackBuffer,
1921 pxIdleTaskTCBBuffer );
1931 *idleTaskHandle = xReturn;
1936 xReturn = xTaskCreate( prvIdleTask,
1946 #if ( configUSE_TIMERS == 1 ) 1964 #ifdef FREERTOS_TASKS_C_ADDITIONS_INIT 1966 freertos_tasks_c_additions_init();
1977 #if ( configUSE_NEWLIB_REENTRANT == 1 ) 2044 #if ( configUSE_TICKLESS_IDLE != 0 ) 2046 static TickType_t prvGetExpectedIdleTime(
void )
2055 #if( configUSE_PORT_OPTIMISED_TASK_SELECTION == 0 ) 2059 uxHigherPriorityReadyTasks =
pdTRUE;
2073 uxHigherPriorityReadyTasks =
pdTRUE;
2089 else if( uxHigherPriorityReadyTasks !=
pdFALSE )
2193 #if( configUSE_PREEMPTION != 0 ) 2195 xAlreadyYielded =
pdTRUE;
2213 return xAlreadyYielded;
2283 #if ( INCLUDE_xTaskGetHandle == 1 ) 2285 static TCB_t *prvSearchForNameWithinSingleList(
List_t *pxList,
const char pcNameToQuery[] )
2287 TCB_t *pxNextTCB, *pxFirstTCB, *pxReturn =
NULL;
2307 if( cNextChar != pcNameToQuery[ x ] )
2312 else if( cNextChar == 0x00 )
2316 pxReturn = pxNextTCB;
2325 if( pxReturn !=
NULL )
2331 }
while( pxNextTCB != pxFirstTCB );
2344 #if ( INCLUDE_xTaskGetHandle == 1 ) 2381 #if ( INCLUDE_vTaskSuspend == 1 ) 2386 pxTCB = prvSearchForNameWithinSingleList( &xSuspendedTaskList, pcNameToQuery );
2391 #if( INCLUDE_vTaskDelete == 1 ) 2396 pxTCB = prvSearchForNameWithinSingleList( &xTasksWaitingTermination, pcNameToQuery );
2409 #if ( configUSE_TRACE_FACILITY == 1 ) 2425 uxTask += prvListTasksWithinSingleList( &( pxTaskStatusArray[ uxTask ] ), &(
pxReadyTasksLists[ uxQueue ] ),
eReady );
2434 #if( INCLUDE_vTaskDelete == 1 ) 2438 uxTask += prvListTasksWithinSingleList( &( pxTaskStatusArray[ uxTask ] ), &xTasksWaitingTermination,
eDeleted );
2442 #if ( INCLUDE_vTaskSuspend == 1 ) 2446 uxTask += prvListTasksWithinSingleList( &( pxTaskStatusArray[ uxTask ] ), &xSuspendedTaskList,
eSuspended );
2450 #if ( configGENERATE_RUN_TIME_STATS == 1) 2452 if( pulTotalRunTime !=
NULL )
2454 #ifdef portALT_GET_RUN_TIME_COUNTER_VALUE 2455 portALT_GET_RUN_TIME_COUNTER_VALUE( ( *pulTotalRunTime ) );
2463 if( pulTotalRunTime !=
NULL )
2465 *pulTotalRunTime = 0;
2483 #if ( INCLUDE_xTaskGetIdleTaskHandle == 1 ) 2500 #if ( configUSE_TICKLESS_IDLE != 0 ) 2515 #if ( INCLUDE_xTaskAbortDelay == 1 ) 2546 pxTCB->ucDelayAborted =
pdTRUE;
2560 #if ( configUSE_PREEMPTION == 1 ) 2647 if( xConstTickCount < xItemValue )
2682 #if ( configUSE_PREEMPTION == 1 ) 2690 xSwitchRequired =
pdTRUE;
2705 #if ( ( configUSE_PREEMPTION == 1 ) && ( configUSE_TIME_SLICING == 1 ) ) 2709 xSwitchRequired =
pdTRUE;
2718 #if ( configUSE_TICK_HOOK == 1 ) 2739 #if ( configUSE_TICK_HOOK == 1 ) 2746 #if ( configUSE_PREEMPTION == 1 ) 2750 xSwitchRequired =
pdTRUE;
2759 return xSwitchRequired;
2763 #if ( configUSE_APPLICATION_TASK_TAG == 1 ) 2777 xTCB = (
TCB_t * ) xTask;
2783 xTCB->pxTaskTag = pxHookFunction;
2790 #if ( configUSE_APPLICATION_TASK_TAG == 1 ) 2804 xTCB = (
TCB_t * ) xTask;
2811 xReturn = xTCB->pxTaskTag;
2821 #if ( configUSE_APPLICATION_TASK_TAG == 1 ) 2835 xTCB = (
TCB_t * ) xTask;
2838 if( xTCB->pxTaskTag !=
NULL )
2840 xReturn = xTCB->pxTaskTag( pvParameter );
2866 #if ( configGENERATE_RUN_TIME_STATS == 1 ) 2868 #ifdef portALT_GET_RUN_TIME_COUNTER_VALUE 2869 portALT_GET_RUN_TIME_COUNTER_VALUE( ulTotalRunTime );
2881 if( ulTotalRunTime > ulTaskSwitchedInTime )
2883 pxCurrentTCB->ulRunTimeCounter += ( ulTotalRunTime - ulTaskSwitchedInTime );
2889 ulTaskSwitchedInTime = ulTotalRunTime;
2901 #if ( configUSE_NEWLIB_REENTRANT == 1 ) 2953 #if( configUSE_TIMERS == 1 ) 2974 if( xWaitIndefinitely !=
pdFALSE )
2988 TCB_t *pxUnblockedTCB;
3036 #if( configUSE_TICKLESS_IDLE != 0 ) 3056 TCB_t *pxUnblockedTCB;
3121 #if( INCLUDE_xTaskAbortDelay == 1 ) 3132 #if ( INCLUDE_vTaskSuspend == 1 ) 3152 else if( xElapsedTime < *pxTicksToWait )
3155 *pxTicksToWait -= xElapsedTime;
3177 #if ( configUSE_TRACE_FACILITY == 1 ) 3186 pxTCB = (
TCB_t * ) xTask;
3187 uxReturn = pxTCB->uxTaskNumber;
3200 #if ( configUSE_TRACE_FACILITY == 1 ) 3208 pxTCB = (
TCB_t * ) xTask;
3209 pxTCB->uxTaskNumber = uxHandle;
3229 ( void ) pvParameters;
3245 #if ( configUSE_PREEMPTION == 0 ) 3255 #if ( ( configUSE_PREEMPTION == 1 ) && ( configIDLE_SHOULD_YIELD == 1 ) ) 3277 #if ( configUSE_IDLE_HOOK == 1 ) 3279 #if defined(__GNUC__) 3280 #pragma GCC diagnostic push 3281 #pragma GCC diagnostic ignored "-Wnested-externs" 3284 #if defined(__GNUC__) 3285 #pragma GCC diagnostic pop 3301 #if ( configUSE_TICKLESS_IDLE != 0 ) 3310 xExpectedIdleTime = prvGetExpectedIdleTime();
3320 xExpectedIdleTime = prvGetExpectedIdleTime();
3350 #if( configUSE_TICKLESS_IDLE != 0 ) 3390 #if ( configNUM_THREAD_LOCAL_STORAGE_POINTERS != 0 ) 3399 pxTCB->pvThreadLocalStoragePointers[ xIndex ] = pvValue;
3406 #if ( configNUM_THREAD_LOCAL_STORAGE_POINTERS != 0 ) 3410 void *pvReturn =
NULL;
3416 pvReturn = pxTCB->pvThreadLocalStoragePointers[ xIndex ];
3429 #if ( portUSING_MPU_WRAPPERS == 1 ) 3439 vPortStoreTaskMPUSettings( &( pxTCB->xMPUSettings ), xRegions,
NULL, 0 );
3458 #if ( INCLUDE_vTaskDelete == 1 ) 3464 #if ( INCLUDE_vTaskSuspend == 1 ) 3482 #if ( INCLUDE_vTaskDelete == 1 ) 3488 while( uxDeletedTasksWaitingCleanUp > (
UBaseType_t ) 0U )
3495 --uxDeletedTasksWaitingCleanUp;
3499 prvDeleteTCB( pxTCB );
3506 #if( configUSE_TRACE_FACILITY == 1 ) 3521 #if ( configUSE_MUTEXES == 1 ) 3531 #if ( configGENERATE_RUN_TIME_STATS == 1 ) 3554 #if ( INCLUDE_vTaskSuspend == 1 ) 3581 if( xGetFreeStackSpace !=
pdFALSE )
3583 #if ( portSTACK_GROWTH > 0 ) 3585 pxTaskStatus->
usStackHighWaterMark = prvTaskCheckFreeStackSpace( ( uint8_t * ) pxTCB->pxEndOfStack );
3602 #if ( configUSE_TRACE_FACILITY == 1 ) 3622 }
while( pxNextTCB != pxFirstTCB );
3635 #if ( ( configUSE_TRACE_FACILITY == 1 ) || ( INCLUDE_uxTaskGetStackHighWaterMark == 1 ) ) 3637 static uint16_t prvTaskCheckFreeStackSpace(
const uint8_t * pucStackByte )
3639 uint32_t ulCount = 0U;
3649 return ( uint16_t ) ulCount;
3655 #if ( INCLUDE_uxTaskGetStackHighWaterMark == 1 ) 3660 uint8_t *pucEndOfStack;
3665 #if portSTACK_GROWTH < 0 3667 pucEndOfStack = ( uint8_t * ) pxTCB->
pxStack;
3671 pucEndOfStack = ( uint8_t * ) pxTCB->pxEndOfStack;
3675 uxReturn = (
UBaseType_t ) prvTaskCheckFreeStackSpace( pucEndOfStack );
3683 #if ( INCLUDE_vTaskDelete == 1 ) 3685 static void prvDeleteTCB(
TCB_t *pxTCB )
3694 #if ( configUSE_NEWLIB_REENTRANT == 1 ) 3696 _reclaim_reent( &( pxTCB->xNewLib_reent ) );
3700 #if( ( configSUPPORT_DYNAMIC_ALLOCATION == 1 ) && ( configSUPPORT_STATIC_ALLOCATION == 0 ) && ( portUSING_MPU_WRAPPERS == 0 ) ) 3707 #elif( tskSTATIC_AND_DYNAMIC_ALLOCATION_POSSIBLE != 0 ) 3763 #if ( ( INCLUDE_xTaskGetCurrentTaskHandle == 1 ) || ( configUSE_MUTEXES == 1 ) ) 3780 #if ( ( INCLUDE_xTaskGetSchedulerState == 1 ) || ( configUSE_TIMERS == 1 ) ) 3808 #if ( configUSE_MUTEXES == 1 ) 3812 TCB_t *
const pxMutexHolderTCB = (
TCB_t * ) pxMutexHolder;
3818 if( pxMutexHolder !=
NULL )
3895 #if ( configUSE_MUTEXES == 1 ) 3899 TCB_t *
const pxTCB = (
TCB_t * ) pxMutexHolder;
3902 if( pxMutexHolder !=
NULL )
3910 ( pxTCB->uxMutexesHeld )--;
3914 if( pxTCB->
uxPriority != pxTCB->uxBasePriority )
3975 #if ( configUSE_MUTEXES == 1 ) 3979 TCB_t *
const pxTCB = (
TCB_t * ) pxMutexHolder;
3980 UBaseType_t uxPriorityUsedOnEntry, uxPriorityToUse;
3983 if( pxMutexHolder !=
NULL )
3993 if( pxTCB->uxBasePriority < uxHighestPriorityWaitingTask )
3995 uxPriorityToUse = uxHighestPriorityWaitingTask;
3999 uxPriorityToUse = pxTCB->uxBasePriority;
4009 if( pxTCB->uxMutexesHeld == uxOnlyOneMutexHeld )
4077 #if ( portCRITICAL_NESTING_IN_TCB == 1 ) 4079 void vTaskEnterCritical(
void )
4107 #if ( portCRITICAL_NESTING_IN_TCB == 1 ) 4109 void vTaskExitCritical(
void )
4140 #if ( ( configUSE_TRACE_FACILITY == 1 ) && ( configUSE_STATS_FORMATTING_FUNCTIONS > 0 ) ) 4142 static char *prvWriteNameToBuffer(
char *pcBuffer,
const char *
pcTaskName )
4147 strcpy( pcBuffer, pcTaskName );
4153 pcBuffer[ x ] =
' ';
4157 pcBuffer[ x ] = 0x00;
4160 return &( pcBuffer[ x ] );
4166 #if ( ( configUSE_TRACE_FACILITY == 1 ) && ( configUSE_STATS_FORMATTING_FUNCTIONS > 0 ) && ( configSUPPORT_DYNAMIC_ALLOCATION == 1 ) ) 4200 *pcWriteBuffer = 0x00;
4211 if( pxTaskStatusArray !=
NULL )
4217 for( x = 0; x < uxArraySize; x++ )
4219 switch( pxTaskStatusArray[ x ].eCurrentState )
4241 pcWriteBuffer = prvWriteNameToBuffer( pcWriteBuffer, pxTaskStatusArray[ x ].pcTaskName );
4244 sprintf( pcWriteBuffer,
"\t%c\t%u\t%u\t%u\r\n", cStatus, (
unsigned int ) pxTaskStatusArray[ x ].uxCurrentPriority, (
unsigned int ) pxTaskStatusArray[ x ].usStackHighWaterMark, (
unsigned int ) pxTaskStatusArray[ x ].xTaskNumber );
4245 pcWriteBuffer += strlen( pcWriteBuffer );
4261 #if ( ( configGENERATE_RUN_TIME_STATS == 1 ) && ( configUSE_STATS_FORMATTING_FUNCTIONS > 0 ) && ( configSUPPORT_DYNAMIC_ALLOCATION == 1 ) ) 4267 uint32_t ulTotalTime, ulStatsAsPercentage;
4269 #if( configUSE_TRACE_FACILITY != 1 ) 4271 #error configUSE_TRACE_FACILITY must also be set to 1 in FreeRTOSConfig.h to use vTaskGetRunTimeStats(). 4301 *pcWriteBuffer = 0x00;
4312 if( pxTaskStatusArray !=
NULL )
4318 ulTotalTime /= 100UL;
4321 if( ulTotalTime > 0 )
4324 for( x = 0; x < uxArraySize; x++ )
4329 ulStatsAsPercentage = pxTaskStatusArray[ x ].
ulRunTimeCounter / ulTotalTime;
4334 pcWriteBuffer = prvWriteNameToBuffer( pcWriteBuffer, pxTaskStatusArray[ x ].pcTaskName );
4336 if( ulStatsAsPercentage > 0UL )
4338 #ifdef portLU_PRINTF_SPECIFIER_REQUIRED 4340 sprintf( pcWriteBuffer,
"\t%lu\t\t%lu%%\r\n", pxTaskStatusArray[ x ].ulRunTimeCounter, ulStatsAsPercentage );
4346 sprintf( pcWriteBuffer,
"\t%u\t\t%u%%\r\n", (
unsigned int ) pxTaskStatusArray[ x ].ulRunTimeCounter, (
unsigned int ) ulStatsAsPercentage );
4354 #ifdef portLU_PRINTF_SPECIFIER_REQUIRED 4356 sprintf( pcWriteBuffer,
"\t%lu\t\t<1%%\r\n", pxTaskStatusArray[ x ].ulRunTimeCounter );
4362 sprintf( pcWriteBuffer,
"\t%u\t\t<1%%\r\n", (
unsigned int ) pxTaskStatusArray[ x ].ulRunTimeCounter );
4367 pcWriteBuffer += strlen( pcWriteBuffer );
4402 #if ( configUSE_MUTEXES == 1 ) 4419 #if( configUSE_TASK_NOTIFICATIONS == 1 ) 4461 if( ulReturn != 0UL )
4463 if( xClearCountOnExit !=
pdFALSE )
4469 pxCurrentTCB->ulNotifiedValue = ulReturn - ( uint32_t ) 1;
4487 #if( configUSE_TASK_NOTIFICATIONS == 1 ) 4501 pxCurrentTCB->ulNotifiedValue &= ~ulBitsToClearOnEntry;
4533 if( pulNotificationValue !=
NULL )
4567 #if( configUSE_TASK_NOTIFICATIONS == 1 ) 4573 uint8_t ucOriginalNotifyState;
4576 pxTCB = (
TCB_t * ) xTaskToNotify;
4580 if( pulPreviousNotificationValue !=
NULL )
4582 *pulPreviousNotificationValue = pxTCB->ulNotifiedValue;
4585 ucOriginalNotifyState = pxTCB->ucNotifyState;
4592 pxTCB->ulNotifiedValue |= ulValue;
4596 ( pxTCB->ulNotifiedValue )++;
4600 pxTCB->ulNotifiedValue = ulValue;
4606 pxTCB->ulNotifiedValue = ulValue;
4633 #if( configUSE_TICKLESS_IDLE != 0 ) 4673 #if( configUSE_TASK_NOTIFICATIONS == 1 ) 4678 uint8_t ucOriginalNotifyState;
4702 pxTCB = (
TCB_t * ) xTaskToNotify;
4706 if( pulPreviousNotificationValue !=
NULL )
4708 *pulPreviousNotificationValue = pxTCB->ulNotifiedValue;
4711 ucOriginalNotifyState = pxTCB->ucNotifyState;
4717 pxTCB->ulNotifiedValue |= ulValue;
4721 ( pxTCB->ulNotifiedValue )++;
4725 pxTCB->ulNotifiedValue = ulValue;
4731 pxTCB->ulNotifiedValue = ulValue;
4771 if( pxHigherPriorityTaskWoken !=
NULL )
4773 *pxHigherPriorityTaskWoken =
pdTRUE;
4797 #if( configUSE_TASK_NOTIFICATIONS == 1 ) 4802 uint8_t ucOriginalNotifyState;
4825 pxTCB = (
TCB_t * ) xTaskToNotify;
4829 ucOriginalNotifyState = pxTCB->ucNotifyState;
4834 ( pxTCB->ulNotifiedValue )++;
4861 if( pxHigherPriorityTaskWoken !=
NULL )
4863 *pxHigherPriorityTaskWoken =
pdTRUE;
4886 #if( configUSE_TASK_NOTIFICATIONS == 1 ) 4923 #if( INCLUDE_xTaskAbortDelay == 1 ) 4945 #if ( INCLUDE_vTaskSuspend == 1 ) 4959 xTimeToWake = xConstTickCount + xTicksToWait;
4964 if( xTimeToWake < xConstTickCount )
4995 xTimeToWake = xConstTickCount + xTicksToWait;
5000 if( xTimeToWake < xConstTickCount )
5024 ( void ) xCanBlockIndefinitely;
5033 #ifdef FREERTOS_MODULE_TEST 5034 #include "tasks_test_access_functions.h" 5038 #if( configINCLUDE_FREERTOS_TASK_C_ADDITIONS_H == 1 ) 5040 #include "freertos_tasks_c_additions.h" 5042 static void freertos_tasks_c_additions_init(
void )
5044 #ifdef FREERTOS_TASKS_C_ADDITIONS_INIT 5045 FREERTOS_TASKS_C_ADDITIONS_INIT();
UBaseType_t uxCurrentPriority
void vPortFree(void *pv) PRIVILEGED_FUNCTION
#define traceTASK_NOTIFY_WAIT()
#define listGET_LIST_ITEM_VALUE(pxListItem)
static PRIVILEGED_DATA List_t pxReadyTasksLists[configMAX_PRIORITIES]
#define listGET_OWNER_OF_NEXT_ENTRY(pxTCB, pxList)
TaskHandle_t xTaskGetHandle(const char *pcNameToQuery) PRIVILEGED_FUNCTION
static PRIVILEGED_DATA volatile TickType_t xTickCount
uint32_t ulRunTimeCounter
UBaseType_t uxTaskPriorityGetFromISR(TaskHandle_t xTask) PRIVILEGED_FUNCTION
static PRIVILEGED_DATA volatile TickType_t xNextTaskUnblockTime
uint16_t usStackHighWaterMark
void vTaskSetTaskNumber(TaskHandle_t xTask, const UBaseType_t uxHandle) PRIVILEGED_FUNCTION
#define traceTASK_RESUME_FROM_ISR(pxTaskToResume)
void vTaskGetRunTimeStats(char *pcWriteBuffer) PRIVILEGED_FUNCTION
#define configEXPECTED_IDLE_TIME_BEFORE_SLEEP
void vTaskSwitchContext(void)
#define listIS_CONTAINED_WITHIN(pxList, pxListItem)
TickType_t xTimeOnEntering
static PRIVILEGED_DATA volatile UBaseType_t uxSchedulerSuspended
BaseType_t xTaskCheckForTimeOut(TimeOut_t *const pxTimeOut, TickType_t *const pxTicksToWait)
static PRIVILEGED_DATA UBaseType_t uxTaskNumber
#define configNUM_THREAD_LOCAL_STORAGE_POINTERS
TaskHandle_t xTaskGetCurrentTaskHandle(void) PRIVILEGED_FUNCTION
#define traceTASK_SUSPEND(pxTaskToSuspend)
static PRIVILEGED_DATA volatile BaseType_t xNumOfOverflows
UBaseType_t uxListRemove(ListItem_t *const pxItemToRemove) PRIVILEGED_FUNCTION
#define portPOINTER_SIZE_TYPE
#define listLIST_ITEM_CONTAINER(pxListItem)
ListItem_t xEventListItem
void vTaskSuspendAll(void)
void vTaskEndScheduler(void)
#define taskEXIT_CRITICAL()
PRIVILEGED_DATA TCB_t *volatile pxCurrentTCB
void vTaskPrioritySet(TaskHandle_t xTask, UBaseType_t uxNewPriority) PRIVILEGED_FUNCTION
static PRIVILEGED_DATA volatile UBaseType_t uxCurrentNumberOfTasks
#define configMAX_PRIORITIES
#define traceTASK_DELAY_UNTIL(x)
#define portENABLE_INTERRUPTS()
static void prvResetNextTaskUnblockTime(void)
#define taskSCHEDULER_NOT_STARTED
#define portSETUP_TCB(pxTCB)
#define configMINIMAL_STACK_SIZE
#define taskNOT_WAITING_NOTIFICATION
#define tskSTACK_FILL_BYTE
#define tskSTATICALLY_ALLOCATED_STACK_ONLY
#define portDISABLE_INTERRUPTS()
static void prvInitialiseTaskLists(static void prvCheckTasksWaitingTermination void)
#define prvAddTaskToReadyList(pxTCB)
StackType_t * pxStackBase
BaseType_t xTaskPriorityInherit(TaskHandle_t const pxMutexHolder) PRIVILEGED_FUNCTION
void vListInsertEnd(List_t *const pxList, ListItem_t *const pxNewListItem) PRIVILEGED_FUNCTION
void * pvTaskIncrementMutexHeldCount(void) PRIVILEGED_FUNCTION
#define taskSCHEDULER_RUNNING
BaseType_t xTaskResumeFromISR(TaskHandle_t xTaskToResume) PRIVILEGED_FUNCTION
#define portGET_RUN_TIME_COUNTER_VALUE()
#define portTICK_TYPE_EXIT_CRITICAL()
void * pvPortMalloc(size_t xSize) PRIVILEGED_FUNCTION
#define traceTASK_PRIORITY_DISINHERIT(pxTCBOfMutexHolder, uxOriginalPriority)
#define traceINCREASE_TICK_COUNT(x)
#define listSET_LIST_ITEM_VALUE(pxListItem, xValue)
#define taskWAITING_NOTIFICATION
void vTaskPlaceOnEventListRestricted(List_t *const pxEventList, TickType_t xTicksToWait, const BaseType_t xWaitIndefinitely) PRIVILEGED_FUNCTION
static PRIVILEGED_DATA List_t xDelayedTaskList1
#define traceTASK_SWITCHED_OUT()
BaseType_t xTaskCallApplicationTaskHook(TaskHandle_t xTask, void *pvParameter) PRIVILEGED_FUNCTION
BaseType_t xTaskRemoveFromEventList(const List_t *const pxEventList)
#define listLIST_IS_EMPTY(pxList)
void vTaskList(char *pcWriteBuffer) PRIVILEGED_FUNCTION
BaseType_t xTimerCreateTimerTask(TaskHandle_t *) PRIVILEGED_FUNCTION
static PRIVILEGED_DATA volatile BaseType_t xSchedulerRunning
void vPortEndScheduler(void) PRIVILEGED_FUNCTION
BaseType_t xTaskAbortDelay(TaskHandle_t xTask) PRIVILEGED_FUNCTION
#define portRESET_READY_PRIORITY(uxPriority, uxTopReadyPriority)
BaseType_t xTaskGenericNotifyFromISR(TaskHandle_t xTaskToNotify, uint32_t ulValue, eNotifyAction eAction, uint32_t *pulPreviousNotificationValue, BaseType_t *pxHigherPriorityTaskWoken) PRIVILEGED_FUNCTION
unsigned long UBaseType_t
#define traceTASK_NOTIFY_FROM_ISR()
#define traceTASK_PRIORITY_SET(pxTask, uxNewPriority)
#define traceTASK_NOTIFY()
void vApplicationIdleHook(void)
#define configLIST_VOLATILE
#define traceTASK_RESUME(pxTaskToResume)
#define traceTASK_DELAY()
void vTaskStepTick(const TickType_t xTicksToJump) PRIVILEGED_FUNCTION
#define portCLEAN_UP_TCB(pxTCB)
void vTaskStartScheduler(TaskHandle_t *idleTaskHandle, TaskHandle_t *timerTaskHandle)
BaseType_t xPortStartScheduler(void) PRIVILEGED_FUNCTION
#define portSET_INTERRUPT_MASK_FROM_ISR()
#define portSUPPRESS_TICKS_AND_SLEEP(xExpectedIdleTime)
#define portTASK_CALLS_SECURE_FUNCTIONS()
StackType_t * pxPortInitialiseStack(StackType_t *pxTopOfStack, TaskFunction_t pxCode, void *pvParameters) PRIVILEGED_FUNCTION
MemoryRegion_t xRegions[portNUM_CONFIGURABLE_REGIONS]
BaseType_t xTaskNotifyWait(uint32_t ulBitsToClearOnEntry, uint32_t ulBitsToClearOnExit, uint32_t *pulNotificationValue, TickType_t xTicksToWait) PRIVILEGED_FUNCTION
UBaseType_t uxTaskPriorityGet(TaskHandle_t xTask) PRIVILEGED_FUNCTION
#define listSET_LIST_ITEM_OWNER(pxListItem, pxOwner)
#define traceTASK_INCREMENT_TICK(xTickCount)
void vTaskRemoveFromUnorderedEventList(ListItem_t *pxEventListItem, const TickType_t xItemValue)
void vTaskPriorityDisinheritAfterTimeout(TaskHandle_t const pxMutexHolder, UBaseType_t uxHighestPriorityWaitingTask) PRIVILEGED_FUNCTION
BaseType_t(* TaskHookFunction_t)(void *)
#define traceTASK_CREATE(pxNewTCB)
#define errCOULD_NOT_ALLOCATE_REQUIRED_MEMORY
#define prvGetTCBFromHandle(pxHandle)
#define traceTASK_NOTIFY_WAIT_BLOCK()
#define tskSTATIC_AND_DYNAMIC_ALLOCATION_POSSIBLE
TickType_t uxTaskResetEventItemValue(void)
void vTaskDelete(TaskHandle_t xTaskToDelete) PRIVILEGED_FUNCTION
struct xSTATIC_TCB StaticTask_t
#define portASSERT_IF_INTERRUPT_PRIORITY_INVALID()
UBaseType_t uxTaskGetTaskNumber(TaskHandle_t xTask) PRIVILEGED_FUNCTION
#define portPRIVILEGE_BIT
BaseType_t xTaskPriorityDisinherit(TaskHandle_t const pxMutexHolder) PRIVILEGED_FUNCTION
static PRIVILEGED_DATA volatile UBaseType_t uxTopReadyPriority
char * pcTaskGetName(TaskHandle_t xTaskToQuery)
static void prvCheckTasksWaitingTermination(void)
#define taskRESET_READY_PRIORITY(uxPriority)
UBaseType_t uxTaskGetStackHighWaterMark(TaskHandle_t xTask) PRIVILEGED_FUNCTION
void vTaskDelayUntil(TickType_t *const pxPreviousWakeTime, const TickType_t xTimeIncrement) PRIVILEGED_FUNCTION
static PRIVILEGED_DATA List_t xDelayedTaskList2
void vTaskSuspend(TaskHandle_t xTaskToSuspend) PRIVILEGED_FUNCTION
#define tskSTATICALLY_ALLOCATED_STACK_AND_TCB
TaskHandle_t xTaskGetIdleTaskHandle(void) PRIVILEGED_FUNCTION
#define portASSERT_IF_IN_ISR()
static PRIVILEGED_DATA List_t *volatile pxDelayedTaskList
static PRIVILEGED_DATA TaskHandle_t xIdleTaskHandle
#define traceTASK_PRIORITY_INHERIT(pxTCBOfMutexHolder, uxInheritedPriority)
#define listGET_OWNER_OF_HEAD_ENTRY(pxList)
#define portTICK_TYPE_CLEAR_INTERRUPT_MASK_FROM_ISR(x)
UBaseType_t uxTaskGetNumberOfTasks(void)
void vTaskSetTimeOutState(TimeOut_t *const pxTimeOut)
#define portTICK_TYPE_ENTER_CRITICAL()
void vTaskNotifyGiveFromISR(TaskHandle_t xTaskToNotify, BaseType_t *pxHigherPriorityTaskWoken) PRIVILEGED_FUNCTION
#define portTICK_TYPE_SET_INTERRUPT_MASK_FROM_ISR()
BaseType_t xTaskNotifyStateClear(TaskHandle_t xTask)
void vTaskPlaceOnUnorderedEventList(List_t *pxEventList, const TickType_t xItemValue, const TickType_t xTicksToWait)
#define configSTACK_DEPTH_TYPE
#define traceTASK_NOTIFY_TAKE()
void vListInsert(List_t *const pxList, ListItem_t *const pxNewListItem) PRIVILEGED_FUNCTION
#define tskSUSPENDED_CHAR
void vTaskResume(TaskHandle_t xTaskToResume) PRIVILEGED_FUNCTION
void vTaskAllocateMPURegions(TaskHandle_t xTask, const MemoryRegion_t *const pxRegions) PRIVILEGED_FUNCTION
void vApplicationStackOverflowHook(xTaskHandle *pxTask, signed char *pcTaskName)
#define portYIELD_WITHIN_API
#define traceTASK_NOTIFY_TAKE_BLOCK()
char pcTaskName[configMAX_TASK_NAME_LEN]
void vTaskInternalSetTimeOutState(TimeOut_t *const pxTimeOut)
TickType_t xTaskGetTickCount(void)
BaseType_t xTaskGetSchedulerState(void) PRIVILEGED_FUNCTION
#define taskYIELD_IF_USING_PREEMPTION()
#define taskENTER_CRITICAL()
#define portTASK_FUNCTION_PROTO(vFunction, pvParameters)
static PRIVILEGED_DATA volatile BaseType_t xYieldPending
void vApplicationTickHook(void)
eSleepModeStatus eTaskConfirmSleepModeStatus(void) PRIVILEGED_FUNCTION
uint32_t ulTaskNotifyTake(BaseType_t xClearCountOnExit, TickType_t xTicksToWait) PRIVILEGED_FUNCTION
#define listGET_LIST_ITEM_OWNER(pxListItem)
#define configIDLE_TASK_NAME
BaseType_t xTaskResumeAll(void)
static PRIVILEGED_DATA List_t xPendingReadyList
#define taskSELECT_HIGHEST_PRIORITY_TASK()
#define traceLOW_POWER_IDLE_END()
#define configINITIAL_TICK_COUNT
#define PRIVILEGED_FUNCTION
void vTaskDelay(const TickType_t xTicksToDelay) PRIVILEGED_FUNCTION
#define taskEVENT_LIST_ITEM_VALUE_IN_USE
#define configPRE_SUPPRESS_TICKS_AND_SLEEP_PROCESSING(x)
#define traceLOW_POWER_IDLE_BEGIN()
#define portCONFIGURE_TIMER_FOR_RUN_TIME_STATS()
UBaseType_t uxBasePriority
#define taskCHECK_FOR_STACK_OVERFLOW()
BaseType_t xOverflowCount
#define traceTASK_DELETE(pxTaskToDelete)
#define mtCOVERAGE_TEST_MARKER()
TaskFunction_t pvTaskCode
#define taskSCHEDULER_SUSPENDED
#define configMAX_TASK_NAME_LEN
UBaseType_t uxTaskGetSystemState(TaskStatus_t *const pxTaskStatusArray, const UBaseType_t uxArraySize, uint32_t *const pulTotalRunTime) PRIVILEGED_FUNCTION
#define portCLEAR_INTERRUPT_MASK_FROM_ISR(uxSavedStatusValue)
void vTaskGetInfo(TaskHandle_t xTask, TaskStatus_t *pxTaskStatus, BaseType_t xGetFreeStackSpace, eTaskState eState) PRIVILEGED_FUNCTION
static portTASK_FUNCTION(prvIdleTask, pvParameters)
#define portPRE_TASK_DELETE_HOOK(pvTaskToDelete, pxYieldPending)
#define listCURRENT_LIST_LENGTH(pxList)
static void prvAddNewTaskToReadyList(TCB_t *pxNewTCB)
BaseType_t xTaskGenericNotify(TaskHandle_t xTaskToNotify, uint32_t ulValue, eNotifyAction eAction, uint32_t *pulPreviousNotificationValue) PRIVILEGED_FUNCTION
#define taskNOTIFICATION_RECEIVED
#define traceTASK_NOTIFY_GIVE_FROM_ISR()
TickType_t xTaskGetTickCountFromISR(void)
static PRIVILEGED_DATA volatile UBaseType_t uxPendedTicks
#define traceTASK_SWITCHED_IN()
#define taskSWITCH_DELAYED_LISTS()
void vTaskPlaceOnEventList(List_t *const pxEventList, const TickType_t xTicksToWait)
static void prvAddCurrentTaskToDelayedList(TickType_t xTicksToWait, const BaseType_t xCanBlockIndefinitely)
void(* TaskFunction_t)(void *)
void vListInitialise(List_t *const pxList) PRIVILEGED_FUNCTION
void vListInitialiseItem(ListItem_t *const pxItem) PRIVILEGED_FUNCTION
void vTaskMissedYield(void)
StackType_t * puxStackBuffer
eTaskState eTaskGetState(TaskHandle_t xTask) PRIVILEGED_FUNCTION
BaseType_t xTaskIncrementTick(void)
portSTACK_TYPE StackType_t
static PRIVILEGED_DATA List_t *volatile pxOverflowDelayedTaskList
ListItem_t xStateListItem
struct tskTaskControlBlock tskTCB
#define tskDYNAMICALLY_ALLOCATED_STACK_AND_TCB
volatile StackType_t * pxTopOfStack