mirror of
https://github.com/FreeRTOS/FreeRTOS-Kernel.git
synced 2025-08-19 17:48:33 -04:00
Add xTaskGetIdleRunTimeCounter() API function to return the run time stats counter for the idle task - useful for POSIX time implementations.
This commit is contained in:
parent
817783d75c
commit
df5952f655
11 changed files with 69 additions and 12 deletions
|
@ -333,6 +333,19 @@ BaseType_t xRunningPrivileged = xPortRaisePrivilege();
|
|||
#endif
|
||||
/*-----------------------------------------------------------*/
|
||||
|
||||
#if( ( configGENERATE_RUN_TIME_STATS == 1 ) && ( INCLUDE_xTaskGetIdleTaskHandle == 1 ) )
|
||||
TickType_t MPU_xTaskGetIdleRunTimeCounter( void )
|
||||
{
|
||||
TickType_t xReturn;
|
||||
BaseType_t xRunningPrivileged = xPortRaisePrivilege();
|
||||
|
||||
xReturn = xTaskGetIdleRunTimeCounter();
|
||||
vPortResetPrivilege( xRunningPrivileged );
|
||||
return xReturn;
|
||||
}
|
||||
#endif
|
||||
/*-----------------------------------------------------------*/
|
||||
|
||||
#if ( configUSE_APPLICATION_TASK_TAG == 1 )
|
||||
void MPU_vTaskSetApplicationTaskTag( TaskHandle_t xTask, TaskHookFunction_t pxTagValue )
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue