diff options
author | Tomi Valkeinen <tomi.valkeinen@ideasonboard.com> | 2023-08-02 10:04:11 +0300 |
---|---|---|
committer | Neil Armstrong <neil.armstrong@linaro.org> | 2023-08-02 10:05:01 +0200 |
commit | 8e4bb53c902ed2b06a2c4778e6dbb2c1eeec4960 (patch) | |
tree | 13da02f70a939acdd39051504a0935cc18f02f7a /include/drm/drm_bridge.h | |
parent | 76edfcf430cc2fa1abcfb910a2643eed102a1590 (diff) |
drm/bridge: Add debugfs print for bridge chains
DRM bridges are not visible to the userspace and it may not be
immediately clear if the chain is somehow constructed incorrectly. I
have had two separate instances of a bridge driver failing to do a
drm_bridge_attach() call, resulting in the bridge connector not being
part of the chain. In some situations this doesn't seem to cause issues,
but it will if DRM_BRIDGE_ATTACH_NO_CONNECTOR flag is used.
Add a debugfs file to print the bridge chains. For me, on this TI AM62
based platform, I get the following output:
encoder[39]
bridge[0] type: 0, ops: 0x0
bridge[1] type: 0, ops: 0x0, OF: /bus@f0000/i2c@20000000/dsi@e:toshiba,tc358778
bridge[2] type: 0, ops: 0x3, OF: /bus@f0000/i2c@20010000/hdmi@48:lontium,lt8912b
bridge[3] type: 11, ops: 0x7, OF: /hdmi-connector:hdmi-connector
Tested-by: Alexander Stein <alexander.stein@ew.tq-group.com>
Reviewed-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ideasonboard.com>
Acked-by: Neil Armstrong <neil.armstrong@linaro.org>
Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org>
Link: https://patchwork.freedesktop.org/patch/msgid/20230802-drm-bridge-chain-debugfs-v4-1-7e3ae3d137c0@ideasonboard.com
Diffstat (limited to 'include/drm/drm_bridge.h')
-rw-r--r-- | include/drm/drm_bridge.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/include/drm/drm_bridge.h b/include/drm/drm_bridge.h index bf964cdfb330..c339fc85fd07 100644 --- a/include/drm/drm_bridge.h +++ b/include/drm/drm_bridge.h @@ -36,6 +36,7 @@ struct drm_bridge; struct drm_bridge_timings; struct drm_connector; struct drm_display_info; +struct drm_minor; struct drm_panel; struct edid; struct i2c_adapter; @@ -949,4 +950,6 @@ static inline struct drm_bridge *drmm_of_get_bridge(struct drm_device *drm, } #endif +void drm_bridge_debugfs_init(struct drm_minor *minor); + #endif |