Re: [PATCH v11 2/3] drm/bridge: imx: Add i.MX93 parallel display format configuration support

Liu Ying
2026-03-11T03:14:32Z

On Tue, Mar 10, 2026 at 12:53:07PM +0100, Luca Ceresoli wrote:
> Hi Liu, Marco,
>
> On Tue Mar 10, 2026 at 3:57 AM CET, Liu Ying wrote:
>> Hi Marco, Luca,
>>
>> On Tue, Mar 03, 2026 at 11:34:27AM +0100, Marco Felsch wrote:
>>
>> [...]
>>
>>> + 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;
>>
>> When I was reviewing another patch[1], I was aware of the necessity of
>> calling drm_bridge_get() for next_bridge to balance the next bridge's
>> refcount put from __drm_bridge_free() for this bridge. I'd be good if
>> Luca may confirm this is correct. Sorry for bringing this up late.
>
> Indeed you have a good point.
>
> After re-checking devm_drm_of_get_bridge(), as I wrote on the other thread
> you pointed to, you should call drm_bridge_get():

Thanks for the confirmation.

>
> - pdfc->bridge.next_bridge = next_bridge;
> + pdfc->bridge.next_bridge = drm_bridge_get(next_bridge);
>
> Marco, you can keep my R-by if you resend with just this change.

Marco, care to resend with just this change?

>
> Sorry about the confusion here.
>
> As mention on the other thread, devm_drm_of_get_bridge() is unable to
> support bridge hotplug. So it should be deprecated, but as of now there is
> no alternative.
>
> Luca
>
> --
> Luca Ceresoli, Bootlin
> Embedded Linux and Kernel engineering
> https://bootlin.com/

--
Regards,
Liu Ying