Skip to content

Commit b9d492e

Browse files
nvlsianpunashif
authored andcommitted
drivers/flash: select to allow flash write by MPU on ARM SoCs
Added selection of MPU_ALLOW_FLASH_WRITE. Using a flash driver while MPU is enable without this option on doesn't make sense at all. Signed-off-by: Andrzej Puzdrowski <[email protected]>
1 parent 91e0895 commit b9d492e

File tree

6 files changed

+6
-0
lines changed

6 files changed

+6
-0
lines changed

drivers/flash/Kconfig.gecko

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ config SOC_FLASH_GECKO
99
select FLASH_HAS_DRIVER_ENABLED
1010
select FLASH_HAS_PAGE_LAYOUT
1111
select SOC_GECKO_MSC
12+
select MPU_ALLOW_FLASH_WRITE if ARM_MPU
1213
help
1314
Enable Silicon Labs Gecko series internal flash driver.
1415

drivers/flash/Kconfig.mcux

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ config SOC_FLASH_MCUX
55
depends on (HAS_MCUX_FTFX || HAS_MCUX_IAP)
66
select FLASH_HAS_PAGE_LAYOUT
77
select FLASH_HAS_DRIVER_ENABLED
8+
select MPU_ALLOW_FLASH_WRITE if ARM_MPU
89
help
910
Enables the MCUX flash shim driver.
1011
WARNING: This driver will disable the system interrupts for

drivers/flash/Kconfig.nrf

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ menuconfig SOC_FLASH_NRF
1414
select FLASH_HAS_PAGE_LAYOUT
1515
select FLASH_HAS_DRIVER_ENABLED
1616
select NRFX_NVMC
17+
select MPU_ALLOW_FLASH_WRITE if ARM_MPU
1718
default y
1819
help
1920
Enables Nordic Semiconductor nRF flash driver.

drivers/flash/Kconfig.sam

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ config SOC_FLASH_SAM
88
default y
99
select FLASH_HAS_PAGE_LAYOUT
1010
select FLASH_HAS_DRIVER_ENABLED
11+
select MPU_ALLOW_FLASH_WRITE if ARM_MPU
1112
depends on SOC_FAMILY_SAM
1213
depends on SOC_SERIES_SAME70 || \
1314
SOC_SERIES_SAMV71

drivers/flash/Kconfig.sam0

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ menuconfig SOC_FLASH_SAM0
99
depends on SOC_FAMILY_SAM0
1010
select FLASH_HAS_PAGE_LAYOUT
1111
select FLASH_HAS_DRIVER_ENABLED
12+
select MPU_ALLOW_FLASH_WRITE if ARM_MPU
1213
help
1314
Enable the Atmel SAM0 series internal flash driver.
1415

drivers/flash/Kconfig.stm32

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ config SOC_FLASH_STM32
2929
select FLASH_HAS_PAGE_LAYOUT if SOC_SERIES_STM32WBX
3030
select FLASH_HAS_PAGE_LAYOUT if SOC_SERIES_STM32G4X
3131
select FLASH_HAS_PAGE_LAYOUT if SOC_SERIES_STM32H7X
32+
select MPU_ALLOW_FLASH_WRITE if ARM_MPU
3233
help
3334
Enable STM32F0x, STM32F1x, STM32F3x, STM32F4x, STM32F7x, STM32L0x,
3435
STM32L1x, STM32L4x, STM32WBx, STM32G0x, STM32G4x or STM3H7x series

0 commit comments

Comments
 (0)