89 lines
2.5 KiB
Plaintext
89 lines
2.5 KiB
Plaintext
# SPDX-License-Identifier: Apache-2.0
|
|
|
|
config SOC_FLASH_MCUX
|
|
bool "MCUX flash shim driver"
|
|
depends on (HAS_MCUX_FTFX || HAS_MCUX_IAP)
|
|
select FLASH_HAS_PAGE_LAYOUT
|
|
select FLASH_HAS_DRIVER_ENABLED
|
|
select MPU_ALLOW_FLASH_WRITE if ARM_MPU
|
|
help
|
|
Enables the MCUX flash shim driver.
|
|
WARNING: This driver will disable the system interrupts for
|
|
the duration of the flash erase/write operations. This will
|
|
have an impact on the overall system performance - whether
|
|
this is acceptable or not will depend on the use case.
|
|
|
|
if SOC_FLASH_MCUX
|
|
|
|
config CHECK_BEFORE_READING
|
|
bool "Verify area before reading it"
|
|
default y if SOC_SERIES_LPC55XXX
|
|
help
|
|
Do a margin check flash command before reading an area.
|
|
This feature prevents erroneous/forbidden reading. Some ECC enabled
|
|
devices will crash when reading an erased or wrongly programmed area.
|
|
|
|
endif # SOC_FLASH_MCUX
|
|
|
|
if HAS_MCUX_FLEXSPI
|
|
|
|
config FLASH_MCUX_FLEXSPI_NOR
|
|
bool "MCUX FlexSPI NOR driver"
|
|
select FLASH_HAS_PAGE_LAYOUT
|
|
select FLASH_HAS_DRIVER_ENABLED
|
|
select MEMC
|
|
select MEMC_MCUX_FLEXSPI
|
|
|
|
config FLASH_MCUX_FLEXSPI_MX25UM51345G
|
|
bool "MCUX FlexSPI MX25UM51345G driver"
|
|
select FLASH_HAS_PAGE_LAYOUT
|
|
select FLASH_HAS_DRIVER_ENABLED
|
|
select MEMC
|
|
select MEMC_MCUX_FLEXSPI
|
|
|
|
config FLASH_MCUX_FLEXSPI_NOR_WRITE_BUFFER
|
|
bool "MCUX FlexSPI NOR write RAM buffer"
|
|
default y
|
|
depends on (FLASH_MCUX_FLEXSPI_NOR || FLASH_MCUX_FLEXSPI_MX25UM51345G)
|
|
help
|
|
Copy the data to a RAM buffer before writing it to the flash.
|
|
This prevents faults when the data to write would be located on the
|
|
flash itself.
|
|
|
|
config FLASH_MCUX_FLEXSPI_XIP
|
|
bool "MCUX FlexSPI flash access with xip"
|
|
depends on MEMC_MCUX_FLEXSPI
|
|
depends on (CODE_FLEXSPI || CODE_FLEXSPI2 || SOC_SERIES_IMX_RT6XX)
|
|
select XIP
|
|
help
|
|
Allows using the flash API while running in XIP.
|
|
WARNING: It is possible to overwrite the running application itself.
|
|
|
|
if FLASH_MCUX_FLEXSPI_XIP
|
|
|
|
choice FLASH_MCUX_FLEXSPI_XIP_MEM_TARGET
|
|
prompt "FlexSPI drivers relocation target"
|
|
default FLASH_MCUX_FLEXSPI_XIP_MEM_ITCM
|
|
help
|
|
Select the location to run the FlexSPI drivers when using
|
|
the flash API.
|
|
|
|
config FLASH_MCUX_FLEXSPI_XIP_MEM_ITCM
|
|
bool "ITCM"
|
|
select CODE_DATA_RELOCATION
|
|
|
|
config FLASH_MCUX_FLEXSPI_XIP_MEM_SRAM
|
|
bool "SRAM"
|
|
select CODE_DATA_RELOCATION_SRAM
|
|
|
|
endchoice
|
|
|
|
config FLASH_MCUX_FLEXSPI_XIP_MEM
|
|
string
|
|
default "ITCM" if FLASH_MCUX_FLEXSPI_XIP_MEM_ITCM
|
|
default "SRAM" if FLASH_MCUX_FLEXSPI_XIP_MEM_SRAM
|
|
|
|
endif # FLASH_MCUX_FLEXSPI_XIP
|
|
|
|
endif # HAS_MCUX_FLEXSPI
|