Commit 00a8037e authored by Alex Deucher's avatar Alex Deucher

drm/amdgpu/display: fix aux registration (v2)

We were registering the aux device in the MST late_register
rather than the regular one.

v2: handle eDP as well

Fixes: 405a1f90 ("drm/amdgpu/display: split dp connector registration (v4)")
Bug: https://gitlab.freedesktop.org/drm/amd/-/issues/1100Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
Reviewed-by: default avatarHarry Wentland <harry.wentland@amd.com>
parent bbc25dad
...@@ -4723,10 +4723,19 @@ amdgpu_dm_connector_atomic_duplicate_state(struct drm_connector *connector) ...@@ -4723,10 +4723,19 @@ amdgpu_dm_connector_atomic_duplicate_state(struct drm_connector *connector)
static int static int
amdgpu_dm_connector_late_register(struct drm_connector *connector) amdgpu_dm_connector_late_register(struct drm_connector *connector)
{ {
#if defined(CONFIG_DEBUG_FS)
struct amdgpu_dm_connector *amdgpu_dm_connector = struct amdgpu_dm_connector *amdgpu_dm_connector =
to_amdgpu_dm_connector(connector); to_amdgpu_dm_connector(connector);
int r;
if ((connector->connector_type == DRM_MODE_CONNECTOR_DisplayPort) ||
(connector->connector_type == DRM_MODE_CONNECTOR_eDP)) {
amdgpu_dm_connector->dm_dp_aux.aux.dev = connector->kdev;
r = drm_dp_aux_register(&amdgpu_dm_connector->dm_dp_aux.aux);
if (r)
return r;
}
#if defined(CONFIG_DEBUG_FS)
connector_debugfs_init(amdgpu_dm_connector); connector_debugfs_init(amdgpu_dm_connector);
#endif #endif
......
...@@ -156,16 +156,16 @@ amdgpu_dm_mst_connector_late_register(struct drm_connector *connector) ...@@ -156,16 +156,16 @@ amdgpu_dm_mst_connector_late_register(struct drm_connector *connector)
to_amdgpu_dm_connector(connector); to_amdgpu_dm_connector(connector);
int r; int r;
amdgpu_dm_connector->dm_dp_aux.aux.dev = connector->kdev; r = drm_dp_mst_connector_late_register(connector,
r = drm_dp_aux_register(&amdgpu_dm_connector->dm_dp_aux.aux); amdgpu_dm_connector->port);
if (r) if (r < 0)
return r; return r;
#if defined(CONFIG_DEBUG_FS) #if defined(CONFIG_DEBUG_FS)
connector_debugfs_init(amdgpu_dm_connector); connector_debugfs_init(amdgpu_dm_connector);
#endif #endif
return r; return 0;
} }
static void static void
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment