* [PATCH 1/7] ARM: imx: add mmdc ipg clock operation for mmdc
2018-08-31 7:53 [PATCH 0/7] Add i.MX6 SoCs mmdc ipg clocks management Anson Huang
@ 2018-08-31 7:53 ` Anson Huang
2018-09-10 0:17 ` Shawn Guo
2018-08-31 7:53 ` [PATCH 2/7] clk: imx6ul: add mmdc1 ipg clock Anson Huang
` (5 subsequent siblings)
6 siblings, 1 reply; 20+ messages in thread
From: Anson Huang @ 2018-08-31 7:53 UTC (permalink / raw)
To: shawnguo, s.hauer, kernel, fabio.estevam, robh+dt, mark.rutland,
linux, mturquette, sboyd, colin.didier, clement.peron, ping.bai,
aisheng.dong, shengjiu.wang, matteo.lisi, michael,
linux-arm-kernel, devicetree, linux-kernel, linux-clk
Cc: Linux-imx
i.MX6 SoCs have MMDC ipg clock for registers access, to make
sure MMDC registers access successfully, add optional clock
enable for MMDC driver.
Signed-off-by: Anson Huang <Anson.Huang@nxp.com>
---
arch/arm/mach-imx/mmdc.c | 14 ++++++++++++++
1 file changed, 14 insertions(+)
diff --git a/arch/arm/mach-imx/mmdc.c b/arch/arm/mach-imx/mmdc.c
index 04b3bf7..e49e068 100644
--- a/arch/arm/mach-imx/mmdc.c
+++ b/arch/arm/mach-imx/mmdc.c
@@ -11,6 +11,7 @@
* http://www.gnu.org/copyleft/gpl.html
*/
+#include <linux/clk.h>
#include <linux/hrtimer.h>
#include <linux/init.h>
#include <linux/interrupt.h>
@@ -546,7 +547,20 @@ static int imx_mmdc_probe(struct platform_device *pdev)
{
struct device_node *np = pdev->dev.of_node;
void __iomem *mmdc_base, *reg;
+ struct clk *mmdc_ipg_clk;
u32 val;
+ int err;
+
+ /* the ipg clock is optional */
+ mmdc_ipg_clk = devm_clk_get(&pdev->dev, NULL);
+ if (IS_ERR(mmdc_ipg_clk))
+ mmdc_ipg_clk = NULL;
+
+ err = clk_prepare_enable(mmdc_ipg_clk);
+ if (err) {
+ dev_err(&pdev->dev, "Unable to enable mmdc ipg clock.\n");
+ return err;
+ }
mmdc_base = of_iomap(np, 0);
WARN_ON(!mmdc_base);
--
2.7.4
^ permalink raw reply related [flat|nested] 20+ messages in thread
* Re: [PATCH 1/7] ARM: imx: add mmdc ipg clock operation for mmdc
2018-08-31 7:53 ` [PATCH 1/7] ARM: imx: add mmdc ipg clock operation for mmdc Anson Huang
@ 2018-09-10 0:17 ` Shawn Guo
0 siblings, 0 replies; 20+ messages in thread
From: Shawn Guo @ 2018-09-10 0:17 UTC (permalink / raw)
To: Anson Huang
Cc: s.hauer, kernel, fabio.estevam, robh+dt, mark.rutland, linux,
mturquette, sboyd, colin.didier, clement.peron, ping.bai,
aisheng.dong, shengjiu.wang, matteo.lisi, michael,
linux-arm-kernel, devicetree, linux-kernel, linux-clk, Linux-imx
On Fri, Aug 31, 2018 at 03:53:12PM +0800, Anson Huang wrote:
> i.MX6 SoCs have MMDC ipg clock for registers access, to make
> sure MMDC registers access successfully, add optional clock
> enable for MMDC driver.
>
> Signed-off-by: Anson Huang <Anson.Huang@nxp.com>
Applied this one, thanks.
^ permalink raw reply [flat|nested] 20+ messages in thread
* [PATCH 2/7] clk: imx6ul: add mmdc1 ipg clock
2018-08-31 7:53 [PATCH 0/7] Add i.MX6 SoCs mmdc ipg clocks management Anson Huang
2018-08-31 7:53 ` [PATCH 1/7] ARM: imx: add mmdc ipg clock operation for mmdc Anson Huang
@ 2018-08-31 7:53 ` Anson Huang
2018-09-04 13:36 ` Rob Herring
2018-10-17 18:16 ` Stephen Boyd
2018-08-31 7:53 ` [PATCH 3/7] clk: imx6sx: " Anson Huang
` (4 subsequent siblings)
6 siblings, 2 replies; 20+ messages in thread
From: Anson Huang @ 2018-08-31 7:53 UTC (permalink / raw)
To: shawnguo, s.hauer, kernel, fabio.estevam, robh+dt, mark.rutland,
linux, mturquette, sboyd, colin.didier, clement.peron, ping.bai,
aisheng.dong, shengjiu.wang, matteo.lisi, michael,
linux-arm-kernel, devicetree, linux-kernel, linux-clk
Cc: Linux-imx
i.MX6UL has MMDC1 ipg clock in CCM CCGR, add it into
clock tree for clock management.
Signed-off-by: Anson Huang <Anson.Huang@nxp.com>
---
drivers/clk/imx/clk-imx6ul.c | 1 +
include/dt-bindings/clock/imx6ul-clock.h | 3 ++-
2 files changed, 3 insertions(+), 1 deletion(-)
diff --git a/drivers/clk/imx/clk-imx6ul.c b/drivers/clk/imx/clk-imx6ul.c
index 361b43f..fd60d15 100644
--- a/drivers/clk/imx/clk-imx6ul.c
+++ b/drivers/clk/imx/clk-imx6ul.c
@@ -408,6 +408,7 @@ static void __init imx6ul_clocks_init(struct device_node *ccm_node)
clks[IMX6UL_CLK_WDOG1] = imx_clk_gate2("wdog1", "ipg", base + 0x74, 16);
clks[IMX6UL_CLK_MMDC_P0_FAST] = imx_clk_gate_flags("mmdc_p0_fast", "mmdc_podf", base + 0x74, 20, CLK_IS_CRITICAL);
clks[IMX6UL_CLK_MMDC_P0_IPG] = imx_clk_gate2_flags("mmdc_p0_ipg", "ipg", base + 0x74, 24, CLK_IS_CRITICAL);
+ clks[IMX6UL_CLK_MMDC_P1_IPG] = imx_clk_gate2("mmdc_p1_ipg", "ipg", base + 0x74, 26);
clks[IMX6UL_CLK_AXI] = imx_clk_gate_flags("axi", "axi_podf", base + 0x74, 28, CLK_IS_CRITICAL);
/* CCGR4 */
diff --git a/include/dt-bindings/clock/imx6ul-clock.h b/include/dt-bindings/clock/imx6ul-clock.h
index f8e0476..f718aac 100644
--- a/include/dt-bindings/clock/imx6ul-clock.h
+++ b/include/dt-bindings/clock/imx6ul-clock.h
@@ -259,7 +259,8 @@
#define IMX6UL_CLK_GPIO3 246
#define IMX6UL_CLK_GPIO4 247
#define IMX6UL_CLK_GPIO5 248
+#define IMX6UL_CLK_MMDC_P1_IPG 249
-#define IMX6UL_CLK_END 249
+#define IMX6UL_CLK_END 250
#endif /* __DT_BINDINGS_CLOCK_IMX6UL_H */
--
2.7.4
^ permalink raw reply related [flat|nested] 20+ messages in thread
* Re: [PATCH 2/7] clk: imx6ul: add mmdc1 ipg clock
2018-08-31 7:53 ` [PATCH 2/7] clk: imx6ul: add mmdc1 ipg clock Anson Huang
@ 2018-09-04 13:36 ` Rob Herring
2018-10-17 18:16 ` Stephen Boyd
1 sibling, 0 replies; 20+ messages in thread
From: Rob Herring @ 2018-09-04 13:36 UTC (permalink / raw)
To: Anson Huang
Cc: shawnguo, s.hauer, kernel, fabio.estevam, robh+dt, mark.rutland,
linux, mturquette, sboyd, colin.didier, clement.peron, ping.bai,
aisheng.dong, shengjiu.wang, matteo.lisi, michael,
linux-arm-kernel, devicetree, linux-kernel, linux-clk, Linux-imx
On Fri, 31 Aug 2018 15:53:13 +0800, Anson Huang wrote:
> i.MX6UL has MMDC1 ipg clock in CCM CCGR, add it into
> clock tree for clock management.
>
> Signed-off-by: Anson Huang <Anson.Huang@nxp.com>
> ---
> drivers/clk/imx/clk-imx6ul.c | 1 +
> include/dt-bindings/clock/imx6ul-clock.h | 3 ++-
> 2 files changed, 3 insertions(+), 1 deletion(-)
>
Reviewed-by: Rob Herring <robh@kernel.org>
^ permalink raw reply [flat|nested] 20+ messages in thread
* Re: [PATCH 2/7] clk: imx6ul: add mmdc1 ipg clock
2018-08-31 7:53 ` [PATCH 2/7] clk: imx6ul: add mmdc1 ipg clock Anson Huang
2018-09-04 13:36 ` Rob Herring
@ 2018-10-17 18:16 ` Stephen Boyd
1 sibling, 0 replies; 20+ messages in thread
From: Stephen Boyd @ 2018-10-17 18:16 UTC (permalink / raw)
To: Anson Huang, aisheng.dong, clement.peron, colin.didier,
devicetree, fabio.estevam, kernel, linux-arm-kernel, linux-clk,
linux-kernel, linux, mark.rutland, matteo.lisi, michael,
mturquette, ping.bai, robh+dt, s.hauer, shawnguo, shengjiu.wang
Cc: Linux-imx
Quoting Anson Huang (2018-08-31 00:53:13)
> i.MX6UL has MMDC1 ipg clock in CCM CCGR, add it into
> clock tree for clock management.
>
> Signed-off-by: Anson Huang <Anson.Huang@nxp.com>
> ---
Applied to clk-next
^ permalink raw reply [flat|nested] 20+ messages in thread
* [PATCH 3/7] clk: imx6sx: add mmdc1 ipg clock
2018-08-31 7:53 [PATCH 0/7] Add i.MX6 SoCs mmdc ipg clocks management Anson Huang
2018-08-31 7:53 ` [PATCH 1/7] ARM: imx: add mmdc ipg clock operation for mmdc Anson Huang
2018-08-31 7:53 ` [PATCH 2/7] clk: imx6ul: add mmdc1 ipg clock Anson Huang
@ 2018-08-31 7:53 ` Anson Huang
2018-09-04 13:36 ` Rob Herring
2018-10-17 18:16 ` Stephen Boyd
2018-08-31 7:53 ` [PATCH 4/7] clk: imx6sll: " Anson Huang
` (3 subsequent siblings)
6 siblings, 2 replies; 20+ messages in thread
From: Anson Huang @ 2018-08-31 7:53 UTC (permalink / raw)
To: shawnguo, s.hauer, kernel, fabio.estevam, robh+dt, mark.rutland,
linux, mturquette, sboyd, colin.didier, clement.peron, ping.bai,
aisheng.dong, shengjiu.wang, matteo.lisi, michael,
linux-arm-kernel, devicetree, linux-kernel, linux-clk
Cc: Linux-imx
i.MX6SX has MMDC1 ipg clock in CCM CCGR, add it into
clock tree for clock management.
Signed-off-by: Anson Huang <Anson.Huang@nxp.com>
---
drivers/clk/imx/clk-imx6sx.c | 1 +
include/dt-bindings/clock/imx6sx-clock.h | 3 ++-
2 files changed, 3 insertions(+), 1 deletion(-)
diff --git a/drivers/clk/imx/clk-imx6sx.c b/drivers/clk/imx/clk-imx6sx.c
index d9f2890..18527a3 100644
--- a/drivers/clk/imx/clk-imx6sx.c
+++ b/drivers/clk/imx/clk-imx6sx.c
@@ -431,6 +431,7 @@ static void __init imx6sx_clocks_init(struct device_node *ccm_node)
clks[IMX6SX_CLK_MLB] = imx_clk_gate2("mlb", "ahb", base + 0x74, 18);
clks[IMX6SX_CLK_MMDC_P0_FAST] = imx_clk_gate2_flags("mmdc_p0_fast", "mmdc_podf", base + 0x74, 20, CLK_IS_CRITICAL);
clks[IMX6SX_CLK_MMDC_P0_IPG] = imx_clk_gate2_flags("mmdc_p0_ipg", "ipg", base + 0x74, 24, CLK_IS_CRITICAL);
+ clks[IMX6SX_CLK_MMDC_P1_IPG] = imx_clk_gate2("mmdc_p1_ipg", "ipg", base + 0x74, 26);
clks[IMX6SX_CLK_OCRAM] = imx_clk_gate2_flags("ocram", "ocram_podf", base + 0x74, 28, CLK_IS_CRITICAL);
/* CCGR4 */
diff --git a/include/dt-bindings/clock/imx6sx-clock.h b/include/dt-bindings/clock/imx6sx-clock.h
index cd2d6c5..fb420c7 100644
--- a/include/dt-bindings/clock/imx6sx-clock.h
+++ b/include/dt-bindings/clock/imx6sx-clock.h
@@ -279,6 +279,7 @@
#define IMX6SX_CLK_LVDS2_OUT 266
#define IMX6SX_CLK_LVDS2_IN 267
#define IMX6SX_CLK_ANACLK2 268
-#define IMX6SX_CLK_CLK_END 269
+#define IMX6SX_CLK_MMDC_P1_IPG 269
+#define IMX6SX_CLK_CLK_END 270
#endif /* __DT_BINDINGS_CLOCK_IMX6SX_H */
--
2.7.4
^ permalink raw reply related [flat|nested] 20+ messages in thread
* Re: [PATCH 3/7] clk: imx6sx: add mmdc1 ipg clock
2018-08-31 7:53 ` [PATCH 3/7] clk: imx6sx: " Anson Huang
@ 2018-09-04 13:36 ` Rob Herring
2018-10-17 18:16 ` Stephen Boyd
1 sibling, 0 replies; 20+ messages in thread
From: Rob Herring @ 2018-09-04 13:36 UTC (permalink / raw)
To: Anson Huang
Cc: shawnguo, s.hauer, kernel, fabio.estevam, robh+dt, mark.rutland,
linux, mturquette, sboyd, colin.didier, clement.peron, ping.bai,
aisheng.dong, shengjiu.wang, matteo.lisi, michael,
linux-arm-kernel, devicetree, linux-kernel, linux-clk, Linux-imx
On Fri, 31 Aug 2018 15:53:14 +0800, Anson Huang wrote:
> i.MX6SX has MMDC1 ipg clock in CCM CCGR, add it into
> clock tree for clock management.
>
> Signed-off-by: Anson Huang <Anson.Huang@nxp.com>
> ---
> drivers/clk/imx/clk-imx6sx.c | 1 +
> include/dt-bindings/clock/imx6sx-clock.h | 3 ++-
> 2 files changed, 3 insertions(+), 1 deletion(-)
>
Reviewed-by: Rob Herring <robh@kernel.org>
^ permalink raw reply [flat|nested] 20+ messages in thread
* Re: [PATCH 3/7] clk: imx6sx: add mmdc1 ipg clock
2018-08-31 7:53 ` [PATCH 3/7] clk: imx6sx: " Anson Huang
2018-09-04 13:36 ` Rob Herring
@ 2018-10-17 18:16 ` Stephen Boyd
1 sibling, 0 replies; 20+ messages in thread
From: Stephen Boyd @ 2018-10-17 18:16 UTC (permalink / raw)
To: Anson Huang, aisheng.dong, clement.peron, colin.didier,
devicetree, fabio.estevam, kernel, linux-arm-kernel, linux-clk,
linux-kernel, linux, mark.rutland, matteo.lisi, michael,
mturquette, ping.bai, robh+dt, s.hauer, shawnguo, shengjiu.wang
Cc: Linux-imx
Quoting Anson Huang (2018-08-31 00:53:14)
> i.MX6SX has MMDC1 ipg clock in CCM CCGR, add it into
> clock tree for clock management.
>
> Signed-off-by: Anson Huang <Anson.Huang@nxp.com>
> ---
Applied to clk-next
^ permalink raw reply [flat|nested] 20+ messages in thread
* [PATCH 4/7] clk: imx6sll: add mmdc1 ipg clock
2018-08-31 7:53 [PATCH 0/7] Add i.MX6 SoCs mmdc ipg clocks management Anson Huang
` (2 preceding siblings ...)
2018-08-31 7:53 ` [PATCH 3/7] clk: imx6sx: " Anson Huang
@ 2018-08-31 7:53 ` Anson Huang
2018-09-04 13:36 ` Rob Herring
2018-10-17 18:16 ` Stephen Boyd
2018-08-31 7:53 ` [PATCH 5/7] clk: imx6sl: add mmdc ipg clocks Anson Huang
` (2 subsequent siblings)
6 siblings, 2 replies; 20+ messages in thread
From: Anson Huang @ 2018-08-31 7:53 UTC (permalink / raw)
To: shawnguo, s.hauer, kernel, fabio.estevam, robh+dt, mark.rutland,
linux, mturquette, sboyd, colin.didier, clement.peron, ping.bai,
aisheng.dong, shengjiu.wang, matteo.lisi, michael,
linux-arm-kernel, devicetree, linux-kernel, linux-clk
Cc: Linux-imx
i.MX6SLL has MMDC1 ipg clock in CCM CCGR, add it into
clock tree for clock management.
Signed-off-by: Anson Huang <Anson.Huang@nxp.com>
---
drivers/clk/imx/clk-imx6sll.c | 1 +
include/dt-bindings/clock/imx6sll-clock.h | 3 ++-
2 files changed, 3 insertions(+), 1 deletion(-)
diff --git a/drivers/clk/imx/clk-imx6sll.c b/drivers/clk/imx/clk-imx6sll.c
index 52379ee..3bd2044 100644
--- a/drivers/clk/imx/clk-imx6sll.c
+++ b/drivers/clk/imx/clk-imx6sll.c
@@ -293,6 +293,7 @@ static void __init imx6sll_clocks_init(struct device_node *ccm_node)
clks[IMX6SLL_CLK_WDOG1] = imx_clk_gate2("wdog1", "ipg", base + 0x74, 16);
clks[IMX6SLL_CLK_MMDC_P0_FAST] = imx_clk_gate_flags("mmdc_p0_fast", "mmdc_podf", base + 0x74, 20, CLK_IS_CRITICAL);
clks[IMX6SLL_CLK_MMDC_P0_IPG] = imx_clk_gate2_flags("mmdc_p0_ipg", "ipg", base + 0x74, 24, CLK_IS_CRITICAL);
+ clks[IMX6SLL_CLK_MMDC_P1_IPG] = imx_clk_gate2("mmdc_p1_ipg", "ipg", base + 0x74, 26);
clks[IMX6SLL_CLK_OCRAM] = imx_clk_gate_flags("ocram","ahb", base + 0x74, 28, CLK_IS_CRITICAL);
/* CCGR4 */
diff --git a/include/dt-bindings/clock/imx6sll-clock.h b/include/dt-bindings/clock/imx6sll-clock.h
index 1036475..f446710 100644
--- a/include/dt-bindings/clock/imx6sll-clock.h
+++ b/include/dt-bindings/clock/imx6sll-clock.h
@@ -203,7 +203,8 @@
#define IMX6SLL_CLK_GPIO4 176
#define IMX6SLL_CLK_GPIO5 177
#define IMX6SLL_CLK_GPIO6 178
+#define IMX6SLL_CLK_MMDC_P1_IPG 179
-#define IMX6SLL_CLK_END 179
+#define IMX6SLL_CLK_END 180
#endif /* __DT_BINDINGS_CLOCK_IMX6SLL_H */
--
2.7.4
^ permalink raw reply related [flat|nested] 20+ messages in thread
* Re: [PATCH 4/7] clk: imx6sll: add mmdc1 ipg clock
2018-08-31 7:53 ` [PATCH 4/7] clk: imx6sll: " Anson Huang
@ 2018-09-04 13:36 ` Rob Herring
2018-10-17 18:16 ` Stephen Boyd
1 sibling, 0 replies; 20+ messages in thread
From: Rob Herring @ 2018-09-04 13:36 UTC (permalink / raw)
To: Anson Huang
Cc: shawnguo, s.hauer, kernel, fabio.estevam, robh+dt, mark.rutland,
linux, mturquette, sboyd, colin.didier, clement.peron, ping.bai,
aisheng.dong, shengjiu.wang, matteo.lisi, michael,
linux-arm-kernel, devicetree, linux-kernel, linux-clk, Linux-imx
On Fri, 31 Aug 2018 15:53:15 +0800, Anson Huang wrote:
> i.MX6SLL has MMDC1 ipg clock in CCM CCGR, add it into
> clock tree for clock management.
>
> Signed-off-by: Anson Huang <Anson.Huang@nxp.com>
> ---
> drivers/clk/imx/clk-imx6sll.c | 1 +
> include/dt-bindings/clock/imx6sll-clock.h | 3 ++-
> 2 files changed, 3 insertions(+), 1 deletion(-)
>
Reviewed-by: Rob Herring <robh@kernel.org>
^ permalink raw reply [flat|nested] 20+ messages in thread
* Re: [PATCH 4/7] clk: imx6sll: add mmdc1 ipg clock
2018-08-31 7:53 ` [PATCH 4/7] clk: imx6sll: " Anson Huang
2018-09-04 13:36 ` Rob Herring
@ 2018-10-17 18:16 ` Stephen Boyd
1 sibling, 0 replies; 20+ messages in thread
From: Stephen Boyd @ 2018-10-17 18:16 UTC (permalink / raw)
To: Anson Huang, aisheng.dong, clement.peron, colin.didier,
devicetree, fabio.estevam, kernel, linux-arm-kernel, linux-clk,
linux-kernel, linux, mark.rutland, matteo.lisi, michael,
mturquette, ping.bai, robh+dt, s.hauer, shawnguo, shengjiu.wang
Cc: Linux-imx
Quoting Anson Huang (2018-08-31 00:53:15)
> i.MX6SLL has MMDC1 ipg clock in CCM CCGR, add it into
> clock tree for clock management.
>
> Signed-off-by: Anson Huang <Anson.Huang@nxp.com>
> ---
Applied to clk-next
^ permalink raw reply [flat|nested] 20+ messages in thread
* [PATCH 5/7] clk: imx6sl: add mmdc ipg clocks
2018-08-31 7:53 [PATCH 0/7] Add i.MX6 SoCs mmdc ipg clocks management Anson Huang
` (3 preceding siblings ...)
2018-08-31 7:53 ` [PATCH 4/7] clk: imx6sll: " Anson Huang
@ 2018-08-31 7:53 ` Anson Huang
2018-09-04 13:36 ` Rob Herring
2018-10-17 18:16 ` Stephen Boyd
2018-08-31 7:53 ` [PATCH 6/7] clk: imx6q: add mmdc0 ipg clock Anson Huang
2018-08-31 7:53 ` [PATCH 7/7] ARM: dts: imx6: add mmdc " Anson Huang
6 siblings, 2 replies; 20+ messages in thread
From: Anson Huang @ 2018-08-31 7:53 UTC (permalink / raw)
To: shawnguo, s.hauer, kernel, fabio.estevam, robh+dt, mark.rutland,
linux, mturquette, sboyd, colin.didier, clement.peron, ping.bai,
aisheng.dong, shengjiu.wang, matteo.lisi, michael,
linux-arm-kernel, devicetree, linux-kernel, linux-clk
Cc: Linux-imx
i.MX6SL has MMDC0 and MMDC1 ipg clock in CCM CCGR, add them into
clock tree for clock management.
Signed-off-by: Anson Huang <Anson.Huang@nxp.com>
---
drivers/clk/imx/clk-imx6sl.c | 2 ++
include/dt-bindings/clock/imx6sl-clock.h | 4 +++-
2 files changed, 5 insertions(+), 1 deletion(-)
diff --git a/drivers/clk/imx/clk-imx6sl.c b/drivers/clk/imx/clk-imx6sl.c
index eb6bcbf..6fcfbbd 100644
--- a/drivers/clk/imx/clk-imx6sl.c
+++ b/drivers/clk/imx/clk-imx6sl.c
@@ -386,6 +386,8 @@ static void __init imx6sl_clocks_init(struct device_node *ccm_node)
clks[IMX6SL_CLK_LCDIF_AXI] = imx_clk_gate2("lcdif_axi", "lcdif_axi_podf", base + 0x74, 6);
clks[IMX6SL_CLK_LCDIF_PIX] = imx_clk_gate2("lcdif_pix", "lcdif_pix_podf", base + 0x74, 8);
clks[IMX6SL_CLK_EPDC_PIX] = imx_clk_gate2("epdc_pix", "epdc_pix_podf", base + 0x74, 10);
+ clks[IMX6SL_CLK_MMDC_P0_IPG] = imx_clk_gate2_flags("mmdc_p0_ipg", "ipg", base + 0x74, 24, CLK_IS_CRITICAL);
+ clks[IMX6SL_CLK_MMDC_P1_IPG] = imx_clk_gate2("mmdc_p1_ipg", "ipg", base + 0x74, 26);
clks[IMX6SL_CLK_OCRAM] = imx_clk_gate2("ocram", "ocram_podf", base + 0x74, 28);
clks[IMX6SL_CLK_PWM1] = imx_clk_gate2("pwm1", "perclk", base + 0x78, 16);
clks[IMX6SL_CLK_PWM2] = imx_clk_gate2("pwm2", "perclk", base + 0x78, 18);
diff --git a/include/dt-bindings/clock/imx6sl-clock.h b/include/dt-bindings/clock/imx6sl-clock.h
index e14573e..cfbfc39 100644
--- a/include/dt-bindings/clock/imx6sl-clock.h
+++ b/include/dt-bindings/clock/imx6sl-clock.h
@@ -175,6 +175,8 @@
#define IMX6SL_CLK_SSI2_IPG 162
#define IMX6SL_CLK_SSI3_IPG 163
#define IMX6SL_CLK_SPDIF_GCLK 164
-#define IMX6SL_CLK_END 165
+#define IMX6SL_CLK_MMDC_P0_IPG 165
+#define IMX6SL_CLK_MMDC_P1_IPG 166
+#define IMX6SL_CLK_END 167
#endif /* __DT_BINDINGS_CLOCK_IMX6SL_H */
--
2.7.4
^ permalink raw reply related [flat|nested] 20+ messages in thread
* Re: [PATCH 5/7] clk: imx6sl: add mmdc ipg clocks
2018-08-31 7:53 ` [PATCH 5/7] clk: imx6sl: add mmdc ipg clocks Anson Huang
@ 2018-09-04 13:36 ` Rob Herring
2018-10-17 18:16 ` Stephen Boyd
1 sibling, 0 replies; 20+ messages in thread
From: Rob Herring @ 2018-09-04 13:36 UTC (permalink / raw)
To: Anson Huang
Cc: shawnguo, s.hauer, kernel, fabio.estevam, robh+dt, mark.rutland,
linux, mturquette, sboyd, colin.didier, clement.peron, ping.bai,
aisheng.dong, shengjiu.wang, matteo.lisi, michael,
linux-arm-kernel, devicetree, linux-kernel, linux-clk, Linux-imx
On Fri, 31 Aug 2018 15:53:16 +0800, Anson Huang wrote:
> i.MX6SL has MMDC0 and MMDC1 ipg clock in CCM CCGR, add them into
> clock tree for clock management.
>
> Signed-off-by: Anson Huang <Anson.Huang@nxp.com>
> ---
> drivers/clk/imx/clk-imx6sl.c | 2 ++
> include/dt-bindings/clock/imx6sl-clock.h | 4 +++-
> 2 files changed, 5 insertions(+), 1 deletion(-)
>
Reviewed-by: Rob Herring <robh@kernel.org>
^ permalink raw reply [flat|nested] 20+ messages in thread
* Re: [PATCH 5/7] clk: imx6sl: add mmdc ipg clocks
2018-08-31 7:53 ` [PATCH 5/7] clk: imx6sl: add mmdc ipg clocks Anson Huang
2018-09-04 13:36 ` Rob Herring
@ 2018-10-17 18:16 ` Stephen Boyd
1 sibling, 0 replies; 20+ messages in thread
From: Stephen Boyd @ 2018-10-17 18:16 UTC (permalink / raw)
To: Anson Huang, aisheng.dong, clement.peron, colin.didier,
devicetree, fabio.estevam, kernel, linux-arm-kernel, linux-clk,
linux-kernel, linux, mark.rutland, matteo.lisi, michael,
mturquette, ping.bai, robh+dt, s.hauer, shawnguo, shengjiu.wang
Cc: Linux-imx
Quoting Anson Huang (2018-08-31 00:53:16)
> i.MX6SL has MMDC0 and MMDC1 ipg clock in CCM CCGR, add them into
> clock tree for clock management.
>
> Signed-off-by: Anson Huang <Anson.Huang@nxp.com>
> ---
Applied to clk-next
^ permalink raw reply [flat|nested] 20+ messages in thread
* [PATCH 6/7] clk: imx6q: add mmdc0 ipg clock
2018-08-31 7:53 [PATCH 0/7] Add i.MX6 SoCs mmdc ipg clocks management Anson Huang
` (4 preceding siblings ...)
2018-08-31 7:53 ` [PATCH 5/7] clk: imx6sl: add mmdc ipg clocks Anson Huang
@ 2018-08-31 7:53 ` Anson Huang
2018-09-04 13:36 ` Rob Herring
2018-10-17 18:16 ` Stephen Boyd
2018-08-31 7:53 ` [PATCH 7/7] ARM: dts: imx6: add mmdc " Anson Huang
6 siblings, 2 replies; 20+ messages in thread
From: Anson Huang @ 2018-08-31 7:53 UTC (permalink / raw)
To: shawnguo, s.hauer, kernel, fabio.estevam, robh+dt, mark.rutland,
linux, mturquette, sboyd, colin.didier, clement.peron, ping.bai,
aisheng.dong, shengjiu.wang, matteo.lisi, michael,
linux-arm-kernel, devicetree, linux-kernel, linux-clk
Cc: Linux-imx
i.MX6Q has MMDC0 ipg clock in CCM CCGR, add it into
clock tree for clock management.
Signed-off-by: Anson Huang <Anson.Huang@nxp.com>
---
drivers/clk/imx/clk-imx6q.c | 1 +
include/dt-bindings/clock/imx6qdl-clock.h | 3 ++-
2 files changed, 3 insertions(+), 1 deletion(-)
diff --git a/drivers/clk/imx/clk-imx6q.c b/drivers/clk/imx/clk-imx6q.c
index 8c7c2fc..bbe0c60 100644
--- a/drivers/clk/imx/clk-imx6q.c
+++ b/drivers/clk/imx/clk-imx6q.c
@@ -789,6 +789,7 @@ static void __init imx6q_clocks_init(struct device_node *ccm_node)
clk[IMX6QDL_CLK_MLB] = imx_clk_gate2("mlb", "axi", base + 0x74, 18);
clk[IMX6QDL_CLK_MMDC_CH0_AXI] = imx_clk_gate2_flags("mmdc_ch0_axi", "mmdc_ch0_axi_podf", base + 0x74, 20, CLK_IS_CRITICAL);
clk[IMX6QDL_CLK_MMDC_CH1_AXI] = imx_clk_gate2("mmdc_ch1_axi", "mmdc_ch1_axi_podf", base + 0x74, 22);
+ clk[IMX6QDL_CLK_MMDC_P0_IPG] = imx_clk_gate2_flags("mmdc_p0_ipg", "ipg", base + 0x74, 24, CLK_IS_CRITICAL);
clk[IMX6QDL_CLK_OCRAM] = imx_clk_gate2("ocram", "ahb", base + 0x74, 28);
clk[IMX6QDL_CLK_OPENVG_AXI] = imx_clk_gate2("openvg_axi", "axi", base + 0x74, 30);
clk[IMX6QDL_CLK_PCIE_AXI] = imx_clk_gate2("pcie_axi", "pcie_axi_sel", base + 0x78, 0);
diff --git a/include/dt-bindings/clock/imx6qdl-clock.h b/include/dt-bindings/clock/imx6qdl-clock.h
index 7ad171b..87b068f 100644
--- a/include/dt-bindings/clock/imx6qdl-clock.h
+++ b/include/dt-bindings/clock/imx6qdl-clock.h
@@ -273,6 +273,7 @@
#define IMX6QDL_CLK_MLB_PODF 260
#define IMX6QDL_CLK_EPIT1 261
#define IMX6QDL_CLK_EPIT2 262
-#define IMX6QDL_CLK_END 263
+#define IMX6QDL_CLK_MMDC_P0_IPG 263
+#define IMX6QDL_CLK_END 264
#endif /* __DT_BINDINGS_CLOCK_IMX6QDL_H */
--
2.7.4
^ permalink raw reply related [flat|nested] 20+ messages in thread
* Re: [PATCH 6/7] clk: imx6q: add mmdc0 ipg clock
2018-08-31 7:53 ` [PATCH 6/7] clk: imx6q: add mmdc0 ipg clock Anson Huang
@ 2018-09-04 13:36 ` Rob Herring
2018-10-17 18:16 ` Stephen Boyd
1 sibling, 0 replies; 20+ messages in thread
From: Rob Herring @ 2018-09-04 13:36 UTC (permalink / raw)
To: Anson Huang
Cc: shawnguo, s.hauer, kernel, fabio.estevam, robh+dt, mark.rutland,
linux, mturquette, sboyd, colin.didier, clement.peron, ping.bai,
aisheng.dong, shengjiu.wang, matteo.lisi, michael,
linux-arm-kernel, devicetree, linux-kernel, linux-clk, Linux-imx
On Fri, 31 Aug 2018 15:53:17 +0800, Anson Huang wrote:
> i.MX6Q has MMDC0 ipg clock in CCM CCGR, add it into
> clock tree for clock management.
>
> Signed-off-by: Anson Huang <Anson.Huang@nxp.com>
> ---
> drivers/clk/imx/clk-imx6q.c | 1 +
> include/dt-bindings/clock/imx6qdl-clock.h | 3 ++-
> 2 files changed, 3 insertions(+), 1 deletion(-)
>
Reviewed-by: Rob Herring <robh@kernel.org>
^ permalink raw reply [flat|nested] 20+ messages in thread
* Re: [PATCH 6/7] clk: imx6q: add mmdc0 ipg clock
2018-08-31 7:53 ` [PATCH 6/7] clk: imx6q: add mmdc0 ipg clock Anson Huang
2018-09-04 13:36 ` Rob Herring
@ 2018-10-17 18:16 ` Stephen Boyd
1 sibling, 0 replies; 20+ messages in thread
From: Stephen Boyd @ 2018-10-17 18:16 UTC (permalink / raw)
To: Anson Huang, aisheng.dong, clement.peron, colin.didier,
devicetree, fabio.estevam, kernel, linux-arm-kernel, linux-clk,
linux-kernel, linux, mark.rutland, matteo.lisi, michael,
mturquette, ping.bai, robh+dt, s.hauer, shawnguo, shengjiu.wang
Cc: Linux-imx
Quoting Anson Huang (2018-08-31 00:53:17)
> i.MX6Q has MMDC0 ipg clock in CCM CCGR, add it into
> clock tree for clock management.
>
> Signed-off-by: Anson Huang <Anson.Huang@nxp.com>
> ---
Applied to clk-next
^ permalink raw reply [flat|nested] 20+ messages in thread
* [PATCH 7/7] ARM: dts: imx6: add mmdc ipg clock
2018-08-31 7:53 [PATCH 0/7] Add i.MX6 SoCs mmdc ipg clocks management Anson Huang
` (5 preceding siblings ...)
2018-08-31 7:53 ` [PATCH 6/7] clk: imx6q: add mmdc0 ipg clock Anson Huang
@ 2018-08-31 7:53 ` Anson Huang
2018-11-05 2:20 ` Shawn Guo
6 siblings, 1 reply; 20+ messages in thread
From: Anson Huang @ 2018-08-31 7:53 UTC (permalink / raw)
To: shawnguo, s.hauer, kernel, fabio.estevam, robh+dt, mark.rutland,
linux, mturquette, sboyd, colin.didier, clement.peron, ping.bai,
aisheng.dong, shengjiu.wang, matteo.lisi, michael,
linux-arm-kernel, devicetree, linux-kernel, linux-clk
Cc: Linux-imx
i.MX6 SoCs has MMDC clock gates in CCM CCGR, add
clock property for MMDC driver's clock operation.
Signed-off-by: Anson Huang <Anson.Huang@nxp.com>
---
arch/arm/boot/dts/imx6qdl.dtsi | 1 +
arch/arm/boot/dts/imx6sl.dtsi | 1 +
arch/arm/boot/dts/imx6sll.dtsi | 1 +
arch/arm/boot/dts/imx6sx.dtsi | 1 +
arch/arm/boot/dts/imx6ul.dtsi | 1 +
5 files changed, 5 insertions(+)
diff --git a/arch/arm/boot/dts/imx6qdl.dtsi b/arch/arm/boot/dts/imx6qdl.dtsi
index 61d2d26..5d33729 100644
--- a/arch/arm/boot/dts/imx6qdl.dtsi
+++ b/arch/arm/boot/dts/imx6qdl.dtsi
@@ -1115,6 +1115,7 @@
mmdc0: mmdc@21b0000 { /* MMDC0 */
compatible = "fsl,imx6q-mmdc";
reg = <0x021b0000 0x4000>;
+ clocks = <&clks IMX6QDL_CLK_MMDC_P0_IPG>;
};
mmdc1: mmdc@21b4000 { /* MMDC1 */
diff --git a/arch/arm/boot/dts/imx6sl.dtsi b/arch/arm/boot/dts/imx6sl.dtsi
index 7a4f5da..63a18e1 100644
--- a/arch/arm/boot/dts/imx6sl.dtsi
+++ b/arch/arm/boot/dts/imx6sl.dtsi
@@ -921,6 +921,7 @@
mmdc: mmdc@21b0000 {
compatible = "fsl,imx6sl-mmdc", "fsl,imx6q-mmdc";
reg = <0x021b0000 0x4000>;
+ clocks = <&clks IMX6SL_CLK_MMDC_P0_IPG>;
};
rngb: rngb@21b4000 {
diff --git a/arch/arm/boot/dts/imx6sll.dtsi b/arch/arm/boot/dts/imx6sll.dtsi
index ed9a980..e462f76 100644
--- a/arch/arm/boot/dts/imx6sll.dtsi
+++ b/arch/arm/boot/dts/imx6sll.dtsi
@@ -770,6 +770,7 @@
mmdc: memory-controller@21b0000 {
compatible = "fsl,imx6sll-mmdc", "fsl,imx6q-mmdc";
reg = <0x021b0000 0x4000>;
+ clocks = <&clks IMX6SLL_CLK_MMDC_P0_IPG>;
};
ocotp: ocotp-ctrl@21bc000 {
diff --git a/arch/arm/boot/dts/imx6sx.dtsi b/arch/arm/boot/dts/imx6sx.dtsi
index 844caa3..ba4ab79 100644
--- a/arch/arm/boot/dts/imx6sx.dtsi
+++ b/arch/arm/boot/dts/imx6sx.dtsi
@@ -1002,6 +1002,7 @@
mmdc: mmdc@21b0000 {
compatible = "fsl,imx6sx-mmdc", "fsl,imx6q-mmdc";
reg = <0x021b0000 0x4000>;
+ clocks = <&clks IMX6SX_CLK_MMDC_P0_IPG>;
};
fec2: ethernet@21b4000 {
diff --git a/arch/arm/boot/dts/imx6ul.dtsi b/arch/arm/boot/dts/imx6ul.dtsi
index 448d765..2019ad5 100644
--- a/arch/arm/boot/dts/imx6ul.dtsi
+++ b/arch/arm/boot/dts/imx6ul.dtsi
@@ -916,6 +916,7 @@
mmdc: mmdc@21b0000 {
compatible = "fsl,imx6ul-mmdc", "fsl,imx6q-mmdc";
reg = <0x021b0000 0x4000>;
+ clocks = <&clks IMX6UL_CLK_MMDC_P0_IPG>;
};
weim: weim@21b8000 {
--
2.7.4
^ permalink raw reply related [flat|nested] 20+ messages in thread
* Re: [PATCH 7/7] ARM: dts: imx6: add mmdc ipg clock
2018-08-31 7:53 ` [PATCH 7/7] ARM: dts: imx6: add mmdc " Anson Huang
@ 2018-11-05 2:20 ` Shawn Guo
0 siblings, 0 replies; 20+ messages in thread
From: Shawn Guo @ 2018-11-05 2:20 UTC (permalink / raw)
To: Anson Huang
Cc: s.hauer, kernel, fabio.estevam, robh+dt, mark.rutland, linux,
mturquette, sboyd, colin.didier, clement.peron, ping.bai,
aisheng.dong, shengjiu.wang, matteo.lisi, michael,
linux-arm-kernel, devicetree, linux-kernel, linux-clk, Linux-imx
On Fri, Aug 31, 2018 at 03:53:18PM +0800, Anson Huang wrote:
> i.MX6 SoCs has MMDC clock gates in CCM CCGR, add
> clock property for MMDC driver's clock operation.
>
> Signed-off-by: Anson Huang <Anson.Huang@nxp.com>
Applied, thanks.
^ permalink raw reply [flat|nested] 20+ messages in thread