Re: [PATCH 0/7] drm: remove deprecated *_of_get_bridge() from non-OF drivers (fixes build regression)
From: Icenowy Zheng
Date: Tue Sep 29 2026 - 07:21:15 EST
在 2026-09-29二的 12:36 +0200,Luca Ceresoli写道:
> After commit Fixes: aa8a8c7e4641 ("drm/bridge: panel: move all code
> to
> drm_panel.c") some drivers fail building:
>
> error: implicit declaration of function 'devm_drm_of_get_bridge'
>
> This is because devm_drm_of_get_bridge() (and drmm_of_get_bridge())
> have
> been moved to drm-panel.h.
>
> The affected drivers are those which:
>
> * can be built without CONFIG_OF, and
> * don't include drm_panel.h
>
> The affected drivers are 3, fix them (patches 1-3) by replacing the
> deprecated *_of_get_bridge() calls with
> of_drm_get_bridge_by_endpoint().
The comment of drm_of_find_panel_or_bridge() still suggests
devm_of_get_bridge(), and the documentation at the head of drm_bridge.c
also mentions it.
Should this get fixed?
BTW should drm_of_get_bridge_by_endpoint() has some drmm/devm variant?
Thanks,
Icenowy
>
> While there, do the same for all drivers which be built without
> CONFIG_OF,
> even if they don't fail (patches 4-7).
>
> Signed-off-by: Luca Ceresoli <luca.ceresoli@xxxxxxxxxxx>
> ---
> Luca Ceresoli (7):
> drm/imx/lcdc: stop using deprecated devm_drm_of_get_bridge()
> drm: verisilicon: stop using deprecated
> devm_drm_of_get_bridge()
> drm/bridge: dw-mipi-dsi: stop using deprecated
> devm_drm_of_get_bridge()
> drm/bridge: dw-mipi-dsi2: stop using deprecated
> devm_drm_of_get_bridge()
> drm/vc4: dpi: stop using deprecated drmm_of_get_bridge()
> drm/vc4: dsi: stop using deprecated drmm_of_get_bridge()
> drm: renesas: shmobile: stop using deprecated
> devm_drm_of_get_bridge()
>
> drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c | 9 +++------
> drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi2.c | 9 +++------
> drivers/gpu/drm/imx/lcdc/imx-lcdc.c | 4 ++--
> drivers/gpu/drm/renesas/shmobile/shmob_drm_crtc.c | 5 ++---
> drivers/gpu/drm/vc4/vc4_dpi.c | 9 ++-------
> drivers/gpu/drm/vc4/vc4_dsi.c | 10 ++++------
> drivers/gpu/drm/verisilicon/vs_bridge.c | 7 +++----
> drivers/gpu/drm/verisilicon/vs_bridge.h | 1 -
> 8 files changed, 19 insertions(+), 35 deletions(-)
> ---
> base-commit: 91ceac83e599c9d48da4c4d2d91410c588a215f7
> change-id: 20260929-drm-fix-of_get_bridge-build-regression-
> 98f22f8a1dcc
>
> Best regards,
> --
> Luca Ceresoli, Bootlin
> Embedded Linux and Kernel engineering
> https://bootlin.com