All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Ville Syrjälä" <ville.syrjala@linux.intel.com>
To: Chris Wilson <chris@chris-wilson.co.uk>
Cc: intel-gfx@lists.freedesktop.org
Subject: Re: [PATCH] drm/i915: Hold rpm wakeref for debugfs/i915_drop_caches_set
Date: Mon, 15 Oct 2018 17:01:25 +0300	[thread overview]
Message-ID: <20181015140125.GB9144@intel.com> (raw)
In-Reply-To: <20181015115856.18590-1-chris@chris-wilson.co.uk>

On Mon, Oct 15, 2018 at 12:58:56PM +0100, Chris Wilson wrote:
> Since we peek into HW state and poke around, it behoves us to acquire a
> runtime pm wakeref beforehand.
> 
> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=108364
> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
> ---
>  drivers/gpu/drm/i915/i915_debugfs.c | 3 +++
>  1 file changed, 3 insertions(+)
> 
> diff --git a/drivers/gpu/drm/i915/i915_debugfs.c b/drivers/gpu/drm/i915/i915_debugfs.c
> index 7b7f844d325b..80dec5740de0 100644
> --- a/drivers/gpu/drm/i915/i915_debugfs.c
> +++ b/drivers/gpu/drm/i915/i915_debugfs.c
> @@ -4187,6 +4187,7 @@ i915_drop_caches_set(void *data, u64 val)
>  
>  	DRM_DEBUG("Dropping caches: 0x%08llx [0x%08llx]\n",
>  		  val, val & DROP_ALL);
> +	intel_runtime_pm_get(i915);
>  
>  	if (val & DROP_RESET_ACTIVE && !intel_engines_are_idle(i915))
>  		i915_gem_set_wedged(i915);
> @@ -4246,6 +4247,8 @@ i915_drop_caches_set(void *data, u64 val)
>  	if (val & DROP_FREED)
>  		i915_gem_drain_freed_objects(i915);
>  
> +	intel_runtime_pm_put(i915);
> +

I see some other rpm get/put calls inside this function. Drop those?

Either way
Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com>

>  	return ret;
>  }
>  
> -- 
> 2.19.1
> 
> _______________________________________________
> Intel-gfx mailing list
> Intel-gfx@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/intel-gfx

-- 
Ville Syrjälä
Intel
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

  parent reply	other threads:[~2018-10-15 14:01 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-10-15 11:58 [PATCH] drm/i915: Hold rpm wakeref for debugfs/i915_drop_caches_set Chris Wilson
2018-10-15 13:22 ` ✓ Fi.CI.BAT: success for " Patchwork
2018-10-15 14:01 ` Ville Syrjälä [this message]
2018-10-15 14:06   ` [PATCH] " Chris Wilson
2018-10-15 17:09 ` ✓ Fi.CI.IGT: success for " Patchwork

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=20181015140125.GB9144@intel.com \
    --to=ville.syrjala@linux.intel.com \
    --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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.