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 2/2] drm/i915: Don't access snooped pages through the GTT (even for error capture)
Date: Thu, 30 Jan 2014 17:08:09 +0200	[thread overview]
Message-ID: <20140130150809.GQ9454@intel.com> (raw)
In-Reply-To: <1391092696-29574-2-git-send-email-chris@chris-wilson.co.uk>

On Thu, Jan 30, 2014 at 02:38:16PM +0000, Chris Wilson wrote:
> We want to use the GTT for reading back objects upon an error so that we
> have exactly the information that the GPU saw. However, it is verboten
> to access snoopable pages through the GTT and causes my PineView GPU to
> throw a page fault instead.
> 
> This has not been a problem in the past as we only dumped ringbuffers
> and batchbuffers, both of which must be uncached. However, the
> introduction of HWS page dumping leads to a read of a snooped object
> through the GTT. This was introduced by
> 
> commit f3ce3821393e31a3f1a8ca6c24eb2d735a428445
> Author: Chris Wilson <chris@chris-wilson.co.uk>
> Date:   Thu Jan 23 22:40:36 2014 +0000
> 
>     drm/i915: Include HW status page in error capture
> 
> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
> ---
>  drivers/gpu/drm/i915/i915_gpu_error.c | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/gpu/drm/i915/i915_gpu_error.c b/drivers/gpu/drm/i915/i915_gpu_error.c
> index 6d5ab945132c..3b18c2dff3b8 100644
> --- a/drivers/gpu/drm/i915/i915_gpu_error.c
> +++ b/drivers/gpu/drm/i915/i915_gpu_error.c
> @@ -527,7 +527,8 @@ i915_error_object_create_sized(struct drm_i915_private *dev_priv,
>  			goto unwind;
>  
>  		local_irq_save(flags);
> -		if (reloc_offset < dev_priv->gtt.mappable_end &&
> +		if (src->cache_level == I915_CACHE_NONE &&
> +		    reloc_offset < dev_priv->gtt.mappable_end &&
>  		    src->has_global_gtt_mapping &&
>  		    i915_is_ggtt(vm)) {
>  			void __iomem *s;

So you don't want to make it (cache_level == NONE || HAS_LLC)?

-- 
Ville Syrjälä
Intel OTC

  parent reply	other threads:[~2014-01-30 15:08 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-01-30 14:38 [PATCH 1/2] drm/i915: Only print information for filing bug reports once Chris Wilson
2014-01-30 14:38 ` [PATCH 2/2] drm/i915: Don't access snooped pages through the GTT (even for error capture) Chris Wilson
2014-01-30 14:44   ` Chris Wilson
2014-01-30 15:08   ` Ville Syrjälä [this message]
2014-01-30 15:11     ` Chris Wilson
2014-01-30 15:32       ` Ville Syrjälä
2014-01-30 16:02         ` Daniel Vetter

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=20140130150809.GQ9454@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.