Skip to content

Commit f22d698

Browse files
committed
boards: arm: stm32u585 disco kit for XiP on external octoflash
Define the Device tree of the b_u585i_iot02a disco kit to access the external NOR octo-flash in MemoryMapped mode for XiP Signed-off-by: Francois Ramu <[email protected]>
1 parent efdb29d commit f22d698

File tree

3 files changed

+9
-11
lines changed

3 files changed

+9
-11
lines changed

boards/arm/b_u585i_iot02a/b_u585i_iot02a-common.dtsi

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -131,11 +131,10 @@
131131

132132
status = "okay";
133133

134-
mx25lm51245: ospi-nor-flash@0 {
134+
mx25lm51245: ospi-nor-flash@70000000 {
135135
compatible = "st,stm32-ospi-nor";
136-
reg = <0>;
136+
reg = <0x70000000 DT_SIZE_M(64)>; /* 512 Mbits */
137137
ospi-max-frequency = <DT_FREQ_M(50)>;
138-
size = <DT_SIZE_M(512)>; /* 64 MBytes */
139138
spi-bus-width = <OSPI_OPI_MODE>;
140139
data-rate = <OSPI_DTR_TRANSFER>;
141140
four-byte-opcodes;
@@ -146,8 +145,10 @@
146145
#address-cells = <1>;
147146
#size-cells = <1>;
148147

149-
partition@0 {
150-
reg = <0x00000000 DT_SIZE_M(64)>;
148+
/* put image at offset 0 in slot1 */
149+
slot1_partition:partition@0 {
150+
label = "nor";
151+
reg = <0x00000000 DT_SIZE_M(32)>;
151152
};
152153
};
153154
};

boards/arm/b_u585i_iot02a/b_u585i_iot02a.dts

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,8 @@
1616
zephyr,shell-uart = &usart1;
1717
zephyr,sram = &sram0;
1818
zephyr,flash = &flash0;
19-
zephyr,code-partition = &slot0_partition;
19+
zephyr,code-partition = &slot1_partition;
20+
zephyr,flash-controller = &mx25lm51245;
2021
};
2122

2223
aliases {
@@ -45,10 +46,7 @@
4546
label = "image-0";
4647
reg = <0x00010000 DT_SIZE_K(416)>;
4748
};
48-
slot1_partition: partition@78000 {
49-
label = "image-1";
50-
reg = <0x00078000 DT_SIZE_K(416)>;
51-
};
49+
5250
scratch_partition: partition@e0000 {
5351
label = "image-scratch";
5452
reg = <0x000e0000 DT_SIZE_K(64)>;

boards/arm/b_u585i_iot02a/board.cmake

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@ if(CONFIG_BUILD_WITH_TFM)
1212
endif()
1313
endif()
1414

15-
board_runner_args(stm32cubeprogrammer "--erase" "--port=swd" "--reset-mode=hw")
1615
board_runner_args(stm32cubeprogrammer "--port=swd" "--reset-mode=hw")
1716

1817
board_runner_args(openocd "--tcl-port=6666")

0 commit comments

Comments
 (0)