From 2bff5161d3a15b434c8b0f6c39b436c998eb7caa Mon Sep 17 00:00:00 2001 From: Alex Deucher Date: Wed, 26 May 2010 17:41:08 -0400 Subject: [PATCH] drm/radeon/kms: make sure display hw is disabled when suspending Apparently the suspend prefers that the display hw be turned off. https://bugzilla.redhat.com/show_bug.cgi?id=522393 Signed-off-by: Alex Deucher --- drivers/gpu/drm/radeon/radeon_device.c | 7 +++++++ 1 files changed, 7 insertions(+), 0 deletions(-) diff --git a/drivers/gpu/drm/radeon/radeon_device.c b/drivers/gpu/drm/radeon/radeon_device.c index a20b612..25fde6d 100644 --- a/drivers/gpu/drm/radeon/radeon_device.c +++ b/drivers/gpu/drm/radeon/radeon_device.c @@ -711,6 +711,7 @@ int radeon_suspend_kms(struct drm_device *dev, pm_message_t state) { struct radeon_device *rdev; struct drm_crtc *crtc; + struct drm_connector *connector; int r; if (dev == NULL || dev->dev_private == NULL) { @@ -723,6 +724,12 @@ int radeon_suspend_kms(struct drm_device *dev, pm_message_t state) if (rdev->powered_down) return 0; + + /* turn off display hw */ + list_for_each_entry(connector, &dev->mode_config.connector_list, head) { + drm_helper_connector_dpms(connector, DRM_MODE_DPMS_OFF); + } + /* unpin the front buffers */ list_for_each_entry(crtc, &dev->mode_config.crtc_list, head) { struct radeon_framebuffer *rfb = to_radeon_framebuffer(crtc->fb); -- 1.5.6.3