]> git.sur5r.net Git - freertos/commitdiff
Allow compilation when portALT_GET_RUN_TIME_COUNTER_VALUE() is defined.
authorrichardbarry <richardbarry@1d2547de-c912-0410-9cb9-b8ca96c0e9e2>
Wed, 14 Aug 2013 08:35:40 +0000 (08:35 +0000)
committerrichardbarry <richardbarry@1d2547de-c912-0410-9cb9-b8ca96c0e9e2>
Wed, 14 Aug 2013 08:35:40 +0000 (08:35 +0000)
git-svn-id: https://svn.code.sf.net/p/freertos/code/trunk@2003 1d2547de-c912-0410-9cb9-b8ca96c0e9e2

FreeRTOS/Source/tasks.c

index 830f172636fab4f2cf3bf94876cc7a95fdc05d07..7406d673c0d44c26eae8acd38d37830eb0bda407 100644 (file)
@@ -939,7 +939,7 @@ tskTCB * pxNewTCB;
                                                running task is being raised.  Is the priority being\r
                                                raised above that of the running task? */\r
                                                if( uxNewPriority >= pxCurrentTCB->uxPriority )\r
-                                               {                                                       \r
+                                               {\r
                                                        xYieldRequired = pdTRUE;\r
                                                }\r
                                        }\r
@@ -952,8 +952,8 @@ tskTCB * pxNewTCB;
                                }\r
                                else if( pxTCB == pxCurrentTCB )\r
                                {\r
-                                       /* Setting the priority of the running task down means \r
-                                       there may now be another task of higher priority that \r
+                                       /* Setting the priority of the running task down means\r
+                                       there may now be another task of higher priority that\r
                                        is ready to execute. */\r
                                        xYieldRequired = pdTRUE;\r
                                }\r
@@ -1515,7 +1515,11 @@ unsigned portBASE_TYPE uxTaskGetNumberOfTasks( void )
                                {\r
                                        if( pulTotalRunTime != NULL )\r
                                        {\r
-                                               *pulTotalRunTime = portGET_RUN_TIME_COUNTER_VALUE();\r
+                                               #ifdef portALT_GET_RUN_TIME_COUNTER_VALUE\r
+                                                       portALT_GET_RUN_TIME_COUNTER_VALUE( ( *pulTotalRunTime ) );\r
+                                               #else\r
+                                                       *pulTotalRunTime = portGET_RUN_TIME_COUNTER_VALUE();\r
+                                               #endif                                  \r
                                        }\r
                                }\r
                                #else\r