linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] arm64: dts: imx8mp: configure GPU and NPU clocks in nominal DTSI
@ 2025-03-11 19:41 Ahmad Fatoum
  2025-04-22  2:18 ` Shawn Guo
  0 siblings, 1 reply; 2+ messages in thread
From: Ahmad Fatoum @ 2025-03-11 19:41 UTC (permalink / raw)
  To: Shawn Guo, Sascha Hauer, Lucas Stach, Pengutronix Kernel Team
  Cc: Rob Herring, Krzysztof Kozlowski, Conor Dooley, Fabio Estevam,
	Peng Fan, devicetree, imx, linux-arm-kernel, linux-kernel,
	Ahmad Fatoum

Commit 255fbd9eabe7 ("arm64: dts: imx8mp: Add optional nominal drive
mode DTSI") added imx8mp-nominal.dtsi, which overrides all overdrive
clock rates in imx8mp.dtsi to the nominal rates.

At the same time, commit 9f7595b3e5ae ("arm64: dts: imx8mp: configure
GPU and NPU clocks to overdrive rate") went in, which changed some
clock rates away from the nominal values.

Resolve the discrepancy by effectively reverting the changes in the
latter commit inside imx8mp-nominal.dtsi. This is required for proper
operation of the imx8mp-skov boards, which are currently
imx8mp-nominal.dtsi's only users and lets all other boards that don't
include it benefit from the new higher frequencies.

Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de>
---
If the commit hashes are not stable, please feel free to squash this
change directly into what's currently commit 255fbd9eabe7 ("arm64: dts:

imx8mp: Add optional nominal drive mode DTSI").
---
 arch/arm64/boot/dts/freescale/imx8mp-nominal.dtsi | 26 +++++++++++++++++++++++
 1 file changed, 26 insertions(+)

diff --git a/arch/arm64/boot/dts/freescale/imx8mp-nominal.dtsi b/arch/arm64/boot/dts/freescale/imx8mp-nominal.dtsi
index a1b75c9068b288a2fba73bbd96b1519a50df85a3..dc0ccd723c6d92e7946ebd52bac535e4175498d0 100644
--- a/arch/arm64/boot/dts/freescale/imx8mp-nominal.dtsi
+++ b/arch/arm64/boot/dts/freescale/imx8mp-nominal.dtsi
@@ -24,6 +24,20 @@ &clk {
 	fsl,operating-mode = "nominal";
 };
 
+&gpu2d {
+	assigned-clocks = <&clk IMX8MP_CLK_GPU2D_CORE>;
+	assigned-clock-parents = <&clk IMX8MP_SYS_PLL1_800M>;
+	assigned-clock-rates = <800000000>;
+};
+
+&gpu3d {
+	assigned-clocks = <&clk IMX8MP_CLK_GPU3D_CORE>,
+			  <&clk IMX8MP_CLK_GPU3D_SHADER_CORE>;
+	assigned-clock-parents = <&clk IMX8MP_SYS_PLL1_800M>,
+				 <&clk IMX8MP_SYS_PLL1_800M>;
+	assigned-clock-rates = <800000000>, <800000000>;
+};
+
 &pgc_hdmimix {
 	assigned-clocks = <&clk IMX8MP_CLK_HDMI_AXI>,
 			  <&clk IMX8MP_CLK_HDMI_APB>;
@@ -46,6 +60,18 @@ &pgc_gpumix {
 	assigned-clock-rates = <600000000>, <300000000>;
 };
 
+&pgc_mlmix {
+	assigned-clocks = <&clk IMX8MP_CLK_ML_CORE>,
+			  <&clk IMX8MP_CLK_ML_AXI>,
+			  <&clk IMX8MP_CLK_ML_AHB>;
+	assigned-clock-parents = <&clk IMX8MP_SYS_PLL1_800M>,
+				 <&clk IMX8MP_SYS_PLL1_800M>,
+				 <&clk IMX8MP_SYS_PLL1_800M>;
+	assigned-clock-rates = <800000000>,
+			       <800000000>,
+			       <300000000>;
+};
+
 &media_blk_ctrl {
 	assigned-clocks = <&clk IMX8MP_CLK_MEDIA_AXI>,
 			  <&clk IMX8MP_CLK_MEDIA_APB>,

---
base-commit: 5a690619426fc4b09c7fd3f40d3a69264ef3db0f
change-id: 20250311-imx8m-clk-nominal-gpu-db3bd7b7c905

Best regards,
-- 
Ahmad Fatoum <a.fatoum@pengutronix.de>



^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] arm64: dts: imx8mp: configure GPU and NPU clocks in nominal DTSI
  2025-03-11 19:41 [PATCH] arm64: dts: imx8mp: configure GPU and NPU clocks in nominal DTSI Ahmad Fatoum
@ 2025-04-22  2:18 ` Shawn Guo
  0 siblings, 0 replies; 2+ messages in thread
From: Shawn Guo @ 2025-04-22  2:18 UTC (permalink / raw)
  To: Ahmad Fatoum
  Cc: Shawn Guo, Sascha Hauer, Lucas Stach, Pengutronix Kernel Team,
	Rob Herring, Krzysztof Kozlowski, Conor Dooley, Fabio Estevam,
	Peng Fan, devicetree, imx, linux-arm-kernel, linux-kernel

On Tue, Mar 11, 2025 at 08:41:12PM +0100, Ahmad Fatoum wrote:
> Commit 255fbd9eabe7 ("arm64: dts: imx8mp: Add optional nominal drive
> mode DTSI") added imx8mp-nominal.dtsi, which overrides all overdrive
> clock rates in imx8mp.dtsi to the nominal rates.
> 
> At the same time, commit 9f7595b3e5ae ("arm64: dts: imx8mp: configure
> GPU and NPU clocks to overdrive rate") went in, which changed some
> clock rates away from the nominal values.
> 
> Resolve the discrepancy by effectively reverting the changes in the
> latter commit inside imx8mp-nominal.dtsi. This is required for proper
> operation of the imx8mp-skov boards, which are currently
> imx8mp-nominal.dtsi's only users and lets all other boards that don't
> include it benefit from the new higher frequencies.
> 
> Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de>

Applied, thanks!



^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2025-04-22  2:53 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-03-11 19:41 [PATCH] arm64: dts: imx8mp: configure GPU and NPU clocks in nominal DTSI Ahmad Fatoum
2025-04-22  2:18 ` Shawn Guo

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).