On 02/07/2026 15:37, Tvrtko Ursulin wrote:
> After calling drm_sched_job_cleanup(), the free job callback releases it's

NIT: s/it's/its/

> reference to the job, where the act of dropping the last reference will
> also call the drm_sched_job_cleanup() helper.
> 
> We can therefore remove the redundant call from the .free_job callback.
> 
> But we have to leave the "if (job->base.s_fence)" guard in job_release(),
> since that one not only handles the above described double cleanup, but
> also deals with all job cleanup paths which happen before the point the
> job was armed.
> 
> Signed-off-by: Tvrtko Ursulin <[email protected]>
> Cc: Boris Brezillon <[email protected]>
> Cc: Liviu Dudau <[email protected]>
> Cc: Steven Price <[email protected]>

I agree this looks redundant.

Reviewed-by: Steven Price <[email protected]>

Thanks,
Steve

> ---
>  drivers/gpu/drm/panthor/panthor_sched.c | 1 -
>  1 file changed, 1 deletion(-)
> 
> diff --git a/drivers/gpu/drm/panthor/panthor_sched.c 
> b/drivers/gpu/drm/panthor/panthor_sched.c
> index 5b34032deff8..2bee1c92fb9e 100644
> --- a/drivers/gpu/drm/panthor/panthor_sched.c
> +++ b/drivers/gpu/drm/panthor/panthor_sched.c
> @@ -3434,7 +3434,6 @@ queue_timedout_job(struct drm_sched_job *sched_job)
>  
>  static void queue_free_job(struct drm_sched_job *sched_job)
>  {
> -     drm_sched_job_cleanup(sched_job);
>       panthor_job_put(sched_job);
>  }
>  

Reply via email to