Commit 92020e81 authored by Alex Deucher's avatar Alex Deucher

drm/amdgpu/display: set vblank_disable_immediate for DC

Disable vblanks immediately to save power.  I think this was
missed when we merged DC support.

Bug: https://gitlab.freedesktop.org/drm/amd/-/issues/1781Reviewed-by: default avatarHarry Wentland <harry.wentland@amd.com>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
parent a689e8d1
...@@ -333,7 +333,6 @@ int amdgpu_irq_init(struct amdgpu_device *adev) ...@@ -333,7 +333,6 @@ int amdgpu_irq_init(struct amdgpu_device *adev)
if (!amdgpu_device_has_dc_support(adev)) { if (!amdgpu_device_has_dc_support(adev)) {
if (!adev->enable_virtual_display) if (!adev->enable_virtual_display)
/* Disable vblank IRQs aggressively for power-saving */ /* Disable vblank IRQs aggressively for power-saving */
/* XXX: can this be enabled for DC? */
adev_to_drm(adev)->vblank_disable_immediate = true; adev_to_drm(adev)->vblank_disable_immediate = true;
r = drm_vblank_init(adev_to_drm(adev), adev->mode_info.num_crtc); r = drm_vblank_init(adev_to_drm(adev), adev->mode_info.num_crtc);
......
...@@ -1592,6 +1592,9 @@ static int amdgpu_dm_init(struct amdgpu_device *adev) ...@@ -1592,6 +1592,9 @@ static int amdgpu_dm_init(struct amdgpu_device *adev)
adev_to_drm(adev)->mode_config.cursor_width = adev->dm.dc->caps.max_cursor_size; adev_to_drm(adev)->mode_config.cursor_width = adev->dm.dc->caps.max_cursor_size;
adev_to_drm(adev)->mode_config.cursor_height = adev->dm.dc->caps.max_cursor_size; adev_to_drm(adev)->mode_config.cursor_height = adev->dm.dc->caps.max_cursor_size;
/* Disable vblank IRQs aggressively for power-saving */
adev_to_drm(adev)->vblank_disable_immediate = true;
if (drm_vblank_init(adev_to_drm(adev), adev->dm.display_indexes_num)) { if (drm_vblank_init(adev_to_drm(adev), adev->dm.display_indexes_num)) {
DRM_ERROR( DRM_ERROR(
"amdgpu: failed to initialize sw for display support.\n"); "amdgpu: failed to initialize sw for display support.\n");
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment