dri-devel.lists.freedesktop.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v5 0/7] drm: Add DSI/DP support for Renesas r8a779h0 V4M and grey-hawk board
@ 2024-12-17  5:31 Tomi Valkeinen
  2024-12-17  5:31 ` [PATCH v5 1/7] drm/rcar-du: dsi: Fix PHY lock bit check Tomi Valkeinen
                   ` (7 more replies)
  0 siblings, 8 replies; 21+ messages in thread
From: Tomi Valkeinen @ 2024-12-17  5:31 UTC (permalink / raw)
  To: Laurent Pinchart, Kieran Bingham, Andrzej Hajda, Neil Armstrong,
	Robert Foss, Jonas Karlman, Jernej Skrabec, David Airlie,
	Simona Vetter, Maarten Lankhorst, Maxime Ripard,
	Thomas Zimmermann, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
	Geert Uytterhoeven, Magnus Damm, Michael Turquette, Stephen Boyd,
	LUU HOAI, Jagan Teki, Sam Ravnborg, Biju Das
  Cc: Laurent Pinchart, dri-devel, linux-renesas-soc, devicetree,
	linux-kernel, Laurent Pinchart, linux-clk, Tomi Valkeinen, stable,
	Krzysztof Kozlowski

Add everything needed to support the DSI output on Renesas r8a779h0
(V4M) SoC, and the DP output (via sn65dsi86 DSI to DP bridge) on the
Renesas grey-hawk board.

Overall the DSI and the board design is almost identical to Renesas
r8a779g0 and white-hawk board.

Note: the v4 no longer has the dts and the clk patches, as those have
been merged to renesas-devel.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen+renesas@ideasonboard.com>
---
Changes in v5:
- Add minItems/maxItems to the top level cmms & vsps properties
- Drop "minItems: 1" when not needed
- Link to v4: https://lore.kernel.org/r/20241213-rcar-gh-dsi-v4-0-f8e41425207b@ideasonboard.com

Changes in v4:
- Dropped patches merged to renesas-devel
- Added new patch "dt-bindings: display: renesas,du: Add missing
  maxItems" to fix the bindings
- Add the missing maxItems to "dt-bindings: display: renesas,du: Add
  r8a779h0"
- Link to v3: https://lore.kernel.org/r/20241206-rcar-gh-dsi-v3-0-d74c2166fa15@ideasonboard.com

Changes in v3:
- Update "Write DPTSR only if there are more than one crtc" patch to
  "Write DPTSR only if the second source exists"
- Add Laurent's Rb
- Link to v2: https://lore.kernel.org/r/20241205-rcar-gh-dsi-v2-0-42471851df86@ideasonboard.com

Changes in v2:
- Add the DT binding with a new conditional block, so that we can set
  only the port@0 as required
- Drop port@1 from r8a779h0.dtsi (there's no port@1)
- Add a new patch to write DPTSR only if num_crtcs > 1
- Drop RCAR_DU_FEATURE_NO_DPTSR (not needed anymore)
- Add Cc: stable to the fix, and move it as first patch
- Added the tags from reviews
- Link to v1: https://lore.kernel.org/r/20241203-rcar-gh-dsi-v1-0-738ae1a95d2a@ideasonboard.com

---
Tomi Valkeinen (7):
      drm/rcar-du: dsi: Fix PHY lock bit check
      drm/rcar-du: Write DPTSR only if the second source exists
      dt-bindings: display: renesas,du: Add missing constraints
      dt-bindings: display: renesas,du: Add r8a779h0
      dt-bindings: display: bridge: renesas,dsi-csi2-tx: Add r8a779h0
      drm/rcar-du: dsi: Add r8a779h0 support
      drm/rcar-du: Add support for r8a779h0

 .../display/bridge/renesas,dsi-csi2-tx.yaml        |  1 +
 .../devicetree/bindings/display/renesas,du.yaml    | 67 ++++++++++++++++++++--
 drivers/gpu/drm/renesas/rcar-du/rcar_du_drv.c      | 18 ++++++
 drivers/gpu/drm/renesas/rcar-du/rcar_du_group.c    | 24 ++++++--
 drivers/gpu/drm/renesas/rcar-du/rcar_mipi_dsi.c    |  4 +-
 .../gpu/drm/renesas/rcar-du/rcar_mipi_dsi_regs.h   |  1 -
 6 files changed, 102 insertions(+), 13 deletions(-)
---
base-commit: adc218676eef25575469234709c2d87185ca223a
change-id: 20241008-rcar-gh-dsi-9c01f5deeac8

Best regards,
-- 
Tomi Valkeinen <tomi.valkeinen@ideasonboard.com>


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

* [PATCH v5 1/7] drm/rcar-du: dsi: Fix PHY lock bit check
  2024-12-17  5:31 [PATCH v5 0/7] drm: Add DSI/DP support for Renesas r8a779h0 V4M and grey-hawk board Tomi Valkeinen
@ 2024-12-17  5:31 ` Tomi Valkeinen
  2024-12-17  5:31 ` [PATCH v5 2/7] drm/rcar-du: Write DPTSR only if the second source exists Tomi Valkeinen
                   ` (6 subsequent siblings)
  7 siblings, 0 replies; 21+ messages in thread
From: Tomi Valkeinen @ 2024-12-17  5:31 UTC (permalink / raw)
  To: Laurent Pinchart, Kieran Bingham, Andrzej Hajda, Neil Armstrong,
	Robert Foss, Jonas Karlman, Jernej Skrabec, David Airlie,
	Simona Vetter, Maarten Lankhorst, Maxime Ripard,
	Thomas Zimmermann, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
	Geert Uytterhoeven, Magnus Damm, Michael Turquette, Stephen Boyd,
	LUU HOAI, Jagan Teki, Sam Ravnborg, Biju Das
  Cc: Laurent Pinchart, dri-devel, linux-renesas-soc, devicetree,
	linux-kernel, Laurent Pinchart, linux-clk, Tomi Valkeinen, stable

From: Tomi Valkeinen <tomi.valkeinen+renesas@ideasonboard.com>

The driver checks for bit 16 (using CLOCKSET1_LOCK define) in CLOCKSET1
register when waiting for the PPI clock. However, the right bit to check
is bit 17 (CLOCKSET1_LOCK_PHY define). Not only that, but there's
nothing in the documents for bit 16 for V3U nor V4H.

So, fix the check to use bit 17, and drop the define for bit 16.

Fixes: 155358310f01 ("drm: rcar-du: Add R-Car DSI driver")
Fixes: 11696c5e8924 ("drm: Place Renesas drivers in a separate dir")
Cc: stable@vger.kernel.org
Signed-off-by: Tomi Valkeinen <tomi.valkeinen+renesas@ideasonboard.com>
Reviewed-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Tested-by: Geert Uytterhoeven <geert+renesas@glider.be>
---
 drivers/gpu/drm/renesas/rcar-du/rcar_mipi_dsi.c      | 2 +-
 drivers/gpu/drm/renesas/rcar-du/rcar_mipi_dsi_regs.h | 1 -
 2 files changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/gpu/drm/renesas/rcar-du/rcar_mipi_dsi.c b/drivers/gpu/drm/renesas/rcar-du/rcar_mipi_dsi.c
index 2dba7c5ffd2c..92f4261305bd 100644
--- a/drivers/gpu/drm/renesas/rcar-du/rcar_mipi_dsi.c
+++ b/drivers/gpu/drm/renesas/rcar-du/rcar_mipi_dsi.c
@@ -587,7 +587,7 @@ static int rcar_mipi_dsi_startup(struct rcar_mipi_dsi *dsi,
 	for (timeout = 10; timeout > 0; --timeout) {
 		if ((rcar_mipi_dsi_read(dsi, PPICLSR) & PPICLSR_STPST) &&
 		    (rcar_mipi_dsi_read(dsi, PPIDLSR) & PPIDLSR_STPST) &&
-		    (rcar_mipi_dsi_read(dsi, CLOCKSET1) & CLOCKSET1_LOCK))
+		    (rcar_mipi_dsi_read(dsi, CLOCKSET1) & CLOCKSET1_LOCK_PHY))
 			break;
 
 		usleep_range(1000, 2000);
diff --git a/drivers/gpu/drm/renesas/rcar-du/rcar_mipi_dsi_regs.h b/drivers/gpu/drm/renesas/rcar-du/rcar_mipi_dsi_regs.h
index f8114d11f2d1..a6b276f1d6ee 100644
--- a/drivers/gpu/drm/renesas/rcar-du/rcar_mipi_dsi_regs.h
+++ b/drivers/gpu/drm/renesas/rcar-du/rcar_mipi_dsi_regs.h
@@ -142,7 +142,6 @@
 
 #define CLOCKSET1			0x101c
 #define CLOCKSET1_LOCK_PHY		(1 << 17)
-#define CLOCKSET1_LOCK			(1 << 16)
 #define CLOCKSET1_CLKSEL		(1 << 8)
 #define CLOCKSET1_CLKINSEL_EXTAL	(0 << 2)
 #define CLOCKSET1_CLKINSEL_DIG		(1 << 2)

-- 
2.43.0


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

* [PATCH v5 2/7] drm/rcar-du: Write DPTSR only if the second source exists
  2024-12-17  5:31 [PATCH v5 0/7] drm: Add DSI/DP support for Renesas r8a779h0 V4M and grey-hawk board Tomi Valkeinen
  2024-12-17  5:31 ` [PATCH v5 1/7] drm/rcar-du: dsi: Fix PHY lock bit check Tomi Valkeinen
@ 2024-12-17  5:31 ` Tomi Valkeinen
  2024-12-17  5:31 ` [PATCH v5 3/7] dt-bindings: display: renesas,du: Add missing constraints Tomi Valkeinen
                   ` (5 subsequent siblings)
  7 siblings, 0 replies; 21+ messages in thread
From: Tomi Valkeinen @ 2024-12-17  5:31 UTC (permalink / raw)
  To: Laurent Pinchart, Kieran Bingham, Andrzej Hajda, Neil Armstrong,
	Robert Foss, Jonas Karlman, Jernej Skrabec, David Airlie,
	Simona Vetter, Maarten Lankhorst, Maxime Ripard,
	Thomas Zimmermann, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
	Geert Uytterhoeven, Magnus Damm, Michael Turquette, Stephen Boyd,
	LUU HOAI, Jagan Teki, Sam Ravnborg, Biju Das
  Cc: Laurent Pinchart, dri-devel, linux-renesas-soc, devicetree,
	linux-kernel, Laurent Pinchart, linux-clk, Tomi Valkeinen

From: Tomi Valkeinen <tomi.valkeinen+renesas@ideasonboard.com>

Currently the driver always writes DPTSR when setting up the hardware.
However, writing the register is only meaningful when the second source
for a plane is used, and the register is not even documented for SoCs
that do not have the second source.

So move the write behind a condition.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen+renesas@ideasonboard.com>
Reviewed-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Tested-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> # On R-Car M3-N
---
 drivers/gpu/drm/renesas/rcar-du/rcar_du_group.c | 20 +++++++++++++++-----
 1 file changed, 15 insertions(+), 5 deletions(-)

diff --git a/drivers/gpu/drm/renesas/rcar-du/rcar_du_group.c b/drivers/gpu/drm/renesas/rcar-du/rcar_du_group.c
index 2ccd2581f544..1ec806c8e013 100644
--- a/drivers/gpu/drm/renesas/rcar-du/rcar_du_group.c
+++ b/drivers/gpu/drm/renesas/rcar-du/rcar_du_group.c
@@ -185,11 +185,21 @@ static void rcar_du_group_setup(struct rcar_du_group *rgrp)
 		dorcr |= DORCR_PG1T | DORCR_DK1S | DORCR_PG1D_DS1;
 	rcar_du_group_write(rgrp, DORCR, dorcr);
 
-	/* Apply planes to CRTCs association. */
-	mutex_lock(&rgrp->lock);
-	rcar_du_group_write(rgrp, DPTSR, (rgrp->dptsr_planes << 16) |
-			    rgrp->dptsr_planes);
-	mutex_unlock(&rgrp->lock);
+	/*
+	 * DPTSR is used to select the source for the planes of a group. The
+	 * first source is chosen by writing 0 to the respective bits, and this
+	 * is always the default value of the register. In other words, writing
+	 * DPTSR is only needed if the SoC supports choosing the second source.
+	 *
+	 * The SoCs documentations seems to confirm this, as the DPTSR register
+	 * is not documented if only the first source exists on that SoC.
+	 */
+	if (rgrp->channels_mask & BIT(1)) {
+		mutex_lock(&rgrp->lock);
+		rcar_du_group_write(rgrp, DPTSR, (rgrp->dptsr_planes << 16) |
+				    rgrp->dptsr_planes);
+		mutex_unlock(&rgrp->lock);
+	}
 }
 
 /*

-- 
2.43.0


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

* [PATCH v5 3/7] dt-bindings: display: renesas,du: Add missing constraints
  2024-12-17  5:31 [PATCH v5 0/7] drm: Add DSI/DP support for Renesas r8a779h0 V4M and grey-hawk board Tomi Valkeinen
  2024-12-17  5:31 ` [PATCH v5 1/7] drm/rcar-du: dsi: Fix PHY lock bit check Tomi Valkeinen
  2024-12-17  5:31 ` [PATCH v5 2/7] drm/rcar-du: Write DPTSR only if the second source exists Tomi Valkeinen
@ 2024-12-17  5:31 ` Tomi Valkeinen
  2024-12-17  6:25   ` Krzysztof Kozlowski
                     ` (2 more replies)
  2024-12-17  5:31 ` [PATCH v5 4/7] dt-bindings: display: renesas,du: Add r8a779h0 Tomi Valkeinen
                   ` (4 subsequent siblings)
  7 siblings, 3 replies; 21+ messages in thread
From: Tomi Valkeinen @ 2024-12-17  5:31 UTC (permalink / raw)
  To: Laurent Pinchart, Kieran Bingham, Andrzej Hajda, Neil Armstrong,
	Robert Foss, Jonas Karlman, Jernej Skrabec, David Airlie,
	Simona Vetter, Maarten Lankhorst, Maxime Ripard,
	Thomas Zimmermann, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
	Geert Uytterhoeven, Magnus Damm, Michael Turquette, Stephen Boyd,
	LUU HOAI, Jagan Teki, Sam Ravnborg, Biju Das
  Cc: Laurent Pinchart, dri-devel, linux-renesas-soc, devicetree,
	linux-kernel, Laurent Pinchart, linux-clk, Tomi Valkeinen

From: Tomi Valkeinen <tomi.valkeinen+renesas@ideasonboard.com>

The binding is missing maxItems for all renesas,cmms and renesas,vsps
properties. As the amount of cmms or vsps is always a fixed amount, set
the maxItems to match the minItems.

Also add the minItems and maxItems to the top level properties.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen+renesas@ideasonboard.com>
---
 Documentation/devicetree/bindings/display/renesas,du.yaml | 15 ++++++++++++++-
 1 file changed, 14 insertions(+), 1 deletion(-)

diff --git a/Documentation/devicetree/bindings/display/renesas,du.yaml b/Documentation/devicetree/bindings/display/renesas,du.yaml
index c5b9e6812bce..ef4568118e94 100644
--- a/Documentation/devicetree/bindings/display/renesas,du.yaml
+++ b/Documentation/devicetree/bindings/display/renesas,du.yaml
@@ -77,6 +77,8 @@ properties:
 
   renesas,cmms:
     $ref: /schemas/types.yaml#/definitions/phandle-array
+    minItems: 1
+    maxItems: 4
     items:
       maxItems: 1
     description:
@@ -85,6 +87,8 @@ properties:
 
   renesas,vsps:
     $ref: /schemas/types.yaml#/definitions/phandle-array
+    minItems: 1
+    maxItems: 4
     items:
       items:
         - description: phandle to VSP instance that serves the DU channel
@@ -489,9 +493,11 @@ allOf:
 
         renesas,cmms:
           minItems: 4
+          maxItems: 4
 
         renesas,vsps:
           minItems: 4
+          maxItems: 4
 
       required:
         - clock-names
@@ -558,9 +564,11 @@ allOf:
 
         renesas,cmms:
           minItems: 3
+          maxItems: 3
 
         renesas,vsps:
           minItems: 3
+          maxItems: 3
 
       required:
         - clock-names
@@ -627,9 +635,11 @@ allOf:
 
         renesas,cmms:
           minItems: 3
+          maxItems: 3
 
         renesas,vsps:
           minItems: 3
+          maxItems: 3
 
       required:
         - clock-names
@@ -683,7 +693,7 @@ allOf:
             - port@1
 
         renesas,vsps:
-          minItems: 1
+          maxItems: 1
 
       required:
         - clock-names
@@ -746,9 +756,11 @@ allOf:
 
         renesas,cmms:
           minItems: 2
+          maxItems: 2
 
         renesas,vsps:
           minItems: 2
+          maxItems: 2
 
       required:
         - clock-names
@@ -799,6 +811,7 @@ allOf:
 
         renesas,vsps:
           minItems: 2
+          maxItems: 2
 
       required:
         - clock-names

-- 
2.43.0


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

* [PATCH v5 4/7] dt-bindings: display: renesas,du: Add r8a779h0
  2024-12-17  5:31 [PATCH v5 0/7] drm: Add DSI/DP support for Renesas r8a779h0 V4M and grey-hawk board Tomi Valkeinen
                   ` (2 preceding siblings ...)
  2024-12-17  5:31 ` [PATCH v5 3/7] dt-bindings: display: renesas,du: Add missing constraints Tomi Valkeinen
@ 2024-12-17  5:31 ` Tomi Valkeinen
  2024-12-17  6:28   ` Krzysztof Kozlowski
  2024-12-17  5:31 ` [PATCH v5 5/7] dt-bindings: display: bridge: renesas,dsi-csi2-tx: " Tomi Valkeinen
                   ` (3 subsequent siblings)
  7 siblings, 1 reply; 21+ messages in thread
From: Tomi Valkeinen @ 2024-12-17  5:31 UTC (permalink / raw)
  To: Laurent Pinchart, Kieran Bingham, Andrzej Hajda, Neil Armstrong,
	Robert Foss, Jonas Karlman, Jernej Skrabec, David Airlie,
	Simona Vetter, Maarten Lankhorst, Maxime Ripard,
	Thomas Zimmermann, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
	Geert Uytterhoeven, Magnus Damm, Michael Turquette, Stephen Boyd,
	LUU HOAI, Jagan Teki, Sam Ravnborg, Biju Das
  Cc: Laurent Pinchart, dri-devel, linux-renesas-soc, devicetree,
	linux-kernel, Laurent Pinchart, linux-clk, Tomi Valkeinen

From: Tomi Valkeinen <tomi.valkeinen+renesas@ideasonboard.com>

Extend the Renesas DU display bindings to support the r8a779h0 V4M.

Note that we remove the requirement for two ports from the global part
of the bindings, as each conditional part defines the number of required
ports already. This came up with r8a779h0 as it's the first one that has
only one port.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen+renesas@ideasonboard.com>
Reviewed-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Tested-by: Geert Uytterhoeven <geert+renesas@glider.be>
---
 .../devicetree/bindings/display/renesas,du.yaml    | 52 ++++++++++++++++++++--
 1 file changed, 48 insertions(+), 4 deletions(-)

diff --git a/Documentation/devicetree/bindings/display/renesas,du.yaml b/Documentation/devicetree/bindings/display/renesas,du.yaml
index ef4568118e94..3880b4c2ea9a 100644
--- a/Documentation/devicetree/bindings/display/renesas,du.yaml
+++ b/Documentation/devicetree/bindings/display/renesas,du.yaml
@@ -41,6 +41,7 @@ properties:
       - renesas,du-r8a77995 # for R-Car D3 compatible DU
       - renesas,du-r8a779a0 # for R-Car V3U compatible DU
       - renesas,du-r8a779g0 # for R-Car V4H compatible DU
+      - renesas,du-r8a779h0 # for R-Car V4M compatible DU
 
   reg:
     maxItems: 1
@@ -69,10 +70,6 @@ properties:
         $ref: /schemas/graph.yaml#/properties/port
         unevaluatedProperties: false
 
-    required:
-      - port@0
-      - port@1
-
     unevaluatedProperties: false
 
   renesas,cmms:
@@ -820,6 +817,53 @@ allOf:
         - reset-names
         - renesas,vsps
 
+  - if:
+      properties:
+        compatible:
+          contains:
+            enum:
+              - renesas,du-r8a779h0
+    then:
+      properties:
+        clocks:
+          items:
+            - description: Functional clock
+
+        clock-names:
+          items:
+            - const: du.0
+
+        interrupts:
+          maxItems: 1
+
+        resets:
+          maxItems: 1
+
+        reset-names:
+          items:
+            - const: du.0
+
+        ports:
+          properties:
+            port@0:
+              description: DSI 0
+            port@1: false
+            port@2: false
+            port@3: false
+
+          required:
+            - port@0
+
+        renesas,vsps:
+          maxItems: 1
+
+      required:
+        - clock-names
+        - interrupts
+        - resets
+        - reset-names
+        - renesas,vsps
+
 additionalProperties: false
 
 examples:

-- 
2.43.0


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

* [PATCH v5 5/7] dt-bindings: display: bridge: renesas,dsi-csi2-tx: Add r8a779h0
  2024-12-17  5:31 [PATCH v5 0/7] drm: Add DSI/DP support for Renesas r8a779h0 V4M and grey-hawk board Tomi Valkeinen
                   ` (3 preceding siblings ...)
  2024-12-17  5:31 ` [PATCH v5 4/7] dt-bindings: display: renesas,du: Add r8a779h0 Tomi Valkeinen
@ 2024-12-17  5:31 ` Tomi Valkeinen
  2024-12-17  5:31 ` [PATCH v5 6/7] drm/rcar-du: dsi: Add r8a779h0 support Tomi Valkeinen
                   ` (2 subsequent siblings)
  7 siblings, 0 replies; 21+ messages in thread
From: Tomi Valkeinen @ 2024-12-17  5:31 UTC (permalink / raw)
  To: Laurent Pinchart, Kieran Bingham, Andrzej Hajda, Neil Armstrong,
	Robert Foss, Jonas Karlman, Jernej Skrabec, David Airlie,
	Simona Vetter, Maarten Lankhorst, Maxime Ripard,
	Thomas Zimmermann, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
	Geert Uytterhoeven, Magnus Damm, Michael Turquette, Stephen Boyd,
	LUU HOAI, Jagan Teki, Sam Ravnborg, Biju Das
  Cc: Laurent Pinchart, dri-devel, linux-renesas-soc, devicetree,
	linux-kernel, Laurent Pinchart, linux-clk, Tomi Valkeinen,
	Krzysztof Kozlowski

From: Tomi Valkeinen <tomi.valkeinen+renesas@ideasonboard.com>

Extend the Renesas DSI display bindings to support the r8a779h0 V4M.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen+renesas@ideasonboard.com>
Reviewed-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Acked-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Tested-by: Geert Uytterhoeven <geert+renesas@glider.be>
---
 .../devicetree/bindings/display/bridge/renesas,dsi-csi2-tx.yaml          | 1 +
 1 file changed, 1 insertion(+)

diff --git a/Documentation/devicetree/bindings/display/bridge/renesas,dsi-csi2-tx.yaml b/Documentation/devicetree/bindings/display/bridge/renesas,dsi-csi2-tx.yaml
index d33026f85e19..c167795c63f6 100644
--- a/Documentation/devicetree/bindings/display/bridge/renesas,dsi-csi2-tx.yaml
+++ b/Documentation/devicetree/bindings/display/bridge/renesas,dsi-csi2-tx.yaml
@@ -19,6 +19,7 @@ properties:
     enum:
       - renesas,r8a779a0-dsi-csi2-tx    # for V3U
       - renesas,r8a779g0-dsi-csi2-tx    # for V4H
+      - renesas,r8a779h0-dsi-csi2-tx    # for V4M
 
   reg:
     maxItems: 1

-- 
2.43.0


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

* [PATCH v5 6/7] drm/rcar-du: dsi: Add r8a779h0 support
  2024-12-17  5:31 [PATCH v5 0/7] drm: Add DSI/DP support for Renesas r8a779h0 V4M and grey-hawk board Tomi Valkeinen
                   ` (4 preceding siblings ...)
  2024-12-17  5:31 ` [PATCH v5 5/7] dt-bindings: display: bridge: renesas,dsi-csi2-tx: " Tomi Valkeinen
@ 2024-12-17  5:31 ` Tomi Valkeinen
  2024-12-17  5:31 ` [PATCH v5 7/7] drm/rcar-du: Add support for r8a779h0 Tomi Valkeinen
  2024-12-17 13:33 ` [PATCH v5 0/7] drm: Add DSI/DP support for Renesas r8a779h0 V4M and grey-hawk board Tomi Valkeinen
  7 siblings, 0 replies; 21+ messages in thread
From: Tomi Valkeinen @ 2024-12-17  5:31 UTC (permalink / raw)
  To: Laurent Pinchart, Kieran Bingham, Andrzej Hajda, Neil Armstrong,
	Robert Foss, Jonas Karlman, Jernej Skrabec, David Airlie,
	Simona Vetter, Maarten Lankhorst, Maxime Ripard,
	Thomas Zimmermann, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
	Geert Uytterhoeven, Magnus Damm, Michael Turquette, Stephen Boyd,
	LUU HOAI, Jagan Teki, Sam Ravnborg, Biju Das
  Cc: Laurent Pinchart, dri-devel, linux-renesas-soc, devicetree,
	linux-kernel, Laurent Pinchart, linux-clk, Tomi Valkeinen

From: Tomi Valkeinen <tomi.valkeinen+renesas@ideasonboard.com>

Add support for DSI on r8a779h0. As it is identical to DSI on r8a779g0,
all we need is to handle the compatible string.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen+renesas@ideasonboard.com>
Reviewed-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Tested-by: Geert Uytterhoeven <geert+renesas@glider.be>
---
 drivers/gpu/drm/renesas/rcar-du/rcar_mipi_dsi.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/gpu/drm/renesas/rcar-du/rcar_mipi_dsi.c b/drivers/gpu/drm/renesas/rcar-du/rcar_mipi_dsi.c
index 92f4261305bd..36e902601f84 100644
--- a/drivers/gpu/drm/renesas/rcar-du/rcar_mipi_dsi.c
+++ b/drivers/gpu/drm/renesas/rcar-du/rcar_mipi_dsi.c
@@ -1081,6 +1081,8 @@ static const struct rcar_mipi_dsi_device_info v4h_data = {
 static const struct of_device_id rcar_mipi_dsi_of_table[] = {
 	{ .compatible = "renesas,r8a779a0-dsi-csi2-tx", .data = &v3u_data },
 	{ .compatible = "renesas,r8a779g0-dsi-csi2-tx", .data = &v4h_data },
+	/* DSI in r8a779h0 is identical to r8a779g0 */
+	{ .compatible = "renesas,r8a779h0-dsi-csi2-tx", .data = &v4h_data },
 	{ }
 };
 

-- 
2.43.0


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

* [PATCH v5 7/7] drm/rcar-du: Add support for r8a779h0
  2024-12-17  5:31 [PATCH v5 0/7] drm: Add DSI/DP support for Renesas r8a779h0 V4M and grey-hawk board Tomi Valkeinen
                   ` (5 preceding siblings ...)
  2024-12-17  5:31 ` [PATCH v5 6/7] drm/rcar-du: dsi: Add r8a779h0 support Tomi Valkeinen
@ 2024-12-17  5:31 ` Tomi Valkeinen
  2024-12-17 13:33 ` [PATCH v5 0/7] drm: Add DSI/DP support for Renesas r8a779h0 V4M and grey-hawk board Tomi Valkeinen
  7 siblings, 0 replies; 21+ messages in thread
From: Tomi Valkeinen @ 2024-12-17  5:31 UTC (permalink / raw)
  To: Laurent Pinchart, Kieran Bingham, Andrzej Hajda, Neil Armstrong,
	Robert Foss, Jonas Karlman, Jernej Skrabec, David Airlie,
	Simona Vetter, Maarten Lankhorst, Maxime Ripard,
	Thomas Zimmermann, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
	Geert Uytterhoeven, Magnus Damm, Michael Turquette, Stephen Boyd,
	LUU HOAI, Jagan Teki, Sam Ravnborg, Biju Das
  Cc: Laurent Pinchart, dri-devel, linux-renesas-soc, devicetree,
	linux-kernel, Laurent Pinchart, linux-clk, Tomi Valkeinen

From: Tomi Valkeinen <tomi.valkeinen+renesas@ideasonboard.com>

Add support for r8a779h0. It is very similar to r8a779g0, but has only
one output.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen+renesas@ideasonboard.com>
Tested-by: Geert Uytterhoeven <geert+renesas@glider.be>
Reviewed-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
---
 drivers/gpu/drm/renesas/rcar-du/rcar_du_drv.c   | 18 ++++++++++++++++++
 drivers/gpu/drm/renesas/rcar-du/rcar_du_group.c |  4 +++-
 2 files changed, 21 insertions(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/renesas/rcar-du/rcar_du_drv.c b/drivers/gpu/drm/renesas/rcar-du/rcar_du_drv.c
index fb719d9aff10..7858e10839f2 100644
--- a/drivers/gpu/drm/renesas/rcar-du/rcar_du_drv.c
+++ b/drivers/gpu/drm/renesas/rcar-du/rcar_du_drv.c
@@ -545,6 +545,23 @@ static const struct rcar_du_device_info rcar_du_r8a779g0_info = {
 	.dsi_clk_mask =  BIT(1) | BIT(0),
 };
 
+static const struct rcar_du_device_info rcar_du_r8a779h0_info = {
+	.gen = 4,
+	.features = RCAR_DU_FEATURE_CRTC_IRQ
+		  | RCAR_DU_FEATURE_VSP1_SOURCE
+		  | RCAR_DU_FEATURE_NO_BLENDING,
+	.channels_mask = BIT(0),
+	.routes = {
+		/* R8A779H0 has one MIPI DSI output. */
+		[RCAR_DU_OUTPUT_DSI0] = {
+			.possible_crtcs = BIT(0),
+			.port = 0,
+		},
+	},
+	.num_rpf = 5,
+	.dsi_clk_mask = BIT(0),
+};
+
 static const struct of_device_id rcar_du_of_table[] = {
 	{ .compatible = "renesas,du-r8a7742", .data = &rcar_du_r8a7790_info },
 	{ .compatible = "renesas,du-r8a7743", .data = &rzg1_du_r8a7743_info },
@@ -571,6 +588,7 @@ static const struct of_device_id rcar_du_of_table[] = {
 	{ .compatible = "renesas,du-r8a77995", .data = &rcar_du_r8a7799x_info },
 	{ .compatible = "renesas,du-r8a779a0", .data = &rcar_du_r8a779a0_info },
 	{ .compatible = "renesas,du-r8a779g0", .data = &rcar_du_r8a779g0_info },
+	{ .compatible = "renesas,du-r8a779h0", .data = &rcar_du_r8a779h0_info },
 	{ }
 };
 
diff --git a/drivers/gpu/drm/renesas/rcar-du/rcar_du_group.c b/drivers/gpu/drm/renesas/rcar-du/rcar_du_group.c
index 1ec806c8e013..068c106e586c 100644
--- a/drivers/gpu/drm/renesas/rcar-du/rcar_du_group.c
+++ b/drivers/gpu/drm/renesas/rcar-du/rcar_du_group.c
@@ -107,10 +107,12 @@ static void rcar_du_group_setup_didsr(struct rcar_du_group *rgrp)
 		 */
 		rcrtc = rcdu->crtcs;
 		num_crtcs = rcdu->num_crtcs;
-	} else if (rcdu->info->gen >= 3 && rgrp->num_crtcs > 1) {
+	} else if ((rcdu->info->gen == 3 && rgrp->num_crtcs > 1) ||
+		   rcdu->info->gen == 4) {
 		/*
 		 * On Gen3 dot clocks are setup through per-group registers,
 		 * only available when the group has two channels.
+		 * On Gen4 the registers are there for single channel too.
 		 */
 		rcrtc = &rcdu->crtcs[rgrp->index * 2];
 		num_crtcs = rgrp->num_crtcs;

-- 
2.43.0


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

* Re: [PATCH v5 3/7] dt-bindings: display: renesas,du: Add missing constraints
  2024-12-17  5:31 ` [PATCH v5 3/7] dt-bindings: display: renesas,du: Add missing constraints Tomi Valkeinen
@ 2024-12-17  6:25   ` Krzysztof Kozlowski
  2025-01-28  9:42     ` Krzysztof Kozlowski
  2024-12-17  8:14   ` [PATCH v5 3/7] dt-bindings: display: renesas, du: " Geert Uytterhoeven
  2024-12-17 11:44   ` Laurent Pinchart
  2 siblings, 1 reply; 21+ messages in thread
From: Krzysztof Kozlowski @ 2024-12-17  6:25 UTC (permalink / raw)
  To: Tomi Valkeinen
  Cc: Laurent Pinchart, Kieran Bingham, Andrzej Hajda, Neil Armstrong,
	Robert Foss, Jonas Karlman, Jernej Skrabec, David Airlie,
	Simona Vetter, Maarten Lankhorst, Maxime Ripard,
	Thomas Zimmermann, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
	Geert Uytterhoeven, Magnus Damm, Michael Turquette, Stephen Boyd,
	LUU HOAI, Jagan Teki, Sam Ravnborg, Biju Das, dri-devel,
	linux-renesas-soc, devicetree, linux-kernel, Laurent Pinchart,
	linux-clk, Tomi Valkeinen

On Tue, Dec 17, 2024 at 07:31:37AM +0200, Tomi Valkeinen wrote:
> From: Tomi Valkeinen <tomi.valkeinen+renesas@ideasonboard.com>
> 
> The binding is missing maxItems for all renesas,cmms and renesas,vsps
> properties. As the amount of cmms or vsps is always a fixed amount, set
> the maxItems to match the minItems.
> 
> Also add the minItems and maxItems to the top level properties.
> 
> Signed-off-by: Tomi Valkeinen <tomi.valkeinen+renesas@ideasonboard.com>
> ---
>  Documentation/devicetree/bindings/display/renesas,du.yaml | 15 ++++++++++++++-
>  1 file changed, 14 insertions(+), 1 deletion(-)

Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>

Best regards,
Krzysztof


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

* Re: [PATCH v5 4/7] dt-bindings: display: renesas,du: Add r8a779h0
  2024-12-17  5:31 ` [PATCH v5 4/7] dt-bindings: display: renesas,du: Add r8a779h0 Tomi Valkeinen
@ 2024-12-17  6:28   ` Krzysztof Kozlowski
  2024-12-17  6:33     ` Tomi Valkeinen
  0 siblings, 1 reply; 21+ messages in thread
From: Krzysztof Kozlowski @ 2024-12-17  6:28 UTC (permalink / raw)
  To: Tomi Valkeinen
  Cc: Laurent Pinchart, Kieran Bingham, Andrzej Hajda, Neil Armstrong,
	Robert Foss, Jonas Karlman, Jernej Skrabec, David Airlie,
	Simona Vetter, Maarten Lankhorst, Maxime Ripard,
	Thomas Zimmermann, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
	Geert Uytterhoeven, Magnus Damm, Michael Turquette, Stephen Boyd,
	LUU HOAI, Jagan Teki, Sam Ravnborg, Biju Das, dri-devel,
	linux-renesas-soc, devicetree, linux-kernel, Laurent Pinchart,
	linux-clk, Tomi Valkeinen

On Tue, Dec 17, 2024 at 07:31:38AM +0200, Tomi Valkeinen wrote:
> From: Tomi Valkeinen <tomi.valkeinen+renesas@ideasonboard.com>
> 
> Extend the Renesas DU display bindings to support the r8a779h0 V4M.
> 
> Note that we remove the requirement for two ports from the global part
> of the bindings, as each conditional part defines the number of required
> ports already. This came up with r8a779h0 as it's the first one that has
> only one port.
> 
> Signed-off-by: Tomi Valkeinen <tomi.valkeinen+renesas@ideasonboard.com>
> Reviewed-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
> Tested-by: Geert Uytterhoeven <geert+renesas@glider.be>

TBH, I really dislike tested-by on bindings, because "testing" is
essentially "building". You cannot test the binding different way. You
can review it, that it matches datasheet. You can test the DTS on the
physical hardware, but not the binding.  So if this is equal to
"building" we do not act like: "I built a kernel, so add my Tested-by
tag".  Maybe this was added to cover letter, so the tag
populated here as well.

> ---
>  .../devicetree/bindings/display/renesas,du.yaml    | 52 ++++++++++++++++++++--
>  1 file changed, 48 insertions(+), 4 deletions(-)

Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>

Best regards,
Krzysztof


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

* Re: [PATCH v5 4/7] dt-bindings: display: renesas,du: Add r8a779h0
  2024-12-17  6:28   ` Krzysztof Kozlowski
@ 2024-12-17  6:33     ` Tomi Valkeinen
  0 siblings, 0 replies; 21+ messages in thread
From: Tomi Valkeinen @ 2024-12-17  6:33 UTC (permalink / raw)
  To: Krzysztof Kozlowski
  Cc: Laurent Pinchart, Kieran Bingham, Andrzej Hajda, Neil Armstrong,
	Robert Foss, Jonas Karlman, Jernej Skrabec, David Airlie,
	Simona Vetter, Maarten Lankhorst, Maxime Ripard,
	Thomas Zimmermann, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
	Geert Uytterhoeven, Magnus Damm, Michael Turquette, Stephen Boyd,
	LUU HOAI, Jagan Teki, Sam Ravnborg, Biju Das, dri-devel,
	linux-renesas-soc, devicetree, linux-kernel, Laurent Pinchart,
	linux-clk, Tomi Valkeinen

Hi,

On 17/12/2024 08:28, Krzysztof Kozlowski wrote:
> On Tue, Dec 17, 2024 at 07:31:38AM +0200, Tomi Valkeinen wrote:
>> From: Tomi Valkeinen <tomi.valkeinen+renesas@ideasonboard.com>
>>
>> Extend the Renesas DU display bindings to support the r8a779h0 V4M.
>>
>> Note that we remove the requirement for two ports from the global part
>> of the bindings, as each conditional part defines the number of required
>> ports already. This came up with r8a779h0 as it's the first one that has
>> only one port.
>>
>> Signed-off-by: Tomi Valkeinen <tomi.valkeinen+renesas@ideasonboard.com>
>> Reviewed-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
>> Tested-by: Geert Uytterhoeven <geert+renesas@glider.be>
> 
> TBH, I really dislike tested-by on bindings, because "testing" is
> essentially "building". You cannot test the binding different way. You
> can review it, that it matches datasheet. You can test the DTS on the
> physical hardware, but not the binding.  So if this is equal to
> "building" we do not act like: "I built a kernel, so add my Tested-by
> tag".  Maybe this was added to cover letter, so the tag
> populated here as well.

Yes, Geert gave a tested-by for the series, so b4 applied it to all patches.

I'll drop the Tested-by from this and the next patches.

  Tomi


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

* Re: [PATCH v5 3/7] dt-bindings: display: renesas, du: Add missing constraints
  2024-12-17  5:31 ` [PATCH v5 3/7] dt-bindings: display: renesas,du: Add missing constraints Tomi Valkeinen
  2024-12-17  6:25   ` Krzysztof Kozlowski
@ 2024-12-17  8:14   ` Geert Uytterhoeven
  2024-12-17  9:59     ` [PATCH v5 3/7] dt-bindings: display: renesas,du: " Tomi Valkeinen
  2024-12-17 11:44   ` Laurent Pinchart
  2 siblings, 1 reply; 21+ messages in thread
From: Geert Uytterhoeven @ 2024-12-17  8:14 UTC (permalink / raw)
  To: Tomi Valkeinen
  Cc: Laurent Pinchart, Kieran Bingham, Andrzej Hajda, Neil Armstrong,
	Robert Foss, Jonas Karlman, Jernej Skrabec, David Airlie,
	Simona Vetter, Maarten Lankhorst, Maxime Ripard,
	Thomas Zimmermann, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
	Magnus Damm, Michael Turquette, Stephen Boyd, LUU HOAI,
	Jagan Teki, Sam Ravnborg, Biju Das, dri-devel, linux-renesas-soc,
	devicetree, linux-kernel, Laurent Pinchart, linux-clk,
	Tomi Valkeinen

Hi Tomi,

On Tue, Dec 17, 2024 at 6:32 AM Tomi Valkeinen
<tomi.valkeinen@ideasonboard.com> wrote:
> From: Tomi Valkeinen <tomi.valkeinen+renesas@ideasonboard.com>
>
> The binding is missing maxItems for all renesas,cmms and renesas,vsps
> properties. As the amount of cmms or vsps is always a fixed amount, set
> the maxItems to match the minItems.
>
> Also add the minItems and maxItems to the top level properties.
>
> Signed-off-by: Tomi Valkeinen <tomi.valkeinen+renesas@ideasonboard.com>

Thanks for your patch!

> --- a/Documentation/devicetree/bindings/display/renesas,du.yaml
> +++ b/Documentation/devicetree/bindings/display/renesas,du.yaml
> @@ -77,6 +77,8 @@ properties:
>
>    renesas,cmms:
>      $ref: /schemas/types.yaml#/definitions/phandle-array
> +    minItems: 1
> +    maxItems: 4
>      items:
>        maxItems: 1
>      description:
> @@ -85,6 +87,8 @@ properties:
>
>    renesas,vsps:
>      $ref: /schemas/types.yaml#/definitions/phandle-array
> +    minItems: 1
> +    maxItems: 4
>      items:
>        items:
>          - description: phandle to VSP instance that serves the DU channel
> @@ -489,9 +493,11 @@ allOf:
>
>          renesas,cmms:
>            minItems: 4
> +          maxItems: 4
>
>          renesas,vsps:
>            minItems: 4
> +          maxItems: 4

AFAIK these two additions are not needed, as they already match the
values defined at the top level.

The rest LGTM.

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

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

* Re: [PATCH v5 3/7] dt-bindings: display: renesas,du: Add missing constraints
  2024-12-17  8:14   ` [PATCH v5 3/7] dt-bindings: display: renesas, du: " Geert Uytterhoeven
@ 2024-12-17  9:59     ` Tomi Valkeinen
  2024-12-17 11:42       ` Laurent Pinchart
  0 siblings, 1 reply; 21+ messages in thread
From: Tomi Valkeinen @ 2024-12-17  9:59 UTC (permalink / raw)
  To: Geert Uytterhoeven
  Cc: Laurent Pinchart, Kieran Bingham, Andrzej Hajda, Neil Armstrong,
	Robert Foss, Jonas Karlman, Jernej Skrabec, David Airlie,
	Simona Vetter, Maarten Lankhorst, Maxime Ripard,
	Thomas Zimmermann, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
	Magnus Damm, Michael Turquette, Stephen Boyd, LUU HOAI,
	Jagan Teki, Sam Ravnborg, Biju Das, dri-devel, linux-renesas-soc,
	devicetree, linux-kernel, Laurent Pinchart, linux-clk,
	Tomi Valkeinen

Hi,

On 17/12/2024 10:14, Geert Uytterhoeven wrote:
> Hi Tomi,
> 
> On Tue, Dec 17, 2024 at 6:32 AM Tomi Valkeinen
> <tomi.valkeinen@ideasonboard.com> wrote:
>> From: Tomi Valkeinen <tomi.valkeinen+renesas@ideasonboard.com>
>>
>> The binding is missing maxItems for all renesas,cmms and renesas,vsps
>> properties. As the amount of cmms or vsps is always a fixed amount, set
>> the maxItems to match the minItems.
>>
>> Also add the minItems and maxItems to the top level properties.
>>
>> Signed-off-by: Tomi Valkeinen <tomi.valkeinen+renesas@ideasonboard.com>
> 
> Thanks for your patch!
> 
>> --- a/Documentation/devicetree/bindings/display/renesas,du.yaml
>> +++ b/Documentation/devicetree/bindings/display/renesas,du.yaml
>> @@ -77,6 +77,8 @@ properties:
>>
>>     renesas,cmms:
>>       $ref: /schemas/types.yaml#/definitions/phandle-array
>> +    minItems: 1
>> +    maxItems: 4
>>       items:
>>         maxItems: 1
>>       description:
>> @@ -85,6 +87,8 @@ properties:
>>
>>     renesas,vsps:
>>       $ref: /schemas/types.yaml#/definitions/phandle-array
>> +    minItems: 1
>> +    maxItems: 4
>>       items:
>>         items:
>>           - description: phandle to VSP instance that serves the DU channel
>> @@ -489,9 +493,11 @@ allOf:
>>
>>           renesas,cmms:
>>             minItems: 4
>> +          maxItems: 4
>>
>>           renesas,vsps:
>>             minItems: 4
>> +          maxItems: 4
> 
> AFAIK these two additions are not needed, as they already match the
> values defined at the top level.

But if we add a new SoC, which has 5 vsps, we would need to increase the 
values in the top level. Which would then mean these are needed, and I'm 
sure adding them could be missed.

  Tomi


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

* Re: [PATCH v5 3/7] dt-bindings: display: renesas,du: Add missing constraints
  2024-12-17  9:59     ` [PATCH v5 3/7] dt-bindings: display: renesas,du: " Tomi Valkeinen
@ 2024-12-17 11:42       ` Laurent Pinchart
  0 siblings, 0 replies; 21+ messages in thread
From: Laurent Pinchart @ 2024-12-17 11:42 UTC (permalink / raw)
  To: Tomi Valkeinen
  Cc: Geert Uytterhoeven, Kieran Bingham, Andrzej Hajda, Neil Armstrong,
	Robert Foss, Jonas Karlman, Jernej Skrabec, David Airlie,
	Simona Vetter, Maarten Lankhorst, Maxime Ripard,
	Thomas Zimmermann, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
	Magnus Damm, Michael Turquette, Stephen Boyd, LUU HOAI,
	Jagan Teki, Sam Ravnborg, Biju Das, dri-devel, linux-renesas-soc,
	devicetree, linux-kernel, linux-clk, Tomi Valkeinen

On Tue, Dec 17, 2024 at 11:59:53AM +0200, Tomi Valkeinen wrote:
> Hi,
> 
> On 17/12/2024 10:14, Geert Uytterhoeven wrote:
> > Hi Tomi,
> > 
> > On Tue, Dec 17, 2024 at 6:32 AM Tomi Valkeinen
> > <tomi.valkeinen@ideasonboard.com> wrote:
> >> From: Tomi Valkeinen <tomi.valkeinen+renesas@ideasonboard.com>
> >>
> >> The binding is missing maxItems for all renesas,cmms and renesas,vsps
> >> properties. As the amount of cmms or vsps is always a fixed amount, set
> >> the maxItems to match the minItems.
> >>
> >> Also add the minItems and maxItems to the top level properties.
> >>
> >> Signed-off-by: Tomi Valkeinen <tomi.valkeinen+renesas@ideasonboard.com>
> > 
> > Thanks for your patch!
> > 
> >> --- a/Documentation/devicetree/bindings/display/renesas,du.yaml
> >> +++ b/Documentation/devicetree/bindings/display/renesas,du.yaml
> >> @@ -77,6 +77,8 @@ properties:
> >>
> >>     renesas,cmms:
> >>       $ref: /schemas/types.yaml#/definitions/phandle-array
> >> +    minItems: 1
> >> +    maxItems: 4
> >>       items:
> >>         maxItems: 1
> >>       description:
> >> @@ -85,6 +87,8 @@ properties:
> >>
> >>     renesas,vsps:
> >>       $ref: /schemas/types.yaml#/definitions/phandle-array
> >> +    minItems: 1
> >> +    maxItems: 4
> >>       items:
> >>         items:
> >>           - description: phandle to VSP instance that serves the DU channel
> >> @@ -489,9 +493,11 @@ allOf:
> >>
> >>           renesas,cmms:
> >>             minItems: 4
> >> +          maxItems: 4
> >>
> >>           renesas,vsps:
> >>             minItems: 4
> >> +          maxItems: 4
> > 
> > AFAIK these two additions are not needed, as they already match the
> > values defined at the top level.
> 
> But if we add a new SoC, which has 5 vsps, we would need to increase the 
> values in the top level. Which would then mean these are needed, and I'm 
> sure adding them could be missed.

Let's keep things consistent with maxItems specified everywhere (my
preference is to not specify the items count at the top level hereas I
don't see any value in doing so, but I won't fight on that one if it's
what it takes to get the bindings merged).

-- 
Regards,

Laurent Pinchart

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

* Re: [PATCH v5 3/7] dt-bindings: display: renesas,du: Add missing constraints
  2024-12-17  5:31 ` [PATCH v5 3/7] dt-bindings: display: renesas,du: Add missing constraints Tomi Valkeinen
  2024-12-17  6:25   ` Krzysztof Kozlowski
  2024-12-17  8:14   ` [PATCH v5 3/7] dt-bindings: display: renesas, du: " Geert Uytterhoeven
@ 2024-12-17 11:44   ` Laurent Pinchart
  2 siblings, 0 replies; 21+ messages in thread
From: Laurent Pinchart @ 2024-12-17 11:44 UTC (permalink / raw)
  To: Tomi Valkeinen
  Cc: Kieran Bingham, Andrzej Hajda, Neil Armstrong, Robert Foss,
	Jonas Karlman, Jernej Skrabec, David Airlie, Simona Vetter,
	Maarten Lankhorst, Maxime Ripard, Thomas Zimmermann, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Geert Uytterhoeven,
	Magnus Damm, Michael Turquette, Stephen Boyd, LUU HOAI,
	Jagan Teki, Sam Ravnborg, Biju Das, dri-devel, linux-renesas-soc,
	devicetree, linux-kernel, linux-clk, Tomi Valkeinen

On Tue, Dec 17, 2024 at 07:31:37AM +0200, Tomi Valkeinen wrote:
> From: Tomi Valkeinen <tomi.valkeinen+renesas@ideasonboard.com>
> 
> The binding is missing maxItems for all renesas,cmms and renesas,vsps
> properties. As the amount of cmms or vsps is always a fixed amount, set
> the maxItems to match the minItems.
> 
> Also add the minItems and maxItems to the top level properties.
> 
> Signed-off-by: Tomi Valkeinen <tomi.valkeinen+renesas@ideasonboard.com>

Reviewed-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>

> ---
>  Documentation/devicetree/bindings/display/renesas,du.yaml | 15 ++++++++++++++-
>  1 file changed, 14 insertions(+), 1 deletion(-)
> 
> diff --git a/Documentation/devicetree/bindings/display/renesas,du.yaml b/Documentation/devicetree/bindings/display/renesas,du.yaml
> index c5b9e6812bce..ef4568118e94 100644
> --- a/Documentation/devicetree/bindings/display/renesas,du.yaml
> +++ b/Documentation/devicetree/bindings/display/renesas,du.yaml
> @@ -77,6 +77,8 @@ properties:
>  
>    renesas,cmms:
>      $ref: /schemas/types.yaml#/definitions/phandle-array
> +    minItems: 1
> +    maxItems: 4
>      items:
>        maxItems: 1
>      description:
> @@ -85,6 +87,8 @@ properties:
>  
>    renesas,vsps:
>      $ref: /schemas/types.yaml#/definitions/phandle-array
> +    minItems: 1
> +    maxItems: 4
>      items:
>        items:
>          - description: phandle to VSP instance that serves the DU channel
> @@ -489,9 +493,11 @@ allOf:
>  
>          renesas,cmms:
>            minItems: 4
> +          maxItems: 4
>  
>          renesas,vsps:
>            minItems: 4
> +          maxItems: 4
>  
>        required:
>          - clock-names
> @@ -558,9 +564,11 @@ allOf:
>  
>          renesas,cmms:
>            minItems: 3
> +          maxItems: 3
>  
>          renesas,vsps:
>            minItems: 3
> +          maxItems: 3
>  
>        required:
>          - clock-names
> @@ -627,9 +635,11 @@ allOf:
>  
>          renesas,cmms:
>            minItems: 3
> +          maxItems: 3
>  
>          renesas,vsps:
>            minItems: 3
> +          maxItems: 3
>  
>        required:
>          - clock-names
> @@ -683,7 +693,7 @@ allOf:
>              - port@1
>  
>          renesas,vsps:
> -          minItems: 1
> +          maxItems: 1
>  
>        required:
>          - clock-names
> @@ -746,9 +756,11 @@ allOf:
>  
>          renesas,cmms:
>            minItems: 2
> +          maxItems: 2
>  
>          renesas,vsps:
>            minItems: 2
> +          maxItems: 2
>  
>        required:
>          - clock-names
> @@ -799,6 +811,7 @@ allOf:
>  
>          renesas,vsps:
>            minItems: 2
> +          maxItems: 2
>  
>        required:
>          - clock-names

-- 
Regards,

Laurent Pinchart

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

* Re: [PATCH v5 0/7] drm: Add DSI/DP support for Renesas r8a779h0 V4M and grey-hawk board
  2024-12-17  5:31 [PATCH v5 0/7] drm: Add DSI/DP support for Renesas r8a779h0 V4M and grey-hawk board Tomi Valkeinen
                   ` (6 preceding siblings ...)
  2024-12-17  5:31 ` [PATCH v5 7/7] drm/rcar-du: Add support for r8a779h0 Tomi Valkeinen
@ 2024-12-17 13:33 ` Tomi Valkeinen
  2025-01-28 10:09   ` Krzysztof Kozlowski
  7 siblings, 1 reply; 21+ messages in thread
From: Tomi Valkeinen @ 2024-12-17 13:33 UTC (permalink / raw)
  To: Tomi Valkeinen, Laurent Pinchart, Kieran Bingham, Andrzej Hajda,
	Neil Armstrong, Robert Foss, Jonas Karlman, Jernej Skrabec,
	David Airlie, Simona Vetter, Maarten Lankhorst, Maxime Ripard,
	Thomas Zimmermann, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
	Geert Uytterhoeven, Magnus Damm, Michael Turquette, Stephen Boyd,
	LUU HOAI, Jagan Teki, Sam Ravnborg, Biju Das
  Cc: dri-devel, linux-renesas-soc, devicetree, linux-kernel,
	Laurent Pinchart, linux-clk, stable, Krzysztof Kozlowski

Hi all,

On 17/12/2024 07:31, Tomi Valkeinen wrote:
> Add everything needed to support the DSI output on Renesas r8a779h0
> (V4M) SoC, and the DP output (via sn65dsi86 DSI to DP bridge) on the
> Renesas grey-hawk board.
> 
> Overall the DSI and the board design is almost identical to Renesas
> r8a779g0 and white-hawk board.
> 
> Note: the v4 no longer has the dts and the clk patches, as those have
> been merged to renesas-devel.
> 

I have pushed this to drm-misc-next. Thank you all for the reviews!

  Tomi


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

* Re: [PATCH v5 3/7] dt-bindings: display: renesas,du: Add missing constraints
  2024-12-17  6:25   ` Krzysztof Kozlowski
@ 2025-01-28  9:42     ` Krzysztof Kozlowski
  2025-01-28 10:38       ` Tomi Valkeinen
  0 siblings, 1 reply; 21+ messages in thread
From: Krzysztof Kozlowski @ 2025-01-28  9:42 UTC (permalink / raw)
  To: Tomi Valkeinen
  Cc: Laurent Pinchart, Kieran Bingham, Andrzej Hajda, Neil Armstrong,
	Robert Foss, Jonas Karlman, Jernej Skrabec, David Airlie,
	Simona Vetter, Maarten Lankhorst, Maxime Ripard,
	Thomas Zimmermann, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
	Geert Uytterhoeven, Magnus Damm, Michael Turquette, Stephen Boyd,
	LUU HOAI, Jagan Teki, Sam Ravnborg, Biju Das, dri-devel,
	linux-renesas-soc, devicetree, linux-kernel, Laurent Pinchart,
	linux-clk, Tomi Valkeinen

On 17/12/2024 07:25, Krzysztof Kozlowski wrote:
> On Tue, Dec 17, 2024 at 07:31:37AM +0200, Tomi Valkeinen wrote:
>> From: Tomi Valkeinen <tomi.valkeinen+renesas@ideasonboard.com>
>>
>> The binding is missing maxItems for all renesas,cmms and renesas,vsps
>> properties. As the amount of cmms or vsps is always a fixed amount, set
>> the maxItems to match the minItems.
>>
>> Also add the minItems and maxItems to the top level properties.
>>
>> Signed-off-by: Tomi Valkeinen <tomi.valkeinen+renesas@ideasonboard.com>
>> ---
>>  Documentation/devicetree/bindings/display/renesas,du.yaml | 15 ++++++++++++++-
>>  1 file changed, 14 insertions(+), 1 deletion(-)
> 
> Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>

So you just repeated parts I sent much earlier...

https://lore.kernel.org/all/20240818173003.122025-2-krzysztof.kozlowski@linaro.org/

That one got reviews but was not merged for some reason.

Best regards,
Krzysztof

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

* Re: [PATCH v5 0/7] drm: Add DSI/DP support for Renesas r8a779h0 V4M and grey-hawk board
  2024-12-17 13:33 ` [PATCH v5 0/7] drm: Add DSI/DP support for Renesas r8a779h0 V4M and grey-hawk board Tomi Valkeinen
@ 2025-01-28 10:09   ` Krzysztof Kozlowski
  2025-01-28 10:26     ` Tomi Valkeinen
  0 siblings, 1 reply; 21+ messages in thread
From: Krzysztof Kozlowski @ 2025-01-28 10:09 UTC (permalink / raw)
  To: Tomi Valkeinen, Laurent Pinchart, Kieran Bingham, Andrzej Hajda,
	Neil Armstrong, Robert Foss, Jonas Karlman, Jernej Skrabec,
	David Airlie, Simona Vetter, Maarten Lankhorst, Maxime Ripard,
	Thomas Zimmermann, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
	Geert Uytterhoeven, Magnus Damm, Michael Turquette, Stephen Boyd,
	LUU HOAI, Jagan Teki, Sam Ravnborg, Biju Das
  Cc: dri-devel, linux-renesas-soc, devicetree, linux-kernel,
	Laurent Pinchart, linux-clk, stable, Krzysztof Kozlowski

On 17/12/2024 14:33, Tomi Valkeinen wrote:
> Hi all,
> 
> On 17/12/2024 07:31, Tomi Valkeinen wrote:
>> Add everything needed to support the DSI output on Renesas r8a779h0
>> (V4M) SoC, and the DP output (via sn65dsi86 DSI to DP bridge) on the
>> Renesas grey-hawk board.
>>
>> Overall the DSI and the board design is almost identical to Renesas
>> r8a779g0 and white-hawk board.
>>
>> Note: the v4 no longer has the dts and the clk patches, as those have
>> been merged to renesas-devel.
>>
> 
> I have pushed this to drm-misc-next. Thank you all for the reviews!
I am confused how this is supposed to work. You merged your own patches
for Renesas DRM, even not being the Renesas DRM maintainer, while my
much earlier patchset was "only" reviewed by Renesas DRM maintainers but
not picked up by them.

So maybe you are the Renesas DRM maintainer? But get_maintainers.pl is
silent on that, so I don't Cc you.

Can you guys clarify that so maintainers file reflect reality?

Best regards,
Krzysztof

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

* Re: [PATCH v5 0/7] drm: Add DSI/DP support for Renesas r8a779h0 V4M and grey-hawk board
  2025-01-28 10:09   ` Krzysztof Kozlowski
@ 2025-01-28 10:26     ` Tomi Valkeinen
  2025-01-28 10:28       ` Krzysztof Kozlowski
  0 siblings, 1 reply; 21+ messages in thread
From: Tomi Valkeinen @ 2025-01-28 10:26 UTC (permalink / raw)
  To: Krzysztof Kozlowski, Laurent Pinchart, Kieran Bingham,
	Andrzej Hajda, Neil Armstrong, Robert Foss, Jonas Karlman,
	Jernej Skrabec, David Airlie, Simona Vetter, Maarten Lankhorst,
	Maxime Ripard, Thomas Zimmermann, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Geert Uytterhoeven,
	Magnus Damm, Michael Turquette, Stephen Boyd, LUU HOAI,
	Jagan Teki, Sam Ravnborg, Biju Das
  Cc: dri-devel, linux-renesas-soc, devicetree, linux-kernel,
	Laurent Pinchart, linux-clk, stable, Krzysztof Kozlowski

Hi,

On 28/01/2025 12:09, Krzysztof Kozlowski wrote:
> On 17/12/2024 14:33, Tomi Valkeinen wrote:
>> Hi all,
>>
>> On 17/12/2024 07:31, Tomi Valkeinen wrote:
>>> Add everything needed to support the DSI output on Renesas r8a779h0
>>> (V4M) SoC, and the DP output (via sn65dsi86 DSI to DP bridge) on the
>>> Renesas grey-hawk board.
>>>
>>> Overall the DSI and the board design is almost identical to Renesas
>>> r8a779g0 and white-hawk board.
>>>
>>> Note: the v4 no longer has the dts and the clk patches, as those have
>>> been merged to renesas-devel.
>>>
>>
>> I have pushed this to drm-misc-next. Thank you all for the reviews!
> I am confused how this is supposed to work. You merged your own patches
> for Renesas DRM, even not being the Renesas DRM maintainer, while my
> much earlier patchset was "only" reviewed by Renesas DRM maintainers but
> not picked up by them.
> 
> So maybe you are the Renesas DRM maintainer? But get_maintainers.pl is
> silent on that, so I don't Cc you.
> 
> Can you guys clarify that so maintainers file reflect reality?

Yep, that's not right. Laurent has been requesting me to merge rcar-du 
patches via drm-misc for a while now, so in practice I have been a 
maintainer. But the maintainers file has not been updated. I'll do that now.

Sorry about the confusion.

  Tomi


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

* Re: [PATCH v5 0/7] drm: Add DSI/DP support for Renesas r8a779h0 V4M and grey-hawk board
  2025-01-28 10:26     ` Tomi Valkeinen
@ 2025-01-28 10:28       ` Krzysztof Kozlowski
  0 siblings, 0 replies; 21+ messages in thread
From: Krzysztof Kozlowski @ 2025-01-28 10:28 UTC (permalink / raw)
  To: Tomi Valkeinen, Laurent Pinchart, Kieran Bingham, Andrzej Hajda,
	Neil Armstrong, Robert Foss, Jonas Karlman, Jernej Skrabec,
	David Airlie, Simona Vetter, Maarten Lankhorst, Maxime Ripard,
	Thomas Zimmermann, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
	Geert Uytterhoeven, Magnus Damm, Michael Turquette, Stephen Boyd,
	LUU HOAI, Jagan Teki, Sam Ravnborg, Biju Das
  Cc: dri-devel, linux-renesas-soc, devicetree, linux-kernel,
	Laurent Pinchart, linux-clk, stable, Krzysztof Kozlowski

On 28/01/2025 11:26, Tomi Valkeinen wrote:
>>
>> So maybe you are the Renesas DRM maintainer? But get_maintainers.pl is
>> silent on that, so I don't Cc you.
>>
>> Can you guys clarify that so maintainers file reflect reality?
> 
> Yep, that's not right. Laurent has been requesting me to merge rcar-du 
> patches via drm-misc for a while now, so in practice I have been a 
> maintainer. But the maintainers file has not been updated. I'll do that now.

Thanks.

Best regards,
Krzysztof

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

* Re: [PATCH v5 3/7] dt-bindings: display: renesas,du: Add missing constraints
  2025-01-28  9:42     ` Krzysztof Kozlowski
@ 2025-01-28 10:38       ` Tomi Valkeinen
  0 siblings, 0 replies; 21+ messages in thread
From: Tomi Valkeinen @ 2025-01-28 10:38 UTC (permalink / raw)
  To: Krzysztof Kozlowski
  Cc: Laurent Pinchart, Kieran Bingham, Andrzej Hajda, Neil Armstrong,
	Robert Foss, Jonas Karlman, Jernej Skrabec, David Airlie,
	Simona Vetter, Maarten Lankhorst, Maxime Ripard,
	Thomas Zimmermann, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
	Geert Uytterhoeven, Magnus Damm, Michael Turquette, Stephen Boyd,
	LUU HOAI, Jagan Teki, Sam Ravnborg, Biju Das, dri-devel,
	linux-renesas-soc, devicetree, linux-kernel, Laurent Pinchart,
	linux-clk, Tomi Valkeinen

Hi,

On 28/01/2025 11:42, Krzysztof Kozlowski wrote:
> On 17/12/2024 07:25, Krzysztof Kozlowski wrote:
>> On Tue, Dec 17, 2024 at 07:31:37AM +0200, Tomi Valkeinen wrote:
>>> From: Tomi Valkeinen <tomi.valkeinen+renesas@ideasonboard.com>
>>>
>>> The binding is missing maxItems for all renesas,cmms and renesas,vsps
>>> properties. As the amount of cmms or vsps is always a fixed amount, set
>>> the maxItems to match the minItems.
>>>
>>> Also add the minItems and maxItems to the top level properties.
>>>
>>> Signed-off-by: Tomi Valkeinen <tomi.valkeinen+renesas@ideasonboard.com>
>>> ---
>>>   Documentation/devicetree/bindings/display/renesas,du.yaml | 15 ++++++++++++++-
>>>   1 file changed, 14 insertions(+), 1 deletion(-)
>>
>> Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
> 
> So you just repeated parts I sent much earlier...
> 
> https://lore.kernel.org/all/20240818173003.122025-2-krzysztof.kozlowski@linaro.org/
> 
> That one got reviews but was not merged for some reason.

Yes, that was somehow missed. The patches still look relevant to me. 
Should I rebase and sort out the conflicts, or would you like to rebase it?

  Tomi


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

end of thread, other threads:[~2025-01-28 10:39 UTC | newest]

Thread overview: 21+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-12-17  5:31 [PATCH v5 0/7] drm: Add DSI/DP support for Renesas r8a779h0 V4M and grey-hawk board Tomi Valkeinen
2024-12-17  5:31 ` [PATCH v5 1/7] drm/rcar-du: dsi: Fix PHY lock bit check Tomi Valkeinen
2024-12-17  5:31 ` [PATCH v5 2/7] drm/rcar-du: Write DPTSR only if the second source exists Tomi Valkeinen
2024-12-17  5:31 ` [PATCH v5 3/7] dt-bindings: display: renesas,du: Add missing constraints Tomi Valkeinen
2024-12-17  6:25   ` Krzysztof Kozlowski
2025-01-28  9:42     ` Krzysztof Kozlowski
2025-01-28 10:38       ` Tomi Valkeinen
2024-12-17  8:14   ` [PATCH v5 3/7] dt-bindings: display: renesas, du: " Geert Uytterhoeven
2024-12-17  9:59     ` [PATCH v5 3/7] dt-bindings: display: renesas,du: " Tomi Valkeinen
2024-12-17 11:42       ` Laurent Pinchart
2024-12-17 11:44   ` Laurent Pinchart
2024-12-17  5:31 ` [PATCH v5 4/7] dt-bindings: display: renesas,du: Add r8a779h0 Tomi Valkeinen
2024-12-17  6:28   ` Krzysztof Kozlowski
2024-12-17  6:33     ` Tomi Valkeinen
2024-12-17  5:31 ` [PATCH v5 5/7] dt-bindings: display: bridge: renesas,dsi-csi2-tx: " Tomi Valkeinen
2024-12-17  5:31 ` [PATCH v5 6/7] drm/rcar-du: dsi: Add r8a779h0 support Tomi Valkeinen
2024-12-17  5:31 ` [PATCH v5 7/7] drm/rcar-du: Add support for r8a779h0 Tomi Valkeinen
2024-12-17 13:33 ` [PATCH v5 0/7] drm: Add DSI/DP support for Renesas r8a779h0 V4M and grey-hawk board Tomi Valkeinen
2025-01-28 10:09   ` Krzysztof Kozlowski
2025-01-28 10:26     ` Tomi Valkeinen
2025-01-28 10:28       ` Krzysztof Kozlowski

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).