drm/amd/display: Block optimize on consecutive FAMS enables
authorWesley Chalmers <Wesley.Chalmers@amd.com>
Wed, 31 May 2023 17:29:34 +0000 (13:29 -0400)
committerAlex Deucher <alexander.deucher@amd.com>
Mon, 10 Jul 2023 13:02:07 +0000 (09:02 -0400)
commit3b6df06f01cdbff3b610b492ad4879691afdc70d
tree2174a5d47821db18916bcbb6c2ad45de9881da9d
parent09c8cbedba5fa85f15ac91ed74848aceff69f8e5
drm/amd/display: Block optimize on consecutive FAMS enables

[WHY]
It is possible to commit state multiple times in rapid succession with
FAMS enabled; if each of these commits were to set optimized_required,
then the user may see latency.

[HOW]
fw_based_mclk_switching is currently not used in dc->clk_mgr; use it
to track whether the current state has FAMS enabled;
if it has, then do not disable FAMS in prepare_bandwidth, and do not set
optimized_required.

Reviewed-by: Rodrigo Siqueira <Rodrigo.Siqueira@amd.com>
Signed-off-by: Wesley Chalmers <Wesley.Chalmers@amd.com>
Tested-by: Daniel Wheeler <daniel.wheeler@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Acked-by: Hamza Mahfooz <hamza.mahfooz@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/display/dc/dcn20/dcn20_hwseq.c
drivers/gpu/drm/amd/display/dc/dcn30/dcn30_hwseq.c