diff options
author | Dave Airlie <airlied@redhat.com> | 2011-04-12 19:20:24 -0400 |
---|---|---|
committer | Dave Airlie <airlied@redhat.com> | 2011-04-12 19:20:24 -0400 |
commit | 2582b6efceb43dce63b4a1090d289934067a972d (patch) | |
tree | 75674dd842aac422a58c386693757e609105874c /drivers/gpu | |
parent | d87dfdbfc91c5e37288e7e8f7afdd992ba61a60d (diff) |
Revert "i915: restore only the mode of this driver on lastclose"
This reverts commit 0a0883c8433c743dad0a4d9ebe2717558f2c209e.
this was in my tree by accident, I meant to rebase it out and
didn't realise in time.
Signed-off-by: Dave Airlie <airlied@redhat.com>
Diffstat (limited to 'drivers/gpu')
-rw-r--r-- | drivers/gpu/drm/i915/i915_dma.c | 2 | ||||
-rw-r--r-- | drivers/gpu/drm/i915/intel_drv.h | 1 | ||||
-rw-r--r-- | drivers/gpu/drm/i915/intel_fb.c | 16 |
3 files changed, 1 insertions, 18 deletions
diff --git a/drivers/gpu/drm/i915/i915_dma.c b/drivers/gpu/drm/i915/i915_dma.c index 12876f2795d2..72730377a01b 100644 --- a/drivers/gpu/drm/i915/i915_dma.c +++ b/drivers/gpu/drm/i915/i915_dma.c | |||
@@ -2207,7 +2207,7 @@ void i915_driver_lastclose(struct drm_device * dev) | |||
2207 | drm_i915_private_t *dev_priv = dev->dev_private; | 2207 | drm_i915_private_t *dev_priv = dev->dev_private; |
2208 | 2208 | ||
2209 | if (!dev_priv || drm_core_check_feature(dev, DRIVER_MODESET)) { | 2209 | if (!dev_priv || drm_core_check_feature(dev, DRIVER_MODESET)) { |
2210 | intel_fb_restore_mode(dev); | 2210 | drm_fb_helper_restore(); |
2211 | vga_switcheroo_process_delayed_switch(); | 2211 | vga_switcheroo_process_delayed_switch(); |
2212 | return; | 2212 | return; |
2213 | } | 2213 | } |
diff --git a/drivers/gpu/drm/i915/intel_drv.h b/drivers/gpu/drm/i915/intel_drv.h index 1d20712d527f..f5b0d8306d83 100644 --- a/drivers/gpu/drm/i915/intel_drv.h +++ b/drivers/gpu/drm/i915/intel_drv.h | |||
@@ -338,5 +338,4 @@ extern int intel_overlay_attrs(struct drm_device *dev, void *data, | |||
338 | struct drm_file *file_priv); | 338 | struct drm_file *file_priv); |
339 | 339 | ||
340 | extern void intel_fb_output_poll_changed(struct drm_device *dev); | 340 | extern void intel_fb_output_poll_changed(struct drm_device *dev); |
341 | extern void intel_fb_restore_mode(struct drm_device *dev); | ||
342 | #endif /* __INTEL_DRV_H__ */ | 341 | #endif /* __INTEL_DRV_H__ */ |
diff --git a/drivers/gpu/drm/i915/intel_fb.c b/drivers/gpu/drm/i915/intel_fb.c index 96a45c4e9a16..512782728e51 100644 --- a/drivers/gpu/drm/i915/intel_fb.c +++ b/drivers/gpu/drm/i915/intel_fb.c | |||
@@ -264,19 +264,3 @@ void intel_fb_output_poll_changed(struct drm_device *dev) | |||
264 | drm_i915_private_t *dev_priv = dev->dev_private; | 264 | drm_i915_private_t *dev_priv = dev->dev_private; |
265 | drm_fb_helper_hotplug_event(&dev_priv->fbdev->helper); | 265 | drm_fb_helper_hotplug_event(&dev_priv->fbdev->helper); |
266 | } | 266 | } |
267 | |||
268 | void intel_fb_restore_mode(struct drm_device *dev) | ||
269 | { | ||
270 | drm_i915_private_t *dev_priv = dev->dev_private; | ||
271 | int ret, i; | ||
272 | |||
273 | if (!dev_priv->fbdev) | ||
274 | return; | ||
275 | |||
276 | for (i = 0; i < dev_priv->fbdev->helper.crtc_count; i++) { | ||
277 | struct drm_mode_set *mode_set = &dev_priv->fbdev->helper.crtc_info[i].mode_set; | ||
278 | ret = drm_crtc_helper_set_config(mode_set); | ||
279 | if (ret) | ||
280 | DRM_DEBUG("failed to restore crtc mode\n"); | ||
281 | } | ||
282 | } | ||