Commit a5ce8695 authored by Mario Limonciello's avatar Mario Limonciello Committed by Alex Deucher
Browse files

drm/amd/display: Avoid configuring PSR granularity if PSR-SU not supported



[Why]
If PSR-SU is disabled on the link, then configuring su_y granularity in
mod_power_calc_psr_configs() can lead to assertions in
psr_su_set_dsc_slice_height().

[How]
Check the PSR version in amdgpu_dm_link_setup_psr() to determine whether
or not to configure granularity.

Reviewed-by: default avatarSun peng (Leo) Li <sunpeng.li@amd.com>
Signed-off-by: default avatarMario Limonciello <mario.limonciello@amd.com>
Signed-off-by: default avatarIvan Lipski <ivan.lipski@amd.com>
Tested-by: default avatarDaniel Wheeler <daniel.wheeler@amd.com>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
parent 02f3ec53
Loading
Loading
Loading
Loading
+4 −2
Original line number Diff line number Diff line
@@ -119,8 +119,10 @@ bool amdgpu_dm_link_setup_psr(struct dc_stream_state *stream)
		psr_config.allow_multi_disp_optimizations =
			(amdgpu_dc_feature_mask & DC_PSR_ALLOW_MULTI_DISP_OPT);

		if (link->psr_settings.psr_version == DC_PSR_VERSION_SU_1) {
			if (!psr_su_set_dsc_slice_height(dc, link, stream, &psr_config))
				return false;
		}

		ret = dc_link_setup_psr(link, stream, &psr_config, &psr_context);