Intel-GFX Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Daniel Vetter <daniel@ffwll.ch>
To: Chris Wilson <chris@chris-wilson.co.uk>
Cc: intel-gfx@lists.freedesktop.org
Subject: Re: [PATCH] drm/i915: Assert that we successfully downclock the GPU before suspend
Date: Tue, 25 Nov 2014 14:52:34 +0100	[thread overview]
Message-ID: <20141125135234.GN25711@phenom.ffwll.local> (raw)
In-Reply-To: <1416916593-20897-1-git-send-email-chris@chris-wilson.co.uk>

On Tue, Nov 25, 2014 at 11:56:33AM +0000, Chris Wilson wrote:
> Before suspending, we wait upon the outstanding GPU requests and flush
> our pending idle handlers. This should downclock the GPU to its lowest
> power state. Add a WARN to check that the delayed tasks were run and did
> their job properly.
> 
> Suggested-by: Akash Goel <akash.goel@intel.com>
> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>

Queued for -next, thanks for the patch.
-Daniel

> ---
>  drivers/gpu/drm/i915/i915_gem.c | 5 +++++
>  1 file changed, 5 insertions(+)
> 
> diff --git a/drivers/gpu/drm/i915/i915_gem.c b/drivers/gpu/drm/i915/i915_gem.c
> index 4a1ca7abd7f9..e4fa0bc62c10 100644
> --- a/drivers/gpu/drm/i915/i915_gem.c
> +++ b/drivers/gpu/drm/i915/i915_gem.c
> @@ -4669,6 +4669,11 @@ i915_gem_suspend(struct drm_device *dev)
>  	cancel_delayed_work_sync(&dev_priv->mm.retire_work);
>  	flush_delayed_work(&dev_priv->mm.idle_work);
>  
> +	/* Assert that we sucessfully flushed all the work and
> +	 * reset the GPU back to its idle, low power state.
> +	 */
> +	WARN_ON(dev_priv->mm.busy);
> +
>  	return 0;
>  
>  err:
> -- 
> 2.1.3
> 
> _______________________________________________
> Intel-gfx mailing list
> Intel-gfx@lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/intel-gfx

-- 
Daniel Vetter
Software Engineer, Intel Corporation
+41 (0) 79 365 57 48 - http://blog.ffwll.ch
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx

  reply	other threads:[~2014-11-25 13:52 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-11-25 11:56 [PATCH] drm/i915: Assert that we successfully downclock the GPU before suspend Chris Wilson
2014-11-25 13:52 ` Daniel Vetter [this message]
2014-11-25 20:29 ` [PATCH] drm/i915: Assert that we successfully downclock shuang.he

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20141125135234.GN25711@phenom.ffwll.local \
    --to=daniel@ffwll.ch \
    --cc=chris@chris-wilson.co.uk \
    --cc=intel-gfx@lists.freedesktop.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox