public inbox for intel-gfx@lists.freedesktop.org
 help / color / mirror / Atom feed
From: Daniel Vetter <daniel@ffwll.ch>
To: Thomas Daniel <thomas.daniel@intel.com>
Cc: intel-gfx@lists.freedesktop.org, Paulo Zanoni <paulo.r.zanoni@intel.com>
Subject: Re: [PATCH] drm/i915: Reset CSB read pointer when enabling contexts
Date: Thu, 8 Jan 2015 09:01:18 +0100	[thread overview]
Message-ID: <20150108080118.GG26519@phenom.ffwll.local> (raw)
In-Reply-To: <1420646970-4897-1-git-send-email-thomas.daniel@intel.com>

On Wed, Jan 07, 2015 at 04:09:30PM +0000, Thomas Daniel wrote:
> During a suspend/resume cycle the hardware Context Status Buffer write pointer
> is reset.  However since recent changes to the init sequence the software CSB
> read pointer is no longer reset.  This means that context status events are not
> handled correctly and new contexts are not written to the ELSP, resulting in an
> apparent GPU hang.
> 
> Pending further changes to the ring init code, just move the
> ring->next_context_status_buffer initialization into i915_gem_context_enable to
> fix this regression.
> 
> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=88097
There's also

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=88096

Can you please take a look at that one too?
-Daniel

> Cc: Paulo Zanoni <paulo.r.zanoni@intel.com>
> Signed-off-by: Thomas Daniel <thomas.daniel@intel.com>
> ---
>  drivers/gpu/drm/i915/i915_gem_context.c |    1 +
>  drivers/gpu/drm/i915/intel_lrc.c        |    1 -
>  2 files changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/gpu/drm/i915/i915_gem_context.c b/drivers/gpu/drm/i915/i915_gem_context.c
> index bf9778e..cc100c9 100644
> --- a/drivers/gpu/drm/i915/i915_gem_context.c
> +++ b/drivers/gpu/drm/i915/i915_gem_context.c
> @@ -412,6 +412,7 @@ int i915_gem_context_enable(struct drm_i915_private *dev_priv)
>  
>  	if (i915.enable_execlists) {
>  		for_each_ring(ring, dev_priv, i) {
> +			ring->next_context_status_buffer = 0;
>  			if (ring->init_context) {
>  				ret = ring->init_context(ring,
>  						ring->default_context);
> diff --git a/drivers/gpu/drm/i915/intel_lrc.c b/drivers/gpu/drm/i915/intel_lrc.c
> index 7670a0f..4580267 100644
> --- a/drivers/gpu/drm/i915/intel_lrc.c
> +++ b/drivers/gpu/drm/i915/intel_lrc.c
> @@ -1394,7 +1394,6 @@ static int logical_ring_init(struct drm_device *dev, struct intel_engine_cs *rin
>  	INIT_LIST_HEAD(&ring->execlist_queue);
>  	INIT_LIST_HEAD(&ring->execlist_retired_req_list);
>  	spin_lock_init(&ring->execlist_lock);
> -	ring->next_context_status_buffer = 0;
>  
>  	ret = i915_cmd_parser_init_ring(ring);
>  	if (ret)
> -- 
> 1.7.9.5
> 
> _______________________________________________
> 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

  parent reply	other threads:[~2015-01-08  8:01 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-01-07 16:09 [PATCH] drm/i915: Reset CSB read pointer when enabling contexts Thomas Daniel
2015-01-07 16:56 ` Daniel Vetter
2015-01-07 20:39 ` shuang.he
2015-01-08  8:01 ` Daniel Vetter [this message]
2015-01-09 11:09 ` [PATCH v2] drm/i915: Reset CSB read pointer in ring init Thomas Daniel
2015-01-09 16:31   ` shuang.he
2015-01-09 16:54   ` Dave Gordon

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=20150108080118.GG26519@phenom.ffwll.local \
    --to=daniel@ffwll.ch \
    --cc=intel-gfx@lists.freedesktop.org \
    --cc=paulo.r.zanoni@intel.com \
    --cc=thomas.daniel@intel.com \
    /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