drm/amdgpu: Add preferred mode in modeset when freesync video mode's enabled.
authorSolomon Chiu <solomon.chiu@amd.com>
Tue, 27 Jul 2021 16:20:30 +0000 (00:20 +0800)
committerAlex Deucher <alexander.deucher@amd.com>
Fri, 6 Aug 2021 21:00:50 +0000 (17:00 -0400)
commit46dd2965bdd1c5a4f6499c73ff32e636fa8f9769
treec83268b14b4a51367aac5e82238ab4da6746ee67
parent5126da7d99cf6396c929f3b577ba3aed1e74acd7
drm/amdgpu: Add preferred mode in modeset when freesync video mode's enabled.

[Why]
With kernel module parameter "freesync_video" is enabled, if the mode
is changed to preferred mode(the mode with highest rate), then Freesync
fails because the preferred mode is treated as one of freesync video
mode, and then be configurated as freesync video mode(fixed refresh
rate).

[How]
Skip freesync fixed rate configurating when modeset to preferred mode.

Signed-off-by: Solomon Chiu <solomon.chiu@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Cc: stable@vger.kernel.org
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c