1
0
mirror of https://github.com/trezor/trezor-firmware.git synced 2024-12-22 22:38:08 +00:00

mpu_config: depend on MEMORY_PROTECT

This commit is contained in:
mcudev 2018-04-09 05:16:38 -04:00 committed by Pavol Rusnak
parent e907cb87bc
commit 14233fcc26

View File

@ -163,6 +163,7 @@ void setupApp(void)
// Never use in bootloader! Disables access to PPB (including MPU, NVIC, SCB)
void mpu_config(void)
{
#if MEMORY_PROTECT
// Disable MPU
MPU_CTRL = 0;
@ -206,4 +207,5 @@ void mpu_config(void)
// Switch to unprivileged software execution to prevent access to MPU
set_mode_unprivileged();
#endif
}