From 5aaa02f776c98760a75e14f9988c269a756dcd38 Mon Sep 17 00:00:00 2001 From: richardbarry Date: Wed, 14 Aug 2013 08:35:40 +0000 Subject: [PATCH] Allow compilation when portALT_GET_RUN_TIME_COUNTER_VALUE() is defined. git-svn-id: https://svn.code.sf.net/p/freertos/code/trunk@2003 1d2547de-c912-0410-9cb9-b8ca96c0e9e2 --- FreeRTOS/Source/tasks.c | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/FreeRTOS/Source/tasks.c b/FreeRTOS/Source/tasks.c index 830f17263..7406d673c 100644 --- a/FreeRTOS/Source/tasks.c +++ b/FreeRTOS/Source/tasks.c @@ -939,7 +939,7 @@ tskTCB * pxNewTCB; running task is being raised. Is the priority being raised above that of the running task? */ if( uxNewPriority >= pxCurrentTCB->uxPriority ) - { + { xYieldRequired = pdTRUE; } } @@ -952,8 +952,8 @@ tskTCB * pxNewTCB; } else if( pxTCB == pxCurrentTCB ) { - /* Setting the priority of the running task down means - there may now be another task of higher priority that + /* Setting the priority of the running task down means + there may now be another task of higher priority that is ready to execute. */ xYieldRequired = pdTRUE; } @@ -1515,7 +1515,11 @@ unsigned portBASE_TYPE uxTaskGetNumberOfTasks( void ) { if( pulTotalRunTime != NULL ) { - *pulTotalRunTime = portGET_RUN_TIME_COUNTER_VALUE(); + #ifdef portALT_GET_RUN_TIME_COUNTER_VALUE + portALT_GET_RUN_TIME_COUNTER_VALUE( ( *pulTotalRunTime ) ); + #else + *pulTotalRunTime = portGET_RUN_TIME_COUNTER_VALUE(); + #endif } } #else -- 2.39.5