boards: nxp: mimxrt1180_evk: add flexspi1 support
USE_HYPERRAM macro defined shouldn't be placed under CONFIG_BOOT_FLEXSPI_NOR. Add flexspi1 pinmux pinctrl and flash partitions Add flash partitions and correct flash parameter. This commit was tested with samples: flash_shell on cm33/cm7 cores Signed-off-by: Lucien Zhao <lucien.zhao@nxp.com>
This commit is contained in:
parent
6463dd610d
commit
850d471b95
4 changed files with 54 additions and 6 deletions
|
|
@ -22,11 +22,12 @@ if(CONFIG_NXP_IMXRT_BOOT_HEADER)
|
|||
# used on your custom board.
|
||||
zephyr_compile_definitions(XIP_EXTERNAL_FLASH=1)
|
||||
zephyr_compile_definitions(XIP_BOOT_HEADER_ENABLE=1)
|
||||
if(CONFIG_EXTERNAL_MEM_CONFIG_DATA AND CONFIG_NXP_IMX_EXTERNAL_HYPERRAM)
|
||||
zephyr_compile_definitions(USE_HYPERRAM)
|
||||
endif()
|
||||
zephyr_library_sources(${RT1180_BOARD_DIR}/xip/evkmimxrt1180_flexspi_nor_config.c)
|
||||
zephyr_library_include_directories(${RT1180_BOARD_DIR}/xip)
|
||||
zephyr_library_include_directories(${RT1180_BOARD_DIR})
|
||||
endif()
|
||||
if(CONFIG_EXTERNAL_MEM_CONFIG_DATA AND CONFIG_NXP_IMX_EXTERNAL_HYPERRAM)
|
||||
zephyr_compile_definitions(USE_HYPERRAM)
|
||||
zephyr_library_sources(${RT1180_BOARD_DIR}/xip/evkmimxrt1180_flexspi_nor_config.c)
|
||||
endif()
|
||||
endif()
|
||||
|
|
|
|||
|
|
@ -112,6 +112,8 @@ configuration supports the following hardware features:
|
|||
+-----------+------------+-------------------------------------+
|
||||
| LPTMR | on-chip | counter |
|
||||
+-----------+------------+-------------------------------------+
|
||||
| FLEXSPI | on-chip | flash programming |
|
||||
+-----------+------------+-------------------------------------+
|
||||
|
||||
The default configuration can be found in the defconfig file:
|
||||
:zephyr_file:`boards/nxp/mimxrt1180_evk/mimxrt1180_evk_mimxrt1189_cm33_defconfig`
|
||||
|
|
|
|||
|
|
@ -115,4 +115,18 @@
|
|||
slew-rate = "fast";
|
||||
};
|
||||
};
|
||||
|
||||
pinmux_flexspi1: pinmux_flexspi1 {
|
||||
group0 {
|
||||
pinmux = <&iomuxc_gpio_sd_b2_05_flexspi1_b_dqs>,
|
||||
<&iomuxc_gpio_sd_b2_06_flexspi1_b_ss0_b>,
|
||||
<&iomuxc_gpio_sd_b2_07_flexspi1_b_sclk>,
|
||||
<&iomuxc_gpio_sd_b2_08_flexspi1_b_data0>,
|
||||
<&iomuxc_gpio_sd_b2_09_flexspi1_b_data1>,
|
||||
<&iomuxc_gpio_sd_b2_10_flexspi1_b_data2>,
|
||||
<&iomuxc_gpio_sd_b2_11_flexspi1_b_data3>;
|
||||
bias-pull-down;
|
||||
input-enable;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
|
|
|||
|
|
@ -55,20 +55,51 @@
|
|||
status = "okay";
|
||||
};
|
||||
|
||||
&flexspi1 {
|
||||
&flexspi {
|
||||
pinctrl-0 = <&pinmux_flexspi1>;
|
||||
pinctrl-names = "default";
|
||||
};
|
||||
|
||||
&flexspi {
|
||||
status = "okay";
|
||||
ahb-prefetch;
|
||||
ahb-read-addr-opt;
|
||||
rx-clock-source = <1>;
|
||||
w25q128jw: w25q128jw@0 {
|
||||
compatible = "nxp,imx-flexspi-nor";
|
||||
size = <134217728>;
|
||||
size = <DT_SIZE_M(16*8)>;
|
||||
reg = <0>;
|
||||
spi-max-frequency = <133000000>;
|
||||
status = "okay";
|
||||
jedec-id = [ef 80 18];
|
||||
jedec-id = [ef 60 18];
|
||||
erase-block-size = <4096>;
|
||||
write-block-size = <1>;
|
||||
|
||||
partitions {
|
||||
compatible = "fixed-partitions";
|
||||
#address-cells = <1>;
|
||||
#size-cells = <1>;
|
||||
|
||||
boot_partition: partition@0 {
|
||||
label = "mcuboot";
|
||||
reg = <0x00000000 DT_SIZE_K(128)>;
|
||||
};
|
||||
/* The MCUBoot swap-move algorithm uses the last 3 sectors
|
||||
* of the primary slot0 for swap status and move.
|
||||
*/
|
||||
slot0_partition: partition@20000 {
|
||||
label = "image-0";
|
||||
reg = <0x00020000 (DT_SIZE_M(7) + DT_SIZE_K(12))>;
|
||||
};
|
||||
slot1_partition: partition@723000 {
|
||||
label = "image-1";
|
||||
reg = <0x00723000 DT_SIZE_M(7)>;
|
||||
};
|
||||
storage_partition: partition@E23000 {
|
||||
label = "storage";
|
||||
reg = <0x00E23000 (DT_SIZE_M(2) - DT_SIZE_K(140))>;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue