These are all SW only init steps, so we can move them earlier. Signed-off-by: Imre Deak <imre.deak@xxxxxxxxx> --- drivers/gpu/drm/i915/i915_dma.c | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/drivers/gpu/drm/i915/i915_dma.c b/drivers/gpu/drm/i915/i915_dma.c index d3dc4d4..9269f1c 100644 --- a/drivers/gpu/drm/i915/i915_dma.c +++ b/drivers/gpu/drm/i915/i915_dma.c @@ -1021,7 +1021,12 @@ int i915_driver_load(struct drm_device *dev, unsigned long flags) if (ret < 0) goto out_free_priv; + /* This must be called before any calls to HAS_PCH_* */ + intel_detect_pch(dev); + intel_pm_setup(dev); + intel_init_dpio(dev_priv); + intel_power_domains_init(dev_priv); intel_runtime_pm_get(dev_priv); @@ -1047,9 +1052,6 @@ int i915_driver_load(struct drm_device *dev, unsigned long flags) if (ret < 0) goto put_bridge; - /* This must be called before any calls to HAS_PCH_* */ - intel_detect_pch(dev); - intel_uncore_init(dev); /* Init phase: setup state requiring accessing the device. */ @@ -1127,16 +1129,12 @@ int i915_driver_load(struct drm_device *dev, unsigned long flags) intel_device_info_runtime_init(dev); - intel_init_dpio(dev_priv); - if (INTEL_INFO(dev)->num_pipes) { ret = drm_vblank_init(dev, INTEL_INFO(dev)->num_pipes); if (ret) goto out_gem_unload; } - intel_power_domains_init(dev_priv); - ret = i915_load_modeset_init(dev); if (ret < 0) { DRM_ERROR("failed to init modeset\n"); -- 2.5.0 _______________________________________________ Intel-gfx mailing list Intel-gfx@xxxxxxxxxxxxxxxxxxxxx https://lists.freedesktop.org/mailman/listinfo/intel-gfx