diff mbox

[2/5] drm/i915: Change WARN to ERROR in CSB count

Message ID 1452018609-10142-3-git-send-email-benjamin.widawsky@intel.com (mailing list archive)
State New, archived
Headers show

Commit Message

Ben Widawsky Jan. 5, 2016, 6:30 p.m. UTC
There is no point in emitting a WARN since the backtrace will always be the
same. Errors have actually become easier to spot given the large number of WARNs
which exist today in modesetting paths.

Signed-off-by: Ben Widawsky <benjamin.widawsky@intel.com>
---
 drivers/gpu/drm/i915/intel_lrc.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

Comments

Michel Thierry Jan. 6, 2016, 3:09 p.m. UTC | #1
On 1/5/2016 6:30 PM, Ben Widawsky wrote:
> There is no point in emitting a WARN since the backtrace will always be the
> same. Errors have actually become easier to spot given the large number of WARNs
> which exist today in modesetting paths.
>
> Signed-off-by: Ben Widawsky <benjamin.widawsky@intel.com>
> ---
>   drivers/gpu/drm/i915/intel_lrc.c | 4 +++-
>   1 file changed, 3 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/i915/intel_lrc.c b/drivers/gpu/drm/i915/intel_lrc.c
> index 7fb2035..14affaa 100644
> --- a/drivers/gpu/drm/i915/intel_lrc.c
> +++ b/drivers/gpu/drm/i915/intel_lrc.c
> @@ -556,7 +556,9 @@ void intel_lrc_irq_handler(struct intel_engine_cs *ring)
>
>          spin_unlock(&ring->execlist_lock);
>
> -       WARN(submit_contexts > 2, "More than two context complete events?\n");
> +       if (unlikely(submit_contexts > 2))
> +               DRM_ERROR("More than two context complete events?\n");
> +
>          ring->next_context_status_buffer = write_pointer % GEN8_CSB_ENTRIES;
>
>          /* Update the read pointer to the old write pointer. Manual ringbuffer

And it's unlikely we'd recover without some kind of GPU reset...

Reviewed-by: Michel Thierry <michel.thierry@intel.com>

> --
> 2.6.4
>
> _______________________________________________
> Intel-gfx mailing list
> Intel-gfx@lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/intel-gfx
>
diff mbox

Patch

diff --git a/drivers/gpu/drm/i915/intel_lrc.c b/drivers/gpu/drm/i915/intel_lrc.c
index 7fb2035..14affaa 100644
--- a/drivers/gpu/drm/i915/intel_lrc.c
+++ b/drivers/gpu/drm/i915/intel_lrc.c
@@ -556,7 +556,9 @@  void intel_lrc_irq_handler(struct intel_engine_cs *ring)
 
 	spin_unlock(&ring->execlist_lock);
 
-	WARN(submit_contexts > 2, "More than two context complete events?\n");
+	if (unlikely(submit_contexts > 2))
+		DRM_ERROR("More than two context complete events?\n");
+
 	ring->next_context_status_buffer = write_pointer % GEN8_CSB_ENTRIES;
 
 	/* Update the read pointer to the old write pointer. Manual ringbuffer