diff mbox series

[RFC,2/3] arm64: dts: rockchip: rk356x: add LVDS bindings

Message ID 20220923160115.2946615-3-a1ba.omarov@gmail.com (mailing list archive)
State New, archived
Headers show
Series rockchip-lvds for rk3568 | expand

Commit Message

Alibek Omarov Sept. 23, 2022, 4:01 p.m. UTC
Exposes ports for VOP2 and for panel

Signed-off-by: Alibek Omarov <a1ba.omarov@gmail.com>
---
 arch/arm64/boot/dts/rockchip/rk356x.dtsi | 25 ++++++++++++++++++++++++
 1 file changed, 25 insertions(+)

Comments

A. Sverdlin Nov. 16, 2022, 1:19 p.m. UTC | #1
Hello Alibek!

On Fri, 2022-09-23 at 19:01 +0300, Alibek Omarov wrote:
> > Exposes ports for VOP2 and for panel
> > 
> > Signed-off-by: Alibek Omarov <a1ba.omarov@gmail.com>
> > ---
> >  arch/arm64/boot/dts/rockchip/rk356x.dtsi | 25 >
> > ++++++++++++++++++++++++
> >  1 file changed, 25 insertions(+)
> > 
> > diff --git a/arch/arm64/boot/dts/rockchip/rk356x.dtsi >
> > b/arch/arm64/boot/dts/rockchip/rk356x.dtsi
> > index 0473d7ee2668..fea3319a6a4e 100644
> > --- a/arch/arm64/boot/dts/rockchip/rk356x.dtsi
> > +++ b/arch/arm64/boot/dts/rockchip/rk356x.dtsi
> > @@ -787,6 +787,31 @@ hdmi_out: port@1 {
> >                 };
> >         };
> >  
> > +       lvds: lvds {
> > +               compatible = "rockchip,rk3568-lvds";
> > +               clocks = <&cru PCLK_DSITX_0>;
> > +               clock-names = "pclk_lvds";
> > +               phys = <&dsi_dphy0>;

If this patch depends of the 
https://lore.kernel.org/all/20220906174823.28561-6-macroalpha82@gmail.com/
patch, then should the phys reference "mipi_dphy0" node?

> > +               phy-names = "dphy";
> > +               power-domains = <&power RK3568_PD_VO>;
> > +               rockchip,grf = <&grf>;
> > +               rockchip,output = "lvds";
> > +               status = "disabled";
> > +
> > +               ports {
> > +                       #address-cells = <1>;
> > +                       #size-cells = <0>;
> > +
> > +                       lvds_in: port@0 {
> > +                               reg = <0>;
> > +                       };
> > +
> > +                       lvds_out: port@1 {
> > +                               reg = <1>;
> > +                       };
> > +               };
> > +       };
> > +
> >         qos_gpu: qos@fe128000 {
> >                 compatible = "rockchip,rk3568-qos", "syscon";
> >                 reg = <0x0 0xfe128000 0x0 0x20>;
Alibek Omarov Nov. 16, 2022, 3:09 p.m. UTC | #2
> patch, then should the phys reference "mipi_dphy0" node?

Looks like I just linked the old patch version instead of the one that
got merged.

https://git.kernel.org/pub/scm/linux/kernel/git/mmind/linux-rockchip.git/commit/arch/arm64/boot/dts/rockchip/rk356x.dtsi?h=for-next&id=e18d9b093006d8abd53e1ce13c0d5a8d0fcd5f64
A. Sverdlin Nov. 18, 2022, 6:06 p.m. UTC | #3
Hi!

On Wed, 2022-11-16 at 18:09 +0300, Alibek Omarov wrote:
> > patch, then should the phys reference "mipi_dphy0" node?
> 
> Looks like I just linked the old patch version instead of the one
> that
> got merged.
> 
> https://git.kernel.org/pub/scm/linux/kernel/git/mmind/linux-rockchip.git/commit/arch/arm64/boot/dts/rockchip/rk356x.dtsi?h=for-next&id=e18d9b093006d8abd53e1ce13c0d5a8d0fcd5f64

No, it's me totally missed v4 and the whole rockchip tree, sorry for
that!

You can add my
Tested-by: Alexander Sverdlin <alexander.sverdlin@siemens.com>

Your patch works fine and shows some LVDS panel graphics on a custom
rk3566-based board, thank you!
Alibek Omarov Nov. 18, 2022, 6:52 p.m. UTC | #4
>Your patch works fine and shows some LVDS panel graphics on a custom
>rk3566-based board, thank you!

Awesome, thanks!

I didn't made any significant changes since that but I will probably
resend it when I will have free time.
Johan Jonker Jan. 31, 2023, 1:33 p.m. UTC | #5
On 9/23/22 18:01, Alibek Omarov wrote:
> Exposes ports for VOP2 and for panel
> 
> Signed-off-by: Alibek Omarov <a1ba.omarov@gmail.com>
> ---
>  arch/arm64/boot/dts/rockchip/rk356x.dtsi | 25 ++++++++++++++++++++++++
>  1 file changed, 25 insertions(+)
> 
> diff --git a/arch/arm64/boot/dts/rockchip/rk356x.dtsi b/arch/arm64/boot/dts/rockchip/rk356x.dtsi
> index 0473d7ee2668..fea3319a6a4e 100644
> --- a/arch/arm64/boot/dts/rockchip/rk356x.dtsi
> +++ b/arch/arm64/boot/dts/rockchip/rk356x.dtsi
> @@ -787,6 +787,31 @@ hdmi_out: port@1 {
>  		};
>  	};
> 

 
> +	lvds: lvds {
> +		compatible = "rockchip,rk3568-lvds";

Hi Alibek,

1:
In the manufacturer tree they model this node in the grf node.
Any particular reason to do that different?

https://github.com/rockchip-linux/kernel/blob/develop-5.10/arch/arm64/boot/dts/rockchip/rk3568.dtsi#L734

In mainline PX30 already does the same.

2:
There's complete "Acked" serie to be merged by Heiko for a LVDS yaml binding.

[PATCH v6 01/17] dt-bindings: display: rockchip: convert rockchip-lvds.txt to YAML
https://lore.kernel.org/linux-rockchip/67771143-fd83-383d-41b2-68e8707134e8@gmail.com/

Maybe it's better to check this node in a automated way?

Johan


> +		clocks = <&cru PCLK_DSITX_0>;
> +		clock-names = "pclk_lvds";
> +		phys = <&dsi_dphy0>;
> +		phy-names = "dphy";
> +		power-domains = <&power RK3568_PD_VO>;
> +		rockchip,grf = <&grf>;
> +		rockchip,output = "lvds";
> +		status = "disabled";
> +
> +		ports {
> +			#address-cells = <1>;
> +			#size-cells = <0>;
> +
> +			lvds_in: port@0 {
> +				reg = <0>;
> +			};
> +
> +			lvds_out: port@1 {
> +				reg = <1>;
> +			};
> +		};
> +	};
> +
>  	qos_gpu: qos@fe128000 {
>  		compatible = "rockchip,rk3568-qos", "syscon";
>  		reg = <0x0 0xfe128000 0x0 0x20>;
Alibek Omarov Jan. 31, 2023, 6:21 p.m. UTC | #6
Hi Johan!

1. That's interesting, there is no particular reason for this. I can
move it since it makes more sense, as lvds driver only modifies the
grf.

2. I haven't noticed this patch. If it's merged to Heiko's branch, I
will rebase it on YAML then.

Sorry, I don't have that much free time to finish the v2 yet.
Hopefully will send an updated patchset next week or so.

Alibek.
diff mbox series

Patch

diff --git a/arch/arm64/boot/dts/rockchip/rk356x.dtsi b/arch/arm64/boot/dts/rockchip/rk356x.dtsi
index 0473d7ee2668..fea3319a6a4e 100644
--- a/arch/arm64/boot/dts/rockchip/rk356x.dtsi
+++ b/arch/arm64/boot/dts/rockchip/rk356x.dtsi
@@ -787,6 +787,31 @@  hdmi_out: port@1 {
 		};
 	};
 
+	lvds: lvds {
+		compatible = "rockchip,rk3568-lvds";
+		clocks = <&cru PCLK_DSITX_0>;
+		clock-names = "pclk_lvds";
+		phys = <&dsi_dphy0>;
+		phy-names = "dphy";
+		power-domains = <&power RK3568_PD_VO>;
+		rockchip,grf = <&grf>;
+		rockchip,output = "lvds";
+		status = "disabled";
+
+		ports {
+			#address-cells = <1>;
+			#size-cells = <0>;
+
+			lvds_in: port@0 {
+				reg = <0>;
+			};
+
+			lvds_out: port@1 {
+				reg = <1>;
+			};
+		};
+	};
+
 	qos_gpu: qos@fe128000 {
 		compatible = "rockchip,rk3568-qos", "syscon";
 		reg = <0x0 0xfe128000 0x0 0x20>;