From: "Tauro, Riana" <riana.tauro@intel.com>
To: Raag Jadav <raag.jadav@intel.com>, <intel-xe@lists.freedesktop.org>
Cc: <matthew.brost@intel.com>, <rodrigo.vivi@intel.com>,
<michal.wajdeczko@intel.com>, <matthew.d.roper@intel.com>,
<umesh.nerlige.ramappa@intel.com>, <mallesh.koujalagi@intel.com>
Subject: Re: [PATCH v2 3/4] drm/xe/hw_error: Allow debugging hardware errors
Date: Mon, 27 Apr 2026 13:50:53 +0530 [thread overview]
Message-ID: <4b73f2c7-d52a-4654-8559-befae2ad0263@intel.com> (raw)
In-Reply-To: <20260402174229.1062874-4-raag.jadav@intel.com>
On 4/2/2026 11:12 PM, Raag Jadav wrote:
> Hardware errors are reported through System Controller on the platforms
> that support it, and never routed as direct IRQ to SGUnit other than
> debug cases. Wedge the device on XE_WEDGED_MODE_UPON_ANY_HANG_NO_RESET
> so that the hardware errors are available to the user for debugging.
>
> Signed-off-by: Raag Jadav <raag.jadav@intel.com>
> ---
> v2: Explain the usecase (Matt Roper)
> ---
> drivers/gpu/drm/xe/xe_hw_error.c | 24 ++++++++++++++++++++----
> 1 file changed, 20 insertions(+), 4 deletions(-)
>
> diff --git a/drivers/gpu/drm/xe/xe_hw_error.c b/drivers/gpu/drm/xe/xe_hw_error.c
> index c7b720ba5a4f..79a85925a02f 100644
> --- a/drivers/gpu/drm/xe/xe_hw_error.c
> +++ b/drivers/gpu/drm/xe/xe_hw_error.c
> @@ -169,11 +169,14 @@ static void hw_error_work(struct work_struct *work)
> {
> struct xe_tile *tile = container_of(work, typeof(*tile), hw_error_work);
> struct xe_device *xe = tile_to_xe(tile);
> - int ret;
> + bool wedge = xe->wedged.mode == XE_WEDGED_MODE_UPON_ANY_HANG_NO_RESET;
>
> - ret = xe_survivability_mode_runtime_enable(xe);
> - if (ret)
> - drm_err(&xe->drm, "Failed to enable runtime survivability mode\n");
> + if (wedge) {
A fault_inject_csc_hw_error check should also be added here.
There could be a condition where fault injection is enabled along with
XE_WEDGED_MODE_UPON_ANY_HANG_NO_RESET. Thanks Riana
> + xe_device_declare_wedged(xe);
> + return;
> + }
> +
> + xe_survivability_mode_runtime_enable(xe);
> }
>
> static void csc_hw_error_handler(struct xe_tile *tile, const enum hardware_error hw_err)
> @@ -433,6 +436,19 @@ static void hw_error_source_handler(struct xe_tile *tile, const enum hardware_er
> if (!IS_DGFX(xe))
> return;
>
> + if (xe->info.has_sysctrl) {
> + /*
> + * Hardware errors are reported through System Controller on the platforms that
> + * support it, so we should never be here other than debug cases. Retain the
> + * hardware state and bail without clearing error registers, so that they are
> + * available to the user for debugging.
> + */
> + drm_err_ratelimited(&xe->drm, HW_ERR "Tile%d reported %s error\n",
> + tile->id, severity_str);
> + schedule_work(&tile->hw_error_work);
> + return;
> + }
> +
> spin_lock_irqsave(&xe->irq.lock, flags);
> err_src = xe_mmio_read32(&tile->mmio, DEV_ERR_STAT_REG(hw_err));
> if (!err_src) {
next prev parent reply other threads:[~2026-04-27 8:21 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-04-02 17:42 [PATCH v2 0/4] Hardware Error handling for Crescent Island Raag Jadav
2026-04-02 17:42 ` [PATCH v2 1/4] drm/xe/hw_error: Setup hardware error routing Raag Jadav
2026-04-27 8:14 ` Tauro, Riana
2026-04-02 17:42 ` [PATCH v2 2/4] drm/xe/hw_error: Reuse CSC worker for generic error handling Raag Jadav
2026-04-27 8:18 ` Tauro, Riana
2026-04-02 17:42 ` [PATCH v2 3/4] drm/xe/hw_error: Allow debugging hardware errors Raag Jadav
2026-04-27 8:20 ` Tauro, Riana [this message]
2026-04-02 17:42 ` [PATCH v2 4/4] drm/xe/debugfs: Update hardware error routing with wedged.mode Raag Jadav
2026-04-02 17:53 ` ✓ CI.KUnit: success for Hardware Error handling for Crescent Island (rev2) Patchwork
2026-04-02 18:43 ` ✓ Xe.CI.BAT: " Patchwork
2026-04-03 6:37 ` ✓ Xe.CI.FULL: " Patchwork
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=4b73f2c7-d52a-4654-8559-befae2ad0263@intel.com \
--to=riana.tauro@intel.com \
--cc=intel-xe@lists.freedesktop.org \
--cc=mallesh.koujalagi@intel.com \
--cc=matthew.brost@intel.com \
--cc=matthew.d.roper@intel.com \
--cc=michal.wajdeczko@intel.com \
--cc=raag.jadav@intel.com \
--cc=rodrigo.vivi@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox