On Sat, May 03, 2025 at 05:59:58PM -0300, Maíra Canal wrote: > Xe can skip the reset if TDR has fired before the free job worker. Instead > of using the scheduler internals to add the job to the pending list, use > the DRM_GPU_SCHED_STAT_RUNNING status to skip the reset and rearm the > timer. > > Note that there is no need to restart submission if it hasn't been > stopped. > > Signed-off-by: Maíra Canal <mca...@igalia.com> > --- > drivers/gpu/drm/xe/xe_guc_submit.c | 8 ++------ > 1 file changed, 2 insertions(+), 6 deletions(-) > > diff --git a/drivers/gpu/drm/xe/xe_guc_submit.c > b/drivers/gpu/drm/xe/xe_guc_submit.c > index > 31bc2022bfc2d80f0ef54726dfeb8d7f8e6b32c8..4c40d3921d4a5e190d3413736a68c6e7295223dd > 100644 > --- a/drivers/gpu/drm/xe/xe_guc_submit.c > +++ b/drivers/gpu/drm/xe/xe_guc_submit.c > @@ -1058,12 +1058,8 @@ guc_exec_queue_timedout_job(struct drm_sched_job > *drm_job) > * list so job can be freed and kick scheduler ensuring free job is not > * lost. > */ > - if (test_bit(DMA_FENCE_FLAG_SIGNALED_BIT, &job->fence->flags)) { > - xe_sched_add_pending_job(sched, job); > - xe_sched_submission_start(sched); > - > - return DRM_GPU_SCHED_STAT_NOMINAL; > - } > + if (test_bit(DMA_FENCE_FLAG_SIGNALED_BIT, &job->fence->flags)) > + return DRM_GPU_SCHED_STAT_RUNNING;
There are a couple of other calls to xe_sched_add_pending_job in this function which I can believe can be dropped in favor of return DRM_GPU_SCHED_STAT_RUNNING too. Matt > > /* Kill the run_job entry point */ > xe_sched_submission_stop(sched); > > -- > 2.49.0 >