diff mbox series

[v2] drm/i915/guc: GuC suspend path cleanup

Message ID 20190321203804.6845-1-sujaritha.sundaresan@intel.com (mailing list archive)
State New, archived
Headers show
Series [v2] drm/i915/guc: GuC suspend path cleanup | expand

Commit Message

Sundaresan, Sujaritha March 21, 2019, 8:38 p.m. UTC
Adding a call to intel_uc_suspend in i915_gem_suspend, which
is a common point for the suspend/resume and hibernate paths.
This fixes an unbalanced call that causes issues with the CTB
register/deregister.

v2: Making the call unconditional (Daniele)
	Moving the call to after the GEM_BUG_ON (Chris)

Cc: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com>
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Michal Wajdeczko <michal.wajdeczko@intel.com>
Signed-off-by: Sujaritha Sundaresan <sujaritha.sundaresan@intel.com>
---
 drivers/gpu/drm/i915/i915_gem.c | 2 ++
 1 file changed, 2 insertions(+)

Comments

Chris Wilson March 22, 2019, 8:57 a.m. UTC | #1
Quoting Sujaritha Sundaresan (2019-03-21 20:38:04)
> Adding a call to intel_uc_suspend in i915_gem_suspend, which
> is a common point for the suspend/resume and hibernate paths.
> This fixes an unbalanced call that causes issues with the CTB
> register/deregister.
> 
> v2: Making the call unconditional (Daniele)
>         Moving the call to after the GEM_BUG_ON (Chris)
> 
> Cc: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com>
> Cc: Chris Wilson <chris@chris-wilson.co.uk>
> Cc: Michal Wajdeczko <michal.wajdeczko@intel.com>
> Signed-off-by: Sujaritha Sundaresan <sujaritha.sundaresan@intel.com>

So I removed this when forcing a reset; then made the forced reset
conditional...
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
-Chris
Chris Wilson March 22, 2019, 9:39 a.m. UTC | #2
Quoting Chris Wilson (2019-03-22 08:57:35)
> Quoting Sujaritha Sundaresan (2019-03-21 20:38:04)
> > Adding a call to intel_uc_suspend in i915_gem_suspend, which
> > is a common point for the suspend/resume and hibernate paths.
> > This fixes an unbalanced call that causes issues with the CTB
> > register/deregister.
> > 
> > v2: Making the call unconditional (Daniele)
> >         Moving the call to after the GEM_BUG_ON (Chris)
> > 
> > Cc: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com>
> > Cc: Chris Wilson <chris@chris-wilson.co.uk>
> > Cc: Michal Wajdeczko <michal.wajdeczko@intel.com>
> > Signed-off-by: Sujaritha Sundaresan <sujaritha.sundaresan@intel.com>
> 
> So I removed this when forcing a reset; then made the forced reset
> conditional...
> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>

And pushed, thanks for the fixup.
-Chris
diff mbox series

Patch

diff --git a/drivers/gpu/drm/i915/i915_gem.c b/drivers/gpu/drm/i915/i915_gem.c
index 1a684b7e8c09..8e8b79711a31 100644
--- a/drivers/gpu/drm/i915/i915_gem.c
+++ b/drivers/gpu/drm/i915/i915_gem.c
@@ -4388,6 +4388,8 @@  void i915_gem_suspend(struct drm_i915_private *i915)
 	 */
 	GEM_BUG_ON(i915->gt.awake);
 
+	intel_uc_suspend(i915);
+
 	intel_runtime_pm_put(i915, wakeref);
 }