All of lore.kernel.org
 help / color / mirror / Atom feed
From: Leonard Crestez <leonard.crestez@nxp.com>
To: Peng Fan <peng.fan@nxp.com>,
	"sboyd@kernel.org" <sboyd@kernel.org>,
	"shawnguo@kernel.org" <shawnguo@kernel.org>
Cc: "s.hauer@pengutronix.de" <s.hauer@pengutronix.de>,
	"festevam@gmail.com" <festevam@gmail.com>,
	Abel Vesa <abel.vesa@nxp.com>,
	"kernel@pengutronix.de" <kernel@pengutronix.de>,
	dl-linux-imx <linux-imx@nxp.com>,
	Anson Huang <anson.huang@nxp.com>, Jacky Bai <ping.bai@nxp.com>,
	"linux-clk@vger.kernel.org" <linux-clk@vger.kernel.org>,
	"linux-arm-kernel@lists.infradead.org" 
	<linux-arm-kernel@lists.infradead.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH V2 2/4] clk: imx: imx8mn: Switch to clk_hw based API
Date: Mon, 18 Nov 2019 13:06:26 +0000	[thread overview]
Message-ID: <VI1PR04MB7023CC47DC123A66627940E9EE4D0@VI1PR04MB7023.eurprd04.prod.outlook.com> (raw)
In-Reply-To: 1572846270-24375-3-git-send-email-peng.fan@nxp.com

On 2019-11-04 7:46 AM, Peng Fan wrote:
> From: Peng Fan <peng.fan@nxp.com>
> 
> Switch the entire clk-imx8mn driver to clk_hw based API.
> This allows us to move closer to a clear split between
> consumer and provider clk APIs.

> -	clks[IMX8MN_AUDIO_PLL1] = imx_clk_pll14xx("audio_pll1", "audio_pll1_ref_sel", base, &imx_1443x_pll);
> -	clks[IMX8MN_AUDIO_PLL2] = imx_clk_pll14xx("audio_pll2", "audio_pll2_ref_sel", base + 0x14, &imx_1443x_pll);
> -	clks[IMX8MN_VIDEO_PLL1] = imx_clk_pll14xx("video_pll1", "video_pll1_ref_sel", base + 0x28, &imx_1443x_pll);
> -	clks[IMX8MN_DRAM_PLL] = imx_clk_pll14xx("dram_pll", "dram_pll_ref_sel", base + 0x50, &imx_1443x_pll);
> -	clks[IMX8MN_GPU_PLL] = imx_clk_pll14xx("gpu_pll", "gpu_pll_ref_sel", base + 0x64, &imx_1416x_pll);
> -	clks[IMX8MN_VPU_PLL] = imx_clk_pll14xx("vpu_pll", "vpu_pll_ref_sel", base + 0x74, &imx_1416x_pll);
> -	clks[IMX8MN_ARM_PLL] = imx_clk_pll14xx("arm_pll", "arm_pll_ref_sel", base + 0x84, &imx_1416x_pll);
> -	clks[IMX8MN_SYS_PLL1] = imx_clk_fixed("sys_pll1", 800000000);
> -	clks[IMX8MN_SYS_PLL2] = imx_clk_fixed("sys_pll2", 1000000000);
> -	clks[IMX8MN_SYS_PLL3] = imx_clk_pll14xx("sys_pll3", "sys_pll3_ref_sel", base + 0x114, &imx_1416x_pll);
> +	clks[IMX8MN_AUDIO_PLL1] = imx_clk_hw_pll14xx("audio_pll1", "audio_pll1_ref_sel", base, &imx_1416x_pll);
> +	clks[IMX8MN_AUDIO_PLL2] = imx_clk_hw_pll14xx("audio_pll2", "audio_pll2_ref_sel", base + 0x14, &imx_1416x_pll);
> +	clks[IMX8MN_VIDEO_PLL1] = imx_clk_hw_pll14xx("video_pll1", "video_pll1_ref_sel", base + 0x28, &imx_1416x_pll);
> +	clks[IMX8MN_DRAM_PLL] = imx_clk_hw_pll14xx("dram_pll", "dram_pll_ref_sel", base + 0x50, &imx_1416x_pll);
> +	clks[IMX8MN_GPU_PLL] = imx_clk_hw_pll14xx("gpu_pll", "gpu_pll_ref_sel", base + 0x64, &imx_1416x_pll);
> +	clks[IMX8MN_VPU_PLL] = imx_clk_hw_pll14xx("vpu_pll", "vpu_pll_ref_sel", base + 0x74, &imx_1416x_pll);
> +	clks[IMX8MN_ARM_PLL] = imx_clk_hw_pll14xx("arm_pll", "arm_pll_ref_sel", base + 0x84, &imx_1416x_pll);
> +	clks[IMX8MN_SYS_PLL1] = imx_clk_hw_fixed("sys_pll1", 800000000);
> +	clks[IMX8MN_SYS_PLL2] = imx_clk_hw_fixed("sys_pll2", 1000000000);
> +	clks[IMX8MN_SYS_PLL3] = imx_clk_hw_pll14xx("sys_pll3", "sys_pll3_ref_sel", base + 0x114, &imx_1416x_pll);

You are switching audio/video/dram PLL from imx_1443x_pll to 
imx_1416x_pll, are you sure this is correct?

If this is intentional it should be an separate patch.

> -	clks[IMX8MN_CLK_ARM] = imx_clk_cpu("arm", "arm_a53_div",
> -					   clks[IMX8MN_CLK_A53_DIV],
> -					   clks[IMX8MN_CLK_A53_SRC],
> -					   clks[IMX8MN_ARM_PLL_OUT],
> -					   clks[IMX8MN_CLK_24M]);

> +	clks[IMX8MN_CLK_ARM] = imx_clk_hw_cpu("arm", "arm_a53_div",
> +					      clks[IMX8MN_CLK_A53_DIV]->clk,
> +					      clks[IMX8MN_CLK_A53_SRC]->clk,
> +					      clks[IMX8MN_ARM_PLL_OUT]->clk,
> +					      clks[IMX8MN_CLK_24M]->clk);

This series seems to be against Shawn's clk/imx but there is an 
additional patch in Stephen's tree which changes this 24M to PLL1_800M. 
Maybe that should be pulled into clk/imx? Otherwise it might spawn an 
unreadable merge conflicts since almost the entire file is rewritten.

--
Regards,
Leonard

WARNING: multiple messages have this Message-ID (diff)
From: Leonard Crestez <leonard.crestez@nxp.com>
To: Peng Fan <peng.fan@nxp.com>,
	"sboyd@kernel.org" <sboyd@kernel.org>,
	"shawnguo@kernel.org" <shawnguo@kernel.org>
Cc: Abel Vesa <abel.vesa@nxp.com>, Anson Huang <anson.huang@nxp.com>,
	"s.hauer@pengutronix.de" <s.hauer@pengutronix.de>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	dl-linux-imx <linux-imx@nxp.com>,
	"kernel@pengutronix.de" <kernel@pengutronix.de>,
	"festevam@gmail.com" <festevam@gmail.com>,
	"linux-clk@vger.kernel.org" <linux-clk@vger.kernel.org>,
	"linux-arm-kernel@lists.infradead.org"
	<linux-arm-kernel@lists.infradead.org>,
	Jacky Bai <ping.bai@nxp.com>
Subject: Re: [PATCH V2 2/4] clk: imx: imx8mn: Switch to clk_hw based API
Date: Mon, 18 Nov 2019 13:06:26 +0000	[thread overview]
Message-ID: <VI1PR04MB7023CC47DC123A66627940E9EE4D0@VI1PR04MB7023.eurprd04.prod.outlook.com> (raw)
In-Reply-To: 1572846270-24375-3-git-send-email-peng.fan@nxp.com

On 2019-11-04 7:46 AM, Peng Fan wrote:
> From: Peng Fan <peng.fan@nxp.com>
> 
> Switch the entire clk-imx8mn driver to clk_hw based API.
> This allows us to move closer to a clear split between
> consumer and provider clk APIs.

> -	clks[IMX8MN_AUDIO_PLL1] = imx_clk_pll14xx("audio_pll1", "audio_pll1_ref_sel", base, &imx_1443x_pll);
> -	clks[IMX8MN_AUDIO_PLL2] = imx_clk_pll14xx("audio_pll2", "audio_pll2_ref_sel", base + 0x14, &imx_1443x_pll);
> -	clks[IMX8MN_VIDEO_PLL1] = imx_clk_pll14xx("video_pll1", "video_pll1_ref_sel", base + 0x28, &imx_1443x_pll);
> -	clks[IMX8MN_DRAM_PLL] = imx_clk_pll14xx("dram_pll", "dram_pll_ref_sel", base + 0x50, &imx_1443x_pll);
> -	clks[IMX8MN_GPU_PLL] = imx_clk_pll14xx("gpu_pll", "gpu_pll_ref_sel", base + 0x64, &imx_1416x_pll);
> -	clks[IMX8MN_VPU_PLL] = imx_clk_pll14xx("vpu_pll", "vpu_pll_ref_sel", base + 0x74, &imx_1416x_pll);
> -	clks[IMX8MN_ARM_PLL] = imx_clk_pll14xx("arm_pll", "arm_pll_ref_sel", base + 0x84, &imx_1416x_pll);
> -	clks[IMX8MN_SYS_PLL1] = imx_clk_fixed("sys_pll1", 800000000);
> -	clks[IMX8MN_SYS_PLL2] = imx_clk_fixed("sys_pll2", 1000000000);
> -	clks[IMX8MN_SYS_PLL3] = imx_clk_pll14xx("sys_pll3", "sys_pll3_ref_sel", base + 0x114, &imx_1416x_pll);
> +	clks[IMX8MN_AUDIO_PLL1] = imx_clk_hw_pll14xx("audio_pll1", "audio_pll1_ref_sel", base, &imx_1416x_pll);
> +	clks[IMX8MN_AUDIO_PLL2] = imx_clk_hw_pll14xx("audio_pll2", "audio_pll2_ref_sel", base + 0x14, &imx_1416x_pll);
> +	clks[IMX8MN_VIDEO_PLL1] = imx_clk_hw_pll14xx("video_pll1", "video_pll1_ref_sel", base + 0x28, &imx_1416x_pll);
> +	clks[IMX8MN_DRAM_PLL] = imx_clk_hw_pll14xx("dram_pll", "dram_pll_ref_sel", base + 0x50, &imx_1416x_pll);
> +	clks[IMX8MN_GPU_PLL] = imx_clk_hw_pll14xx("gpu_pll", "gpu_pll_ref_sel", base + 0x64, &imx_1416x_pll);
> +	clks[IMX8MN_VPU_PLL] = imx_clk_hw_pll14xx("vpu_pll", "vpu_pll_ref_sel", base + 0x74, &imx_1416x_pll);
> +	clks[IMX8MN_ARM_PLL] = imx_clk_hw_pll14xx("arm_pll", "arm_pll_ref_sel", base + 0x84, &imx_1416x_pll);
> +	clks[IMX8MN_SYS_PLL1] = imx_clk_hw_fixed("sys_pll1", 800000000);
> +	clks[IMX8MN_SYS_PLL2] = imx_clk_hw_fixed("sys_pll2", 1000000000);
> +	clks[IMX8MN_SYS_PLL3] = imx_clk_hw_pll14xx("sys_pll3", "sys_pll3_ref_sel", base + 0x114, &imx_1416x_pll);

You are switching audio/video/dram PLL from imx_1443x_pll to 
imx_1416x_pll, are you sure this is correct?

If this is intentional it should be an separate patch.

> -	clks[IMX8MN_CLK_ARM] = imx_clk_cpu("arm", "arm_a53_div",
> -					   clks[IMX8MN_CLK_A53_DIV],
> -					   clks[IMX8MN_CLK_A53_SRC],
> -					   clks[IMX8MN_ARM_PLL_OUT],
> -					   clks[IMX8MN_CLK_24M]);

> +	clks[IMX8MN_CLK_ARM] = imx_clk_hw_cpu("arm", "arm_a53_div",
> +					      clks[IMX8MN_CLK_A53_DIV]->clk,
> +					      clks[IMX8MN_CLK_A53_SRC]->clk,
> +					      clks[IMX8MN_ARM_PLL_OUT]->clk,
> +					      clks[IMX8MN_CLK_24M]->clk);

This series seems to be against Shawn's clk/imx but there is an 
additional patch in Stephen's tree which changes this 24M to PLL1_800M. 
Maybe that should be pulled into clk/imx? Otherwise it might spawn an 
unreadable merge conflicts since almost the entire file is rewritten.

--
Regards,
Leonard

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

  reply	other threads:[~2019-11-18 13:06 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-11-04  5:46 [PATCH V2 0/4] clk: imx: imx8m[x]: switch to clk_hw API Peng Fan
2019-11-04  5:46 ` Peng Fan
2019-11-04  5:46 ` [PATCH V2 1/4] clk: imx: Remove __init for imx_obtain_fixed_clk_hw() API Peng Fan
2019-11-04  5:46   ` Peng Fan
2019-11-04  5:46 ` [PATCH V2 2/4] clk: imx: imx8mn: Switch to clk_hw based API Peng Fan
2019-11-04  5:46   ` Peng Fan
2019-11-18 13:06   ` Leonard Crestez [this message]
2019-11-18 13:06     ` Leonard Crestez
2019-11-19  1:06     ` Peng Fan
2019-11-19  1:06       ` Peng Fan
2019-11-04  5:46 ` [PATCH V2 3/4] clk: imx: imx8mm: " Peng Fan
2019-11-04  5:46   ` Peng Fan
2019-11-04  5:46 ` [PATCH V2 4/4] clk: imx: imx8mq: " Peng Fan
2019-11-04  5:46   ` Peng Fan
2019-11-05 11:35 ` [PATCH V2 0/4] clk: imx: imx8m[x]: switch to clk_hw API Abel Vesa
2019-11-05 11:35   ` Abel Vesa

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=VI1PR04MB7023CC47DC123A66627940E9EE4D0@VI1PR04MB7023.eurprd04.prod.outlook.com \
    --to=leonard.crestez@nxp.com \
    --cc=abel.vesa@nxp.com \
    --cc=anson.huang@nxp.com \
    --cc=festevam@gmail.com \
    --cc=kernel@pengutronix.de \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-clk@vger.kernel.org \
    --cc=linux-imx@nxp.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=peng.fan@nxp.com \
    --cc=ping.bai@nxp.com \
    --cc=s.hauer@pengutronix.de \
    --cc=sboyd@kernel.org \
    --cc=shawnguo@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.