Use lockdep to warn before we wait indefinitely in case we may be waiting indefinitely. Suggested-by: Mika Kuoppala <mika.kuoppala@xxxxxxxxx> References: 2caffbf11762 ("drm/i915: Revoke mmaps and prevent access to fence registers across reset") Signed-off-by: Chris Wilson <chris@xxxxxxxxxxxxxxxxxx> Cc: Mika Kuoppala <mika.kuoppala@xxxxxxxxx> --- drivers/gpu/drm/i915/i915_reset.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/gpu/drm/i915/i915_reset.c b/drivers/gpu/drm/i915/i915_reset.c index c1b53533ada6..364c74d1d59b 100644 --- a/drivers/gpu/drm/i915/i915_reset.c +++ b/drivers/gpu/drm/i915/i915_reset.c @@ -1305,6 +1305,8 @@ int i915_reset_trylock(struct drm_i915_private *i915) struct i915_gpu_error *error = &i915->gpu_error; int srcu; + might_lock(&error->reset_backoff_srcu); + rcu_read_lock(); while (test_bit(I915_RESET_BACKOFF, &error->flags)) { rcu_read_unlock(); -- 2.20.1 _______________________________________________ Intel-gfx mailing list Intel-gfx@xxxxxxxxxxxxxxxxxxxxx https://lists.freedesktop.org/mailman/listinfo/intel-gfx