Skip to content

Commit 63266e4

Browse files
danieldegrassecarlescufi
authored andcommitted
boards: mimxrt1170_evk: Refactor flexspi partition definition
Flexspi partition definition is shared between both cm4 and cm7 core. Refactor it to be in shared dtsi file. This will ensure that both cores share the same partition information, for dual core operation. Signed-off-by: Daniel DeGrasse <[email protected]>
1 parent 6bcdcc3 commit 63266e4

File tree

3 files changed

+48
-94
lines changed

3 files changed

+48
-94
lines changed

boards/arm/mimxrt1170_evk/mimxrt1170_evk.dtsi

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -147,3 +147,51 @@
147147
pinctrl-1 = <&pinmux_usdhc1_dat3_nopull>;
148148
pinctrl-names = "default", "nopull";
149149
};
150+
151+
&flexspi {
152+
status = "okay";
153+
ahb-prefetch;
154+
ahb-read-addr-opt;
155+
rx-clock-source = <1>;
156+
reg = <0x400cc000 0x4000>, <0x30000000 DT_SIZE_M(16)>;
157+
is25wp128: is25wp128@0 {
158+
compatible = "nxp,imx-flexspi-nor";
159+
size = <134217728>;
160+
reg = <0>;
161+
spi-max-frequency = <133000000>;
162+
status = "okay";
163+
jedec-id = [9d 70 17];
164+
erase-block-size = <4096>;
165+
write-block-size = <1>;
166+
167+
partitions {
168+
compatible = "fixed-partitions";
169+
#address-cells = <1>;
170+
#size-cells = <1>;
171+
172+
boot_partition: partition@0 {
173+
label = "mcuboot";
174+
reg = <0x00000000 DT_SIZE_K(128)>;
175+
};
176+
/* Note slot 0 has one additional sector,
177+
* this is intended for use with the swap move algorithm
178+
*/
179+
slot0_partition: partition@20000 {
180+
label = "image-0";
181+
reg = <0x00020000 0x301000>;
182+
};
183+
slot1_partition: partition@321000 {
184+
label = "image-1";
185+
reg = <0x00321000 0x300000>;
186+
};
187+
scratch_partition: partition@621000 {
188+
label = "image-scratch";
189+
reg = <0x00621000 DT_SIZE_K(128)>;
190+
};
191+
storage_partition: partition@641000 {
192+
label = "storage";
193+
reg = <0x00641000 DT_SIZE_K(1856)>;
194+
};
195+
};
196+
};
197+
};

boards/arm/mimxrt1170_evk/mimxrt1170_evk_cm4.dts

Lines changed: 0 additions & 46 deletions
Original file line numberDiff line numberDiff line change
@@ -45,52 +45,6 @@
4545
status = "okay";
4646
};
4747

48-
&flexspi {
49-
status = "okay";
50-
ahb-prefetch;
51-
ahb-read-addr-opt;
52-
rx-clock-source = <1>;
53-
reg = <0x400cc000 0x4000>, <0x30000000 DT_SIZE_M(16)>;
54-
is25wp128: is25wp128@0 {
55-
compatible = "nxp,imx-flexspi-nor";
56-
size = <134217728>;
57-
reg = <0>;
58-
spi-max-frequency = <133000000>;
59-
status = "okay";
60-
jedec-id = [9d 70 17];
61-
62-
partitions {
63-
compatible = "fixed-partitions";
64-
#address-cells = <1>;
65-
#size-cells = <1>;
66-
67-
boot_partition: partition@0 {
68-
label = "mcuboot";
69-
reg = <0x00000000 DT_SIZE_K(128)>;
70-
};
71-
/* Note slot 0 has one additional sector,
72-
* this is intended for use with the swap move algorithm
73-
*/
74-
slot0_partition: partition@20000 {
75-
label = "image-0";
76-
reg = <0x00020000 0x301000>;
77-
};
78-
slot1_partition: partition@321000 {
79-
label = "image-1";
80-
reg = <0x00321000 0x300000>;
81-
};
82-
scratch_partition: partition@621000 {
83-
label = "image-scratch";
84-
reg = <0x00621000 DT_SIZE_K(128)>;
85-
};
86-
storage_partition: partition@641000 {
87-
label = "storage";
88-
reg = <0x00641000 DT_SIZE_K(1856)>;
89-
};
90-
};
91-
};
92-
};
93-
9448
/* Enable GPT for use as a hardware timer. This disables Cortex Systick.
9549
* to use systick, change this node from "gpt_hw_timer" to "systick"
9650
*/

boards/arm/mimxrt1170_evk/mimxrt1170_evk_cm7.dts

Lines changed: 0 additions & 48 deletions
Original file line numberDiff line numberDiff line change
@@ -115,54 +115,6 @@
115115
};
116116
};
117117

118-
&flexspi {
119-
status = "okay";
120-
ahb-prefetch;
121-
ahb-read-addr-opt;
122-
rx-clock-source = <1>;
123-
reg = <0x400cc000 0x4000>, <0x30000000 DT_SIZE_M(16)>;
124-
is25wp128: is25wp128@0 {
125-
compatible = "nxp,imx-flexspi-nor";
126-
size = <134217728>;
127-
reg = <0>;
128-
spi-max-frequency = <133000000>;
129-
status = "okay";
130-
jedec-id = [9d 70 17];
131-
erase-block-size = <4096>;
132-
write-block-size = <1>;
133-
134-
partitions {
135-
compatible = "fixed-partitions";
136-
#address-cells = <1>;
137-
#size-cells = <1>;
138-
139-
boot_partition: partition@0 {
140-
label = "mcuboot";
141-
reg = <0x00000000 DT_SIZE_K(128)>;
142-
};
143-
/* Note slot 0 has one additional sector,
144-
* this is intended for use with the swap move algorithm
145-
*/
146-
slot0_partition: partition@20000 {
147-
label = "image-0";
148-
reg = <0x00020000 0x301000>;
149-
};
150-
slot1_partition: partition@321000 {
151-
label = "image-1";
152-
reg = <0x00321000 0x300000>;
153-
};
154-
scratch_partition: partition@621000 {
155-
label = "image-scratch";
156-
reg = <0x00621000 DT_SIZE_K(128)>;
157-
};
158-
storage_partition: partition@641000 {
159-
label = "storage";
160-
reg = <0x00641000 DT_SIZE_K(1856)>;
161-
};
162-
};
163-
};
164-
};
165-
166118
&lpadc0 {
167119
status = "okay";
168120
};

0 commit comments

Comments
 (0)