From d633fb7ac1e6abc39270edebbfa23131c673b5b9 Mon Sep 17 00:00:00 2001 From: Sascha Hauer Date: Thu, 23 Apr 2015 10:35:40 +0200 Subject: clk: mediatek: Add reset controller support The pericfg and infracfg units also provide reset lines to several other SoC internal units. This adds a function which can be called from the pericfg and infracfg initialization functions which will register the reset controller using reset_controller_register. The reset controller will provide support for resetting the units connected to the pericfg and infracfg controller. The units resetted by this controller can use the standard reset device tree binding to gain access to the reset lines. Signed-off-by: Sascha Hauer Acked-by: Philipp Zabel Signed-off-by: Stephen Boyd --- drivers/clk/mediatek/clk-mtk.h | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'drivers/clk/mediatek/clk-mtk.h') diff --git a/drivers/clk/mediatek/clk-mtk.h b/drivers/clk/mediatek/clk-mtk.h index 38f8ceb0470b..9dda9d8ad10b 100644 --- a/drivers/clk/mediatek/clk-mtk.h +++ b/drivers/clk/mediatek/clk-mtk.h @@ -156,4 +156,14 @@ void __init mtk_clk_register_plls(struct device_node *node, const struct mtk_pll_data *plls, int num_plls, struct clk_onecell_data *clk_data); +#ifdef CONFIG_RESET_CONTROLLER +void mtk_register_reset_controller(struct device_node *np, + unsigned int num_regs, int regofs); +#else +static inline void mtk_register_reset_controller(struct device_node *np, + unsigned int num_regs, int regofs) +{ +} +#endif + #endif /* __DRV_CLK_MTK_H */ -- cgit v1.2.3