diff options
author | Fangzhi Zuo <jerry.zuo@amd.com> | 2024-06-20 18:27:39 +0300 |
---|---|---|
committer | Alex Deucher <alexander.deucher@amd.com> | 2024-07-01 23:10:35 +0300 |
commit | d6d884b68ad65c832be5ba22ac61dc7173059d9a (patch) | |
tree | 5a83cee86dcb1b40a04b12d41399c6b84f0fe094 /drivers | |
parent | ea04ef19ebdcd22e8a21054a19c2c8fefae011ce (diff) | |
download | linux-d6d884b68ad65c832be5ba22ac61dc7173059d9a.tar.xz |
drm/amd/display: Fix dmub timeout after fams2 enabled
Reset fams stream count upon stream removal, otherwise
fams2 state machine in dmub will get corrupted.
Reviewed-by: Dillon Varone <dillon.varone@amd.com>
Signed-off-by: Jerry Zuo <jerry.zuo@amd.com>
Signed-off-by: Fangzhi Zuo <jerry.zuo@amd.com>
Tested-by: Daniel Wheeler <daniel.wheeler@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/gpu/drm/amd/display/dc/dml2/dml21/dml21_wrapper.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/drivers/gpu/drm/amd/display/dc/dml2/dml21/dml21_wrapper.c b/drivers/gpu/drm/amd/display/dc/dml2/dml21/dml21_wrapper.c index c310354cd5fc..9edcacdde6b7 100644 --- a/drivers/gpu/drm/amd/display/dc/dml2/dml21/dml21_wrapper.c +++ b/drivers/gpu/drm/amd/display/dc/dml2/dml21/dml21_wrapper.c @@ -197,8 +197,13 @@ static bool dml21_mode_check_and_programming(const struct dc *in_dc, struct dc_s memset(&dml_ctx->v21.dml_to_dc_pipe_mapping, 0, sizeof(struct dml2_dml_to_dc_pipe_mapping)); memset(&dml_ctx->v21.mode_programming.dml2_instance->scratch.build_mode_programming_locals.mode_programming_params, 0, sizeof(struct dml2_core_mode_programming_in_out)); - if (!context || context->stream_count == 0) + if (!context) + return true; + + if (context->stream_count == 0) { + dml21_build_fams2_programming(in_dc, context, dml_ctx); return true; + } /* scrub phantom's from current dc_state */ dml_ctx->config.svp_pstate.callbacks.remove_phantom_streams_and_planes(in_dc, context); |