Re: [PATCH v3 09/14] drm/bridge: imx: Add i.MX8qxp pixel link to DPI support

From: Liu Ying
Date: Wed Feb 17 2021 - 21:58:56 EST


On Tue, 2021-02-09 at 12:15 -0600, Rob Herring wrote:
> On Wed, Jan 27, 2021 at 04:51:23PM +0800, Liu Ying wrote:
> > This patch adds a drm bridge driver for i.MX8qxp pixel link to display
> > pixel interface(PXL2DPI). The PXL2DPI interfaces the pixel link 36-bit
> > data output and the DSI controller’s MIPI-DPI 24-bit data input, and
> > inputs of LVDS Display Bridge(LDB) module used in LVDS mode, to remap
> > the pixel color codings between those modules. The PXL2DPI is purely
> > combinatorial.
> >
> > Signed-off-by: Liu Ying <victor.liu@xxxxxxx>
> > ---
> > v2->v3:
> > * Call syscon_node_to_regmap() to get regmap instead of
> > syscon_regmap_lookup_by_phandle().
> >
> > v1->v2:
> > * Drop unnecessary port availability check.
> >
> > drivers/gpu/drm/bridge/imx/Kconfig | 8 +
> > drivers/gpu/drm/bridge/imx/Makefile | 1 +
> > drivers/gpu/drm/bridge/imx/imx8qxp-pxl2dpi.c | 488 +++++++++++++++++++++++++++
> > 3 files changed, 497 insertions(+)
> > create mode 100644 drivers/gpu/drm/bridge/imx/imx8qxp-pxl2dpi.c
> > + p2d->regmap = syscon_node_to_regmap(np->parent);
> > + if (IS_ERR(p2d->regmap)) {
> > + ret = PTR_ERR(p2d->regmap);
> > + if (ret != -EPROBE_DEFER)
> > + DRM_DEV_ERROR(dev, "failed to get regmap: %d\n", ret);
> > + return ret;
> > + }
> > +
> > + p2d->id = of_alias_get_id(np, "pxl2dpi");
>
> Don't add random aliases. I'd rather see a property in this node as long
> as it is specific to what this is used for (and not a generic index).

Ok. I'll use a DT property to get the SCU resource ID associated with
the PXL2DPI instance. Thanks.

Liu Ying

>
> Rob