All of lore.kernel.org
 help / color / mirror / Atom feed
From: Andi Shyti <andi.shyti@intel.com>
To: Chris Wilson <chris@chris-wilson.co.uk>
Cc: intel-gfx@lists.freedesktop.org
Subject: Re: [Intel-gfx] [PATCH 3/6] drm/i915/gt: Allow failed resets without assertion
Date: Tue, 5 Jan 2021 03:55:16 +0200	[thread overview]
Message-ID: <X/PHBIqvkoo9E8g3@intel.intel> (raw)
In-Reply-To: <20210104115145.24460-3-chris@chris-wilson.co.uk>

Hi Chris,

On Mon, Jan 04, 2021 at 11:51:42AM +0000, Chris Wilson wrote:
> If the engine reset fails, we will attempt to resume with the current
> inflight submissions. When that happens, we cannot assert that the
> engine reset cleared the pending submission, so do not.
> 
> Closes: https://gitlab.freedesktop.org/drm/intel/-/issues/2878
> Fixes: 16f2941ad307 ("drm/i915/gt: Replace direct submit with direct call to tasklet")
> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
> Cc: Mika Kuoppala <mika.kuoppala@linux.intel.com>
> ---
>  drivers/gpu/drm/i915/gt/intel_engine_types.h  |  2 +
>  .../drm/i915/gt/intel_execlists_submission.c  |  6 +-
>  drivers/gpu/drm/i915/gt/intel_reset.c         |  3 +
>  drivers/gpu/drm/i915/gt/selftest_execlists.c  | 75 +++++++++++++++++++
>  4 files changed, 85 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/gpu/drm/i915/gt/intel_engine_types.h b/drivers/gpu/drm/i915/gt/intel_engine_types.h
> index c28f4e190fe6..430066e5884c 100644
> --- a/drivers/gpu/drm/i915/gt/intel_engine_types.h
> +++ b/drivers/gpu/drm/i915/gt/intel_engine_types.h
> @@ -561,6 +561,8 @@ struct intel_engine_cs {
>  		unsigned long stop_timeout_ms;
>  		unsigned long timeslice_duration_ms;
>  	} props, defaults;
> +
> +	I915_SELFTEST_DECLARE(struct fault_attr reset_timeout);
>  };
>  
>  static inline bool
> diff --git a/drivers/gpu/drm/i915/gt/intel_execlists_submission.c b/drivers/gpu/drm/i915/gt/intel_execlists_submission.c
> index 2afbc0a4ca03..f02e3ae10d28 100644
> --- a/drivers/gpu/drm/i915/gt/intel_execlists_submission.c
> +++ b/drivers/gpu/drm/i915/gt/intel_execlists_submission.c
> @@ -3047,9 +3047,13 @@ static void execlists_reset_finish(struct intel_engine_cs *engine)
>  	 * After a GPU reset, we may have requests to replay. Do so now while
>  	 * we still have the forcewake to be sure that the GPU is not allowed
>  	 * to sleep before we restart and reload a context.
> +	 *
> +	 * If the GPU reset fails, the engine may still be alive with requests
> +	 * inflight. We expect those to complete, or for the device to be
> +	 * reset as the next level of recovery, and as a final resort we
> +	 * will declare the device wedged.
>  	 */
>  	GEM_BUG_ON(!reset_in_progress(execlists));
> -	GEM_BUG_ON(engine->execlists.pending[0]);

I would have split this in two patches, but it looks good anyway.

Reviewed-by: Andi Shyti <andi.shyti@intel.com>

Thanks,
Andi
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

  reply	other threads:[~2021-01-05  1:55 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-01-04 11:51 [Intel-gfx] [PATCH 1/6] drm/i915/selftests: Set error returns Chris Wilson
2021-01-04 11:51 ` [Intel-gfx] [PATCH 2/6] drm/i915: Set rawclk earlier during mmio probe Chris Wilson
2021-01-05  1:53   ` Andi Shyti
2021-01-04 11:51 ` [Intel-gfx] [PATCH 3/6] drm/i915/gt: Allow failed resets without assertion Chris Wilson
2021-01-05  1:55   ` Andi Shyti [this message]
2021-01-04 11:51 ` [Intel-gfx] [PATCH 4/6] drm/i915/gt: Check the virtual still matches upon locking Chris Wilson
2021-01-05  1:55   ` Andi Shyti
2021-01-04 11:51 ` [Intel-gfx] [PATCH 5/6] drm/i915/gt: Restore ce->signal flush before releasing virtual engine Chris Wilson
2021-01-05  1:57   ` Andi Shyti
2021-01-04 11:51 ` [Intel-gfx] [PATCH 6/6] drm/i915/gt: Remove timeslice suppression Chris Wilson
2021-01-06  0:07   ` Andi Shyti
2021-01-06  0:27     ` Chris Wilson
2021-01-06  0:29   ` [Intel-gfx] [PATCH] " Chris Wilson
2021-01-04 12:35 ` [Intel-gfx] ✗ Fi.CI.CHECKPATCH: warning for series starting with [1/6] drm/i915/selftests: Set error returns Patchwork
2021-01-04 13:05 ` [Intel-gfx] ✓ Fi.CI.BAT: success " Patchwork
2021-01-04 15:04 ` [Intel-gfx] ✗ Fi.CI.IGT: failure " Patchwork
2021-01-05  1:53 ` [Intel-gfx] [PATCH 1/6] " Andi Shyti
2021-01-06  1:07 ` [Intel-gfx] ✗ Fi.CI.CHECKPATCH: warning for series starting with [1/6] drm/i915/selftests: Set error returns (rev2) Patchwork
2021-01-06  1:36 ` [Intel-gfx] ✓ Fi.CI.BAT: success " Patchwork
2021-01-06  3:49 ` [Intel-gfx] ✓ Fi.CI.IGT: " 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=X/PHBIqvkoo9E8g3@intel.intel \
    --to=andi.shyti@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.