Intel-XE Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: "Mallesh, Koujalagi" <mallesh.koujalagi@intel.com>
To: Michal Wajdeczko <michal.wajdeczko@intel.com>,
	<intel-xe@lists.freedesktop.org>, <rodrigo.vivi@intel.com>,
	<matthew.brost@intel.com>, <thomas.hellstrom@linux.intel.com>
Cc: <anshuman.gupta@intel.com>, <badal.nilawar@intel.com>,
	<vinay.belgaumkar@intel.com>, <aravind.iddamsetty@intel.com>,
	<riana.tauro@intel.com>, <karthik.poosa@intel.com>,
	<sk.anirban@intel.com>, <raag.jadav@intel.com>
Subject: Re: [RFC PATCH v3 1/3] drm/xe: Add error Signature IDs for RAS logging
Date: Wed, 24 Jun 2026 17:21:19 +0530	[thread overview]
Message-ID: <c06980ee-87ca-4cf8-b5f0-214486eb989b@intel.com> (raw)
In-Reply-To: <db58c7ea-8d55-40c6-9fc7-b69878a02505@intel.com>


On 20-06-2026 10:32 pm, Michal Wajdeczko wrote:
>
> On 6/17/2026 12:47 PM, Mallesh Koujalagi wrote:
>> Every GPU fault needs a stable numeric label so monitoring tools can
> so the goal is to assign unique number to each GPU error that we report?

Thanks for questions, happy to clarify.

Not exactly. SIG_IDs represent types of errors,

not individual events. For example, XE_SIG_WEDGED = 2 just mean a 
"device wedged" error happened.

Multiple log message can share the same SIG_ID because they belongs to 
same category.
>
> can't we teach the monitoring tools to use the message pattern instead?

We can and that is basically what HW_ERR "[Hardware Error]" does today. 
But that approach is

fragile. If the message tech changes (Wording etc) the pattern can 
break. So that is reason a

numeric ID like SIG_ID is more stable and acts like a reliable 
interface, even if the message text changes.

>
> or maybe it's not about unique signature but rather class of Xe GPU errors?
> like HW_ERR defined in [1] for generic hardware errors?
>
> [1] https://elixir.bootlin.com/linux/v7.1/source/include/linux/printk.h#L118

Yes, that is the closest comparison. The difference is that SIG_IDs are 
numeric, specific to Xe

and designed to work with CPER.

>> identify what went wrong without parsing log text.
> hmm, but they will have to parse this text already to find that ID

Fair point, I'll fix the commit message. Tool can identify what went 
wrong by matching the stable SIG_ID field,

without relying on message text.

>> Add xe_sig_ids.h
>> which defines those labels, called SIG_IDs.
> SIG_ID looks like an acronym already - can we know the full real name?
SIG_ID expands to “Signature ID.” which is mentioned in the Spec.
>
> the 'signature' suggests uniqueness, but below definitions are more like a 'class' of errors/faults

It designed function as a stable component/category identifier for a 
class of errors, with the specific cause carried separately

errno, message text etc.

>> Signed-off-by: Mallesh Koujalagi <mallesh.koujalagi@intel.com>
>> ---
>> v3:
>> - Add HW SIG IDS details. (Riana)
>> ---
>>   drivers/gpu/drm/xe/xe_sig_ids.h | 29 +++++++++++++++++++++++++++++
>>   1 file changed, 29 insertions(+)
>>   create mode 100644 drivers/gpu/drm/xe/xe_sig_ids.h
>>
>> diff --git a/drivers/gpu/drm/xe/xe_sig_ids.h b/drivers/gpu/drm/xe/xe_sig_ids.h
>> new file mode 100644
>> index 000000000000..7badd0d7ad72
>> --- /dev/null
>> +++ b/drivers/gpu/drm/xe/xe_sig_ids.h
>> @@ -0,0 +1,29 @@
>> +/* SPDX-License-Identifier: MIT */
>> +/*
>> + * Copyright © 2026 Intel Corporation
>> + */
>> +
>> +#ifndef _XE_SIG_IDS_H_
>> +#define _XE_SIG_IDS_H_
>> +
>> +/*
>> + * Driver SIG_IDs
> please add kernel-doc for SIG_IDs itself
> maybe then it will be clear what is it
Sure, will add in next revision.
>
> based on the "Every GPU fault needs a stable numeric label"
> maybe the more appropriate name would be names like:
>
> 	XE_ERROR_
> 	XE_FAULT_
>
Agreed, need to check with Arch team.
>> + */
>> +#define XE_SIG_PROBE			1  /* FATAL: probe failed */
>> +#define XE_SIG_WEDGED			2  /* FATAL: device wedged */
>> +#define XE_SIG_SURVIVABILITY		3  /* FATAL: survivability mode */
>> +#define XE_SIG_FW			4  /* RECOVERABLE: GuC/HuC/UC/GSC/CSC/PCODE */
>> +#define XE_SIG_GT_TDR			5  /* RECOVERABLE: engine hang / reset */
>> +#define XE_SIG_MEM_FAULT		6  /* RECOVERABLE: VM bind, page fault, GTT */
>> +#define XE_SIG_IO_BUS			7  /* RECOVERABLE: runtime PCIe/IOMMU/MMIO */
> at this patch, there is no description what FATAL or RECOVERABLE (severity?) really means here
> also, if there is a strict relation between SIG and its severity, then maybe those definitions should look like:
>
> #define XE_SIG_PROBE			XE_SIG(1, FATAL)
> #define XE_SIG_WEDGED			XE_SIG(2, FATAL)
> ...
>
> but

Agreed. For driver SIG_IDs, severity is part of the contract, not just 
an incidental comment.

Sure, I can add the severity details in the header.

>> +
>> +/*
>> + * HW SIG_IDs
>> + */
> below SIGs do not have associated severity
> why the same family of IDs is defined so differently?

This is intentional. Driver SIG_IDs are paired with fixed severities via 
the driver logging macros,

while Hardware SIG_IDs identify only the hardware component. Hardware 
severity is not fixed per SIG_ID,

it is carried by the incoming CPER record and may vary per event.

>> +#define XE_SIG_HW_DEVICE_MEMORY		8  /* Device memory errors (e.g. ECC) */
>> +#define XE_SIG_HW_CORE_COMPUTE		9  /* Compute/shader core errors */
>> +#define XE_SIG_HW_PCIE			10 /* PCIe interface errors */
>> +#define XE_SIG_HW_FABRIC		11 /* On-package fabric errors */
>> +#define XE_SIG_HW_SOC_INTERNAL		12 /* SoC-internal errors */
> what's the plan for extending SW or HW SIG_IDs in the future?

The current scheme assumes driver IDs are a fixed low range and HW IDs 
occupy the next contiguous range,

with range alone distinguishing Driver vs Hardware.

> as now it looks that will not be able to have new SW IDs together with old ones
>
> and I guess the goal is to not change the IDs assignments

Yes, the stated goal is stable IDs.

Thanks,

-/Mallesh

>
>> +
>> +#endif /* _XE_SIG_IDS_H_ */

  reply	other threads:[~2026-06-24 11:51 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-06-17 10:47 [RFC PATCH v3 0/3] drm/xe: Structured RAS error logging infrastructure Mallesh Koujalagi
2026-06-17 10:47 ` [RFC PATCH v3 1/3] drm/xe: Add error Signature IDs for RAS logging Mallesh Koujalagi
2026-06-19  5:48   ` Tauro, Riana
2026-06-23  7:41     ` Mallesh, Koujalagi
2026-06-20 17:02   ` Michal Wajdeczko
2026-06-24 11:51     ` Mallesh, Koujalagi [this message]
2026-06-17 10:47 ` [RFC PATCH v3 2/3] drm/xe: Add RAS logging helpers Mallesh Koujalagi
2026-06-19  5:43   ` Tauro, Riana
2026-06-23 10:41     ` Mallesh, Koujalagi
2026-06-20 19:29   ` Michal Wajdeczko
2026-06-24 16:03     ` Mallesh, Koujalagi
2026-07-03 11:23       ` Tauro, Riana
2026-06-17 10:47 ` [RFC PATCH v3 3/3] drm/xe: use XE_RAS_WEDGED macro in xe_device_declare_wedged Mallesh Koujalagi
2026-06-17 16:06   ` Bhadane, Dnyaneshwar
2026-06-20 19:39   ` Michal Wajdeczko
2026-06-24 16:16     ` Mallesh, Koujalagi
2026-06-17 11:11 ` ✗ CI.checkpatch: warning for drm/xe: Structured RAS error logging infrastructure (rev3) Patchwork
2026-06-17 11:11 ` ✗ CI.KUnit: failure " 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=c06980ee-87ca-4cf8-b5f0-214486eb989b@intel.com \
    --to=mallesh.koujalagi@intel.com \
    --cc=anshuman.gupta@intel.com \
    --cc=aravind.iddamsetty@intel.com \
    --cc=badal.nilawar@intel.com \
    --cc=intel-xe@lists.freedesktop.org \
    --cc=karthik.poosa@intel.com \
    --cc=matthew.brost@intel.com \
    --cc=michal.wajdeczko@intel.com \
    --cc=raag.jadav@intel.com \
    --cc=riana.tauro@intel.com \
    --cc=rodrigo.vivi@intel.com \
    --cc=sk.anirban@intel.com \
    --cc=thomas.hellstrom@linux.intel.com \
    --cc=vinay.belgaumkar@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