]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
stm32mp: handle SYSRESET
authorPatrick Delaunay <patrick.delaunay@st.com>
Tue, 20 Mar 2018 13:15:06 +0000 (14:15 +0100)
committerTom Rini <trini@konsulko.com>
Sat, 7 Apr 2018 00:45:44 +0000 (20:45 -0400)
Add support of sysreset with generic driver "syscon-reboot"
provided by RCC, for U-boot and for SPL.

Signed-off-by: Patrick Delaunay <patrick.delaunay@st.com>
arch/arm/Kconfig
arch/arm/dts/stm32mp157-u-boot.dtsi
arch/arm/dts/stm32mp157.dtsi
arch/arm/mach-stm32mp/Kconfig
arch/arm/mach-stm32mp/cpu.c

index 777b2f01ec58d8714468a1d39745ddb31f0f9405..190f883aa800593a7a8f57f71a30e69a2ffc7638 100644 (file)
@@ -1166,6 +1166,7 @@ config ARCH_STM32MP
        select REGMAP
        select SUPPORT_SPL
        select SYSCON
+       select SYSRESET
        select SYS_THUMB_BUILD
        help
          Support for STM32MP SoC family developed by STMicroelectronics,
index 7a9a4ce73cf5d9be38800de129497f750d5b7b4e..1eca8020f966e2f8af0e39467c6969bc1370b253 100644 (file)
        u-boot,dm-pre-reloc;
 };
 
+&rcc_reboot {
+       u-boot,dm-pre-reloc;
+};
+
 &pinctrl {
        u-boot,dm-pre-reloc;
 };
index 77953c8e9d2c3601804785e434737fcfc01a9d6a..b84899a1ea94c1990dd00e19a38b28fb65530b17 100644 (file)
                                #reset-cells = <1>;
                                compatible = "st,stm32mp1-rcc-rst";
                        };
+
+                       rcc_reboot: rcc-reboot@50000000 {
+                               compatible = "syscon-reboot";
+                               regmap = <&rcc>;
+                               offset = <0x404>;
+                               mask = <0x1>;
+                       };
                };
 
                pinctrl: pin-controller {
index 9771af927a13ec0cf25144b62d96b04662141def..8ca97bf0c960885b81811cc6585901fe7ffa57d7 100644 (file)
@@ -16,6 +16,7 @@ config SPL
        select SPL_RESET_SUPPORT
        select SPL_SERIAL_SUPPORT
        select SPL_SYSCON
+       select SPL_DRIVERS_MISC_SUPPORT
        imply SPL_LIBDISK_SUPPORT
 
 config SYS_SOC
@@ -26,6 +27,7 @@ config TARGET_STM32MP1
        select CPU_V7
        select PINCTRL_STM32
        select STM32_RESET
+       select SYSRESET_SYSCON
        help
                target STMicroelectronics SOC STM32MP1 family
                STMicroelectronics MPU with core ARMv7
index 4ba2aecb7f1cfc9ffc2da9a5b3ed6fe7b5fff0ae..f9f3bf9050ecf31c689c7e1cee5451795dbffee3 100644 (file)
@@ -269,7 +269,3 @@ int arch_misc_init(void)
 
        return 0;
 }
-
-void reset_cpu(ulong addr)
-{
-}