FreeRTOS / FreeRTOS-Kernel

FreeRTOS kernel files only, submoduled into https://github.com/FreeRTOS/FreeRTOS and various other repos.
https://www.FreeRTOS.org
MIT License
2.71k stars 1.11k forks source link

freertos-mpu: Add Privileged eXecute Never MPU attribute support #1092

Closed AhmedIsmail02 closed 3 months ago

AhmedIsmail02 commented 3 months ago

A new MPU region attribute Privileged eXecute Never (PXN) is introduced in Armv8.1-M architecture, where if an MPU region has PXN attribute set and the processor attempts to execute the code inside with privileged level, the Memory Management Fault exception would be triggered, with IACCVIOL bit in MemManage Fault State Register set to 1. The PXN feature allows privileged software to ensure specific application tasks (threads) to execute in unprivileged level only.

This PR adds the new MPU region attribute Privileged eXecute Never (PXN) support to the Armv8.1-M architecture port variants.

Description

Test Steps

Checklist:

Related Issue

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

sonarcloud[bot] commented 3 months ago

Quality Gate Passed Quality Gate passed

Issues
0 New issues
0 Accepted issues

Measures
0 Security Hotspots
No data about Coverage
0.0% Duplication on New Code

See analysis details on SonarCloud

AhmedIsmail02 commented 3 months ago

Hi @aggarg, Just checking if i should squash the code review suggestions commit with the existing commit ?

aggarg commented 3 months ago

@AhmedIsmail02, Yes, I have squashed and merged. Thank you for your contribution!