Skip to content

Commit 7025f53

Browse files
committed
mcux: Relocate FlexSPI driver with XIP
Relocates the i.MX RT FlexSPI driver to the configured memory target if required. Signed-off-by: Pieter De Gendt <[email protected]>
1 parent ad8de4f commit 7025f53

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed

mcux/drivers/imx/CMakeLists.txt

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,10 @@ zephyr_library_sources_ifdef(CONFIG_VIDEO_MCUX_CSI fsl_csi.c)
3636
zephyr_library_sources_ifdef(CONFIG_WDT_MCUX_IMX_WDOG fsl_wdog.c)
3737
zephyr_library_sources_ifdef(CONFIG_CAN_MCUX_FLEXCAN fsl_flexcan.c)
3838

39+
if(CONFIG_FLASH_MCUX_FLEXSPI_XIP)
40+
zephyr_code_relocate(fsl_flexspi.c ${CONFIG_FLASH_MCUX_FLEXSPI_XIP_MEM}_TEXT)
41+
endif()
42+
3943
if(NOT CONFIG_ASSERT OR CONFIG_FORCE_NO_ASSERT)
4044
zephyr_compile_definitions(NDEBUG) # squelch fsl_flexcan.c warning
4145
endif()

mcux/drivers/imxrt6xx/CMakeLists.txt

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,3 +21,7 @@ zephyr_sources_ifdef(CONFIG_DMA_MCUX_LPC fsl_dma.c)
2121
zephyr_sources_ifdef(CONFIG_MCUX_ACMP fsl_acmp.c)
2222
zephyr_sources_ifdef(CONFIG_MEMC_MCUX_FLEXSPI fsl_flexspi.c)
2323
zephyr_sources_ifdef(CONFIG_MCUX_OS_TIMER fsl_ostimer.c)
24+
25+
if(CONFIG_FLASH_MCUX_FLEXSPI_XIP)
26+
zephyr_code_relocate(fsl_flexspi.c ${CONFIG_FLASH_MCUX_FLEXSPI_XIP_MEM}_TEXT)
27+
endif()

0 commit comments

Comments
 (0)