Skip to contentSkip to conversation

arm64: dts: amlogic: add power domain to hdmitx

PATCH Applied Jerome Brunet 3 participants 6 messages Jun 25, 2024 – Jun 26, 2024

Subsystems (5)
lore
Share & tools
lore

Jerome Brunet

author reviewer
#0 lore raw

cover arm64: dts: amlogic: add power domain to hdmitx

This patchset add the bindings for the power domain of the HDMI Tx on Amlogic SoC.

This is a 1st step in cleaning HDMI Tx and its direct usage of HHI register space. Eventually, this will help remove component usage from the Amlogic display drivers.

Jerome Brunet (2):
dt-bindings: display: meson-dw-hdmi: add missing power-domain
arm64: dts: amlogic: add power domain to hdmitx

 .../devicetree/bindings/display/amlogic,meson-dw-hdmi.yaml   | 5 +++++
 arch/arm64/boot/dts/amlogic/meson-g12.dtsi                   | 4 ++++
 arch/arm64/boot/dts/amlogic/meson-gxbb.dtsi                  | 1 +
 arch/arm64/boot/dts/amlogic/meson-gxl.dtsi                   | 1 +
 arch/arm64/boot/dts/amlogic/meson-sm1.dtsi                   | 4 ++++
 5 files changed, 15 insertions(+)
Signature · 1 line
2.43.0
author reviewer
#1 lore raw

PATCH 1/2 dt-bindings: display: meson-dw-hdmi: add missing power-domain

All Amlogic instances of the Synopsys HDMI controller need a power domain enabled. This is currently missing because the Amlogic HDMI driver directly pokes the power domain controller registers, which it should not do.

Instead The HDMI controller should use the power controller. Fix the bindings accordingly.

---
 .../devicetree/bindings/display/amlogic,meson-dw-hdmi.yaml   | 5 +++++
 1 file changed, 5 insertions(+)
Documentation/devicetree/bindings/display/amlogic,meson-dw-hdmi.yaml +5 -0
index 0c85894648d8..84d68b8cfccc 100644
@@ -71,6 +71,10 @@ properties:
       - const: iahb
       - const: venci
 
+  power-domains:
+    maxItems: 1
+    description: phandle to the associated power domain
+
   resets:
     minItems: 3
 
@@ -129,6 +133,7 @@ examples:
         reset-names = "hdmitx_apb", "hdmitx", "hdmitx_phy";
         clocks = <&clk_isfr>, <&clk_iahb>, <&clk_venci>;
         clock-names = "isfr", "iahb", "venci";
+        power-domains = <&pd_vpu>;
         #address-cells = <1>;
         #size-cells = <0>;
 
Signature · 1 line
2.43.0
Acked-by on v1 1/2
#2 lore raw

Re: [PATCH 1/2] dt-bindings: display: meson-dw-hdmi: add missing power-domain

Quoted 8 lines · Jerome Brunet

All Amlogic instances of the Synopsys HDMI controller need a power domain enabled. This is currently missing because the Amlogic HDMI driver directly pokes the power domain controller registers, which it should not do.

Instead The HDMI controller should use the power controller. Fix the bindings accordingly.

author reviewer
#3 lore raw

PATCH 2/2 arm64: dts: amlogic: add power domain to hdmitx

In reply to Jerome Brunet

HDMI Tx needs HDMI Tx memory power domain turned on. This power domain is handled under the VPU power domain.

The HDMI Tx currently works because it is enabling the PD by directly poking the power controller register. It is should not do that but properly use the power domain controller.

Fix this by adding the power domain to HDMI Tx.

---
 arch/arm64/boot/dts/amlogic/meson-g12.dtsi  | 4 ++++
 arch/arm64/boot/dts/amlogic/meson-gxbb.dtsi | 1 +
 arch/arm64/boot/dts/amlogic/meson-gxl.dtsi  | 1 +
 arch/arm64/boot/dts/amlogic/meson-sm1.dtsi  | 4 ++++
 4 files changed, 10 insertions(+)
arch/arm64/boot/dts/amlogic/meson-g12.dtsi +4 -0
index e732df3f3114..664912d1beaa 100644
@@ -363,6 +363,10 @@ &ethmac {
 	power-domains = <&pwrc PWRC_G12A_ETH_ID>;
 };
 
+&hdmi_tx {
+	power-domains = <&pwrc PWRC_G12A_VPU_ID>;
+};
+
 &vpu {
 	power-domains = <&pwrc PWRC_G12A_VPU_ID>;
 };
arch/arm64/boot/dts/amlogic/meson-gxbb.dtsi +1 -0
index 12ef6e81c8bd..d8a386c31914 100644
@@ -315,6 +315,7 @@ &hdmi_tx {
 		 <&clkc CLKID_CLK81>,
 		 <&clkc CLKID_GCLK_VENCI_INT0>;
 	clock-names = "isfr", "iahb", "venci";
+	power-domains = <&pwrc PWRC_GXBB_VPU_ID>;
 };
 
 &sysctrl {
arch/arm64/boot/dts/amlogic/meson-gxl.dtsi +1 -0
index 17bcfa4702e1..82386feb5177 100644
@@ -327,6 +327,7 @@ &hdmi_tx {
 		 <&clkc CLKID_CLK81>,
 		 <&clkc CLKID_GCLK_VENCI_INT0>;
 	clock-names = "isfr", "iahb", "venci";
+	power-domains = <&pwrc PWRC_GXBB_VPU_ID>;
 };
 
 &sysctrl {
arch/arm64/boot/dts/amlogic/meson-sm1.dtsi +4 -0
index cd0046c0fe72..c76dcb0158a7 100644
@@ -514,6 +514,10 @@ &gpio_intc {
 		     "amlogic,meson-gpio-intc";
 };
 
+&hdmi_tx {
+	power-domains = <&pwrc PWRC_SM1_VPU_ID>;
+};
+
 &pcie {
 	power-domains = <&pwrc PWRC_SM1_PCIE_ID>;
 };
Signature · 1 line
2.43.0
maintainer Applied
#4 lore raw

Re: (subset) [PATCH 0/2] arm64: dts: amlogic: add power domain to hdmitx

In reply to Jerome Brunet

Hi,

Quoted 8 lines · Jerome Brunet

This patchset add the bindings for the power domain of the HDMI Tx on Amlogic SoC.

This is a 1st step in cleaning HDMI Tx and its direct usage of HHI register space. Eventually, this will help remove component usage from the Amlogic display drivers.

[...]

Thanks, Applied to https://gitlab.freedesktop.org/drm/misc/kernel.git (drm-misc-next)

[1/2] dt-bindings: display: meson-dw-hdmi: add missing power-domain

      https://gitlab.freedesktop.org/drm/misc/kernel/-/commit/c19f15b1e056a1ab896d54909f75febf70d98be6
Signature · 1 line
Neil
maintainer Applied
#5 lore raw

Re: (subset) [PATCH 0/2] arm64: dts: amlogic: add power domain to hdmitx

In reply to Jerome Brunet

Hi,

Quoted 8 lines · Jerome Brunet

This patchset add the bindings for the power domain of the HDMI Tx on Amlogic SoC.

This is a 1st step in cleaning HDMI Tx and its direct usage of HHI register space. Eventually, this will help remove component usage from the Amlogic display drivers.

[...]

Thanks, Applied to https://git.kernel.org/pub/scm/linux/kernel/git/amlogic/linux.git (v6.11/arm64-dt)

[2/2] arm64: dts: amlogic: add power domain to hdmitx

      https://git.kernel.org/amlogic/c/f1ab099d6591a353899a2ee09c89de0fc908e2d2

These changes has been applied on the intermediate git tree [1].

The v6.11/arm64-dt branch will then be sent via a formal Pull Request to the Linux SoC maintainers for inclusion in their intermediate git branches in order to be sent to Linus during the next merge window, or sooner if it's a set of fixes.

In the cases of fixes, those will be merged in the current release candidate kernel and as soon they appear on the Linux master branch they will be backported to the previous Stable and Long-Stable kernels [2].

The intermediate git branches are merged daily in the linux-next tree [3], people are encouraged testing these pre-release kernels and report issues on the relevant mailing-lists.

If problems are discovered on those changes, please submit a signed-off-by revert patch followed by a corrective changeset.

[1] https://git.kernel.org/pub/scm/linux/kernel/git/amlogic/linux.git
[2] https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
[3] https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git

Signature · 1 line
Neil