From: Alex Hung Date: Thu, 2 May 2024 16:30:12 +0000 (-0600) Subject: drm/amd/display: Assign disp_cfg_index_max when dml21 X-Git-Url: https://www.infradead.org/git/?a=commitdiff_plain;h=b3f4ee8e4a168b78a3ca8341e18a50c620ed7344;p=users%2Fwilly%2Flinux.git drm/amd/display: Assign disp_cfg_index_max when dml21 [WHY & HOW] The assignment of disp_cfg_index_max is missed and should be assigned to __DML2_WRAPPER_MAX_STREAMS_PLANES__. Fixes: 55ec7679e6a5 ("drm/amd/display: Limit array index according to architecture") Reviewed-by: Hersen Wu Signed-off-by: Alex Hung Signed-off-by: Alex Deucher --- diff --git a/drivers/gpu/drm/amd/display/dc/dml2/dml2_dc_resource_mgmt.c b/drivers/gpu/drm/amd/display/dc/dml2/dml2_dc_resource_mgmt.c index 49e2cc65a43b..190fa2962271 100644 --- a/drivers/gpu/drm/amd/display/dc/dml2/dml2_dc_resource_mgmt.c +++ b/drivers/gpu/drm/amd/display/dc/dml2/dml2_dc_resource_mgmt.c @@ -1058,6 +1058,7 @@ bool dml2_map_dc_pipes(struct dml2_context *ctx, struct dc_state *state, const s ODMMode = (const unsigned int *)odm_mode_array; DPPPerSurface = (const unsigned int *)dpp_per_surface_array; + disp_cfg_index_max = __DML2_WRAPPER_MAX_STREAMS_PLANES__; } else { ODMMode = (unsigned int *)disp_cfg->hw.ODMMode; DPPPerSurface = disp_cfg->hw.DPPPerSurface;