Skip to content

Commit

Permalink
boards: arm: stm32 u585 disco kit set flash partition
Browse files Browse the repository at this point in the history
Enables the flash controller node for the stm32u585 disco kit
with an arbitrary definition of the board partitions
to fill the 1MB bank1 of the flash memory,
for the secure and non-secure targets.

Signed-off-by: Francois Ramu <francois.ramu@st.com>
  • Loading branch information
FRASTM committed Mar 18, 2022
1 parent de5efa9 commit a996192
Show file tree
Hide file tree
Showing 2 changed files with 39 additions and 3 deletions.
36 changes: 36 additions & 0 deletions boards/arm/b_u585i_iot02a/b_u585i_iot02a.dts
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
zephyr,shell-uart = &usart1;
zephyr,sram = &sram0;
zephyr,flash = &flash0;
zephyr,code-partition = &slot0_partition;
};

aliases {
Expand All @@ -24,3 +25,38 @@
sw0 = &user_button;
};
};

&flash0 {
partitions {
compatible = "fixed-partitions";
#address-cells = <1>;
#size-cells = <1>;

/*
* Following flash partition is dedicated to the use of b_u585i_iot02a
* with TZEN=0 (so w/o TFM).
* Set the partitions with first MB to make use of the whole Bank1
*/
boot_partition: partition@0 {
label = "mcuboot";
reg = <0x00000000 0x10000>;
};
slot0_partition: partition@10000 {
label = "image-0";
reg = <0x00010000 0x68000>;
};
slot1_partition: partition@78000 {
label = "image-1";
reg = <0x00078000 0x68000>;
};
scratch_partition: partition@e0000 {
label = "image-scratch";
reg = <0x000e0000 0x10000>;
};
storage_partition: partition@f0000 {
label = "storage";
reg = <0x000f0000 0x10000>;
};

};
};
6 changes: 3 additions & 3 deletions boards/arm/b_u585i_iot02a/b_u585i_iot02a_ns.dts
Original file line number Diff line number Diff line change
Expand Up @@ -51,16 +51,16 @@
};
/* Non-secure image primary slot */
slot1_partition: partition@74000 {
label = "image-1";
label = "image-1-nonsecure";
reg = <0x00074000 0x00080000>;
};
/*
* The flash starting at 0xEA000 and ending at
* 0xEB000 is reserved for the application.
*/
storage_partition: partition@EA000 {
storage_partition: partition@ea000 {
label = "storage";
reg = <0x000EA000 0x00001000>;
reg = <0x000ea000 0x00001000>;
};
};
};

0 comments on commit a996192

Please sign in to comment.