Skip to content

Commit 4887bb4

Browse files
committed
Rename taskTASK_YIELD to taskTASK_SCHEDULED_TO_YIELD
1 parent 740b86b commit 4887bb4

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

tasks.c

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -260,10 +260,10 @@
260260
#endif
261261

262262
/* Indicates that the task is not actively running on any core. */
263-
#define taskTASK_NOT_RUNNING ( BaseType_t ) ( -1 )
263+
#define taskTASK_NOT_RUNNING ( ( BaseType_t ) ( -1 ) )
264264

265265
/* Indicates that the task is actively running but scheduled to yield. */
266-
#define taskTASK_YIELDING ( BaseType_t ) ( -2 )
266+
#define taskTASK_SCHEDULED_TO_YILED ( ( BaseType_t ) ( -2 ) )
267267

268268
/* Returns pdTRUE if the task is actively running and not scheduled to yield. */
269269
#if ( configNUMBER_OF_CORES == 1 )
@@ -700,7 +700,7 @@ static void prvAddNewTaskToReadyList( TCB_t * pxNewTCB ) PRIVILEGED_FUNCTION;
700700
* so this is safe. */
701701
pxThisTCB = pxCurrentTCBs[ portGET_CORE_ID() ];
702702

703-
while( pxThisTCB->xTaskRunState == taskTASK_YIELDING )
703+
while( pxThisTCB->xTaskRunState == taskTASK_SCHEDULED_TO_YILED )
704704
{
705705
/* We are only here if we just entered a critical section
706706
* or if we just suspended the scheduler, and another task
@@ -727,14 +727,14 @@ static void prvAddNewTaskToReadyList( TCB_t * pxNewTCB ) PRIVILEGED_FUNCTION;
727727
portRELEASE_TASK_LOCK();
728728

729729
portMEMORY_BARRIER();
730-
configASSERT( pxThisTCB->xTaskRunState == taskTASK_YIELDING );
730+
configASSERT( pxThisTCB->xTaskRunState == taskTASK_SCHEDULED_TO_YILED );
731731

732732
portENABLE_INTERRUPTS();
733733

734734
/* Enabling interrupts should cause this core to immediately
735735
* service the pending interrupt and yield. If the run state is still
736736
* yielding here then that is a problem. */
737-
configASSERT( pxThisTCB->xTaskRunState != taskTASK_YIELDING );
737+
configASSERT( pxThisTCB->xTaskRunState != taskTASK_SCHEDULED_TO_YILED );
738738

739739
portDISABLE_INTERRUPTS();
740740
portGET_TASK_LOCK();
@@ -763,7 +763,7 @@ static void prvAddNewTaskToReadyList( TCB_t * pxNewTCB ) PRIVILEGED_FUNCTION;
763763
}
764764
else
765765
{
766-
if( pxCurrentTCBs[ xCoreID ]->xTaskRunState != taskTASK_YIELDING )
766+
if( pxCurrentTCBs[ xCoreID ]->xTaskRunState != taskTASK_SCHEDULED_TO_YILED )
767767
{
768768
if( xCoreID == ( BaseType_t ) portGET_CORE_ID() )
769769
{
@@ -772,7 +772,7 @@ static void prvAddNewTaskToReadyList( TCB_t * pxNewTCB ) PRIVILEGED_FUNCTION;
772772
else
773773
{
774774
portYIELD_CORE( xCoreID );
775-
pxCurrentTCBs[ xCoreID ]->xTaskRunState = taskTASK_YIELDING;
775+
pxCurrentTCBs[ xCoreID ]->xTaskRunState = taskTASK_SCHEDULED_TO_YILED;
776776
}
777777
}
778778
}
@@ -990,7 +990,7 @@ static void prvAddNewTaskToReadyList( TCB_t * pxNewTCB ) PRIVILEGED_FUNCTION;
990990
}
991991
else if( pxTCB == pxCurrentTCBs[ xCoreID ] )
992992
{
993-
configASSERT( ( pxTCB->xTaskRunState == xCoreID ) || ( pxTCB->xTaskRunState == taskTASK_YIELDING ) );
993+
configASSERT( ( pxTCB->xTaskRunState == xCoreID ) || ( pxTCB->xTaskRunState == taskTASK_SCHEDULED_TO_YILED ) );
994994

995995
#if ( configUSE_CORE_AFFINITY == 1 )
996996
if( ( pxTCB->uxCoreAffinityMask & ( ( UBaseType_t ) 1U << ( UBaseType_t ) xCoreID ) ) != 0U )

0 commit comments

Comments
 (0)