drm/amdgpu/display: fix build when CONFIG_DRM_AMD_DC_DCN is not set
Subsystems (3)
Alex Deucher
maintainerPATCH 1/1 drm/amdgpu/display: fix build when CONFIG_DRM_AMD_DC_DCN is not set
Need to guard some things with CONFIG_DRM_AMD_DC_DCN.
---
Lyude, can you apply this to topic/amdgpu-dp2.0-mst? or Dave, if it's already pulled can you apply this to drm-next?
Thanks!
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 2 +- drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_helpers.c | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-)
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c +1 -1
@@ -10723,9 +10723,9 @@ static int amdgpu_dm_atomic_check(struct drm_device *dev,struct dm_crtc_state *dm_old_crtc_state;#if defined(CONFIG_DRM_AMD_DC_DCN )struct dsc_mst_fairness_vars vars[MAX_PIPES ]; -#endif struct drm_dp_mst_topology_state *mst_state;struct drm_dp_mst_topology_mgr *mgr; +#endif trace_amdgpu_dm_atomic_check_begin (state);
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_helpers.c +3 -1
@@ -219,7 +219,7 @@ bool dm_helpers_dp_mst_write_payload_allocation_table(struct drm_dp_mst_topology_mgr *mst_mgr;struct drm_dp_mst_port *mst_port;bool ret; -u8 link_encoding_cap; +u8 link_encoding_cap = DP_8b_10b_ENCODING; aconnector = (struct amdgpu_dm_connector *)stream->dm_stream_context;/* Accessing the connector state is required for vcpi_slots allocation
@@ -239,7 +239,9 @@ bool dm_helpers_dp_mst_write_payload_allocation_table( mst_port = aconnector->port; +#if defined(CONFIG_DRM_AMD_DC_DCN ) link_encoding_cap =dc_link_dp_mst_decide_link_encoding_format (aconnector->dc_link); +#endif if (enable) {
Signature · 1 line
2.31.1
Will add to the topic branch right now
Quoted 61 lines · Alex Deucher
Need to guard some things with
CONFIG_DRM_AMD_DC_DCN.Fixes 41724ea273cdda ("drm/amd/display: Add DP 2.0 MST DM Support")Signed-off-by Alex Deucher <[email protected]>Cc Lyude Paul <[email protected]>Cc Dave Airlie <[email protected]>---
Lyude, can you apply this to topic/amdgpu-dp2.0-mst? or Dave, if it's already pulled can you apply this to drm-next?
Thanks!
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 2 +-
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_helpers.c| 4 +++-2 files changed, 4 insertions(+), 2 deletions(-)drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c +1
-1@@ -10723,9 +10723,9 @@ static int amdgpu_dm_atomic_check(struct drm_device *dev, struct dm_crtc_state *dm_old_crtc_state; #if defined(CONFIG_DRM_AMD_DC_DCN) struct dsc_mst_fairness_vars vars[MAX_PIPES]; -#endif struct drm_dp_mst_topology_state *mst_state; struct drm_dp_mst_topology_mgr *mgr; +#endif
trace_amdgpu_dm_atomic_check_begin(state);drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_helpers.c +1
-1@@ -219,7 +219,7 @@ bool dm_helpers_dp_mst_write_payload_allocation_table( struct drm_dp_mst_topology_mgr *mst_mgr; struct drm_dp_mst_port *mst_port; bool ret; - u8 link_encoding_cap; + u8 link_encoding_cap = DP_8b_10b_ENCODING;
aconnector = (structamdgpu_dm_connector*)stream-Quoted 1 line
dm_stream_context;/* Accessing the connector state is required for
vcpi_slotsallocationdrivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_helpers.c +0
-0@@ -239,7 +239,9 @@ bool dm_helpers_dp_mst_write_payload_allocation_table(
mst_port =aconnector->port;
+#ifdefined(CONFIG_DRM_AMD_DC_DCN)
link_encoding_cap =dc_link_dp_mst_decide_link_encoding_format(aconnector->dc_link); +#endif
if (enable) {
Signature · 3 lines
Cheers, Lyude Paul (she/her) Software Engineer at Red Hat