Commit 760ed918 authored by Dillon Varone's avatar Dillon Varone Committed by Alex Deucher

drm/amd/display: Create dc_state after resource initialization

[WHY&HOW]
After refactoring dc_state, it is always constructed at the time of its
creation. Construction can only happen after dc resources are initialized, so
move creation to be after this.
Reviewed-by: default avatarGeorge Shen <george.shen@amd.com>
Acked-by: default avatarWayne Lin <wayne.lin@amd.com>
Signed-off-by: default avatarDillon Varone <dillon.varone@amd.com>
Tested-by: default avatarDaniel Wheeler <daniel.wheeler@amd.com>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
parent b03281e9
......@@ -1025,6 +1025,15 @@ static bool dc_construct(struct dc *dc,
}
#endif
if (!create_links(dc, init_params->num_virtual_links))
goto fail;
/* Create additional DIG link encoder objects if fewer than the platform
* supports were created during link construction.
*/
if (!create_link_encoders(dc))
goto fail;
/* Creation of current_state must occur after dc->dml
* is initialized in dc_create_resource_pool because
* on creation it copies the contents of dc->dml
......@@ -1037,15 +1046,6 @@ static bool dc_construct(struct dc *dc,
goto fail;
}
if (!create_links(dc, init_params->num_virtual_links))
goto fail;
/* Create additional DIG link encoder objects if fewer than the platform
* supports were created during link construction.
*/
if (!create_link_encoders(dc))
goto fail;
return true;
fail:
......
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