aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c
diff options
context:
space:
mode:
authorAlex Deucher <alexander.deucher@amd.com>2016-02-19 17:55:31 -0500
committerAlex Deucher <alexander.deucher@amd.com>2016-02-22 11:31:02 -0500
commit8e7cedc6f7fe762ffe6e348502be34b11fa79298 (patch)
tree302a0b0cccef35888a66b64ac6f3c6228cef9066 /drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c
parent0c67df48597f0e60eaf7f187ee38f6ccce56561e (diff)
drm/amdgpu/pm: adjust display configuration after powerstate
set_power_state defaults to no displays, so we need to update the display configuration after setting up the powerstate on the first call. In most cases this is not an issue since ends up getting called multiple times at any given modeset and the proper order is achieved in the display changed handling at the top of the function. Reviewed-by: Christian König <christian.koenig@amd.com> Acked-by: Jordan Lazare <Jordan.Lazare@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> Cc: stable@vger.kernel.org
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c')
-rw-r--r--drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c
index 8de765dee3e7..66855b62a603 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c
@@ -648,8 +648,6 @@ force:
648 648
649 /* update display watermarks based on new power state */ 649 /* update display watermarks based on new power state */
650 amdgpu_display_bandwidth_update(adev); 650 amdgpu_display_bandwidth_update(adev);
651 /* update displays */
652 amdgpu_dpm_display_configuration_changed(adev);
653 651
654 adev->pm.dpm.current_active_crtcs = adev->pm.dpm.new_active_crtcs; 652 adev->pm.dpm.current_active_crtcs = adev->pm.dpm.new_active_crtcs;
655 adev->pm.dpm.current_active_crtc_count = adev->pm.dpm.new_active_crtc_count; 653 adev->pm.dpm.current_active_crtc_count = adev->pm.dpm.new_active_crtc_count;
@@ -669,6 +667,9 @@ force:
669 667
670 amdgpu_dpm_post_set_power_state(adev); 668 amdgpu_dpm_post_set_power_state(adev);
671 669
670 /* update displays */
671 amdgpu_dpm_display_configuration_changed(adev);
672
672 if (adev->pm.funcs->force_performance_level) { 673 if (adev->pm.funcs->force_performance_level) {
673 if (adev->pm.dpm.thermal_active) { 674 if (adev->pm.dpm.thermal_active) {
674 enum amdgpu_dpm_forced_level level = adev->pm.dpm.forced_level; 675 enum amdgpu_dpm_forced_level level = adev->pm.dpm.forced_level;