diff mbox series

[v2,1/3] arm64: dts: renesas: Prepare AA1024XD12 panel .dtsi for overlay support

Message ID 20211229193135.28767-2-laurent.pinchart+renesas@ideasonboard.com
State Accepted
Commit 79e682024559ccc8b01b36ef128afbe89cf25092
Headers show
Series arm64: dts: renesas: Prepare AA1024XD12 panel .dtsi for overlay support | expand

Commit Message

Laurent Pinchart Dec. 29, 2021, 7:31 p.m. UTC
The Mitsubishi AA1024XD12 panel can be used for R-Car Gen2 and Gen3
boards as an optional external panel. It is described in the
arm/boot/dts/r8a77xx-aa104xd12-panel.dtsi file as a direct child of the
DT root node. This allows including r8a77xx-aa104xd12-panel.dtsi in
board device trees, with other minor modifications, to enable the panel.

This is however not how external components should be modelled. Instead
of modifying the board device tree to enable the panel, it should be
compiled as a DT overlay, to be loaded by the boot loader.

Prepare the r8a77xx-aa104xd12-panel.dtsi file for this usage by
declaring a panel node only, without hardcoding its path. Overlay
sources can then include r8a77xx-aa104xd12-panel.dtsi where appropriate.

This change doesn't cause any regression as r8a77xx-aa104xd12-panel.dtsi
is currently unused. As overlay support for this panel has only been
tested with Gen3 hardware, and Gen2 support will require more
development, move the file to arch/arm64/boot/dts/renesas/.

Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
---
 .../arm/boot/dts/r8a77xx-aa104xd12-panel.dtsi | 39 -------------------
 .../boot/dts/renesas/panel-aa104xd12.dtsi     | 30 ++++++++++++++
 2 files changed, 30 insertions(+), 39 deletions(-)
 delete mode 100644 arch/arm/boot/dts/r8a77xx-aa104xd12-panel.dtsi
 create mode 100644 arch/arm64/boot/dts/renesas/panel-aa104xd12.dtsi

Comments

Geert Uytterhoeven Jan. 26, 2022, 12:18 p.m. UTC | #1
Hi Laurent,

On Wed, Dec 29, 2021 at 8:31 PM Laurent Pinchart
<laurent.pinchart+renesas@ideasonboard.com> wrote:
> The Mitsubishi AA1024XD12 panel can be used for R-Car Gen2 and Gen3
> boards as an optional external panel. It is described in the
> arm/boot/dts/r8a77xx-aa104xd12-panel.dtsi file as a direct child of the
> DT root node. This allows including r8a77xx-aa104xd12-panel.dtsi in
> board device trees, with other minor modifications, to enable the panel.
>
> This is however not how external components should be modelled. Instead
> of modifying the board device tree to enable the panel, it should be
> compiled as a DT overlay, to be loaded by the boot loader.
>
> Prepare the r8a77xx-aa104xd12-panel.dtsi file for this usage by
> declaring a panel node only, without hardcoding its path. Overlay
> sources can then include r8a77xx-aa104xd12-panel.dtsi where appropriate.
>
> This change doesn't cause any regression as r8a77xx-aa104xd12-panel.dtsi
> is currently unused. As overlay support for this panel has only been
> tested with Gen3 hardware, and Gen2 support will require more
> development, move the file to arch/arm64/boot/dts/renesas/.
>
> Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>

Thanks for your patch!

> --- a/arch/arm/boot/dts/r8a77xx-aa104xd12-panel.dtsi

> - * Copyright (C) 2014 Renesas Electronics Corp.

> +++ b/arch/arm64/boot/dts/renesas/panel-aa104xd12.dtsi

> + * Copyright (C) 2021 Renesas Electronics Corp.

Shouldn't you keep the year? Not much has changed.

Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be>

Gr{oetje,eeting}s,

                        Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds
Laurent Pinchart Jan. 26, 2022, 6:58 p.m. UTC | #2
Hi Geert,

On Wed, Jan 26, 2022 at 01:18:56PM +0100, Geert Uytterhoeven wrote:
> On Wed, Dec 29, 2021 at 8:31 PM Laurent Pinchart wrote:
> > The Mitsubishi AA1024XD12 panel can be used for R-Car Gen2 and Gen3
> > boards as an optional external panel. It is described in the
> > arm/boot/dts/r8a77xx-aa104xd12-panel.dtsi file as a direct child of the
> > DT root node. This allows including r8a77xx-aa104xd12-panel.dtsi in
> > board device trees, with other minor modifications, to enable the panel.
> >
> > This is however not how external components should be modelled. Instead
> > of modifying the board device tree to enable the panel, it should be
> > compiled as a DT overlay, to be loaded by the boot loader.
> >
> > Prepare the r8a77xx-aa104xd12-panel.dtsi file for this usage by
> > declaring a panel node only, without hardcoding its path. Overlay
> > sources can then include r8a77xx-aa104xd12-panel.dtsi where appropriate.
> >
> > This change doesn't cause any regression as r8a77xx-aa104xd12-panel.dtsi
> > is currently unused. As overlay support for this panel has only been
> > tested with Gen3 hardware, and Gen2 support will require more
> > development, move the file to arch/arm64/boot/dts/renesas/.
> >
> > Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
> 
> Thanks for your patch!
> 
> > --- a/arch/arm/boot/dts/r8a77xx-aa104xd12-panel.dtsi
> 
> > - * Copyright (C) 2014 Renesas Electronics Corp.
> 
> > +++ b/arch/arm64/boot/dts/renesas/panel-aa104xd12.dtsi
> 
> > + * Copyright (C) 2021 Renesas Electronics Corp.
> 
> Shouldn't you keep the year? Not much has changed.

Indeed.

> Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be>

I see you've reviewed the whole series. Can you pick it up ?
Geert Uytterhoeven Jan. 26, 2022, 7:15 p.m. UTC | #3
Hi Laurent,

On Wed, Jan 26, 2022 at 7:58 PM Laurent Pinchart
<laurent.pinchart@ideasonboard.com> wrote:
> On Wed, Jan 26, 2022 at 01:18:56PM +0100, Geert Uytterhoeven wrote:
> > On Wed, Dec 29, 2021 at 8:31 PM Laurent Pinchart wrote:
> > > The Mitsubishi AA1024XD12 panel can be used for R-Car Gen2 and Gen3
> > > boards as an optional external panel. It is described in the
> > > arm/boot/dts/r8a77xx-aa104xd12-panel.dtsi file as a direct child of the
> > > DT root node. This allows including r8a77xx-aa104xd12-panel.dtsi in
> > > board device trees, with other minor modifications, to enable the panel.
> > >
> > > This is however not how external components should be modelled. Instead
> > > of modifying the board device tree to enable the panel, it should be
> > > compiled as a DT overlay, to be loaded by the boot loader.
> > >
> > > Prepare the r8a77xx-aa104xd12-panel.dtsi file for this usage by
> > > declaring a panel node only, without hardcoding its path. Overlay
> > > sources can then include r8a77xx-aa104xd12-panel.dtsi where appropriate.
> > >
> > > This change doesn't cause any regression as r8a77xx-aa104xd12-panel.dtsi
> > > is currently unused. As overlay support for this panel has only been
> > > tested with Gen3 hardware, and Gen2 support will require more
> > > development, move the file to arch/arm64/boot/dts/renesas/.
> > >
> > > Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>

> I see you've reviewed the whole series. Can you pick it up ?

I believe it depends on the removal of the empty endpoints, for which
we're waiting for feedback from Rob, IIRC?

Gr{oetje,eeting}s,

                        Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds
Laurent Pinchart Jan. 26, 2022, 11:57 p.m. UTC | #4
Hi Geert,

On Wed, Jan 26, 2022 at 08:15:26PM +0100, Geert Uytterhoeven wrote:
> On Wed, Jan 26, 2022 at 7:58 PM Laurent Pinchart wrote:
> > On Wed, Jan 26, 2022 at 01:18:56PM +0100, Geert Uytterhoeven wrote:
> > > On Wed, Dec 29, 2021 at 8:31 PM Laurent Pinchart wrote:
> > > > The Mitsubishi AA1024XD12 panel can be used for R-Car Gen2 and Gen3
> > > > boards as an optional external panel. It is described in the
> > > > arm/boot/dts/r8a77xx-aa104xd12-panel.dtsi file as a direct child of the
> > > > DT root node. This allows including r8a77xx-aa104xd12-panel.dtsi in
> > > > board device trees, with other minor modifications, to enable the panel.
> > > >
> > > > This is however not how external components should be modelled. Instead
> > > > of modifying the board device tree to enable the panel, it should be
> > > > compiled as a DT overlay, to be loaded by the boot loader.
> > > >
> > > > Prepare the r8a77xx-aa104xd12-panel.dtsi file for this usage by
> > > > declaring a panel node only, without hardcoding its path. Overlay
> > > > sources can then include r8a77xx-aa104xd12-panel.dtsi where appropriate.
> > > >
> > > > This change doesn't cause any regression as r8a77xx-aa104xd12-panel.dtsi
> > > > is currently unused. As overlay support for this panel has only been
> > > > tested with Gen3 hardware, and Gen2 support will require more
> > > > development, move the file to arch/arm64/boot/dts/renesas/.
> > > >
> > > > Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
> 
> > I see you've reviewed the whole series. Can you pick it up ?
> 
> I believe it depends on the removal of the empty endpoints, for which
> we're waiting for feedback from Rob, IIRC?

You're right. Let's wait some more time then.
diff mbox series

Patch

diff --git a/arch/arm/boot/dts/r8a77xx-aa104xd12-panel.dtsi b/arch/arm/boot/dts/r8a77xx-aa104xd12-panel.dtsi
deleted file mode 100644
index 79fce67ebb1c..000000000000
--- a/arch/arm/boot/dts/r8a77xx-aa104xd12-panel.dtsi
+++ /dev/null
@@ -1,39 +0,0 @@ 
-// SPDX-License-Identifier: GPL-2.0
-/*
- * Common file for the AA104XD12 panel connected to Renesas R-Car boards
- *
- * Copyright (C) 2014 Renesas Electronics Corp.
- */
-
-/ {
-	panel {
-		compatible = "mitsubishi,aa104xd12", "panel-lvds";
-
-		width-mm = <210>;
-		height-mm = <158>;
-		data-mapping = "jeida-18";
-
-		panel-timing {
-			/* 1024x768 @65Hz */
-			clock-frequency = <65000000>;
-			hactive = <1024>;
-			vactive = <768>;
-			hsync-len = <136>;
-			hfront-porch = <20>;
-			hback-porch = <160>;
-			vfront-porch = <3>;
-			vback-porch = <29>;
-			vsync-len = <6>;
-		};
-
-		port {
-			panel_in: endpoint {
-				remote-endpoint = <&lvds_connector>;
-			};
-		};
-	};
-};
-
-&lvds_connector {
-	remote-endpoint = <&panel_in>;
-};
diff --git a/arch/arm64/boot/dts/renesas/panel-aa104xd12.dtsi b/arch/arm64/boot/dts/renesas/panel-aa104xd12.dtsi
new file mode 100644
index 000000000000..6e9f447d8fe1
--- /dev/null
+++ b/arch/arm64/boot/dts/renesas/panel-aa104xd12.dtsi
@@ -0,0 +1,30 @@ 
+// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
+/*
+ * Common file for the AA104XD12 panel connected to Renesas R-Car Gen3 boards.
+ *
+ * Copyright (C) 2021 Renesas Electronics Corp.
+ */
+
+panel {
+	compatible = "mitsubishi,aa104xd12", "panel-lvds";
+
+	width-mm = <210>;
+	height-mm = <158>;
+	data-mapping = "jeida-18";
+
+	panel-timing {
+		/* 1024x768 @65Hz */
+		clock-frequency = <65000000>;
+		hactive = <1024>;
+		vactive = <768>;
+		hsync-len = <136>;
+		hfront-porch = <20>;
+		hback-porch = <160>;
+		vfront-porch = <3>;
+		vback-porch = <29>;
+		vsync-len = <6>;
+	};
+
+	port {
+	};
+};