mirror of
https://github.com/FreeRTOS/FreeRTOS-Kernel.git
synced 2025-06-07 12:59:04 -04:00
added multiple idle tasks
This commit is contained in:
parent
f916ccf506
commit
a65f379860
10
tasks.c
10
tasks.c
|
@ -1555,11 +1555,10 @@ static void prvInitialiseNewTask( TaskFunction_t pxTaskCode,
|
||||||
pxNewTCB->xTaskRunState = taskTASK_NOT_RUNNING;
|
pxNewTCB->xTaskRunState = taskTASK_NOT_RUNNING;
|
||||||
|
|
||||||
/* Is this an idle task? */
|
/* Is this an idle task? */
|
||||||
if( pxTaskCode == prvIdleTask )
|
if(pxTaskCode == prvIdleTask)
|
||||||
{
|
{
|
||||||
pxNewTCB->xIsIdle = pdTRUE;
|
pxNewTCB->xIsIdle = pdTRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
#if ( configNUM_CORES > 1 )
|
#if ( configNUM_CORES > 1 )
|
||||||
else if( pxTaskCode == prvMinimalIdleTask )
|
else if( pxTaskCode == prvMinimalIdleTask )
|
||||||
{
|
{
|
||||||
|
@ -2703,7 +2702,6 @@ static BaseType_t prvCreateIdleTasks( void )
|
||||||
pxIdleTaskStackBuffer,
|
pxIdleTaskStackBuffer,
|
||||||
pxIdleTaskTCBBuffer ); /*lint !e961 MISRA exception, justified as it is not a redundant explicit cast to all supported compilers. */
|
pxIdleTaskTCBBuffer ); /*lint !e961 MISRA exception, justified as it is not a redundant explicit cast to all supported compilers. */
|
||||||
}
|
}
|
||||||
|
|
||||||
#if ( configNUM_CORES > 1 )
|
#if ( configNUM_CORES > 1 )
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
@ -4236,11 +4234,17 @@ void vTaskMissedYield( void )
|
||||||
* The MinimalIdle task.
|
* The MinimalIdle task.
|
||||||
* ----------------------------------------------------------
|
* ----------------------------------------------------------
|
||||||
*
|
*
|
||||||
|
* The portTASK_FUNCTION() macro is used to allow port/compiler specific
|
||||||
|
* language extensions. The equivalent prototype for this function is:
|
||||||
|
*
|
||||||
|
* void prvMinimalIdleTask( void *pvParameters );
|
||||||
|
*
|
||||||
* The minimal idle task is used for all the additional Cores in a SMP system.
|
* The minimal idle task is used for all the additional Cores in a SMP system.
|
||||||
* There must be only 1 idle task and the rest are minimal idle tasks.
|
* There must be only 1 idle task and the rest are minimal idle tasks.
|
||||||
*
|
*
|
||||||
* @todo additional conditional compiles to remove this function.
|
* @todo additional conditional compiles to remove this function.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#if ( configNUM_CORES > 1 )
|
#if ( configNUM_CORES > 1 )
|
||||||
static portTASK_FUNCTION( prvMinimalIdleTask, pvParameters )
|
static portTASK_FUNCTION( prvMinimalIdleTask, pvParameters )
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in a new issue