Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
2120: arch/cortex-m3: Allow the kernel to access protected memory r=bradjc a=alistair23 ### Pull Request Overview Commit 128782d "mpu: Change the disable_mpu API" converted the disable_app_mpu() function to not make any changes. This means when we return from an app to the kernel we don't disable the MPU. This resulted in some access failures when the kernel tried to access direct write flash regions (#1873 (comment)). We can either disable the MPU when returning to the kernel or change the app MPU configuration permissions to not impact the kernel. This patch converts the Cortex-M3 MPU implementation to always allow the kernel access when configuring the app. This way we can avoid the overhead of disabling the MPU on context switches. There is no security gap here as the kernel could just disable the MPU anyway if it was malicious. Signed-off-by: Alistair Francis <alistair.francis@wdc.com> ### Testing Strategy None. ### TODO or Help Wanted ### Documentation Updated - [X] Updated the relevant files in `/docs`, or no updates are required. ### Formatting - [X] Ran `make prepush`. Co-authored-by: Alistair Francis <alistair.francis@wdc.com>
- Loading branch information