mirror of
https://github.com/FreeRTOS/FreeRTOS-Kernel.git
synced 2026-07-10 13:29:45 -04:00
When MPU is enabled, the first item in the TCB is not the top of the stack but the stored context location. As a result, xSecureContext is located at a negative offset from that position rather than at offset 0. The current implementation unconditionally reads xSecureContext at offset 0, which returns an incorrect value when MPU is enabled. This commit updates vPortFreeSecureContext to read xSecureContext at the correcct offset based on the port configuration: - CM33/CM35P/CM52/CM55/CM85/STAR_MC3: -20 (or -36 with PAC enabled) - CM23: -20 (no PAC support) - Without MPU: 0 (xSecureContext remains at the top of stack) Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com> |
||
|---|---|---|
| .. | ||
| ARMClang | ||
| ARMv8M | ||
| BCC/16BitDOS | ||
| CCRH/F1Kx | ||
| CCS | ||
| CodeWarrior | ||
| Common | ||
| GCC | ||
| IAR | ||
| Keil | ||
| MemMang | ||
| MikroC/ARM_CM4F | ||
| MPLAB | ||
| MSVC-MingW | ||
| oWatcom/16BitDOS | ||
| Paradigm/Tern_EE | ||
| Renesas | ||
| Rowley | ||
| RVDS | ||
| SDCC/Cygnal | ||
| Softune | ||
| Tasking/ARM_CM4F | ||
| template | ||
| ThirdParty | ||
| WizC/PIC18 | ||
| CMakeLists.txt | ||
| readme.txt | ||
Each real time kernel port consists of three files that contain the core kernel components and are common to every port, and one or more files that are specific to a particular microcontroller and/or compiler. + The FreeRTOS/Source/Portable/MemMang directory contains the five sample memory allocators as described on the https://www.FreeRTOS.org WEB site. + The other directories each contain files specific to a particular microcontroller or compiler, where the directory name denotes the compiler specific files the directory contains. For example, if you are interested in the [compiler] port for the [architecture] microcontroller, then the port specific files are contained in FreeRTOS/Source/Portable/[compiler]/[architecture] directory. If this is the only port you are interested in then all the other directories can be ignored.