static void prvCheckTask( void *pvParameters )\r
{\r
TickType_t xNextWakeTime;\r
-const TickType_t xCycleFrequency = pdMS_TO_TICKS( 2500UL );\r
+const TickType_t xCycleFrequency = pdMS_TO_TICKS( 4000UL );\r
\r
/* Just to remove compiler warning. */\r
( void ) pvParameters;\r
being deleted. */\r
pxTCB = prvGetTCBFromHandle( xTaskToDelete );\r
\r
- /* Remove task from the ready list. */\r
+ /* Remove task from the ready/delayed list. */\r
if( uxListRemove( &( pxTCB->xStateListItem ) ) == ( UBaseType_t ) 0 )\r
{\r
taskRESET_READY_PRIORITY( pxTCB->uxPriority );\r
{\r
if( uxListRemove( &( pxMutexHolderTCB->xStateListItem ) ) == ( UBaseType_t ) 0 )\r
{\r
- taskRESET_READY_PRIORITY( pxMutexHolderTCB->uxPriority );\r
+ /* It is known that the task is in its ready list so\r
+ there is no need to check again and the port level\r
+ reset macro can be called directly. */\r
+ portRESET_READY_PRIORITY( pxMutexHolderTCB->uxPriority, uxTopReadyPriority );\r
}\r
else\r
{\r
the mutex. If the mutex is held by a task then it cannot be\r
given from an interrupt, and if a mutex is given by the\r
holding task then it must be the running state task. Remove\r
- the holding task from the ready list. */\r
+ the holding task from the ready/delayed list. */\r
if( uxListRemove( &( pxTCB->xStateListItem ) ) == ( UBaseType_t ) 0 )\r
{\r
taskRESET_READY_PRIORITY( pxTCB->uxPriority );\r
{\r
if( uxListRemove( &( pxTCB->xStateListItem ) ) == ( UBaseType_t ) 0 )\r
{\r
- taskRESET_READY_PRIORITY( pxTCB->uxPriority );\r
+ /* It is known that the task is in its ready list so\r
+ there is no need to check again and the port level\r
+ reset macro can be called directly. */\r
+ portRESET_READY_PRIORITY( pxTCB->uxPriority, uxTopReadyPriority );\r
}\r
else\r
{\r