Skip to contentSkip to conversation

MIPS: ralink: add support for reset-controller API

PATCH Superseded John Crispin 1 participant 1 message Sep 3, 2013

Subsystems (2)

v2 of 3 Superseded Latest is v3 →

lore
Share & tools
lore
#0 lore raw

PATCH v2 1/1 MIPS: ralink: add support for reset-controller API

Add a helper for reseting different devices on the SoC.

---
 arch/mips/Kconfig         |    1 +
 arch/mips/ralink/common.h |    2 ++
 arch/mips/ralink/of.c     |    3 +++
 arch/mips/ralink/reset.c  |   62 +++++++++++++++++++++++++++++++++++++++++++++
 4 files changed, 68 insertions(+)
arch/mips/Kconfig +1 -0
index 45b4356..e59da94 100644
@@ -445,6 +445,7 @@ config RALINK
 	select HAVE_MACH_CLKDEV
 	select CLKDEV_LOOKUP
 	select ARCH_REQUIRE_GPIOLIB
+	select ARCH_HAS_RESET_CONTROLLER
 
 config SGI_IP22
 	bool "SGI IP22 (Indy/Indigo2)"
arch/mips/ralink/common.h +2 -0
index 83144c3..42dfd61 100644
@@ -46,6 +46,8 @@ extern void ralink_of_remap(void);
 extern void ralink_clk_init(void);
 extern void ralink_clk_add(const char *dev, unsigned long rate);
 
+extern void ralink_rst_init(void);
+
 extern void prom_soc_init(struct ralink_soc_info *soc_info);
 
 __iomem void *plat_of_remap_node(const char *node);
arch/mips/ralink/of.c +3 -0
index f25ea5b..ce38d11 100644
@@ -110,6 +110,9 @@ static int __init plat_of_setup(void)
 	if (of_platform_populate(NULL, of_ids, NULL, NULL))
 		panic("failed to populate DT\n");
 
+	/* make sure ithat the reset controller is setup early */
+	ralink_rst_init();
+
 	return 0;
 }
 
arch/mips/ralink/reset.c +62 -0

74 lines not on this page · raw message

Signature · 1 line
1.7.10.4