]> begriffs open source - freertos/commit
Remove run state assertion in prvCheckForRunStateChange (#1093)
authorchinglee-iot <61685396+chinglee-iot@users.noreply.github.com>
Wed, 19 Jun 2024 10:29:04 +0000 (18:29 +0800)
committerGitHub <noreply@github.com>
Wed, 19 Jun 2024 10:29:04 +0000 (18:29 +0800)
commit0c79e74eaa00a528604b14b9eb212b912d629f66
treeeb21f98275fd3a470889fe259502140f7eab25f6
parent76eb44382178237197a2c4982f9d99e8d64c9599
Remove run state assertion in prvCheckForRunStateChange (#1093)

In `prvCheckForRunStateChange()`, enabling interrupts should cause this core to immediately service the pending interrupt and yield. Upon the next scheduling of the task, the assertion `configASSERT(pxThisTCB->xTaskRunState != taskTASK_SCHEDULED_TO_YIELD);` may not be true, as other cores could have requested a yield for this task before it evaluates its run state within the assertion. To address this, the task re-evaluates its run state in critical section within a loop until it is eligible for execution, which is the current implementation. Consequently, this assertion should be removed to ensure correct behavior.
tasks.c