imx.lists.linux.dev archive mirror
 help / color / mirror / Atom feed
* [PATCH V2 0/4] Increase i.MX8MP VPU
@ 2025-06-12  0:39 Adam Ford
  2025-06-12  0:39 ` [PATCH V2 1/4] arm64: dts: imx8mp: drop gpcv2 vpu power-domains and clocks Adam Ford
                   ` (4 more replies)
  0 siblings, 5 replies; 8+ messages in thread
From: Adam Ford @ 2025-06-12  0:39 UTC (permalink / raw)
  To: linux-arm-kernel
  Cc: aford, m.felsch, Adam Ford, Rob Herring, Krzysztof Kozlowski,
	Conor Dooley, Shawn Guo, Sascha Hauer, Pengutronix Kernel Team,
	Fabio Estevam, devicetree, imx, linux-kernel

Some of the VPU clocks are under rated, even for nominal ratings.
Fix the nominial VPU clocks and clock parents, then introduce
the overdrive clock rates.  The fluster scores don't change,
but they do go faster.

This series was adapted from an RFC from Marco Felsch which
was setup to introduce the VC8000E encoder and extacted the
parts that affect the existing infrastructure.

V2:  The only change is 4/4.  Patches 1-3 are all unchanged.

Adam Ford (2):
  arm64: dts: imx8mp-nominal: Explicitly configure nominal VPU clocks
  arm64: dts: imx8mp: Configure VPU clocks for overdrive

Marco Felsch (2):
  arm64: dts: imx8mp: drop gpcv2 vpu power-domains and clocks
  arm64: dts: imx8mp: fix VPU_BUS clock setting

 .../boot/dts/freescale/imx8mp-nominal.dtsi    | 18 +++++++++++++++
 arch/arm64/boot/dts/freescale/imx8mp.dtsi     | 23 +++++++------------
 2 files changed, 26 insertions(+), 15 deletions(-)

-- 
2.48.1


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

* [PATCH V2 1/4] arm64: dts: imx8mp: drop gpcv2 vpu power-domains and clocks
  2025-06-12  0:39 [PATCH V2 0/4] Increase i.MX8MP VPU Adam Ford
@ 2025-06-12  0:39 ` Adam Ford
  2025-06-12  0:39 ` [PATCH V2 2/4] arm64: dts: imx8mp: fix VPU_BUS clock setting Adam Ford
                   ` (3 subsequent siblings)
  4 siblings, 0 replies; 8+ messages in thread
From: Adam Ford @ 2025-06-12  0:39 UTC (permalink / raw)
  To: linux-arm-kernel
  Cc: aford, m.felsch, Adam Ford, Rob Herring, Krzysztof Kozlowski,
	Conor Dooley, Shawn Guo, Sascha Hauer, Pengutronix Kernel Team,
	Fabio Estevam, devicetree, imx, linux-kernel

From: Marco Felsch <m.felsch@pengutronix.de>

The GPCv2 G1, G2 and VC8000E power-domain don't need to reference the
VPUMIX power-domain nor their module clocks since the power and reset
handling is done by the VPUMIX blkctrl driver.

Signed-off-by: Marco Felsch <m.felsch@pengutronix.de>
Signed-off-by: Adam Ford <aford173@gmail.com>

diff --git a/arch/arm64/boot/dts/freescale/imx8mp.dtsi b/arch/arm64/boot/dts/freescale/imx8mp.dtsi
index 948b88cf5e9d..1bf15c502280 100644
--- a/arch/arm64/boot/dts/freescale/imx8mp.dtsi
+++ b/arch/arm64/boot/dts/freescale/imx8mp.dtsi
@@ -876,24 +876,17 @@ pgc_mediamix: power-domain@10 {
 
 					pgc_vpu_g1: power-domain@11 {
 						#power-domain-cells = <0>;
-						power-domains = <&pgc_vpumix>;
 						reg = <IMX8MP_POWER_DOMAIN_VPU_G1>;
-						clocks = <&clk IMX8MP_CLK_VPU_G1_ROOT>;
 					};
 
 					pgc_vpu_g2: power-domain@12 {
 						#power-domain-cells = <0>;
-						power-domains = <&pgc_vpumix>;
 						reg = <IMX8MP_POWER_DOMAIN_VPU_G2>;
-						clocks = <&clk IMX8MP_CLK_VPU_G2_ROOT>;
-
 					};
 
 					pgc_vpu_vc8000e: power-domain@13 {
 						#power-domain-cells = <0>;
-						power-domains = <&pgc_vpumix>;
 						reg = <IMX8MP_POWER_DOMAIN_VPU_VC8000E>;
-						clocks = <&clk IMX8MP_CLK_VPU_VC8KE_ROOT>;
 					};
 
 					pgc_hdmimix: power-domain@14 {
-- 
2.48.1


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

* [PATCH V2 2/4] arm64: dts: imx8mp: fix VPU_BUS clock setting
  2025-06-12  0:39 [PATCH V2 0/4] Increase i.MX8MP VPU Adam Ford
  2025-06-12  0:39 ` [PATCH V2 1/4] arm64: dts: imx8mp: drop gpcv2 vpu power-domains and clocks Adam Ford
@ 2025-06-12  0:39 ` Adam Ford
  2025-06-12  0:39 ` [PATCH V2 3/4] arm64: dts: imx8mp-nominal: Explicitly configure nominal VPU clocks Adam Ford
                   ` (2 subsequent siblings)
  4 siblings, 0 replies; 8+ messages in thread
From: Adam Ford @ 2025-06-12  0:39 UTC (permalink / raw)
  To: linux-arm-kernel
  Cc: aford, m.felsch, Adam Ford, Rob Herring, Krzysztof Kozlowski,
	Conor Dooley, Shawn Guo, Sascha Hauer, Pengutronix Kernel Team,
	Fabio Estevam, devicetree, imx, linux-kernel

From: Marco Felsch <m.felsch@pengutronix.de>

The VPU_PLL clock must be set before the VPU_BUS clock which is derived
from the VPU_PLL clock else the VPU_BUS clock is 300MHz and not 600MHz.

Signed-off-by: Marco Felsch <m.felsch@pengutronix.de>
Signed-off-by: Adam Ford <aford173@gmail.com>

diff --git a/arch/arm64/boot/dts/freescale/imx8mp.dtsi b/arch/arm64/boot/dts/freescale/imx8mp.dtsi
index 1bf15c502280..909555a5da4b 100644
--- a/arch/arm64/boot/dts/freescale/imx8mp.dtsi
+++ b/arch/arm64/boot/dts/freescale/imx8mp.dtsi
@@ -2283,8 +2283,8 @@ vpumix_blk_ctrl: blk-ctrl@38330000 {
 				 <&clk IMX8MP_CLK_VPU_G2_ROOT>,
 				 <&clk IMX8MP_CLK_VPU_VC8KE_ROOT>;
 			clock-names = "g1", "g2", "vc8000e";
-			assigned-clocks = <&clk IMX8MP_CLK_VPU_BUS>, <&clk IMX8MP_VPU_PLL>;
-			assigned-clock-parents = <&clk IMX8MP_VPU_PLL_OUT>;
+			assigned-clocks = <&clk IMX8MP_VPU_PLL>, <&clk IMX8MP_CLK_VPU_BUS>;
+			assigned-clock-parents = <0>, <&clk IMX8MP_VPU_PLL_OUT>;
 			assigned-clock-rates = <600000000>, <600000000>;
 			interconnects = <&noc IMX8MP_ICM_VPU_G1 &noc IMX8MP_ICN_VIDEO>,
 					<&noc IMX8MP_ICM_VPU_G2 &noc IMX8MP_ICN_VIDEO>,
-- 
2.48.1


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

* [PATCH V2 3/4] arm64: dts: imx8mp-nominal: Explicitly configure nominal VPU clocks
  2025-06-12  0:39 [PATCH V2 0/4] Increase i.MX8MP VPU Adam Ford
  2025-06-12  0:39 ` [PATCH V2 1/4] arm64: dts: imx8mp: drop gpcv2 vpu power-domains and clocks Adam Ford
  2025-06-12  0:39 ` [PATCH V2 2/4] arm64: dts: imx8mp: fix VPU_BUS clock setting Adam Ford
@ 2025-06-12  0:39 ` Adam Ford
  2025-06-12 13:17   ` Marco Felsch
  2025-06-12  0:39 ` [PATCH V2 4/4] arm64: dts: imx8mp: Configure VPU clocks for overdrive Adam Ford
  2025-07-02  9:51 ` [PATCH V2 0/4] Increase i.MX8MP VPU Shawn Guo
  4 siblings, 1 reply; 8+ messages in thread
From: Adam Ford @ 2025-06-12  0:39 UTC (permalink / raw)
  To: linux-arm-kernel
  Cc: aford, m.felsch, Adam Ford, Ahmad Fatoum, Peng Fan, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Shawn Guo, Sascha Hauer,
	Pengutronix Kernel Team, Fabio Estevam, devicetree, imx,
	linux-kernel

In preparation for increasing the default VPU clocks to overdrive,
configure the nominal values first to avoid running the nominal
devices out of spec when imx8mp.dtsi is changed.

Signed-off-by: Adam Ford <aford173@gmail.com>
Reviewed-by: Ahmad Fatoum <a.fatoum@pengutronix.de>
Reviewed-by: Peng Fan <peng.fan@nxp.com>
Signed-off-by: Adam Ford <aford173@gmail.com>

diff --git a/arch/arm64/boot/dts/freescale/imx8mp-nominal.dtsi b/arch/arm64/boot/dts/freescale/imx8mp-nominal.dtsi
index 2ce1860b244d..f269f7a004fc 100644
--- a/arch/arm64/boot/dts/freescale/imx8mp-nominal.dtsi
+++ b/arch/arm64/boot/dts/freescale/imx8mp-nominal.dtsi
@@ -89,4 +89,22 @@ &media_blk_ctrl {
 			       <1039500000>;
 };
 
+&vpu_g1 {
+	assigned-clocks = <&clk IMX8MP_CLK_VPU_G1>;
+	assigned-clock-parents = <&clk IMX8MP_VPU_PLL_OUT>;
+	assigned-clock-rates = <600000000>;
+};
+
+&vpu_g2 {
+	assigned-clocks = <&clk IMX8MP_CLK_VPU_G2>;
+	assigned-clock-parents = <&clk IMX8MP_SYS_PLL2_1000M>;
+	assigned-clock-rates = <500000000>;
+};
+
+&vpumix_blk_ctrl {
+	assigned-clocks = <&clk IMX8MP_VPU_PLL>, <&clk IMX8MP_CLK_VPU_BUS>;
+	assigned-clock-parents = <0>, <&clk IMX8MP_VPU_PLL_OUT>;
+	assigned-clock-rates = <600000000>, <600000000>;
+};
+
 /delete-node/ &{noc_opp_table/opp-1000000000};
-- 
2.48.1


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

* [PATCH V2 4/4] arm64: dts: imx8mp: Configure VPU clocks for overdrive
  2025-06-12  0:39 [PATCH V2 0/4] Increase i.MX8MP VPU Adam Ford
                   ` (2 preceding siblings ...)
  2025-06-12  0:39 ` [PATCH V2 3/4] arm64: dts: imx8mp-nominal: Explicitly configure nominal VPU clocks Adam Ford
@ 2025-06-12  0:39 ` Adam Ford
  2025-06-12 13:16   ` Marco Felsch
  2025-07-02  9:51 ` [PATCH V2 0/4] Increase i.MX8MP VPU Shawn Guo
  4 siblings, 1 reply; 8+ messages in thread
From: Adam Ford @ 2025-06-12  0:39 UTC (permalink / raw)
  To: linux-arm-kernel
  Cc: aford, m.felsch, Adam Ford, Rob Herring, Krzysztof Kozlowski,
	Conor Dooley, Shawn Guo, Sascha Hauer, Pengutronix Kernel Team,
	Fabio Estevam, devicetree, imx, linux-kernel

The defaults for this SoC are configured for overdrive mode, but
the VPU clocks are currently configured for nominal mode.
Increase VPU_G1_CLK_ROOT to 800MHZ from 600MHz,
Increase VPU_G2_CLK_ROOT to 700MHZ from 500MHz, and
Increase VPU_BUS_CLK_ROOT to 800MHz from 600MHz.

This requires adjusting the clock parents. Since there is already
800MHz clock references, move the VPU_BUS and G1 clocks to it.
This frees up the VPU_PLL to be configured at 700MHz to run
the G2 clock at 700MHz.

Signed-off-by: Adam Ford <aford173@gmail.com>
---
V2:  Move VPU_PLL assignment into the G2 node, since it's only needed
     for it.

diff --git a/arch/arm64/boot/dts/freescale/imx8mp.dtsi b/arch/arm64/boot/dts/freescale/imx8mp.dtsi
index 909555a5da4b..8884b3fe5e60 100644
--- a/arch/arm64/boot/dts/freescale/imx8mp.dtsi
+++ b/arch/arm64/boot/dts/freescale/imx8mp.dtsi
@@ -2256,8 +2256,8 @@ vpu_g1: video-codec@38300000 {
 			interrupts = <GIC_SPI 7 IRQ_TYPE_LEVEL_HIGH>;
 			clocks = <&clk IMX8MP_CLK_VPU_G1_ROOT>;
 			assigned-clocks = <&clk IMX8MP_CLK_VPU_G1>;
-			assigned-clock-parents = <&clk IMX8MP_VPU_PLL_OUT>;
-			assigned-clock-rates = <600000000>;
+			assigned-clock-parents = <&clk IMX8MP_SYS_PLL1_800M>;
+			assigned-clock-rates = <800000000>;
 			power-domains = <&vpumix_blk_ctrl IMX8MP_VPUBLK_PD_G1>;
 		};
 
@@ -2266,9 +2266,9 @@ vpu_g2: video-codec@38310000 {
 			reg = <0x38310000 0x10000>;
 			interrupts = <GIC_SPI 8 IRQ_TYPE_LEVEL_HIGH>;
 			clocks = <&clk IMX8MP_CLK_VPU_G2_ROOT>;
-			assigned-clocks = <&clk IMX8MP_CLK_VPU_G2>;
-			assigned-clock-parents = <&clk IMX8MP_SYS_PLL2_1000M>;
-			assigned-clock-rates = <500000000>;
+			assigned-clocks = <&clk IMX8MP_CLK_VPU_G2>, <&clk IMX8MP_VPU_PLL_OUT>;
+			assigned-clock-parents = <&clk IMX8MP_VPU_PLL_OUT>;
+			assigned-clock-rates = <700000000>, <700000000>;
 			power-domains = <&vpumix_blk_ctrl IMX8MP_VPUBLK_PD_G2>;
 		};
 
@@ -2283,9 +2283,9 @@ vpumix_blk_ctrl: blk-ctrl@38330000 {
 				 <&clk IMX8MP_CLK_VPU_G2_ROOT>,
 				 <&clk IMX8MP_CLK_VPU_VC8KE_ROOT>;
 			clock-names = "g1", "g2", "vc8000e";
-			assigned-clocks = <&clk IMX8MP_VPU_PLL>, <&clk IMX8MP_CLK_VPU_BUS>;
-			assigned-clock-parents = <0>, <&clk IMX8MP_VPU_PLL_OUT>;
-			assigned-clock-rates = <600000000>, <600000000>;
+			assigned-clocks = <&clk IMX8MP_CLK_VPU_BUS>;
+			assigned-clock-parents = <&clk IMX8MP_SYS_PLL1_800M>;
+			assigned-clock-rates = <800000000>;
 			interconnects = <&noc IMX8MP_ICM_VPU_G1 &noc IMX8MP_ICN_VIDEO>,
 					<&noc IMX8MP_ICM_VPU_G2 &noc IMX8MP_ICN_VIDEO>,
 					<&noc IMX8MP_ICM_VPU_H1 &noc IMX8MP_ICN_VIDEO>;
-- 
2.48.1


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

* Re: [PATCH V2 4/4] arm64: dts: imx8mp: Configure VPU clocks for overdrive
  2025-06-12  0:39 ` [PATCH V2 4/4] arm64: dts: imx8mp: Configure VPU clocks for overdrive Adam Ford
@ 2025-06-12 13:16   ` Marco Felsch
  0 siblings, 0 replies; 8+ messages in thread
From: Marco Felsch @ 2025-06-12 13:16 UTC (permalink / raw)
  To: Adam Ford
  Cc: linux-arm-kernel, aford, Rob Herring, Krzysztof Kozlowski,
	Conor Dooley, Shawn Guo, Sascha Hauer, Pengutronix Kernel Team,
	Fabio Estevam, devicetree, imx, linux-kernel

On 25-06-11, Adam Ford wrote:
> The defaults for this SoC are configured for overdrive mode, but
> the VPU clocks are currently configured for nominal mode.
> Increase VPU_G1_CLK_ROOT to 800MHZ from 600MHz,
> Increase VPU_G2_CLK_ROOT to 700MHZ from 500MHz, and
> Increase VPU_BUS_CLK_ROOT to 800MHz from 600MHz.
> 
> This requires adjusting the clock parents. Since there is already
> 800MHz clock references, move the VPU_BUS and G1 clocks to it.
> This frees up the VPU_PLL to be configured at 700MHz to run
> the G2 clock at 700MHz.
> 
> Signed-off-by: Adam Ford <aford173@gmail.com>

Reviewed-by: Marco Felsch <m.felsch@pengutronix.de>

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

* Re: [PATCH V2 3/4] arm64: dts: imx8mp-nominal: Explicitly configure nominal VPU clocks
  2025-06-12  0:39 ` [PATCH V2 3/4] arm64: dts: imx8mp-nominal: Explicitly configure nominal VPU clocks Adam Ford
@ 2025-06-12 13:17   ` Marco Felsch
  0 siblings, 0 replies; 8+ messages in thread
From: Marco Felsch @ 2025-06-12 13:17 UTC (permalink / raw)
  To: Adam Ford
  Cc: linux-arm-kernel, aford, Ahmad Fatoum, Peng Fan, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Shawn Guo, Sascha Hauer,
	Pengutronix Kernel Team, Fabio Estevam, devicetree, imx,
	linux-kernel

On 25-06-11, Adam Ford wrote:
> In preparation for increasing the default VPU clocks to overdrive,
> configure the nominal values first to avoid running the nominal
> devices out of spec when imx8mp.dtsi is changed.
> 
> Signed-off-by: Adam Ford <aford173@gmail.com>
> Reviewed-by: Ahmad Fatoum <a.fatoum@pengutronix.de>
> Reviewed-by: Peng Fan <peng.fan@nxp.com>
> Signed-off-by: Adam Ford <aford173@gmail.com>

Reviewed-by: Marco Felsch <m.felsch@pengutronix.de>

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

* Re: [PATCH V2 0/4] Increase i.MX8MP VPU
  2025-06-12  0:39 [PATCH V2 0/4] Increase i.MX8MP VPU Adam Ford
                   ` (3 preceding siblings ...)
  2025-06-12  0:39 ` [PATCH V2 4/4] arm64: dts: imx8mp: Configure VPU clocks for overdrive Adam Ford
@ 2025-07-02  9:51 ` Shawn Guo
  4 siblings, 0 replies; 8+ messages in thread
From: Shawn Guo @ 2025-07-02  9:51 UTC (permalink / raw)
  To: Adam Ford
  Cc: linux-arm-kernel, aford, m.felsch, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Shawn Guo, Sascha Hauer,
	Pengutronix Kernel Team, Fabio Estevam, devicetree, imx,
	linux-kernel

On Wed, Jun 11, 2025 at 07:39:18PM -0500, Adam Ford wrote:
> Some of the VPU clocks are under rated, even for nominal ratings.
> Fix the nominial VPU clocks and clock parents, then introduce
> the overdrive clock rates.  The fluster scores don't change,
> but they do go faster.
> 
> This series was adapted from an RFC from Marco Felsch which
> was setup to introduce the VC8000E encoder and extacted the
> parts that affect the existing infrastructure.
> 
> V2:  The only change is 4/4.  Patches 1-3 are all unchanged.
> 
> Adam Ford (2):
>   arm64: dts: imx8mp-nominal: Explicitly configure nominal VPU clocks
>   arm64: dts: imx8mp: Configure VPU clocks for overdrive
> 
> Marco Felsch (2):
>   arm64: dts: imx8mp: drop gpcv2 vpu power-domains and clocks
>   arm64: dts: imx8mp: fix VPU_BUS clock setting

Applied all, thanks!


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

end of thread, other threads:[~2025-07-02 10:02 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-06-12  0:39 [PATCH V2 0/4] Increase i.MX8MP VPU Adam Ford
2025-06-12  0:39 ` [PATCH V2 1/4] arm64: dts: imx8mp: drop gpcv2 vpu power-domains and clocks Adam Ford
2025-06-12  0:39 ` [PATCH V2 2/4] arm64: dts: imx8mp: fix VPU_BUS clock setting Adam Ford
2025-06-12  0:39 ` [PATCH V2 3/4] arm64: dts: imx8mp-nominal: Explicitly configure nominal VPU clocks Adam Ford
2025-06-12 13:17   ` Marco Felsch
2025-06-12  0:39 ` [PATCH V2 4/4] arm64: dts: imx8mp: Configure VPU clocks for overdrive Adam Ford
2025-06-12 13:16   ` Marco Felsch
2025-07-02  9:51 ` [PATCH V2 0/4] Increase i.MX8MP VPU 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).