From: Ville Syrjälä Date: Mon, 16 Sep 2013 14:38:31 +0000 (+0300) Subject: drm/i915: Pull intel_init_power_well() out of intel_modeset_init_hw() X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=d6317290bfd8673d1cf3b6f8a12c72b3297eac36;p=GitHub%2Fmoto-9609%2Fandroid_kernel_motorola_exynos9610.git drm/i915: Pull intel_init_power_well() out of intel_modeset_init_hw() 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ä Reviewed-by: Paulo Zanoni Signed-off-by: Daniel Vetter --- diff --git a/drivers/gpu/drm/i915/i915_dma.c b/drivers/gpu/drm/i915/i915_dma.c index f4f98957ce47..1eaa0be392dc 100644 --- a/drivers/gpu/drm/i915/i915_dma.c +++ b/drivers/gpu/drm/i915/i915_dma.c @@ -1324,6 +1324,8 @@ static int i915_load_modeset_init(struct drm_device *dev) 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. */ diff --git a/drivers/gpu/drm/i915/i915_drv.c b/drivers/gpu/drm/i915/i915_drv.c index 75e7550064f4..6f385e1e9ed6 100644 --- 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_device *dev, bool restore_gtt_mappings) /* 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); diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c index 1a4232e446fe..1dd474ecc240 100644 --- a/drivers/gpu/drm/i915/intel_display.c +++ b/drivers/gpu/drm/i915/intel_display.c @@ -10273,8 +10273,6 @@ static void i915_enable_vga(struct drm_device *dev) void intel_modeset_init_hw(struct drm_device *dev) { - intel_init_power_well(dev); - intel_prepare_ddi(dev); intel_init_clock_gating(dev);