FreeRTOS MPU - Cortex M4 - Privilege task

If a privileged task is created using xTaskCreate, then in the vPortStoreTaskMPUSettings function, the FreeRTOS kernel explicitly gives access to the entire SRAM. Wanted to know the rationale behind this? Shouldn’t the access to the background region be sufficient for a privileged task? Does it really need access to the kernel data in SRAM?

We specify Execute Never to ensure that code execution is not permitted from the data region.

Got it, thanks. Again just wanted to get it clarified from the experts!

One need for the privileged tasks to access the “kernel data” is that it avoids the need to switch to a “more privileged” mode to perform the operations for FreeRTOS API calls.