<pre>
Hi, Angelo:
On Wed, 2023-07-26 at 13:21 +0800, CK Hu wrote:
> Hi, Angelo:
>
> On Wed, 2023-07-19 at 09:50 +0200, AngeloGioacchino Del Regno wrote:
> > Change drm_bridge_add() to its devm variant to slightly simplify
> > the
> > probe function.
>
> Reviewed-by: CK Hu <ck.hu@mediatek.com>
>
> >
> > Signed-off-by: AngeloGioacchino Del Regno <
> > angelogioacchino.delregno@collabora.com>
> > ---
> > drivers/gpu/drm/mediatek/mtk_dpi.c | 6 +++---
> > 1 file changed, 3 insertions(+), 3 deletions(-)
> >
> > diff --git a/drivers/gpu/drm/mediatek/mtk_dpi.c
> > b/drivers/gpu/drm/mediatek/mtk_dpi.c
> > index 948a53f1f4b3..74068aa70e0c 100644
> > --- a/drivers/gpu/drm/mediatek/mtk_dpi.c
> > +++ b/drivers/gpu/drm/mediatek/mtk_dpi.c
> > @@ -1090,11 +1090,12 @@ static int mtk_dpi_probe(struct
> > platform_device *pdev)
> > dpi->bridge.of_node = dev->of_node;
> > dpi->bridge.type = DRM_MODE_CONNECTOR_DPI;
> >
> > -drm_bridge_add(&dpi->bridge);
> > +ret = devm_drm_bridge_add(dev, &dpi->bridge);
> > +if (ret)
> > +return ret;
> >
> > ret = component_add(dev, &mtk_dpi_component_ops);
> > if (ret) {
> > -drm_bridge_remove(&dpi->bridge);
> > dev_err(dev, "Failed to add component: %d\n", ret);
> > return ret;
> > }
> > @@ -1107,7 +1108,6 @@ static int mtk_dpi_remove(struct
> > platform_device *pdev)
> > struct mtk_dpi *dpi = platform_get_drvdata(pdev);
Remove this also. So drop my Reviewed-by tag.
Regards,
CK
> >
> > component_del(&pdev->dev, &mtk_dpi_component_ops);
> > -drm_bridge_remove(&dpi->bridge);
> >
> > return 0;
> > }
</pre><!--type:text--><!--{--><pre>************* MEDIATEK Confidentiality Notice ********************
The information contained in this e-mail message (including any
attachments) may be confidential, proprietary, privileged, or otherwise
exempt from disclosure under applicable laws. It is intended to be
conveyed only to the designated recipient(s). Any use, dissemination,
distribution, printing, retaining or copying of this e-mail (including its
attachments) by unintended recipient(s) is strictly prohibited and may
be unlawful. If you are not an intended recipient of this e-mail, or believe
that you have received this e-mail in error, please notify the sender
immediately (by replying to this e-mail), delete any and all copies of
this e-mail (including any attachments) from your system, and do not
disclose the content of this e-mail to any other person. Thank you!
</pre><!--}-->