mirror of
https://github.com/FreeRTOS/FreeRTOS-Kernel.git
synced 2026-05-12 11:42:57 -04:00
Fix: Invalidate MPU object pool entry on timer delete in MPU wrappers v2
This commit is contained in:
parent
a8c9d35152
commit
63017388f1
1 changed files with 9 additions and 0 deletions
|
|
@ -3541,6 +3541,15 @@
|
||||||
pxParams->xOptionalValue,
|
pxParams->xOptionalValue,
|
||||||
pxParams->pxHigherPriorityTaskWoken,
|
pxParams->pxHigherPriorityTaskWoken,
|
||||||
pxParams->xTicksToWait );
|
pxParams->xTicksToWait );
|
||||||
|
|
||||||
|
/* Timer deletion is asynchronous - eagerly invalidate the
|
||||||
|
* object pool entry only if the delete command was successfully
|
||||||
|
* queued, to prevent stale handle access after the timer daemon
|
||||||
|
* frees the Timer_t. */
|
||||||
|
if( ( xReturn == pdPASS ) && ( pxParams->xCommandID == tmrCOMMAND_DELETE ) )
|
||||||
|
{
|
||||||
|
MPU_SetIndexFreeInKernelObjectPool( CONVERT_TO_INTERNAL_INDEX( lIndex ) );
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue