]> asedeno.scripts.mit.edu Git - linux.git/commitdiff
drm/i915: Move i915_gem_restore_fences to i915_gem_resume
authorSagar Arun Kamble <sagar.a.kamble@intel.com>
Fri, 29 Sep 2017 04:58:36 +0000 (10:28 +0530)
committerChris Wilson <chris@chris-wilson.co.uk>
Fri, 29 Sep 2017 11:30:17 +0000 (12:30 +0100)
i915_gem_restore_fences is GEM resumption task hence it is moved to
i915_gem_resume from i915_restore_state.

Signed-off-by: Sagar Arun Kamble <sagar.a.kamble@intel.com>
Cc: Michal Wajdeczko <michal.wajdeczko@intel.com>
Cc: MichaƂ Winiarski <michal.winiarski@intel.com>
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/1506661116-12106-1-git-send-email-sagar.a.kamble@intel.com
Reviewed-by: Michal Wajdeczko <michal.wajdeczko@intel.com>
Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
drivers/gpu/drm/i915/i915_gem.c
drivers/gpu/drm/i915/i915_suspend.c

index 73eeb6b1f1cd6682bab4e6eea6c5aca44128d259..ab8c6946fea47f0668dddb35cf974b2e92d8c82b 100644 (file)
@@ -4595,6 +4595,7 @@ void i915_gem_resume(struct drm_i915_private *dev_priv)
 
        mutex_lock(&dev->struct_mutex);
        i915_gem_restore_gtt_mappings(dev_priv);
+       i915_gem_restore_fences(dev_priv);
 
        /* As we didn't flush the kernel context before suspend, we cannot
         * guarantee that the context image is complete. So let's just reset
index 5c86925a029438d795e07d4f72f7da56e2605b23..8f3aa4dc0c98596a3b0443e493be84403d120bc3 100644 (file)
@@ -108,8 +108,6 @@ int i915_restore_state(struct drm_i915_private *dev_priv)
 
        mutex_lock(&dev_priv->drm.struct_mutex);
 
-       i915_gem_restore_fences(dev_priv);
-
        if (IS_GEN4(dev_priv))
                pci_write_config_word(pdev, GCDGMBUS,
                                      dev_priv->regfile.saveGCDGMBUS);