From: Rodrigo Vivi <rodrigo.vivi@intel.com>
To: Sanjay Yadav <sanjay.kumar.yadav@intel.com>
Cc: <intel-xe@lists.freedesktop.org>,
<dri-devel@lists.freedesktop.org>, <nirmoy.das@intel.com>,
<umesh.nerlige.ramappa@intel.com>,
<thomas.hellstrom@linux.intel.com>, <matthew.brost@intel.com>,
<niranjana.vishwanathapura@intel.com>,
<thomas.hellstrom@intel.com>, <fei.yang@intel.com>,
<himal.prasad.ghimiray@intel.com>, <matthew.d.roper@intel.com>,
<maarten.lankhorst@intel.com>, <joonas.lahtinen@intel.com>,
<matthew.auld@intel.com>, <stable@vger.kernel.org>
Subject: Re: [RFC PATCH 2/3] drm/sched: fix drm_sched_tdr_queue_imm to not corrupt timeout value
Date: Wed, 3 Jun 2026 09:47:30 -0400 [thread overview]
Message-ID: <aiAwcnWbsxUIMKbI@intel.com> (raw)
In-Reply-To: <20260603120641.473434-5-sanjay.kumar.yadav@intel.com>
On Wed, Jun 03, 2026 at 05:36:41PM +0530, Sanjay Yadav wrote:
> drm_sched_tdr_queue_imm() sets sched->timeout to 0 and never restores
> it. This breaks all future TDR timers — jobs get timed out instantly
> before they even start running on hardware.
>
> Use mod_delayed_work() directly to fire the TDR worker immediately
> without modifying the timeout field. This preserves the original
> timeout value for subsequent job submissions.
>
> Fixes: 8ec5a4e5ce97 ("drm/xe: Resume TDR after GT reset")
> Cc: <stable@vger.kernel.org> # v6.13+
> Cc: Matthew Brost <matthew.brost@intel.com>
> Cc: Thomas Hellström <thomas.hellstrom@linux.intel.com>
> Cc: Rodrigo Vivi <rodrigo.vivi@intel.com>
> Assisted-by: Claude:claude-opus-4.6
> Suggested-by: Himal Prasad Ghimiray <himal.prasad.ghimiray@intel.com>
> Signed-off-by: Sanjay Yadav <sanjay.kumar.yadav@intel.com>
> ---
> drivers/gpu/drm/scheduler/sched_main.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/gpu/drm/scheduler/sched_main.c b/drivers/gpu/drm/scheduler/sched_main.c
> index 818d3d4434b5..be144e244745 100644
> --- a/drivers/gpu/drm/scheduler/sched_main.c
> +++ b/drivers/gpu/drm/scheduler/sched_main.c
> @@ -212,8 +212,8 @@ static void drm_sched_start_timeout_unlocked(struct drm_gpu_scheduler *sched)
> void drm_sched_tdr_queue_imm(struct drm_gpu_scheduler *sched)
> {
> spin_lock(&sched->job_list_lock);
> - sched->timeout = 0;
> - drm_sched_start_timeout(sched);
> + if (!list_empty(&sched->pending_list))
> + mod_delayed_work(sched->timeout_wq, &sched->work_tdr, 0);
No, please. If there's something wrong with the timeout clear we need
to get that fixed at the drm layer instead of doing our own.
> spin_unlock(&sched->job_list_lock);
> }
> EXPORT_SYMBOL(drm_sched_tdr_queue_imm);
> --
> 2.52.0
>
next prev parent reply other threads:[~2026-06-03 13:47 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-06-03 12:06 [RFC PATCH 1/3] drm/xe: skip banning kernel migration queue on TDR timeout Sanjay Yadav
2026-06-03 12:06 ` [RFC PATCH 2/3] drm/sched: fix drm_sched_tdr_queue_imm to not corrupt timeout value Sanjay Yadav
2026-06-03 13:47 ` Rodrigo Vivi [this message]
2026-06-03 12:06 ` [RFC PATCH 3/3] drm/xe: don't cancel other pending jobs on kernel migration queue timeout Sanjay Yadav
2026-06-03 12:21 ` ✓ CI.KUnit: success for series starting with [RFC,1/3] drm/xe: skip banning kernel migration queue on TDR timeout Patchwork
2026-06-03 12:42 ` [RFC PATCH 1/3] " Matthew Auld
2026-06-03 13:52 ` Rodrigo Vivi
2026-06-03 15:13 ` Hellstrom, Thomas
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=aiAwcnWbsxUIMKbI@intel.com \
--to=rodrigo.vivi@intel.com \
--cc=dri-devel@lists.freedesktop.org \
--cc=fei.yang@intel.com \
--cc=himal.prasad.ghimiray@intel.com \
--cc=intel-xe@lists.freedesktop.org \
--cc=joonas.lahtinen@intel.com \
--cc=maarten.lankhorst@intel.com \
--cc=matthew.auld@intel.com \
--cc=matthew.brost@intel.com \
--cc=matthew.d.roper@intel.com \
--cc=niranjana.vishwanathapura@intel.com \
--cc=nirmoy.das@intel.com \
--cc=sanjay.kumar.yadav@intel.com \
--cc=stable@vger.kernel.org \
--cc=thomas.hellstrom@intel.com \
--cc=thomas.hellstrom@linux.intel.com \
--cc=umesh.nerlige.ramappa@intel.com \
/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.