blob: 9671c589991f0b3068b703cac0ec5804cd119100 [file] [log] [blame]
From ac9fc006e731b8aedfd9b0e326a7997970f699da Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Ville=20Syrj=C3=A4l=C3=A4?= <ville.syrjala@linux.intel.com>
Date: Mon, 16 Sep 2013 17:38:31 +0300
Subject: drm/i915: Pull intel_init_power_well() out of intel_modeset_init_hw()
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
The init and resume codepaths want to handel the power well in slightly
different ways, so pull the power well init out from
intel_modeset_init_hw() which gets called in both cases.
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Reviewed-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
(cherry picked from commit d6317290bfd8673d1cf3b6f8a12c72b3297eac36)
Signed-off-by: Darren Hart <dvhart@linux.intel.com>
---
drivers/gpu/drm/i915/i915_dma.c | 2 ++
drivers/gpu/drm/i915/i915_drv.c | 2 ++
drivers/gpu/drm/i915/intel_display.c | 2 --
3 files changed, 4 insertions(+), 2 deletions(-)
--- a/drivers/gpu/drm/i915/i915_dma.c
+++ b/drivers/gpu/drm/i915/i915_dma.c
@@ -1332,6 +1332,8 @@ static int i915_load_modeset_init(struct
INIT_WORK(&dev_priv->console_resume_work, intel_console_resume);
+ intel_init_power_well(dev);
+
intel_modeset_gem_init(dev);
/* Always safe in the mode setting case. */
--- a/drivers/gpu/drm/i915/i915_drv.c
+++ b/drivers/gpu/drm/i915/i915_drv.c
@@ -605,6 +605,8 @@ static int __i915_drm_thaw(struct drm_de
/* We need working interrupts for modeset enabling ... */
drm_irq_install(dev);
+ intel_init_power_well(dev);
+
intel_modeset_init_hw(dev);
drm_modeset_lock_all(dev);
--- a/drivers/gpu/drm/i915/intel_display.c
+++ b/drivers/gpu/drm/i915/intel_display.c
@@ -10279,8 +10279,6 @@ void i915_disable_vga_mem(struct drm_dev
void intel_modeset_init_hw(struct drm_device *dev)
{
- intel_init_power_well(dev);
-
intel_prepare_ddi(dev);
intel_init_clock_gating(dev);