public inbox for drm-ai-reviews@public-inbox.freedesktop.org
 help / color / mirror / Atom feed
* Claude review: dt-bindings: soc: imx93-media-blk-ctrl: Add PDFC subnode to schema and example
  2026-03-02 16:10 ` [PATCH v10 1/3] dt-bindings: soc: imx93-media-blk-ctrl: Add PDFC subnode to schema and example Marco Felsch
@ 2026-03-03  3:09   ` Claude Code Review Bot
  0 siblings, 0 replies; 15+ messages in thread
From: Claude Code Review Bot @ 2026-03-03  3:09 UTC (permalink / raw)
  To: dri-devel-reviews

Patch Review

**Subject:** `[PATCH v10 1/3] dt-bindings: soc: imx93-media-blk-ctrl: Add PDFC subnode to schema and example`

This patch adds the `dpi-bridge` subnode binding to the existing `fsl,imx93-media-blk-ctrl.yaml`. Looks reasonable.

**Minor observations:**

1. The binding only lists `nxp,imx91-pdfc` and `nxp,imx93-pdfc` in the compatible enum, but the driver in patch 2 only has a match for `nxp,imx93-pdfc`. If `nxp,imx91-pdfc` is a distinct compatible in the binding, the driver should also match it (or document a fallback). See patch 2 comments.

2. The `bus-width` enum is well-documented:
```yaml
                  bus-width:
                    enum: [ 16, 18, 24 ]
```
But the driver only acts on `bus-width == 18` (truncating LSBs). A `bus-width` of 16 at the physical level isn't handled differently in the driver. This is okay if `bus-width: 16` is only informational, but worth confirming intent.

3. No issues with the example node addition - it properly demonstrates `bus-width = <18>` in the output endpoint.

**Verdict:** Looks good. Already has Rob's Reviewed-by.

---

---
Generated by Claude Code Patch Reviewer

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

* [PATCH v11 0/3] Add i.MX91/93 parallel display support
@ 2026-03-03 10:34 Marco Felsch
  2026-03-03 10:34 ` [PATCH v11 1/3] dt-bindings: soc: imx93-media-blk-ctrl: Add PDFC subnode to schema and example Marco Felsch
                   ` (3 more replies)
  0 siblings, 4 replies; 15+ messages in thread
From: Marco Felsch @ 2026-03-03 10:34 UTC (permalink / raw)
  To: Rob Herring, Krzysztof Kozlowski, Conor Dooley, Shawn Guo,
	Sascha Hauer, Pengutronix Kernel Team, Fabio Estevam, Peng Fan,
	Liu Ying, Andrzej Hajda, Neil Armstrong, Robert Foss,
	Laurent Pinchart, Jonas Karlman, Jernej Skrabec,
	Maarten Lankhorst, Maxime Ripard, Thomas Zimmermann, David Airlie,
	Simona Vetter, luca.ceresoli, Frank Li
  Cc: devicetree, imx, linux-arm-kernel, linux-kernel, dri-devel,
	kernel, Marco Felsch

Hi,

this patchset adds the driver, dt-bindings and dt integration required
to drive a parallel display on the i.MX93.

Since the i.MX91 register layout equals the one from the i.MX93, I added
the support for both but tested only the i.MX93 case.

This patchset depends on:
 - https://lore.kernel.org/all/20251201-v6-18-topic-imx93-blkctrl-v1-0-b57a72e60105@pengutronix.de/

@Conor Dooley
I dropped your r-b tag since I added the 'bus-width' property.

Regards,
  Marco

Signed-off-by: Marco Felsch <m.felsch@pengutronix.de>
---
Changes in v11:
- Link to v10: https://lore.kernel.org/r/20260302-v6-18-topic-imx93-parallel-display-v10-0-634fe2778c7a@pengutronix.de
- Fix double space (Liu)
- Drop 'const' (Liu)
- Drop GFP_KERNEL from kmalloc_obj() (Liu)
- Add r-b (Luca)

Changes in v10:
- Link to v9: https://lore.kernel.org/r/20260115-v6-18-topic-imx93-parallel-display-v9-0-2c5051e4b144@pengutronix.de
- Add MEDIA_BUS_FMT_FIXED (Liu)
- Drop next_bridge from driver struct and use bridge.next_bridge (Liu)
- Drop linux/of_address.h include (Liu)
- imx93-pdfc: drop bridge.driver_private usage++ (Liu)
- Make use of kmalloc_obj() (Liu)

Changes in v9:
- Link to v8: https://lore.kernel.org/r/20260113-v6-18-topic-imx93-parallel-display-v8-0-4abccdc473a5@pengutronix.de
- dt-bindings: drop unncessary changes (Frank)
- imx93-pdfc: drop bridge.driver_private usage (Luca)
- Kconfig: Adapt Kconfig symbol and prompt (Luca)

Changes in v8:
- Link to v7: https://lore.kernel.org/r/20251202-v6-18-topic-imx93-parallel-display-v7-0-2cce31d64608@pengutronix.de
- dt-bindings: add nxp,imx91-pdfc compatible (Liu)
- dt-bindings: use video-interfaces.yaml# (Liu)
- dt-bindings: s/data lanes/data lines/ (Liu)
- dt-bindings: drop 'reg' poperty
- dt-bindings: drop #address-cells, #size-cells
- imx93-pdfc: drop drm/drm_print.h include (Liu)
- imx93-pdfc: s/exist/exists/ (Liu)
- imx93-pdfc: drop MEDIA_BUS_FMT_FIXED from imx93_pdfc_bus_output_fmts
- imx93-pdfc: imx93_pdfc_bus_output_fmt_supported: make fmt const
- imx93-pdfc: Rework input-fmt selection to always fallback to a sane
              default.
- imx93-pdfc: imx93_pdfc_bridge_atomic_check: make use of
	      imx93_pdfc_bus_output_fmt_supported() 
- imx93-pdfc: drop 'reg' dt-property usage
- imx93-pdfc: imx93_pdfc_bridge_probe: pass -1 for endpoint reg value (Liu)

Changes in v7:
- Link to v6: https://lore.kernel.org/r/20251201-v6-18-topic-imx93-parallel-display-v6-0-7b056e1e5b1e@pengutronix.de
- Add missing bits.h and bitfield.h headers (lkp)

Changes in v6:
- Link to v5: https://lore.kernel.org/all/20250304082434.834031-1-victor.liu@nxp.com/
- Add bus-width support
- rebase onto v6.18-rc1
- add review feedback (Alexander)
- driver license "GPL v2" -> "GPL" (checkpatch)
- make use of reg of-property
- fix to short Kconfig description (checkpath)
- add OF integration

---
Liu Ying (2):
      dt-bindings: soc: imx93-media-blk-ctrl: Add PDFC subnode to schema and example
      drm/bridge: imx: Add i.MX93 parallel display format configuration support

Marco Felsch (1):
      arm64: dts: imx93: Add parallel display output nodes

 .../bindings/soc/imx/fsl,imx93-media-blk-ctrl.yaml |  78 +++++++
 arch/arm64/boot/dts/freescale/imx91_93_common.dtsi |  54 +++++
 arch/arm64/boot/dts/freescale/imx93.dtsi           |  12 ++
 drivers/gpu/drm/bridge/imx/Kconfig                 |  11 +
 drivers/gpu/drm/bridge/imx/Makefile                |   1 +
 drivers/gpu/drm/bridge/imx/imx93-pdfc.c            | 225 +++++++++++++++++++++
 6 files changed, 381 insertions(+)
---
base-commit: 6de23f81a5e08be8fbf5e8d7e9febc72a5b5f27f
change-id: 20251201-v6-18-topic-imx93-parallel-display-95f9234bf6cc

Best regards,
-- 
Marco Felsch <m.felsch@pengutronix.de>


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

* [PATCH v11 1/3] dt-bindings: soc: imx93-media-blk-ctrl: Add PDFC subnode to schema and example
  2026-03-03 10:34 [PATCH v11 0/3] Add i.MX91/93 parallel display support Marco Felsch
@ 2026-03-03 10:34 ` Marco Felsch
  2026-03-03 21:00   ` Frank Li
  2026-03-03 21:36   ` Claude review: " Claude Code Review Bot
  2026-03-03 10:34 ` [PATCH v11 2/3] drm/bridge: imx: Add i.MX93 parallel display format configuration support Marco Felsch
                   ` (2 subsequent siblings)
  3 siblings, 2 replies; 15+ messages in thread
From: Marco Felsch @ 2026-03-03 10:34 UTC (permalink / raw)
  To: Rob Herring, Krzysztof Kozlowski, Conor Dooley, Shawn Guo,
	Sascha Hauer, Pengutronix Kernel Team, Fabio Estevam, Peng Fan,
	Liu Ying, Andrzej Hajda, Neil Armstrong, Robert Foss,
	Laurent Pinchart, Jonas Karlman, Jernej Skrabec,
	Maarten Lankhorst, Maxime Ripard, Thomas Zimmermann, David Airlie,
	Simona Vetter, luca.ceresoli, Frank Li
  Cc: devicetree, imx, linux-arm-kernel, linux-kernel, dri-devel,
	kernel, Marco Felsch

From: Liu Ying <victor.liu@nxp.com>

i.MX93 SoC mediamix blk-ctrl contains one DISPLAY_MUX register which
configures parallel display format by using the "PARALLEL_DISP_FORMAT"
field. Document the Parallel Display Format Configuration(PDFC) subnode
and add the subnode to example.

Reviewed-by: Rob Herring (Arm) <robh@kernel.org>
Signed-off-by: Liu Ying <victor.liu@nxp.com>
[m.felsch@pengutronix.de: port to v7.0-rc1]
[m.felsch@pengutronix.de: add bus-width]
Signed-off-by: Marco Felsch <m.felsch@pengutronix.de>
---
 .../bindings/soc/imx/fsl,imx93-media-blk-ctrl.yaml | 78 ++++++++++++++++++++++
 1 file changed, 78 insertions(+)

diff --git a/Documentation/devicetree/bindings/soc/imx/fsl,imx93-media-blk-ctrl.yaml b/Documentation/devicetree/bindings/soc/imx/fsl,imx93-media-blk-ctrl.yaml
index 34aea58094e55365a2f9c86092f637e533f954ff..d828c2e82965c7a4cd69a67136047d83c96b0a35 100644
--- a/Documentation/devicetree/bindings/soc/imx/fsl,imx93-media-blk-ctrl.yaml
+++ b/Documentation/devicetree/bindings/soc/imx/fsl,imx93-media-blk-ctrl.yaml
@@ -40,6 +40,58 @@ properties:
     minItems: 8
     maxItems: 10
 
+  dpi-bridge:
+    type: object
+    additionalProperties: false
+
+    properties:
+      compatible:
+        enum:
+          - nxp,imx91-pdfc
+          - nxp,imx93-pdfc
+
+      ports:
+        $ref: /schemas/graph.yaml#/properties/ports
+
+        properties:
+          port@0:
+            $ref: /schemas/graph.yaml#/properties/port
+            description: Input port node to receive pixel data.
+
+          port@1:
+            $ref: /schemas/graph.yaml#/$defs/port-base
+            unevaluatedProperties: false
+            description: Output port node to downstream pixel data receivers.
+
+            properties:
+              endpoint:
+                $ref: /schemas/media/video-interfaces.yaml#
+                unevaluatedProperties: false
+
+                properties:
+                  bus-width:
+                    enum: [ 16, 18, 24 ]
+                    description:
+                      Specify the physical parallel bus width.
+
+                      This property is optional if the display bus-width
+                      matches the SoC bus-width, e.g. a 18-bit RGB666 (display)
+                      is connected and all 18-bit data lines are muxed to the
+                      parallel-output pads.
+
+                      This property must be set to 18 to cut only the LSBs
+                      instead of the MSBs in case a 24-bit RGB888 display is
+                      connected and only the lower 18-bit data lanes are muxed
+                      to the parallel-output pads.
+
+        required:
+          - port@0
+          - port@1
+
+    required:
+      - compatible
+      - ports
+
 allOf:
   - if:
       properties:
@@ -112,4 +164,30 @@ examples:
                clock-names = "apb", "axi", "nic", "disp", "cam",
                              "pxp", "lcdif", "isi", "csi", "dsi";
       #power-domain-cells = <1>;
+
+      dpi-bridge {
+        compatible = "nxp,imx93-pdfc";
+
+        ports {
+          #address-cells = <1>;
+          #size-cells = <0>;
+
+          port@0 {
+            reg = <0>;
+
+            pdfc_from_lcdif: endpoint {
+              remote-endpoint = <&lcdif_to_pdfc>;
+            };
+          };
+
+          port@1 {
+            reg = <1>;
+
+            pdfc_to_panel: endpoint {
+              remote-endpoint = <&panel_from_pdfc>;
+              bus-width = <18>;
+            };
+          };
+        };
+      };
     };

-- 
2.47.3


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

* [PATCH v11 2/3] drm/bridge: imx: Add i.MX93 parallel display format configuration support
  2026-03-03 10:34 [PATCH v11 0/3] Add i.MX91/93 parallel display support Marco Felsch
  2026-03-03 10:34 ` [PATCH v11 1/3] dt-bindings: soc: imx93-media-blk-ctrl: Add PDFC subnode to schema and example Marco Felsch
@ 2026-03-03 10:34 ` Marco Felsch
  2026-03-03 21:00   ` Frank Li
  2026-03-03 21:36   ` Claude review: " Claude Code Review Bot
  2026-03-03 10:34 ` [PATCH v11 3/3] arm64: dts: imx93: Add parallel display output nodes Marco Felsch
  2026-03-03 21:36 ` Claude review: Add i.MX91/93 parallel display support Claude Code Review Bot
  3 siblings, 2 replies; 15+ messages in thread
From: Marco Felsch @ 2026-03-03 10:34 UTC (permalink / raw)
  To: Rob Herring, Krzysztof Kozlowski, Conor Dooley, Shawn Guo,
	Sascha Hauer, Pengutronix Kernel Team, Fabio Estevam, Peng Fan,
	Liu Ying, Andrzej Hajda, Neil Armstrong, Robert Foss,
	Laurent Pinchart, Jonas Karlman, Jernej Skrabec,
	Maarten Lankhorst, Maxime Ripard, Thomas Zimmermann, David Airlie,
	Simona Vetter, luca.ceresoli, Frank Li
  Cc: devicetree, imx, linux-arm-kernel, linux-kernel, dri-devel,
	kernel, Marco Felsch

From: Liu Ying <victor.liu@nxp.com>

NXP i.MX93 mediamix blk-ctrl contains one DISPLAY_MUX register which
configures parallel display format by using the "PARALLEL_DISP_FORMAT"
field. Add a DRM bridge driver to support the display format configuration.

Reviewed-by: Luca Ceresoli <luca.ceresoli@bootlin.com>
Signed-off-by: Liu Ying <victor.liu@nxp.com>
[m.felsch@pengutronix.de: port to v7.0-rc1]
[m.felsch@pengutronix.de: add review feedback (Alexander)]
[m.felsch@pengutronix.de: fix to short Kconfig description (checkpath)]
[m.felsch@pengutronix.de: use "GPL" instead of "GPL v2" (checkpatch)]
[m.felsch@pengutronix.de: add bus-width support]
Signed-off-by: Marco Felsch <m.felsch@pengutronix.de>
---
 drivers/gpu/drm/bridge/imx/Kconfig      |  11 ++
 drivers/gpu/drm/bridge/imx/Makefile     |   1 +
 drivers/gpu/drm/bridge/imx/imx93-pdfc.c | 225 ++++++++++++++++++++++++++++++++
 3 files changed, 237 insertions(+)

diff --git a/drivers/gpu/drm/bridge/imx/Kconfig b/drivers/gpu/drm/bridge/imx/Kconfig
index b9028a5e5a065c3237b404111d8df57e8e017f9d..47829300a4486a090514ebe914b7667a703039a9 100644
--- a/drivers/gpu/drm/bridge/imx/Kconfig
+++ b/drivers/gpu/drm/bridge/imx/Kconfig
@@ -99,4 +99,15 @@ config DRM_IMX93_MIPI_DSI
 	  Choose this to enable MIPI DSI controller found in Freescale i.MX93
 	  processor.
 
+config DRM_IMX93_PARALLEL_DISP_FMT_CONVERTER
+	tristate "NXP i.MX91/i.MX93 parallel display format converter"
+	depends on OF
+	select DRM_KMS_HELPER
+	help
+	  On i.MX93 and i.MX91 SoCs the parallel display format output is
+	  controlled via the MEDIAMIX BLK-CTRL DISPLAY_MUX.
+
+	  Say 'Y' or 'M' if you use the parallel display output path on a
+	  i.MX93 or i.MX91 SoC.
+
 endif # ARCH_MXC || COMPILE_TEST
diff --git a/drivers/gpu/drm/bridge/imx/Makefile b/drivers/gpu/drm/bridge/imx/Makefile
index 8d01fda25451aaa1bf51a068da18948094327116..da57fde2d813b88cdde89115ca801b4cfc69afbd 100644
--- a/drivers/gpu/drm/bridge/imx/Makefile
+++ b/drivers/gpu/drm/bridge/imx/Makefile
@@ -9,3 +9,4 @@ obj-$(CONFIG_DRM_IMX8QXP_PIXEL_COMBINER) += imx8qxp-pixel-combiner.o
 obj-$(CONFIG_DRM_IMX8QXP_PIXEL_LINK) += imx8qxp-pixel-link.o
 obj-$(CONFIG_DRM_IMX8QXP_PIXEL_LINK_TO_DPI) += imx8qxp-pxl2dpi.o
 obj-$(CONFIG_DRM_IMX93_MIPI_DSI) += imx93-mipi-dsi.o
+obj-$(CONFIG_DRM_IMX93_PARALLEL_DISP_FMT_CONVERTER) += imx93-pdfc.o
diff --git a/drivers/gpu/drm/bridge/imx/imx93-pdfc.c b/drivers/gpu/drm/bridge/imx/imx93-pdfc.c
new file mode 100644
index 0000000000000000000000000000000000000000..27a54424319838517b206ab7d7447538aa1489eb
--- /dev/null
+++ b/drivers/gpu/drm/bridge/imx/imx93-pdfc.c
@@ -0,0 +1,225 @@
+// SPDX-License-Identifier: GPL-2.0+
+
+/*
+ * Copyright 2022-2025 NXP
+ */
+
+#include <linux/bitfield.h>
+#include <linux/bits.h>
+#include <linux/media-bus-format.h>
+#include <linux/mfd/syscon.h>
+#include <linux/module.h>
+#include <linux/of.h>
+#include <linux/of_graph.h>
+#include <linux/platform_device.h>
+#include <linux/regmap.h>
+
+#include <drm/drm_atomic_state_helper.h>
+#include <drm/drm_bridge.h>
+
+#define IMX93_DISPLAY_MUX_REG		0x60
+#define PARALLEL_DISP_FORMAT		GENMASK(10, 8)
+#define FORMAT_RGB888_TO_RGB888		FIELD_PREP(PARALLEL_DISP_FORMAT, 0)
+#define FORMAT_RGB888_TO_RGB666		FIELD_PREP(PARALLEL_DISP_FORMAT, 1)
+#define FORMAT_RGB565_TO_RGB565		FIELD_PREP(PARALLEL_DISP_FORMAT, 2)
+
+struct imx93_pdfc {
+	struct drm_bridge bridge;
+	struct device *dev;
+	struct regmap *regmap;
+	u32 phy_bus_width;
+};
+
+static struct imx93_pdfc *bridge_to_imx93_pdfc(struct drm_bridge *bridge)
+{
+	return container_of(bridge, struct imx93_pdfc, bridge);
+}
+
+static int
+imx93_pdfc_bridge_attach(struct drm_bridge *bridge, struct drm_encoder *encoder,
+			 enum drm_bridge_attach_flags flags)
+{
+	return drm_bridge_attach(bridge->encoder, bridge->next_bridge, bridge, flags);
+}
+
+static void imx93_pdfc_bridge_atomic_enable(struct drm_bridge *bridge,
+					    struct drm_atomic_state *state)
+{
+	struct imx93_pdfc *pdfc = bridge_to_imx93_pdfc(bridge);
+	const struct drm_bridge_state *bridge_state;
+	unsigned int mask = PARALLEL_DISP_FORMAT;
+	unsigned int val;
+
+	bridge_state = drm_atomic_get_new_bridge_state(state, bridge);
+
+	switch (bridge_state->output_bus_cfg.format) {
+	case MEDIA_BUS_FMT_RGB888_1X24:
+	case MEDIA_BUS_FMT_FIXED:
+		val = FORMAT_RGB888_TO_RGB888;
+		if (pdfc->phy_bus_width == 18) {
+			/*
+			 * Can be valid if physical bus limitation exists,
+			 * therefore use dev_dbg().
+			 */
+			dev_dbg(pdfc->dev, "Truncate two LSBs from each color\n");
+			val = FORMAT_RGB888_TO_RGB666;
+		}
+		break;
+	case MEDIA_BUS_FMT_RGB666_1X18:
+		val = FORMAT_RGB888_TO_RGB666;
+		break;
+	case MEDIA_BUS_FMT_RGB565_1X16:
+		val = FORMAT_RGB565_TO_RGB565;
+		break;
+	}
+
+	regmap_update_bits(pdfc->regmap, IMX93_DISPLAY_MUX_REG, mask, val);
+}
+
+/* TODO: Add YUV formats */
+static const u32 imx93_pdfc_bus_output_fmts[] = {
+	MEDIA_BUS_FMT_FIXED,
+	MEDIA_BUS_FMT_RGB888_1X24,
+	MEDIA_BUS_FMT_RGB666_1X18,
+	MEDIA_BUS_FMT_RGB565_1X16,
+};
+
+static bool imx93_pdfc_bus_output_fmt_supported(u32 fmt)
+{
+	int i;
+
+	for (i = 0; i < ARRAY_SIZE(imx93_pdfc_bus_output_fmts); i++) {
+		if (imx93_pdfc_bus_output_fmts[i] == fmt)
+			return true;
+	}
+
+	return false;
+}
+
+static u32 *
+imx93_pdfc_bridge_atomic_get_input_bus_fmts(struct drm_bridge *bridge,
+					    struct drm_bridge_state *bridge_state,
+					    struct drm_crtc_state *crtc_state,
+					    struct drm_connector_state *conn_state,
+					    u32 output_fmt,
+					    unsigned int *num_input_fmts)
+{
+	struct imx93_pdfc *pdfc = bridge_to_imx93_pdfc(bridge);
+	u32 *input_fmts;
+
+	*num_input_fmts = 0;
+
+	input_fmts = kmalloc_obj(*input_fmts);
+	if (!input_fmts)
+		return NULL;
+
+	*num_input_fmts = 1;
+
+	if (!imx93_pdfc_bus_output_fmt_supported(output_fmt)) {
+		dev_dbg(pdfc->dev, "No valid output bus-fmt detected, fallback to MEDIA_BUS_FMT_RGB888_1X24\n");
+		input_fmts[0] = MEDIA_BUS_FMT_RGB888_1X24;
+		return input_fmts;
+	}
+
+	switch (output_fmt) {
+	case MEDIA_BUS_FMT_RGB888_1X24:
+	case MEDIA_BUS_FMT_RGB565_1X16:
+		input_fmts[0] = output_fmt;
+		break;
+	case MEDIA_BUS_FMT_RGB666_1X18:
+	case MEDIA_BUS_FMT_FIXED:
+		input_fmts[0] = MEDIA_BUS_FMT_RGB888_1X24;
+		break;
+	}
+
+	return input_fmts;
+}
+
+static int imx93_pdfc_bridge_atomic_check(struct drm_bridge *bridge,
+					  struct drm_bridge_state *bridge_state,
+					  struct drm_crtc_state *crtc_state,
+					  struct drm_connector_state *conn_state)
+{
+	struct imx93_pdfc *pdfc = bridge_to_imx93_pdfc(bridge);
+	u32 format = bridge_state->output_bus_cfg.format;
+
+	if (imx93_pdfc_bus_output_fmt_supported(format))
+		return 0;
+
+	dev_warn(pdfc->dev, "Unsupported output bus format: 0x%x\n", format);
+
+	return -EINVAL;
+}
+
+static const struct drm_bridge_funcs funcs = {
+	.attach			= imx93_pdfc_bridge_attach,
+	.atomic_enable		= imx93_pdfc_bridge_atomic_enable,
+	.atomic_duplicate_state	= drm_atomic_helper_bridge_duplicate_state,
+	.atomic_destroy_state	= drm_atomic_helper_bridge_destroy_state,
+	.atomic_get_input_bus_fmts	= imx93_pdfc_bridge_atomic_get_input_bus_fmts,
+	.atomic_check		= imx93_pdfc_bridge_atomic_check,
+	.atomic_reset		= drm_atomic_helper_bridge_reset,
+};
+
+static int imx93_pdfc_bridge_probe(struct platform_device *pdev)
+{
+	struct device *dev = &pdev->dev;
+	struct drm_bridge *next_bridge;
+	struct imx93_pdfc *pdfc;
+	struct device_node *ep;
+	int err;
+
+	pdfc = devm_drm_bridge_alloc(dev, struct imx93_pdfc, bridge, &funcs);
+	if (IS_ERR(pdfc))
+		return PTR_ERR(pdfc);
+
+	pdfc->regmap = syscon_node_to_regmap(dev->of_node->parent);
+	if (IS_ERR(pdfc->regmap))
+		return dev_err_probe(dev, PTR_ERR(pdfc->regmap),
+				     "failed to get regmap\n");
+
+	/* No limits per default */
+	pdfc->phy_bus_width = 24;
+
+	/* Get output ep (port1/endpoint) */
+	ep = of_graph_get_endpoint_by_regs(dev->of_node, 1, -1);
+	if (ep) {
+		err = of_property_read_u32(ep, "bus-width", &pdfc->phy_bus_width);
+		of_node_put(ep);
+
+		/* bus-width is optional but it must have valid data if present */
+		if (err && err != -EINVAL)
+			return dev_err_probe(dev, err,
+					     "failed to query bus-width\n");
+	}
+
+	next_bridge = devm_drm_of_get_bridge(dev, dev->of_node, 1, 0);
+	if (IS_ERR(next_bridge))
+		return dev_err_probe(dev, PTR_ERR(next_bridge),
+				     "failed to get next bridge\n");
+	pdfc->dev = dev;
+	pdfc->bridge.of_node = dev->of_node;
+	pdfc->bridge.type = DRM_MODE_CONNECTOR_DPI;
+	pdfc->bridge.next_bridge = next_bridge;
+
+	return devm_drm_bridge_add(dev, &pdfc->bridge);
+}
+
+static const struct of_device_id imx93_pdfc_dt_ids[] = {
+	{ .compatible = "nxp,imx93-pdfc", },
+	{ /* sentinel */ }
+};
+MODULE_DEVICE_TABLE(of, imx93_pdfc_dt_ids);
+
+static struct platform_driver imx93_pdfc_bridge_driver = {
+	.probe	= imx93_pdfc_bridge_probe,
+	.driver	= {
+		.of_match_table = imx93_pdfc_dt_ids,
+		.name = "imx93_pdfc",
+	},
+};
+module_platform_driver(imx93_pdfc_bridge_driver);
+
+MODULE_DESCRIPTION("NXP i.MX93 parallel display format configuration driver");
+MODULE_AUTHOR("Liu Ying <victor.liu@nxp.com>");
+MODULE_LICENSE("GPL");

-- 
2.47.3


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

* [PATCH v11 3/3] arm64: dts: imx93: Add parallel display output nodes
  2026-03-03 10:34 [PATCH v11 0/3] Add i.MX91/93 parallel display support Marco Felsch
  2026-03-03 10:34 ` [PATCH v11 1/3] dt-bindings: soc: imx93-media-blk-ctrl: Add PDFC subnode to schema and example Marco Felsch
  2026-03-03 10:34 ` [PATCH v11 2/3] drm/bridge: imx: Add i.MX93 parallel display format configuration support Marco Felsch
@ 2026-03-03 10:34 ` Marco Felsch
  2026-03-03 10:42   ` Marco Felsch
  2026-03-03 21:36   ` Claude review: " Claude Code Review Bot
  2026-03-03 21:36 ` Claude review: Add i.MX91/93 parallel display support Claude Code Review Bot
  3 siblings, 2 replies; 15+ messages in thread
From: Marco Felsch @ 2026-03-03 10:34 UTC (permalink / raw)
  To: Rob Herring, Krzysztof Kozlowski, Conor Dooley, Shawn Guo,
	Sascha Hauer, Pengutronix Kernel Team, Fabio Estevam, Peng Fan,
	Liu Ying, Andrzej Hajda, Neil Armstrong, Robert Foss,
	Laurent Pinchart, Jonas Karlman, Jernej Skrabec,
	Maarten Lankhorst, Maxime Ripard, Thomas Zimmermann, David Airlie,
	Simona Vetter, luca.ceresoli, Frank Li
  Cc: devicetree, imx, linux-arm-kernel, linux-kernel, dri-devel,
	kernel, Marco Felsch

Add required OF nodes to support the i.MX93 parallel output (DPI) path.

On the i.MX93 a single LCDIF is connected to three bridges: DPI, LVDS
LDB and the MIPI-DSI whereas the i.MX91 support only the DPI bridge.

Map endpoint@0 as DPI bridge output since the i.MX93 TRM (Figure 485.
MEDIAMIX block diagram) doesn't mention any port-number <-> bridge
combination.

Set the MEDIA-AXI and MEDIA-APB clocks to the overdrive (OD) values
since the i.MX93 and i.MX91 use the overdrive (OD) clk settings per
default.

Signed-off-by: Marco Felsch <m.felsch@pengutronix.de>
---
 arch/arm64/boot/dts/freescale/imx91_93_common.dtsi | 54 ++++++++++++++++++++++
 arch/arm64/boot/dts/freescale/imx93.dtsi           | 12 +++++
 2 files changed, 66 insertions(+)

diff --git a/arch/arm64/boot/dts/freescale/imx91_93_common.dtsi b/arch/arm64/boot/dts/freescale/imx91_93_common.dtsi
index 7958cef353766a430df5e626ff2403dc05a974b1..5a8813df6bc993d559fb0b20fc742a106bfe6315 100644
--- a/arch/arm64/boot/dts/freescale/imx91_93_common.dtsi
+++ b/arch/arm64/boot/dts/freescale/imx91_93_common.dtsi
@@ -1122,8 +1122,62 @@ media_blk_ctrl: system-controller@4ac10000 {
 				 <&clk IMX93_CLK_MIPI_DSI_GATE>;
 			clock-names = "apb", "axi", "nic", "disp", "cam",
 				      "pxp", "lcdif", "isi", "csi", "dsi";
+			assigned-clocks = <&clk IMX93_CLK_MEDIA_AXI>,
+					  <&clk IMX93_CLK_MEDIA_APB>,
+					  <&clk IMX93_CLK_MEDIA_DISP_PIX>;
+			assigned-clock-parents = <&clk IMX93_CLK_SYS_PLL_PFD1>,
+						 <&clk IMX93_CLK_SYS_PLL_PFD1_DIV2>,
+						 <&clk IMX93_CLK_VIDEO_PLL>;
+			assigned-clock-rates = <400000000>, <133333333>;
 			#power-domain-cells = <1>;
 			status = "disabled";
+
+			dpi_bridge: dpi-bridge {
+				compatible = "nxp,imx93-pdfc";
+				status = "disabled";
+
+				ports {
+					#address-cells = <1>;
+					#size-cells = <0>;
+
+					port@0 {
+						reg = <0>;
+
+						dpi_from_lcdif: endpoint {
+							remote-endpoint = <&lcdif_to_dpi>;
+						};
+					};
+
+					port@1 {
+						reg = <1>;
+
+						dpi_to_panel: endpoint {
+						};
+					};
+				};
+			};
+		};
+
+		lcdif: display-controller@4ae30000 {
+			compatible = "fsl,imx93-lcdif";
+			reg = <0x4ae30000 0x23c>;
+			interrupts = <GIC_SPI 176 IRQ_TYPE_LEVEL_HIGH>;
+			clocks = <&clk IMX93_CLK_MEDIA_DISP_PIX>,
+				 <&clk IMX93_CLK_LCDIF_GATE>,
+				 <&clk IMX93_CLK_MEDIA_AXI>;
+			clock-names = "pix", "axi", "disp_axi";
+			power-domains = <&media_blk_ctrl IMX93_MEDIABLK_PD_LCDIF>;
+			status = "disabled";
+
+			port {
+				#address-cells = <1>;
+				#size-cells = <0>;
+
+				lcdif_to_dpi: endpoint@0 {
+					reg = <0>;
+					remote-endpoint = <&dpi_from_lcdif>;
+				};
+			};
 		};
 
 		usbotg1: usb@4c100000 {
diff --git a/arch/arm64/boot/dts/freescale/imx93.dtsi b/arch/arm64/boot/dts/freescale/imx93.dtsi
index 7b27012dfcb564650882dc8c40e836e797b2fda1..5436b48b30e89eb1f939b398ce1bf105abe7e34b 100644
--- a/arch/arm64/boot/dts/freescale/imx93.dtsi
+++ b/arch/arm64/boot/dts/freescale/imx93.dtsi
@@ -150,6 +150,18 @@ l3_cache: l3-cache {
 	};
 };
 
+&lcdif {
+	port {
+		lcdif_to_ldb: endpoint@1 {
+			reg = <1>;
+		};
+
+		lcdif_to_dsi: endpoint@2 {
+			reg = <2>;
+		};
+	};
+};
+
 &src {
 	mlmix: power-domain@44461800 {
 		compatible = "fsl,imx93-src-slice";

-- 
2.47.3


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

* Re: [PATCH v11 3/3] arm64: dts: imx93: Add parallel display output nodes
  2026-03-03 10:34 ` [PATCH v11 3/3] arm64: dts: imx93: Add parallel display output nodes Marco Felsch
@ 2026-03-03 10:42   ` Marco Felsch
  2026-03-03 15:45     ` Frank Li
  2026-03-03 21:36   ` Claude review: " Claude Code Review Bot
  1 sibling, 1 reply; 15+ messages in thread
From: Marco Felsch @ 2026-03-03 10:42 UTC (permalink / raw)
  To: Rob Herring, Krzysztof Kozlowski, Conor Dooley, Shawn Guo,
	Sascha Hauer, Pengutronix Kernel Team, Fabio Estevam, Peng Fan,
	Liu Ying, Andrzej Hajda, Neil Armstrong, Robert Foss,
	Laurent Pinchart, Jonas Karlman, Jernej Skrabec,
	Maarten Lankhorst, Maxime Ripard, Thomas Zimmermann, David Airlie,
	Simona Vetter, luca.ceresoli, Frank Li
  Cc: devicetree, imx, linux-arm-kernel, linux-kernel, dri-devel

Hi Frank,

On 26-03-03, Marco Felsch wrote:
> Add required OF nodes to support the i.MX93 parallel output (DPI) path.
> 
> On the i.MX93 a single LCDIF is connected to three bridges: DPI, LVDS
> LDB and the MIPI-DSI whereas the i.MX91 support only the DPI bridge.
> 
> Map endpoint@0 as DPI bridge output since the i.MX93 TRM (Figure 485.
> MEDIAMIX block diagram) doesn't mention any port-number <-> bridge
> combination.
> 
> Set the MEDIA-AXI and MEDIA-APB clocks to the overdrive (OD) values
> since the i.MX93 and i.MX91 use the overdrive (OD) clk settings per
> default.
> 
> Signed-off-by: Marco Felsch <m.felsch@pengutronix.de>

Please ignore this particular patch since you already applied this one.

Next time we should align the apply with the rest of the patch series if
dt-bindings and driver behaviors are involved. In such case the final
integration patch should be merged at the end and not at the beginning
:)

Thanks,
  Marco

> ---
>  arch/arm64/boot/dts/freescale/imx91_93_common.dtsi | 54 ++++++++++++++++++++++
>  arch/arm64/boot/dts/freescale/imx93.dtsi           | 12 +++++
>  2 files changed, 66 insertions(+)
> 
> diff --git a/arch/arm64/boot/dts/freescale/imx91_93_common.dtsi b/arch/arm64/boot/dts/freescale/imx91_93_common.dtsi
> index 7958cef353766a430df5e626ff2403dc05a974b1..5a8813df6bc993d559fb0b20fc742a106bfe6315 100644
> --- a/arch/arm64/boot/dts/freescale/imx91_93_common.dtsi
> +++ b/arch/arm64/boot/dts/freescale/imx91_93_common.dtsi
> @@ -1122,8 +1122,62 @@ media_blk_ctrl: system-controller@4ac10000 {
>  				 <&clk IMX93_CLK_MIPI_DSI_GATE>;
>  			clock-names = "apb", "axi", "nic", "disp", "cam",
>  				      "pxp", "lcdif", "isi", "csi", "dsi";
> +			assigned-clocks = <&clk IMX93_CLK_MEDIA_AXI>,
> +					  <&clk IMX93_CLK_MEDIA_APB>,
> +					  <&clk IMX93_CLK_MEDIA_DISP_PIX>;
> +			assigned-clock-parents = <&clk IMX93_CLK_SYS_PLL_PFD1>,
> +						 <&clk IMX93_CLK_SYS_PLL_PFD1_DIV2>,
> +						 <&clk IMX93_CLK_VIDEO_PLL>;
> +			assigned-clock-rates = <400000000>, <133333333>;
>  			#power-domain-cells = <1>;
>  			status = "disabled";
> +
> +			dpi_bridge: dpi-bridge {
> +				compatible = "nxp,imx93-pdfc";
> +				status = "disabled";
> +
> +				ports {
> +					#address-cells = <1>;
> +					#size-cells = <0>;
> +
> +					port@0 {
> +						reg = <0>;
> +
> +						dpi_from_lcdif: endpoint {
> +							remote-endpoint = <&lcdif_to_dpi>;
> +						};
> +					};
> +
> +					port@1 {
> +						reg = <1>;
> +
> +						dpi_to_panel: endpoint {
> +						};
> +					};
> +				};
> +			};
> +		};
> +
> +		lcdif: display-controller@4ae30000 {
> +			compatible = "fsl,imx93-lcdif";
> +			reg = <0x4ae30000 0x23c>;
> +			interrupts = <GIC_SPI 176 IRQ_TYPE_LEVEL_HIGH>;
> +			clocks = <&clk IMX93_CLK_MEDIA_DISP_PIX>,
> +				 <&clk IMX93_CLK_LCDIF_GATE>,
> +				 <&clk IMX93_CLK_MEDIA_AXI>;
> +			clock-names = "pix", "axi", "disp_axi";
> +			power-domains = <&media_blk_ctrl IMX93_MEDIABLK_PD_LCDIF>;
> +			status = "disabled";
> +
> +			port {
> +				#address-cells = <1>;
> +				#size-cells = <0>;
> +
> +				lcdif_to_dpi: endpoint@0 {
> +					reg = <0>;
> +					remote-endpoint = <&dpi_from_lcdif>;
> +				};
> +			};
>  		};
>  
>  		usbotg1: usb@4c100000 {
> diff --git a/arch/arm64/boot/dts/freescale/imx93.dtsi b/arch/arm64/boot/dts/freescale/imx93.dtsi
> index 7b27012dfcb564650882dc8c40e836e797b2fda1..5436b48b30e89eb1f939b398ce1bf105abe7e34b 100644
> --- a/arch/arm64/boot/dts/freescale/imx93.dtsi
> +++ b/arch/arm64/boot/dts/freescale/imx93.dtsi
> @@ -150,6 +150,18 @@ l3_cache: l3-cache {
>  	};
>  };
>  
> +&lcdif {
> +	port {
> +		lcdif_to_ldb: endpoint@1 {
> +			reg = <1>;
> +		};
> +
> +		lcdif_to_dsi: endpoint@2 {
> +			reg = <2>;
> +		};
> +	};
> +};
> +
>  &src {
>  	mlmix: power-domain@44461800 {
>  		compatible = "fsl,imx93-src-slice";
> 
> -- 
> 2.47.3
> 

-- 
#gernperDu 
#CallMeByMyFirstName

Pengutronix e.K.                           |                             |
Steuerwalder Str. 21                       | https://www.pengutronix.de/ |
31137 Hildesheim, Germany                  | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-9    |

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

* Re: [PATCH v11 3/3] arm64: dts: imx93: Add parallel display output nodes
  2026-03-03 10:42   ` Marco Felsch
@ 2026-03-03 15:45     ` Frank Li
  2026-03-03 15:50       ` Marco Felsch
  0 siblings, 1 reply; 15+ messages in thread
From: Frank Li @ 2026-03-03 15:45 UTC (permalink / raw)
  To: Marco Felsch
  Cc: Rob Herring, Krzysztof Kozlowski, Conor Dooley, Shawn Guo,
	Sascha Hauer, Pengutronix Kernel Team, Fabio Estevam, Peng Fan,
	Liu Ying, Andrzej Hajda, Neil Armstrong, Robert Foss,
	Laurent Pinchart, Jonas Karlman, Jernej Skrabec,
	Maarten Lankhorst, Maxime Ripard, Thomas Zimmermann, David Airlie,
	Simona Vetter, luca.ceresoli, devicetree, imx, linux-arm-kernel,
	linux-kernel, dri-devel

On Tue, Mar 03, 2026 at 11:42:08AM +0100, Marco Felsch wrote:
> Hi Frank,
>
> On 26-03-03, Marco Felsch wrote:
> > Add required OF nodes to support the i.MX93 parallel output (DPI) path.
> >
> > On the i.MX93 a single LCDIF is connected to three bridges: DPI, LVDS
> > LDB and the MIPI-DSI whereas the i.MX91 support only the DPI bridge.
> >
> > Map endpoint@0 as DPI bridge output since the i.MX93 TRM (Figure 485.
> > MEDIAMIX block diagram) doesn't mention any port-number <-> bridge
> > combination.
> >
> > Set the MEDIA-AXI and MEDIA-APB clocks to the overdrive (OD) values
> > since the i.MX93 and i.MX91 use the overdrive (OD) clk settings per
> > default.
> >
> > Signed-off-by: Marco Felsch <m.felsch@pengutronix.de>
>
> Please ignore this particular patch since you already applied this one.

You can skip these when you post new version. post delta if need update,
I can squash to previous patch as need.

>
> Next time we should align the apply with the rest of the patch series if
> dt-bindings and driver behaviors are involved. In such case the final
> integration patch should be merged at the end and not at the beginning
> :)

You request apply at :)
https://lore.kernel.org/all/fl2br7rtcjrjj2uqxva7ai3xbvjwrrbbl2ruaoqolrccr2rd5p@z33qfx7dpavf/

Frank
>
> Thanks,
>   Marco
>
> > ---
> >  arch/arm64/boot/dts/freescale/imx91_93_common.dtsi | 54 ++++++++++++++++++++++
> >  arch/arm64/boot/dts/freescale/imx93.dtsi           | 12 +++++
> >  2 files changed, 66 insertions(+)
> >
> > diff --git a/arch/arm64/boot/dts/freescale/imx91_93_common.dtsi b/arch/arm64/boot/dts/freescale/imx91_93_common.dtsi
> > index 7958cef353766a430df5e626ff2403dc05a974b1..5a8813df6bc993d559fb0b20fc742a106bfe6315 100644
> > --- a/arch/arm64/boot/dts/freescale/imx91_93_common.dtsi
> > +++ b/arch/arm64/boot/dts/freescale/imx91_93_common.dtsi
> > @@ -1122,8 +1122,62 @@ media_blk_ctrl: system-controller@4ac10000 {
> >  				 <&clk IMX93_CLK_MIPI_DSI_GATE>;
> >  			clock-names = "apb", "axi", "nic", "disp", "cam",
> >  				      "pxp", "lcdif", "isi", "csi", "dsi";
> > +			assigned-clocks = <&clk IMX93_CLK_MEDIA_AXI>,
> > +					  <&clk IMX93_CLK_MEDIA_APB>,
> > +					  <&clk IMX93_CLK_MEDIA_DISP_PIX>;
> > +			assigned-clock-parents = <&clk IMX93_CLK_SYS_PLL_PFD1>,
> > +						 <&clk IMX93_CLK_SYS_PLL_PFD1_DIV2>,
> > +						 <&clk IMX93_CLK_VIDEO_PLL>;
> > +			assigned-clock-rates = <400000000>, <133333333>;
> >  			#power-domain-cells = <1>;
> >  			status = "disabled";
> > +
> > +			dpi_bridge: dpi-bridge {
> > +				compatible = "nxp,imx93-pdfc";
> > +				status = "disabled";
> > +
> > +				ports {
> > +					#address-cells = <1>;
> > +					#size-cells = <0>;
> > +
> > +					port@0 {
> > +						reg = <0>;
> > +
> > +						dpi_from_lcdif: endpoint {
> > +							remote-endpoint = <&lcdif_to_dpi>;
> > +						};
> > +					};
> > +
> > +					port@1 {
> > +						reg = <1>;
> > +
> > +						dpi_to_panel: endpoint {
> > +						};
> > +					};
> > +				};
> > +			};
> > +		};
> > +
> > +		lcdif: display-controller@4ae30000 {
> > +			compatible = "fsl,imx93-lcdif";
> > +			reg = <0x4ae30000 0x23c>;
> > +			interrupts = <GIC_SPI 176 IRQ_TYPE_LEVEL_HIGH>;
> > +			clocks = <&clk IMX93_CLK_MEDIA_DISP_PIX>,
> > +				 <&clk IMX93_CLK_LCDIF_GATE>,
> > +				 <&clk IMX93_CLK_MEDIA_AXI>;
> > +			clock-names = "pix", "axi", "disp_axi";
> > +			power-domains = <&media_blk_ctrl IMX93_MEDIABLK_PD_LCDIF>;
> > +			status = "disabled";
> > +
> > +			port {
> > +				#address-cells = <1>;
> > +				#size-cells = <0>;
> > +
> > +				lcdif_to_dpi: endpoint@0 {
> > +					reg = <0>;
> > +					remote-endpoint = <&dpi_from_lcdif>;
> > +				};
> > +			};
> >  		};
> >
> >  		usbotg1: usb@4c100000 {
> > diff --git a/arch/arm64/boot/dts/freescale/imx93.dtsi b/arch/arm64/boot/dts/freescale/imx93.dtsi
> > index 7b27012dfcb564650882dc8c40e836e797b2fda1..5436b48b30e89eb1f939b398ce1bf105abe7e34b 100644
> > --- a/arch/arm64/boot/dts/freescale/imx93.dtsi
> > +++ b/arch/arm64/boot/dts/freescale/imx93.dtsi
> > @@ -150,6 +150,18 @@ l3_cache: l3-cache {
> >  	};
> >  };
> >
> > +&lcdif {
> > +	port {
> > +		lcdif_to_ldb: endpoint@1 {
> > +			reg = <1>;
> > +		};
> > +
> > +		lcdif_to_dsi: endpoint@2 {
> > +			reg = <2>;
> > +		};
> > +	};
> > +};
> > +
> >  &src {
> >  	mlmix: power-domain@44461800 {
> >  		compatible = "fsl,imx93-src-slice";
> >
> > --
> > 2.47.3
> >
>
> --
> #gernperDu
> #CallMeByMyFirstName
>
> Pengutronix e.K.                           |                             |
> Steuerwalder Str. 21                       | https://www.pengutronix.de/ |
> 31137 Hildesheim, Germany                  | Phone: +49-5121-206917-0    |
> Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-9    |

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

* Re: [PATCH v11 3/3] arm64: dts: imx93: Add parallel display output nodes
  2026-03-03 15:45     ` Frank Li
@ 2026-03-03 15:50       ` Marco Felsch
  0 siblings, 0 replies; 15+ messages in thread
From: Marco Felsch @ 2026-03-03 15:50 UTC (permalink / raw)
  To: Frank Li
  Cc: Rob Herring, Krzysztof Kozlowski, Conor Dooley, Shawn Guo,
	Sascha Hauer, Pengutronix Kernel Team, Fabio Estevam, Peng Fan,
	Liu Ying, Andrzej Hajda, Neil Armstrong, Robert Foss,
	Laurent Pinchart, Jonas Karlman, Jernej Skrabec,
	Maarten Lankhorst, Maxime Ripard, Thomas Zimmermann, David Airlie,
	Simona Vetter, luca.ceresoli, devicetree, imx, linux-arm-kernel,
	linux-kernel, dri-devel

On 26-03-03, Frank Li wrote:
> On Tue, Mar 03, 2026 at 11:42:08AM +0100, Marco Felsch wrote:
> > Hi Frank,
> >
> > On 26-03-03, Marco Felsch wrote:
> > > Add required OF nodes to support the i.MX93 parallel output (DPI) path.
> > >
> > > On the i.MX93 a single LCDIF is connected to three bridges: DPI, LVDS
> > > LDB and the MIPI-DSI whereas the i.MX91 support only the DPI bridge.
> > >
> > > Map endpoint@0 as DPI bridge output since the i.MX93 TRM (Figure 485.
> > > MEDIAMIX block diagram) doesn't mention any port-number <-> bridge
> > > combination.
> > >
> > > Set the MEDIA-AXI and MEDIA-APB clocks to the overdrive (OD) values
> > > since the i.MX93 and i.MX91 use the overdrive (OD) clk settings per
> > > default.
> > >
> > > Signed-off-by: Marco Felsch <m.felsch@pengutronix.de>
> >
> > Please ignore this particular patch since you already applied this one.
> 
> You can skip these when you post new version. post delta if need update,
> I can squash to previous patch as need.
> 
> >
> > Next time we should align the apply with the rest of the patch series if
> > dt-bindings and driver behaviors are involved. In such case the final
> > integration patch should be merged at the end and not at the beginning
> > :)
> 
> You request apply at :)
> https://lore.kernel.org/all/fl2br7rtcjrjj2uqxva7ai3xbvjwrrbbl2ruaoqolrccr2rd5p@z33qfx7dpavf/

I meant the whole series :) Although I'm unaware which maintainer is
taken which part. Sorry for causing troubles on your site. However if
you would try to apply this on your tree, git would have told you that
nothing needs to be applied because this patch is untouched.

Regards,
  Marco

> 
> Frank
> >
> > Thanks,
> >   Marco
> >
> > > ---
> > >  arch/arm64/boot/dts/freescale/imx91_93_common.dtsi | 54 ++++++++++++++++++++++
> > >  arch/arm64/boot/dts/freescale/imx93.dtsi           | 12 +++++
> > >  2 files changed, 66 insertions(+)
> > >
> > > diff --git a/arch/arm64/boot/dts/freescale/imx91_93_common.dtsi b/arch/arm64/boot/dts/freescale/imx91_93_common.dtsi
> > > index 7958cef353766a430df5e626ff2403dc05a974b1..5a8813df6bc993d559fb0b20fc742a106bfe6315 100644
> > > --- a/arch/arm64/boot/dts/freescale/imx91_93_common.dtsi
> > > +++ b/arch/arm64/boot/dts/freescale/imx91_93_common.dtsi
> > > @@ -1122,8 +1122,62 @@ media_blk_ctrl: system-controller@4ac10000 {
> > >  				 <&clk IMX93_CLK_MIPI_DSI_GATE>;
> > >  			clock-names = "apb", "axi", "nic", "disp", "cam",
> > >  				      "pxp", "lcdif", "isi", "csi", "dsi";
> > > +			assigned-clocks = <&clk IMX93_CLK_MEDIA_AXI>,
> > > +					  <&clk IMX93_CLK_MEDIA_APB>,
> > > +					  <&clk IMX93_CLK_MEDIA_DISP_PIX>;
> > > +			assigned-clock-parents = <&clk IMX93_CLK_SYS_PLL_PFD1>,
> > > +						 <&clk IMX93_CLK_SYS_PLL_PFD1_DIV2>,
> > > +						 <&clk IMX93_CLK_VIDEO_PLL>;
> > > +			assigned-clock-rates = <400000000>, <133333333>;
> > >  			#power-domain-cells = <1>;
> > >  			status = "disabled";
> > > +
> > > +			dpi_bridge: dpi-bridge {
> > > +				compatible = "nxp,imx93-pdfc";
> > > +				status = "disabled";
> > > +
> > > +				ports {
> > > +					#address-cells = <1>;
> > > +					#size-cells = <0>;
> > > +
> > > +					port@0 {
> > > +						reg = <0>;
> > > +
> > > +						dpi_from_lcdif: endpoint {
> > > +							remote-endpoint = <&lcdif_to_dpi>;
> > > +						};
> > > +					};
> > > +
> > > +					port@1 {
> > > +						reg = <1>;
> > > +
> > > +						dpi_to_panel: endpoint {
> > > +						};
> > > +					};
> > > +				};
> > > +			};
> > > +		};
> > > +
> > > +		lcdif: display-controller@4ae30000 {
> > > +			compatible = "fsl,imx93-lcdif";
> > > +			reg = <0x4ae30000 0x23c>;
> > > +			interrupts = <GIC_SPI 176 IRQ_TYPE_LEVEL_HIGH>;
> > > +			clocks = <&clk IMX93_CLK_MEDIA_DISP_PIX>,
> > > +				 <&clk IMX93_CLK_LCDIF_GATE>,
> > > +				 <&clk IMX93_CLK_MEDIA_AXI>;
> > > +			clock-names = "pix", "axi", "disp_axi";
> > > +			power-domains = <&media_blk_ctrl IMX93_MEDIABLK_PD_LCDIF>;
> > > +			status = "disabled";
> > > +
> > > +			port {
> > > +				#address-cells = <1>;
> > > +				#size-cells = <0>;
> > > +
> > > +				lcdif_to_dpi: endpoint@0 {
> > > +					reg = <0>;
> > > +					remote-endpoint = <&dpi_from_lcdif>;
> > > +				};
> > > +			};
> > >  		};
> > >
> > >  		usbotg1: usb@4c100000 {
> > > diff --git a/arch/arm64/boot/dts/freescale/imx93.dtsi b/arch/arm64/boot/dts/freescale/imx93.dtsi
> > > index 7b27012dfcb564650882dc8c40e836e797b2fda1..5436b48b30e89eb1f939b398ce1bf105abe7e34b 100644
> > > --- a/arch/arm64/boot/dts/freescale/imx93.dtsi
> > > +++ b/arch/arm64/boot/dts/freescale/imx93.dtsi
> > > @@ -150,6 +150,18 @@ l3_cache: l3-cache {
> > >  	};
> > >  };
> > >
> > > +&lcdif {
> > > +	port {
> > > +		lcdif_to_ldb: endpoint@1 {
> > > +			reg = <1>;
> > > +		};
> > > +
> > > +		lcdif_to_dsi: endpoint@2 {
> > > +			reg = <2>;
> > > +		};
> > > +	};
> > > +};
> > > +
> > >  &src {
> > >  	mlmix: power-domain@44461800 {
> > >  		compatible = "fsl,imx93-src-slice";
> > >
> > > --
> > > 2.47.3
> > >
> >
> > --
> > #gernperDu
> > #CallMeByMyFirstName
> >
> > Pengutronix e.K.                           |                             |
> > Steuerwalder Str. 21                       | https://www.pengutronix.de/ |
> > 31137 Hildesheim, Germany                  | Phone: +49-5121-206917-0    |
> > Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-9    |
> 

-- 
#gernperDu 
#CallMeByMyFirstName

Pengutronix e.K.                           |                             |
Steuerwalder Str. 21                       | https://www.pengutronix.de/ |
31137 Hildesheim, Germany                  | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-9    |

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

* Re: [PATCH v11 1/3] dt-bindings: soc: imx93-media-blk-ctrl: Add PDFC subnode to schema and example
  2026-03-03 10:34 ` [PATCH v11 1/3] dt-bindings: soc: imx93-media-blk-ctrl: Add PDFC subnode to schema and example Marco Felsch
@ 2026-03-03 21:00   ` Frank Li
  2026-03-03 21:36   ` Claude review: " Claude Code Review Bot
  1 sibling, 0 replies; 15+ messages in thread
From: Frank Li @ 2026-03-03 21:00 UTC (permalink / raw)
  To: Rob Herring, Krzysztof Kozlowski, Conor Dooley, Shawn Guo,
	Sascha Hauer, Pengutronix Kernel Team, Fabio Estevam, Peng Fan,
	Liu Ying, Andrzej Hajda, Neil Armstrong, Robert Foss,
	Laurent Pinchart, Jonas Karlman, Jernej Skrabec,
	Maarten Lankhorst, Maxime Ripard, Thomas Zimmermann, David Airlie,
	Simona Vetter, luca.ceresoli, Frank Li
  Cc: Frank Li, devicetree, imx, linux-arm-kernel, linux-kernel,
	dri-devel, Marco Felsch

From: Frank Li (AI-BOT) <frank.li@nxp.com>

AI bot review and may be useless.

This is a device tree bindings patch, not kernel C code. The YAML
schema additions look structurally sound. A few observations:

> +  dpi-bridge:
> +    type: object
> +    additionalProperties: false
> +
> +    properties:
> +      compatible:
> +        enum:
> +          - nxp,imx91-pdfc
> +          - nxp,imx93-pdfc

The compatible strings should be documented in a separate vendor
prefix file (nxp.yaml) if not already present. Verify they exist
in Documentation/devicetree/bindings/vendor-prefixes.yaml.

> +      ports:
> +        $ref: /schemas/graph.yaml#/properties/ports
> +
> +        properties:
> +          port@0:
> +            $ref: /schemas/graph.yaml#/properties/port
> +            description: Input port node to receive pixel data.
> +
> +          port@1:
> +            $ref: /schemas/graph.yaml#/$defs/port-base
> +            unevaluatedProperties: false

The port@0 and port@1 both reference graph.yaml but use slightly
different schemas ($defs/port-base vs #/properties/port). Ensure
this inconsistency is intentional; typically both would use the
same reference unless port@1 has special constraints.

> +                properties:
> +                  bus-width:
> +                    enum: [ 16, 18, 24 ]

Line length is acceptable. The bus-width enum values are clear.

> +                      This property must be set to 18 to cut only the LSBs
> +                      instead of the MSBs in case a 24-bit RGB888 display is
> +                      connected and only the lower 18-bit data lanes are muxed
> +                      to the parallel-output pads.

Documentation is thorough and explains the non-obvious behavior
(LSB vs MSB truncation). Good.

Overall: schema is well-structured, example is complete, and
documentation is clear. No blocking issues detected.

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

* Re: [PATCH v11 2/3] drm/bridge: imx: Add i.MX93 parallel display format configuration support
  2026-03-03 10:34 ` [PATCH v11 2/3] drm/bridge: imx: Add i.MX93 parallel display format configuration support Marco Felsch
@ 2026-03-03 21:00   ` Frank Li
  2026-03-03 21:22     ` Marco Felsch
  2026-03-03 21:36   ` Claude review: " Claude Code Review Bot
  1 sibling, 1 reply; 15+ messages in thread
From: Frank Li @ 2026-03-03 21:00 UTC (permalink / raw)
  To: Rob Herring, Krzysztof Kozlowski, Conor Dooley, Shawn Guo,
	Sascha Hauer, Pengutronix Kernel Team, Fabio Estevam, Peng Fan,
	Liu Ying, Andrzej Hajda, Neil Armstrong, Robert Foss,
	Laurent Pinchart, Jonas Karlman, Jernej Skrabec,
	Maarten Lankhorst, Maxime Ripard, Thomas Zimmermann, David Airlie,
	Simona Vetter, luca.ceresoli, Frank Li
  Cc: Frank Li, devicetree, imx, linux-arm-kernel, linux-kernel,
	dri-devel, Marco Felsch

From: Frank Li (AI-BOT) <frank.li@nxp.com>

AI bot review and may be useless.

---

> +static u32 *
> +imx93_pdfc_bridge_atomic_get_input_bus_fmts(struct drm_bridge *bridge,
> +					    struct drm_bridge_state *bridge_state,
> +					    struct drm_crtc_state *crtc_state,
> +					    struct drm_connector_state *conn_state,
> +					    u32 output_fmt,
> +					    unsigned int *num_input_fmts)
> +{
> +	struct imx93_pdfc *pdfc = bridge_to_imx93_pdfc(bridge);
> +	u32 *input_fmts;
> +
> +	*num_input_fmts = 0;
> +
> +	input_fmts = kmalloc_obj(*input_fmts);
> +	if (!input_fmts)
> +		return NULL;

Missing kfree(input_fmts) in error path if the switch statement
or subsequent logic fails. Consider allocating a fixed-size array
or using devm_kzalloc() instead.

> +	*num_input_fmts = 1;
> +
> +	if (!imx93_pdfc_bus_output_fmt_supported(output_fmt)) {
> +		dev_dbg(pdfc->dev, "No valid output bus-fmt detected, fallback to MEDIA_BUS_FMT_RGB888_1X24\n");

Line exceeds 80 characters (97 chars). Break into two lines.

> +		input_fmts[0] = MEDIA_BUS_FMT_RGB888_1X24;
> +		return input_fmts;
> +	}
> +
> +	switch (output_fmt) {
> +	case MEDIA_BUS_FMT_RGB888_1X24:
> +	case MEDIA_BUS_FMT_RGB565_1X16:
> +		input_fmts[0] = output_fmt;
> +		break;
> +	case MEDIA_BUS_FMT_RGB666_1X18:
> +	case MEDIA_BUS_FMT_FIXED:
> +		input_fmts[0] = MEDIA_BUS_FMT_RGB888_1X24;
> +		break;
> +	}

Switch statement lacks default case. Add default case to handle
unexpected format values explicitly.

> +static int imx93_pdfc_bridge_atomic_enable(struct drm_bridge *bridge,
> +					    struct drm_atomic_state *state)
> +{
> +	struct imx93_pdfc *pdfc = bridge_to_imx93_pdfc(bridge);
> +	const struct drm_bridge_state *bridge_state;
> +	unsigned int mask = PARALLEL_DISP_FORMAT;
> +	unsigned int val;
> +
> +	bridge_state = drm_atomic_get_new_bridge_state(state, bridge);
> +
> +	switch (bridge_state->output_bus_cfg.format) {
> +	case MEDIA_BUS_FMT_RGB888_1X24:
> +	case MEDIA_BUS_FMT_FIXED:
> +		val = FORMAT_RGB888_TO_RGB888;
> +		if (pdfc->phy_bus_width == 18) {
> +			/*
> +			 * Can be valid if physical bus limitation exists,
> +			 * therefore use dev_dbg().
> +			 */
> +			dev_dbg(pdfc->dev, "Truncate two LSBs from each color\n");
> +			val = FORMAT_RGB888_TO_RGB666;
> +		}
> +		break;
> +	case MEDIA_BUS_FMT_RGB666_1X18:
> +		val = FORMAT_RGB888_TO_RGB666;
> +		

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

* Re: [PATCH v11 2/3] drm/bridge: imx: Add i.MX93 parallel display format configuration support
  2026-03-03 21:00   ` Frank Li
@ 2026-03-03 21:22     ` Marco Felsch
  0 siblings, 0 replies; 15+ messages in thread
From: Marco Felsch @ 2026-03-03 21:22 UTC (permalink / raw)
  To: Frank Li
  Cc: Rob Herring, Krzysztof Kozlowski, Conor Dooley, Shawn Guo,
	Sascha Hauer, Pengutronix Kernel Team, Fabio Estevam, Peng Fan,
	Liu Ying, Andrzej Hajda, Neil Armstrong, Robert Foss,
	Laurent Pinchart, Jonas Karlman, Jernej Skrabec,
	Maarten Lankhorst, Maxime Ripard, Thomas Zimmermann, David Airlie,
	Simona Vetter, luca.ceresoli, devicetree, imx, linux-arm-kernel,
	linux-kernel, dri-devel

On 26-03-03, Frank Li wrote:
> From: Frank Li (AI-BOT) <frank.li@nxp.com>
> 
> AI bot review and may be useless.

Hi Frank,

albeit I'm very open to new technology, I would appreciate it if your
AI-BOT is used internally first till you're convinced that it reports
real issues instead of false-positives.

Regards,
  Marco

> > +static u32 *
> > +imx93_pdfc_bridge_atomic_get_input_bus_fmts(struct drm_bridge *bridge,
> > +					    struct drm_bridge_state *bridge_state,
> > +					    struct drm_crtc_state *crtc_state,
> > +					    struct drm_connector_state *conn_state,
> > +					    u32 output_fmt,
> > +					    unsigned int *num_input_fmts)
> > +{
> > +	struct imx93_pdfc *pdfc = bridge_to_imx93_pdfc(bridge);
> > +	u32 *input_fmts;
> > +
> > +	*num_input_fmts = 0;
> > +
> > +	input_fmts = kmalloc_obj(*input_fmts);
> > +	if (!input_fmts)
> > +		return NULL;
> 
> Missing kfree(input_fmts) in error path if the switch statement
> or subsequent logic fails. Consider allocating a fixed-size array
> or using devm_kzalloc() instead.
> 
> > +	*num_input_fmts = 1;
> > +
> > +	if (!imx93_pdfc_bus_output_fmt_supported(output_fmt)) {
> > +		dev_dbg(pdfc->dev, "No valid output bus-fmt detected, fallback to MEDIA_BUS_FMT_RGB888_1X24\n");
> 
> Line exceeds 80 characters (97 chars). Break into two lines.
> 
> > +		input_fmts[0] = MEDIA_BUS_FMT_RGB888_1X24;
> > +		return input_fmts;
> > +	}
> > +
> > +	switch (output_fmt) {
> > +	case MEDIA_BUS_FMT_RGB888_1X24:
> > +	case MEDIA_BUS_FMT_RGB565_1X16:
> > +		input_fmts[0] = output_fmt;
> > +		break;
> > +	case MEDIA_BUS_FMT_RGB666_1X18:
> > +	case MEDIA_BUS_FMT_FIXED:
> > +		input_fmts[0] = MEDIA_BUS_FMT_RGB888_1X24;
> > +		break;
> > +	}
> 
> Switch statement lacks default case. Add default case to handle
> unexpected format values explicitly.
> 
> > +static int imx93_pdfc_bridge_atomic_enable(struct drm_bridge *bridge,
> > +					    struct drm_atomic_state *state)
> > +{
> > +	struct imx93_pdfc *pdfc = bridge_to_imx93_pdfc(bridge);
> > +	const struct drm_bridge_state *bridge_state;
> > +	unsigned int mask = PARALLEL_DISP_FORMAT;
> > +	unsigned int val;
> > +
> > +	bridge_state = drm_atomic_get_new_bridge_state(state, bridge);
> > +
> > +	switch (bridge_state->output_bus_cfg.format) {
> > +	case MEDIA_BUS_FMT_RGB888_1X24:
> > +	case MEDIA_BUS_FMT_FIXED:
> > +		val = FORMAT_RGB888_TO_RGB888;
> > +		if (pdfc->phy_bus_width == 18) {
> > +			/*
> > +			 * Can be valid if physical bus limitation exists,
> > +			 * therefore use dev_dbg().
> > +			 */
> > +			dev_dbg(pdfc->dev, "Truncate two LSBs from each color\n");
> > +			val = FORMAT_RGB888_TO_RGB666;
> > +		}
> > +		break;
> > +	case MEDIA_BUS_FMT_RGB666_1X18:
> > +		val = FORMAT_RGB888_TO_RGB666;
> > +		
> 

-- 
#gernperDu 
#CallMeByMyFirstName

Pengutronix e.K.                           |                             |
Steuerwalder Str. 21                       | https://www.pengutronix.de/ |
31137 Hildesheim, Germany                  | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-9    |

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

* Claude review: Add i.MX91/93 parallel display support
  2026-03-03 10:34 [PATCH v11 0/3] Add i.MX91/93 parallel display support Marco Felsch
                   ` (2 preceding siblings ...)
  2026-03-03 10:34 ` [PATCH v11 3/3] arm64: dts: imx93: Add parallel display output nodes Marco Felsch
@ 2026-03-03 21:36 ` Claude Code Review Bot
  3 siblings, 0 replies; 15+ messages in thread
From: Claude Code Review Bot @ 2026-03-03 21:36 UTC (permalink / raw)
  To: dri-devel-reviews

Overall Series Review

Subject: Add i.MX91/93 parallel display support
Author: Marco Felsch <m.felsch@pengutronix.de>
Patches: 10
Reviewed: 2026-03-04T07:36:19.412812

---

This v11 series adds i.MX91/93 parallel display format configuration (PDFC) support via a DRM bridge driver, dt-bindings, and device tree nodes. The series is well-structured and clean after 11 revisions of community review. The driver is simple and correct in concept — it programs the `PARALLEL_DISP_FORMAT` field in the MEDIAMIX BLK-CTRL `DISPLAY_MUX` register to select the output pixel format (RGB888, RGB666, or RGB565).

The code follows established IMX bridge driver patterns and uses modern APIs (`devm_drm_bridge_alloc`, `kmalloc_obj`). I found a few minor issues worth noting but nothing that should block merging.

---
Generated by Claude Code Patch Reviewer

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

* Claude review: dt-bindings: soc: imx93-media-blk-ctrl: Add PDFC subnode to schema and example
  2026-03-03 10:34 ` [PATCH v11 1/3] dt-bindings: soc: imx93-media-blk-ctrl: Add PDFC subnode to schema and example Marco Felsch
  2026-03-03 21:00   ` Frank Li
@ 2026-03-03 21:36   ` Claude Code Review Bot
  1 sibling, 0 replies; 15+ messages in thread
From: Claude Code Review Bot @ 2026-03-03 21:36 UTC (permalink / raw)
  To: dri-devel-reviews

Patch Review

This patch adds the `dpi-bridge` subnode schema and a binding example.

**Observations:**

The binding looks well-structured. It properly references `graph.yaml` and `video-interfaces.yaml` for ports and endpoint properties. The `bus-width` enum restricts to valid values `[16, 18, 24]` and the documentation explains the truncation behavior clearly.

One minor question: the binding defines both `nxp,imx91-pdfc` and `nxp,imx93-pdfc` as compatible strings, but the driver (patch 2) only matches `nxp,imx93-pdfc`. The DTS (patch 3) uses `nxp,imx93-pdfc` in the common dtsi for both SoCs. If the imx91 compatible is intended for future use, that's fine, but if someone were to use `nxp,imx91-pdfc` in a device tree today, the driver would not probe. It would be cleaner to either add `nxp,imx91-pdfc` to the driver's `of_device_id` table now, or document that imx91 should use a fallback compatible pair.

No issues with the binding schema itself.

---
Generated by Claude Code Patch Reviewer

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

* Claude review: drm/bridge: imx: Add i.MX93 parallel display format configuration support
  2026-03-03 10:34 ` [PATCH v11 2/3] drm/bridge: imx: Add i.MX93 parallel display format configuration support Marco Felsch
  2026-03-03 21:00   ` Frank Li
@ 2026-03-03 21:36   ` Claude Code Review Bot
  1 sibling, 0 replies; 15+ messages in thread
From: Claude Code Review Bot @ 2026-03-03 21:36 UTC (permalink / raw)
  To: dri-devel-reviews

Patch Review

This is the main driver patch. Several observations:

**1. Potential uninitialized variable `val` (minor):**

```c
unsigned int val;

bridge_state = drm_atomic_get_new_bridge_state(state, bridge);

switch (bridge_state->output_bus_cfg.format) {
case MEDIA_BUS_FMT_RGB888_1X24:
case MEDIA_BUS_FMT_FIXED:
	val = FORMAT_RGB888_TO_RGB888;
	...
	break;
case MEDIA_BUS_FMT_RGB666_1X18:
	val = FORMAT_RGB888_TO_RGB666;
	break;
case MEDIA_BUS_FMT_RGB565_1X16:
	val = FORMAT_RGB565_TO_RGB565;
	break;
}

regmap_update_bits(pdfc->regmap, IMX93_DISPLAY_MUX_REG, mask, val);
```

The switch has no `default` case. While `atomic_check` should prevent an unsupported format from reaching this point, the compiler will likely warn about `val` being potentially used uninitialized. Adding a `default: return;` (or initializing `val = FORMAT_RGB888_TO_RGB888;`) would silence the warning and be more defensive.

**2. Missing `nxp,imx91-pdfc` in of_device_id:**

```c
static const struct of_device_id imx93_pdfc_dt_ids[] = {
	{ .compatible = "nxp,imx93-pdfc", },
	{ /* sentinel */ }
};
```

As noted above, the binding defines `nxp,imx91-pdfc` but the driver doesn't match it. Since the cover letter explicitly states "I added the support for both," adding `{ .compatible = "nxp,imx91-pdfc", }` here would be consistent.

**3. `kmalloc_obj` usage looks correct:**

```c
input_fmts = kmalloc_obj(*input_fmts);
```

`*input_fmts` dereferences to `u32`, so this allocates `sizeof(u32)` with default GFP flags. Correct for a single-element array.

**4. `bus-width` of 16 is accepted but not fully handled:**

The dt-binding allows `bus-width` of 16, 18, or 24. The driver only handles `phy_bus_width == 18` specially (in `atomic_enable` to select RGB888-to-RGB666 truncation). If `bus-width` is set to 16 in DT, `pdfc->phy_bus_width` will be 16 but the driver doesn't act on it at all — it won't affect the format selection when the output format is `MEDIA_BUS_FMT_RGB888_1X24`. This may be intentional (the downstream bridge's format negotiation handles it via `MEDIA_BUS_FMT_RGB565_1X16`), but it's worth confirming.

**5. Kconfig dependency:**

The driver uses `syscon_node_to_regmap()` which comes from `MFD_SYSCON`. There's no explicit `select MFD_SYSCON` or `depends on MFD_SYSCON` in the Kconfig entry. This typically works because the parent blk-ctrl driver already selects it, but an explicit dependency would be safer for build-testing scenarios (where `COMPILE_TEST` could enable this driver without the blk-ctrl).

**6. Bridge funcs struct naming:**

```c
static const struct drm_bridge_funcs funcs = {
```

A generic name like `funcs` works but `imx93_pdfc_bridge_funcs` would be more consistent with other drivers in the same directory and easier to find in debugging/stack traces.

**7. Overall driver structure is clean.** The use of `devm_drm_bridge_alloc`, `dev_err_probe`, `syscon_node_to_regmap` from the parent, and the bridge format negotiation callbacks all follow modern kernel patterns correctly.

---
Generated by Claude Code Patch Reviewer

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

* Claude review: arm64: dts: imx93: Add parallel display output nodes
  2026-03-03 10:34 ` [PATCH v11 3/3] arm64: dts: imx93: Add parallel display output nodes Marco Felsch
  2026-03-03 10:42   ` Marco Felsch
@ 2026-03-03 21:36   ` Claude Code Review Bot
  1 sibling, 0 replies; 15+ messages in thread
From: Claude Code Review Bot @ 2026-03-03 21:36 UTC (permalink / raw)
  To: dri-devel-reviews

Patch Review

This patch adds DT nodes for the DPI bridge (inside `media_blk_ctrl`) and the LCDIF display controller, plus stubs for LDB and DSI endpoints on imx93.

**1. `assigned-clock-rates` has only 2 entries for 3 assigned clocks:**

```dts
assigned-clocks = <&clk IMX93_CLK_MEDIA_AXI>,
		  <&clk IMX93_CLK_MEDIA_APB>,
		  <&clk IMX93_CLK_MEDIA_DISP_PIX>;
assigned-clock-parents = <&clk IMX93_CLK_SYS_PLL_PFD1>,
			 <&clk IMX93_CLK_SYS_PLL_PFD1_DIV2>,
			 <&clk IMX93_CLK_VIDEO_PLL>;
assigned-clock-rates = <400000000>, <133333333>;
```

Three clocks are listed, three parents are specified, but only two rates. This is valid DT — omitted trailing rates mean "don't set a rate, just reparent." For `MEDIA_DISP_PIX` the rate is presumably determined by the mode, so only the parent is set. This is correct.

**2. Empty endpoint for output port:**

```dts
port@1 {
	reg = <1>;

	dpi_to_panel: endpoint {
	};
};
```

The output endpoint is left empty for board-level DTS files to fill in via `&dpi_to_panel` overrides. This is standard practice.

**3. LCDIF node placement and structure looks correct.** It's a sibling of `media_blk_ctrl` as expected and properly references the LCDIF-specific clocks and power domain.

**4. The imx93.dtsi additions** add stubs for LDB and DSI endpoints with correct reg values (1, 2), preparing for future LVDS and MIPI-DSI bridge support. Clean and forward-looking.

**5. Minor: the `dpi_bridge` label uses underscore while the node name `dpi-bridge` uses hyphen.** This is standard DT convention (labels use underscores, node names use hyphens), so no issue.

Overall, the DTS additions look correct and follow i.MX device tree conventions.

---
Generated by Claude Code Patch Reviewer

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

end of thread, other threads:[~2026-03-03 21:36 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-03-03 10:34 [PATCH v11 0/3] Add i.MX91/93 parallel display support Marco Felsch
2026-03-03 10:34 ` [PATCH v11 1/3] dt-bindings: soc: imx93-media-blk-ctrl: Add PDFC subnode to schema and example Marco Felsch
2026-03-03 21:00   ` Frank Li
2026-03-03 21:36   ` Claude review: " Claude Code Review Bot
2026-03-03 10:34 ` [PATCH v11 2/3] drm/bridge: imx: Add i.MX93 parallel display format configuration support Marco Felsch
2026-03-03 21:00   ` Frank Li
2026-03-03 21:22     ` Marco Felsch
2026-03-03 21:36   ` Claude review: " Claude Code Review Bot
2026-03-03 10:34 ` [PATCH v11 3/3] arm64: dts: imx93: Add parallel display output nodes Marco Felsch
2026-03-03 10:42   ` Marco Felsch
2026-03-03 15:45     ` Frank Li
2026-03-03 15:50       ` Marco Felsch
2026-03-03 21:36   ` Claude review: " Claude Code Review Bot
2026-03-03 21:36 ` Claude review: Add i.MX91/93 parallel display support Claude Code Review Bot
  -- strict thread matches above, loose matches on Subject: below --
2026-03-02 16:10 [PATCH v10 0/3] " Marco Felsch
2026-03-02 16:10 ` [PATCH v10 1/3] dt-bindings: soc: imx93-media-blk-ctrl: Add PDFC subnode to schema and example Marco Felsch
2026-03-03  3:09   ` Claude review: " Claude Code Review Bot

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox