2.7.4.9.1 MPU Configuration for a Microcontroller

Usually, a microcontroller system has only a single processor and no caches. In such a system, program the MPU as indicated in the following table.

Table 2-81. Memory Region Attributes for a Microcontroller
Memory regionTEXCBSMemory type and attributes
Flash memoryb000100Normal memory, Non-shareable, write-through
Internal SRAMb000101Normal memory, Shareable, write-through
External SRAMb000111Normal memory, Shareable, write-back, write-allocate
Peripheralsb000011Device memory, Shareable

In most microcontroller implementations, the shareability and cache policy attributes do not affect the system behavior. However, using these settings for the MPU regions can make the application code more portable. The values given are for typical situations. In special systems, such as multiprocessor designs or designs with a separate DMA engine, the shareability attribute might be important. In these cases refer to the recommendations of the memory device manufacturer.