public inbox for intel-xe@lists.freedesktop.org
 help / color / mirror / Atom feed
From: Raag Jadav <raag.jadav@intel.com>
To: intel-xe@lists.freedesktop.org
Cc: matthew.brost@intel.com, rodrigo.vivi@intel.com,
	riana.tauro@intel.com, michal.wajdeczko@intel.com,
	matthew.d.roper@intel.com, umesh.nerlige.ramappa@intel.com,
	mallesh.koujalagi@intel.com, Raag Jadav <raag.jadav@intel.com>
Subject: [PATCH v1 3/3] drm/xe/cri: Wedge the device on hardware error
Date: Tue, 17 Feb 2026 17:16:33 +0530	[thread overview]
Message-ID: <20260217114656.2546878-4-raag.jadav@intel.com> (raw)
In-Reply-To: <20260217114656.2546878-1-raag.jadav@intel.com>

Hardware error interrupts are routed to SGUnit only for debug cases on
Crescent Island. Wedge the device and have it available to the user for
debugging.

Signed-off-by: Raag Jadav <raag.jadav@intel.com>
---
 drivers/gpu/drm/xe/xe_hw_error.c | 19 +++++++++++++++----
 1 file changed, 15 insertions(+), 4 deletions(-)

diff --git a/drivers/gpu/drm/xe/xe_hw_error.c b/drivers/gpu/drm/xe/xe_hw_error.c
index b704eab7d3bd..b756cbe321d6 100644
--- a/drivers/gpu/drm/xe/xe_hw_error.c
+++ b/drivers/gpu/drm/xe/xe_hw_error.c
@@ -55,11 +55,11 @@ 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;
 
-	ret = xe_survivability_mode_runtime_enable(xe);
-	if (ret)
-		drm_err(&xe->drm, "Failed to enable runtime survivability mode\n");
+	if (xe->info.platform == XE_CRESCENTISLAND)
+		xe_device_declare_wedged(xe);
+	else if (xe->info.platform == XE_BATTLEMAGE)
+		xe_survivability_mode_runtime_enable(xe);
 }
 
 static void csc_hw_error_handler(struct xe_tile *tile, const enum hardware_error hw_err)
@@ -104,6 +104,17 @@ static void hw_error_source_handler(struct xe_tile *tile, const enum hardware_er
 	unsigned long flags;
 	u32 err_src;
 
+	/*
+	 * We should never be here for CRI other than debug cases, so retain the hardware
+	 * state and bail without clearing error registers.
+	 */
+	if (xe->info.platform == XE_CRESCENTISLAND) {
+		drm_err_ratelimited(&xe->drm, HW_ERR "Tile%d reported %s error\n",
+				    tile->id, hw_err_str);
+		schedule_work(&tile->hw_error_work);
+		return;
+	}
+
 	if (xe->info.platform != XE_BATTLEMAGE)
 		return;
 
-- 
2.43.0


  parent reply	other threads:[~2026-02-17 11:51 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-02-17 11:46 [PATCH v1 0/3] Hardware Error handling for Crescent Island Raag Jadav
2026-02-17 11:46 ` [PATCH v1 1/3] drm/xe/cri: Setup hardware error routing Raag Jadav
2026-02-17 21:47   ` Matt Roper
2026-02-19  8:36     ` Raag Jadav
2026-03-26 12:49   ` Mallesh, Koujalagi
2026-04-01 18:21     ` Raag Jadav
2026-02-17 11:46 ` [PATCH v1 2/3] drm/xe/hw_error: Reuse CSC worker for generic error handling Raag Jadav
2026-02-17 11:46 ` Raag Jadav [this message]
2026-02-17 22:10   ` [PATCH v1 3/3] drm/xe/cri: Wedge the device on hardware error Matt Roper
2026-02-17 12:42 ` ✓ CI.KUnit: success for Hardware Error handling for Crescent Island Patchwork
2026-02-17 13:52 ` ✗ Xe.CI.BAT: failure " Patchwork
2026-02-17 16:14 ` ✓ Xe.CI.FULL: success " 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=20260217114656.2546878-4-raag.jadav@intel.com \
    --to=raag.jadav@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=riana.tauro@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