Skip to content

Commit ddc58c0

Browse files
DerekSnellkartben
authored andcommitted
boards: nxp: mimxrt1170_evk: improve zephyr,flash location for M4
- Fixes issue where zephyr,flash in ocram node overlaps with physical SRAM sram1 used for zephyr,sram. - Updates overlays that moved zephyr,flash to ocram now use default Signed-off-by: Derek Snell <[email protected]>
1 parent 6270d29 commit ddc58c0

13 files changed

+21
-12
lines changed

boards/nxp/mimxrt1170_evk/mimxrt1170_evk_mimxrt1176_cm4.dts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525
zephyr,shell-uart = &lpuart1;
2626
zephyr,canbus = &flexcan2;
2727
zephyr,flash-controller = &is25wp128;
28-
zephyr,flash = &ocram;
28+
zephyr,flash = &ocram_m4_itcm;
2929
nxp,m4-partition = &slot1_partition;
3030
zephyr,ipc = &mailbox_b;
3131
};

dts/arm/nxp/nxp_rt11xx.dtsi

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -951,6 +951,22 @@
951951
compatible = "zephyr,memory-region", "mmio-sram";
952952
zephyr,memory-region = "OCRAM";
953953
reg = <0x20200000 DT_SIZE_K(256)>;
954+
#address-cells = <1>;
955+
#size-cells = <1>;
956+
957+
/* The M7 core accesses the M4 TCMs through the OCRAM alias.
958+
* Add an OCRAM alias region just for the M4 ITCM. The M4
959+
* memory map:
960+
* 0x1FFE_0000 - 0x1FFF_FFFF: ITCM/RAM_L/sram0, OCRAM 0x2020_0000
961+
* 0x2000_0000 - 0x2001_FFFF: DTCM/RAM_U/sram1, OCRAM 0x2022_0000
962+
*
963+
* The M7 core can access this OCRAM alias for M4 ITCM and copy
964+
* the M4 image here.
965+
*/
966+
ocram_m4_itcm: ocram_m4_itcm@20200000 {
967+
compatible = "mmio-sram";
968+
reg = <0x20200000 DT_SIZE_K(128)>;
969+
};
954970
};
955971

956972
lpadc1: adc@40050000 {

dts/arm/nxp/nxp_rt11xx_cm4.dtsi

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,8 @@
2525
};
2626

2727
/*
28-
* SRAM0 & SRAM1 are available only to the M4 core. EDMA_LPSR interrupts are connected
28+
* SRAM0 & SRAM1 are TCMs for the M4 core, which the M7 can access through the OCRAM alias.
29+
* EDMA_LPSR interrupts are connected
2930
* to the M4 core alone, hence this EDMA controller has been designated M4 only.
3031
* GPIO's 9, 11 are available to both M4 and M7 cores, however the GPIO interrupts are
3132
* only accessible to the M4.
@@ -35,11 +36,13 @@
3536
soc {
3637
/delete-node/ dma-controller@40070000;
3738

39+
/* M4 ITCM RAM_L */
3840
sram0: memory@1ffe0000 {
3941
compatible = "mmio-sram";
4042
reg = <0x1ffe0000 DT_SIZE_K(128)>;
4143
};
4244

45+
/* M4 DTCM RAM_U */
4346
sram1: memory@20000000 {
4447
compatible = "zephyr,memory-region", "mmio-sram";
4548
reg = <0x20000000 DT_SIZE_K(128)>;

samples/drivers/mbox/remote/boards/mimxrt1170_evk_mimxrt1176_cm4.overlay

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@
66

77
/ {
88
chosen {
9-
zephyr,flash = &ocram;
109
zephyr,console = &lpuart1;
1110
zephyr,shell-uart = &lpuart1;
1211

samples/drivers/mbox/remote/boards/mimxrt1170_evk_mimxrt1176_cm4_B.overlay

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@
66

77
/ {
88
chosen {
9-
zephyr,flash = &ocram;
109
zephyr,console = &lpuart1;
1110
zephyr,shell-uart = &lpuart1;
1211

samples/drivers/mbox_data/remote/boards/mimxrt1170_evk_mimxrt1176_cm4.overlay

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@
66

77
/ {
88
chosen {
9-
zephyr,flash = &ocram;
109
zephyr,console = &lpuart2;
1110
zephyr,shell-uart = &lpuart2;
1211

samples/drivers/mbox_data/remote/boards/mimxrt1170_evk_mimxrt1176_cm4_B.overlay

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@
66

77
/ {
88
chosen {
9-
zephyr,flash = &ocram;
109
zephyr,console = &lpuart2;
1110
zephyr,shell-uart = &lpuart2;
1211

samples/subsys/ipc/ipc_service/static_vrings/remote/boards/mimxrt1170_evk_mimxrt1176_cm4.overlay

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@
99

1010
/ {
1111
chosen {
12-
zephyr,flash = &ocram;
1312
zephyr,console = &lpuart2;
1413
zephyr,shell-uart = &lpuart2;
1514

samples/subsys/ipc/ipc_service/static_vrings/remote/boards/mimxrt1170_evk_mimxrt1176_cm4_B.overlay

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@
99

1010
/ {
1111
chosen {
12-
zephyr,flash = &ocram;
1312
zephyr,console = &lpuart2;
1413
zephyr,shell-uart = &lpuart2;
1514

samples/subsys/ipc/openamp/remote/boards/mimxrt1170_evk_mimxrt1176_cm4.overlay

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@
99
/ {
1010
/* Switch to lpuart2, since primary core uses lpuart1 */
1111
chosen {
12-
zephyr,flash = &ocram;
1312
zephyr,console = &lpuart2;
1413
zephyr,shell-uart = &lpuart2;
1514
zephyr,ipc_shm = &ocram2_overlay;

0 commit comments

Comments
 (0)