Skip to content

Commit 2e9bfc2

Browse files
patrickdelaunayatorgue
authored andcommitted
ARM: dts: stm32: Enable reboot mode support to stm32mp157c
This patch enables syscon reboot mode. Normal, fastboot, recovery, serialx and usb boot modes are declared. Boot mode value is stored in TAMP backup register (TAMP_BKP20R offset 0x150). system.d command is need to set the boot mode. e.g. $ systemctl reboot ums_mmc0 Change-Id: Ia0f376c1d32772c22d571559d445cfdf4557989e Signed-off-by: Gabriel Fernandez <gabriel.fernandez@st.com> Signed-off-by: Lionel Debieve <lionel.debieve@st.com> Reviewed-on: https://gerrit.st.com/109570 Reviewed-by: CITOOLS <smet-aci-reviews@lists.codex.cro.st.com> Reviewed-by: CIBUILD <smet-aci-builds@lists.codex.cro.st.com> Reviewed-by: Alexandre TORGUE <alexandre.torgue@st.com> Reviewed-on: https://gerrit.st.com/c/mpu/oe/st/linux-stm32/+/144217 Tested-by: Alexandre TORGUE <alexandre.torgue@st.com> Reviewed-on: https://gerrit.st.com/c/mpu/oe/st/linux-stm32/+/146677
1 parent fa48dd3 commit 2e9bfc2

File tree

1 file changed

+18
-0
lines changed

1 file changed

+18
-0
lines changed

arch/arm/boot/dts/stm32mp157c.dtsi

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1534,6 +1534,24 @@
15341534
#size-cells = <0>;
15351535
status = "disabled";
15361536
};
1537+
1538+
tamp: tamp@5c00a000 {
1539+
compatible = "simple-bus", "syscon", "simple-mfd";
1540+
reg = <0x5c00a000 0x400>;
1541+
1542+
reboot-mode {
1543+
compatible = "syscon-reboot-mode";
1544+
offset = <0x150>; /* reg20 */
1545+
mask = <0xff>;
1546+
mode-normal = <0>;
1547+
mode-fastboot = <0x1>;
1548+
mode-recovery = <0x2>;
1549+
mode-stm32cubeprogrammer = <0x3>;
1550+
mode-ums_mmc0 = <0x10>;
1551+
mode-ums_mmc1 = <0x11>;
1552+
mode-ums_mmc2 = <0x12>;
1553+
};
1554+
};
15371555
};
15381556

15391557
mlahb {

0 commit comments

Comments
 (0)