Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pass core ID to port lock macros #1212

Merged
merged 7 commits into from
Dec 30, 2024
Prev Previous commit
Next Next commit
Update core ID before getting locks in prvCheckForRunStateChange()
felixvanoost committed Dec 21, 2024
commit 6f0604699835f3367f654783e9afc18193b13ae4
3 changes: 2 additions & 1 deletion tasks.c
Original file line number Diff line number Diff line change
@@ -853,9 +853,10 @@ static void prvAddNewTaskToReadyList( TCB_t * pxNewTCB ) PRIVILEGED_FUNCTION;
* its run state. */

portDISABLE_INTERRUPTS();

xCoreID = ( BaseType_t ) portGET_CORE_ID();
portGET_TASK_LOCK( xCoreID );
portGET_ISR_LOCK( xCoreID );
xCoreID = ( BaseType_t ) portGET_CORE_ID();

portSET_CRITICAL_NESTING_COUNT( xCoreID, uxPrevCriticalNesting );