[Intel-gfx] [PATCH 6/6] drm/i915/gt: Cancel a hung context if already closed

Tvrtko Ursulin tvrtko.ursulin at linux.intel.com
Thu Mar 19 14:43:36 UTC 2020


On 19/03/2020 14:40, Tvrtko Ursulin wrote:
> 
> On 19/03/2020 09:19, Chris Wilson wrote:
>> Use the restored ability to check if a context is closed to decide
>> whether or not to immediately ban the context from further execution
>> after a hang.
>>
>> Fixes: be90e344836a ("drm/i915/gt: Cancel banned contexts after GT 
>> reset")
>> Signed-off-by: Chris Wilson <chris at chris-wilson.co.uk>
>> Cc: Mika Kuoppala <mika.kuoppala at linux.intel.com>
>> Cc: Tvrtko Ursulin <tvrtko.ursulin at intel.com>
>> ---
>>   drivers/gpu/drm/i915/gt/intel_reset.c | 5 +++++
>>   1 file changed, 5 insertions(+)
>>
>> diff --git a/drivers/gpu/drm/i915/gt/intel_reset.c 
>> b/drivers/gpu/drm/i915/gt/intel_reset.c
>> index 9a15bdf31c7f..003f26b42998 100644
>> --- a/drivers/gpu/drm/i915/gt/intel_reset.c
>> +++ b/drivers/gpu/drm/i915/gt/intel_reset.c
>> @@ -88,6 +88,11 @@ static bool mark_guilty(struct i915_request *rq)
>>       bool banned;
>>       int i;
>> +    if (intel_context_is_closed(rq->context)) {
>> +        intel_context_set_banned(rq->context);
>> +        return true;
>> +    }
>> +
>>       rcu_read_lock();
>>       ctx = rcu_dereference(rq->context->gem_context);
>>       if (ctx && !kref_get_unless_zero(&ctx->ref))
>>
> 
> Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin at intel.com>

Although shards are reporting something is not quite right. Is it this 
patch? Doesn't look like it..

Regards,

Tvrtko




More information about the Intel-gfx mailing list