diff mbox series

clk: imx8mq: Add support for the CLKO1 clock

Message ID 20190131002056.12024-1-festevam@gmail.com (mailing list archive)
State Accepted, archived
Headers show
Series clk: imx8mq: Add support for the CLKO1 clock | expand

Commit Message

Fabio Estevam Jan. 31, 2019, 12:20 a.m. UTC
Add the entry for the CLKO1 clock.

Signed-off-by: Fabio Estevam <festevam@gmail.com>
---
 drivers/clk/imx/clk-imx8mq.c             | 3 +++
 include/dt-bindings/clock/imx8mq-clock.h | 4 +++-
 2 files changed, 6 insertions(+), 1 deletion(-)

Comments

Abel Vesa Jan. 31, 2019, 7:33 a.m. UTC | #1
On 19-01-30 22:20:56, Fabio Estevam wrote:
> Add the entry for the CLKO1 clock.
> 
> Signed-off-by: Fabio Estevam <festevam@gmail.com>
> ---
>  drivers/clk/imx/clk-imx8mq.c             | 3 +++
>  include/dt-bindings/clock/imx8mq-clock.h | 4 +++-
>  2 files changed, 6 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/clk/imx/clk-imx8mq.c b/drivers/clk/imx/clk-imx8mq.c
> index 63001bc891d4..a2f8a8d3585c 100644
> --- a/drivers/clk/imx/clk-imx8mq.c
> +++ b/drivers/clk/imx/clk-imx8mq.c
> @@ -264,6 +264,8 @@ static const char * const imx8mq_ecspi3_sels[] = {"osc_25m", "sys2_pll_200m", "s
>  					   "sys1_pll_800m", "sys3_pll2_out", "sys2_pll_250m", "audio_pll2_out", };
>  static const char * const imx8mq_dram_core_sels[] = {"dram_pll_out", "dram_alt_root", };
>  
> +static const char * const imx8mq_clko1_sels[] = {"osc_25m", "sys1_pll_800m", "osc_27m", "sys1_pll_200m",
> +					  "audio_pll2_out", "sys2_pll_500m", "vpu_pll_out", "sys1_pll_80m", };
>  static const char * const imx8mq_clko2_sels[] = {"osc_25m", "sys2_pll_200m", "sys1_pll_400m", "sys2_pll_166m",
>  					  "sys3_pll2_out", "audio_pll1_out", "video_pll1_out", "ckil", };
>  
> @@ -479,6 +481,7 @@ static int imx8mq_clocks_probe(struct platform_device *pdev)
>  	clks[IMX8MQ_CLK_GPT1] = imx8m_clk_composite("gpt1", imx8mq_gpt1_sels, base + 0xb580);
>  	clks[IMX8MQ_CLK_WDOG] = imx8m_clk_composite("wdog", imx8mq_wdog_sels, base + 0xb900);
>  	clks[IMX8MQ_CLK_WRCLK] = imx8m_clk_composite("wrclk", imx8mq_wrclk_sels, base + 0xb980);
> +	clks[IMX8MQ_CLK_CLKO1] = imx8m_clk_composite("clko1", imx8mq_clko1_sels, base + 0xba00);
>  	clks[IMX8MQ_CLK_CLKO2] = imx8m_clk_composite("clko2", imx8mq_clko2_sels, base + 0xba80);
>  	clks[IMX8MQ_CLK_DSI_CORE] = imx8m_clk_composite("dsi_core", imx8mq_dsi_core_sels, base + 0xbb00);
>  	clks[IMX8MQ_CLK_DSI_PHY_REF] = imx8m_clk_composite("dsi_phy_ref", imx8mq_dsi_phy_sels, base + 0xbb80);
> diff --git a/include/dt-bindings/clock/imx8mq-clock.h b/include/dt-bindings/clock/imx8mq-clock.h
> index 04f7ac345984..74f80b26f679 100644
> --- a/include/dt-bindings/clock/imx8mq-clock.h
> +++ b/include/dt-bindings/clock/imx8mq-clock.h
> @@ -391,5 +391,7 @@
>  
>  #define IMX8MQ_CLK_NAND_USDHC_BUS_RAWNAND_CLK	267
>  
> -#define IMX8MQ_CLK_END				268
> +#define IMX8MQ_CLK_CLKO1			268
> +
> +#define IMX8MQ_CLK_END				269
>  #endif /* __DT_BINDINGS_CLOCK_IMX8MQ_H */
> -- 
> 2.17.1
> 

Reviewed-by: Abel Vesa <abel.vesa@nxp.com>
Stephen Boyd Feb. 21, 2019, 8:36 p.m. UTC | #2
Quoting Fabio Estevam (2019-01-30 16:20:56)
> Add the entry for the CLKO1 clock.
> 
> Signed-off-by: Fabio Estevam <festevam@gmail.com>
> ---

Applied to clk-next but I had to fix the whole DT binding number because
I don't know what this patch is based on. In fact, please get everyone
involved at NXP and whoever else is working on i.MX clk drivers to
coordinate somehow. I just spent 20 minutes working through the set of
imx patches in my inbox and I see approximately 6 different authors all
sending out a few clks at a time for the same drivers with zero
information about what the patches are based on or what order they're
supposed to be applied in.

If someone wants to collect all the patches and indicate on the list
they've picked them up and will be sending them as a pull request that's
fine. Otherwise, I recommend working together to post a coherent patch
series that adds the things that everyone wants or working from a stable
baseline like an rc tag and letting me figure out how to do the merging.
Either way, it looks like if I ever get a patch for imx clk drivers that
doesn't have a cover letter or is just adding a few clks here and there
I'll have to assume it's the same story as always and just toss them
into a clk-imx branch without a topic.
Fabio Estevam Feb. 22, 2019, 1:07 a.m. UTC | #3
Hi Stephen,

On Thu, Feb 21, 2019 at 5:36 PM Stephen Boyd <sboyd@kernel.org> wrote:

> Applied to clk-next but I had to fix the whole DT binding number because
> I don't know what this patch is based on. In fact, please get everyone
> involved at NXP and whoever else is working on i.MX clk drivers to
> coordinate somehow. I just spent 20 minutes working through the set of
> imx patches in my inbox and I see approximately 6 different authors all
> sending out a few clks at a time for the same drivers with zero
> information about what the patches are based on or what order they're
> supposed to be applied in.

Sorry for the trouble!

> If someone wants to collect all the patches and indicate on the list
> they've picked them up and will be sending them as a pull request that's
> fine. Otherwise, I recommend working together to post a coherent patch
> series that adds the things that everyone wants or working from a stable
> baseline like an rc tag and letting me figure out how to do the merging.
> Either way, it looks like if I ever get a patch for imx clk drivers that
> doesn't have a cover letter or is just adding a few clks here and there
> I'll have to assume it's the same story as always and just toss them
> into a clk-imx branch without a topic.

Yes, let's try to make this better.

Thanks
Aisheng Dong Feb. 22, 2019, 4:43 a.m. UTC | #4
> From: Stephen Boyd [mailto:sboyd@kernel.org]
> Sent: Friday, February 22, 2019 4:37 AM
> Quoting Fabio Estevam (2019-01-30 16:20:56)
> > Add the entry for the CLKO1 clock.
> >
> > Signed-off-by: Fabio Estevam <festevam@gmail.com>
> > ---
> 
> Applied to clk-next but I had to fix the whole DT binding number because I
> don't know what this patch is based on. In fact, please get everyone involved at
> NXP and whoever else is working on i.MX clk drivers to coordinate somehow. I
> just spent 20 minutes working through the set of imx patches in my inbox and
> I see approximately 6 different authors all sending out a few clks at a time for
> the same drivers with zero information about what the patches are based on
> or what order they're supposed to be applied in.
> 
> If someone wants to collect all the patches and indicate on the list they've
> picked them up and will be sending them as a pull request that's fine.

We know that there were a lot of IMX clocks patches sent in the list recently
and it was a bit overloading as you still need to maintain all other platforms.
So we do appreciate for your big effort!

We're speeding up the IMX upstreaming, there might be more patches sent out
in the following months for new SoCs support.

I'm NXP internal upstreaming leader, currently I'm busy with upstreaming MX8
Arch and assume I will be a bit free later. If you and Shawn are okay,
I would like to spend more time to help review and collect i.MX Clock patches.
Hope this would help relief you a bit.

Regards
Dong Aisheng
Shawn Guo Feb. 28, 2019, 2:15 a.m. UTC | #5
On Thu, Feb 21, 2019 at 12:36:44PM -0800, Stephen Boyd wrote:
> Quoting Fabio Estevam (2019-01-30 16:20:56)
> > Add the entry for the CLKO1 clock.
> > 
> > Signed-off-by: Fabio Estevam <festevam@gmail.com>
> > ---
> 
> Applied to clk-next but I had to fix the whole DT binding number because
> I don't know what this patch is based on. In fact, please get everyone
> involved at NXP and whoever else is working on i.MX clk drivers to
> coordinate somehow. I just spent 20 minutes working through the set of
> imx patches in my inbox and I see approximately 6 different authors all
> sending out a few clks at a time for the same drivers with zero
> information about what the patches are based on or what order they're
> supposed to be applied in.
> 
> If someone wants to collect all the patches and indicate on the list
> they've picked them up and will be sending them as a pull request that's
> fine.

I will help collect the i.MX platform clock patches and send you as
pull request.

Shawn
Stephen Boyd Feb. 28, 2019, 6:27 p.m. UTC | #6
Quoting Shawn Guo (2019-02-27 18:15:12)
> On Thu, Feb 21, 2019 at 12:36:44PM -0800, Stephen Boyd wrote:
> > Quoting Fabio Estevam (2019-01-30 16:20:56)
> > > Add the entry for the CLKO1 clock.
> > > 
> > > Signed-off-by: Fabio Estevam <festevam@gmail.com>
> > > ---
> > 
> > Applied to clk-next but I had to fix the whole DT binding number because
> > I don't know what this patch is based on. In fact, please get everyone
> > involved at NXP and whoever else is working on i.MX clk drivers to
> > coordinate somehow. I just spent 20 minutes working through the set of
> > imx patches in my inbox and I see approximately 6 different authors all
> > sending out a few clks at a time for the same drivers with zero
> > information about what the patches are based on or what order they're
> > supposed to be applied in.
> > 
> > If someone wants to collect all the patches and indicate on the list
> > they've picked them up and will be sending them as a pull request that's
> > fine.
> 
> I will help collect the i.MX platform clock patches and send you as
> pull request.
> 

Ok. Thanks for the heads up. I don't expect anything for the 5.1 merge
window that should open next week, but for the next cycle I'll be on the
lookout for the pull request.
Shawn Guo March 1, 2019, 2:01 a.m. UTC | #7
On Thu, Feb 28, 2019 at 10:27:37AM -0800, Stephen Boyd wrote:
> Quoting Shawn Guo (2019-02-27 18:15:12)
> > On Thu, Feb 21, 2019 at 12:36:44PM -0800, Stephen Boyd wrote:
> > > Quoting Fabio Estevam (2019-01-30 16:20:56)
> > > > Add the entry for the CLKO1 clock.
> > > > 
> > > > Signed-off-by: Fabio Estevam <festevam@gmail.com>
> > > > ---
> > > 
> > > Applied to clk-next but I had to fix the whole DT binding number because
> > > I don't know what this patch is based on. In fact, please get everyone
> > > involved at NXP and whoever else is working on i.MX clk drivers to
> > > coordinate somehow. I just spent 20 minutes working through the set of
> > > imx patches in my inbox and I see approximately 6 different authors all
> > > sending out a few clks at a time for the same drivers with zero
> > > information about what the patches are based on or what order they're
> > > supposed to be applied in.
> > > 
> > > If someone wants to collect all the patches and indicate on the list
> > > they've picked them up and will be sending them as a pull request that's
> > > fine.
> > 
> > I will help collect the i.MX platform clock patches and send you as
> > pull request.
> > 
> 
> Ok. Thanks for the heads up. I don't expect anything for the 5.1 merge
> window that should open next week, but for the next cycle I'll be on the
> lookout for the pull request.

Yeah.  Sorry for being unclear.  I meant to start from next development
cycle.

Shawn
diff mbox series

Patch

diff --git a/drivers/clk/imx/clk-imx8mq.c b/drivers/clk/imx/clk-imx8mq.c
index 63001bc891d4..a2f8a8d3585c 100644
--- a/drivers/clk/imx/clk-imx8mq.c
+++ b/drivers/clk/imx/clk-imx8mq.c
@@ -264,6 +264,8 @@  static const char * const imx8mq_ecspi3_sels[] = {"osc_25m", "sys2_pll_200m", "s
 					   "sys1_pll_800m", "sys3_pll2_out", "sys2_pll_250m", "audio_pll2_out", };
 static const char * const imx8mq_dram_core_sels[] = {"dram_pll_out", "dram_alt_root", };
 
+static const char * const imx8mq_clko1_sels[] = {"osc_25m", "sys1_pll_800m", "osc_27m", "sys1_pll_200m",
+					  "audio_pll2_out", "sys2_pll_500m", "vpu_pll_out", "sys1_pll_80m", };
 static const char * const imx8mq_clko2_sels[] = {"osc_25m", "sys2_pll_200m", "sys1_pll_400m", "sys2_pll_166m",
 					  "sys3_pll2_out", "audio_pll1_out", "video_pll1_out", "ckil", };
 
@@ -479,6 +481,7 @@  static int imx8mq_clocks_probe(struct platform_device *pdev)
 	clks[IMX8MQ_CLK_GPT1] = imx8m_clk_composite("gpt1", imx8mq_gpt1_sels, base + 0xb580);
 	clks[IMX8MQ_CLK_WDOG] = imx8m_clk_composite("wdog", imx8mq_wdog_sels, base + 0xb900);
 	clks[IMX8MQ_CLK_WRCLK] = imx8m_clk_composite("wrclk", imx8mq_wrclk_sels, base + 0xb980);
+	clks[IMX8MQ_CLK_CLKO1] = imx8m_clk_composite("clko1", imx8mq_clko1_sels, base + 0xba00);
 	clks[IMX8MQ_CLK_CLKO2] = imx8m_clk_composite("clko2", imx8mq_clko2_sels, base + 0xba80);
 	clks[IMX8MQ_CLK_DSI_CORE] = imx8m_clk_composite("dsi_core", imx8mq_dsi_core_sels, base + 0xbb00);
 	clks[IMX8MQ_CLK_DSI_PHY_REF] = imx8m_clk_composite("dsi_phy_ref", imx8mq_dsi_phy_sels, base + 0xbb80);
diff --git a/include/dt-bindings/clock/imx8mq-clock.h b/include/dt-bindings/clock/imx8mq-clock.h
index 04f7ac345984..74f80b26f679 100644
--- a/include/dt-bindings/clock/imx8mq-clock.h
+++ b/include/dt-bindings/clock/imx8mq-clock.h
@@ -391,5 +391,7 @@ 
 
 #define IMX8MQ_CLK_NAND_USDHC_BUS_RAWNAND_CLK	267
 
-#define IMX8MQ_CLK_END				268
+#define IMX8MQ_CLK_CLKO1			268
+
+#define IMX8MQ_CLK_END				269
 #endif /* __DT_BINDINGS_CLOCK_IMX8MQ_H */