Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 50683606A31A for ; Thu, 29 Oct 2026 13:26:39 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key, unprotected) header.d=intel.com header.i=@intel.com header.a=rsa-sha256 header.s=Intel header.b=UvfiaUGw Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 0B1CD1122B8; Thu, 29 Oct 2026 13:26:34 +0000 (UTC) Received: from mgamail.intel.com (mgamail.intel.com [198.175.65.13]) by gabe.freedesktop.org (Postfix) with ESMTPS id 6CEFE1122B8 for ; Thu, 29 Oct 2026 13:26:27 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1793280388; x=1824816388; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=BS29iwjzsTaxhVPKzXusuiNHy7UcxkAoXO1YYeIju0Y=; b=UvfiaUGwTcUFy0tdewAJn0SUHP0yfoFxTVkSB8/xpW2yz2GsNS6fWNli HHtE6iNOoczl3Dx1hnbxItgKHTUq3lpkwDnAQt8YuUoCpJtBzFcsJ4hYq 5jW045K/+nhl12BST8lReP933kMe7I8cRKnoETcx3ssfBlALTu3H1lymm svy1Z1ZhqyPZbzL/lc89FrzXg4BnLqZjTbbxrFJEX3sk1pbgkfF4RxoLn OyAVemH7GkrGC0VJp5XqTd0l34ymOFBsaRVUuC6TGguOmGHpBmzL1333/ 69Vbvul2r0xXh/+YLxl3v+9N3+BGFpvyJ8SRdDDTOAkuPX1kogH3bt0Wz g==; X-CSE-ConnectionGUID: 2YHlhSL1QwaOv6URBYejSQ== X-CSE-MsgGUID: RoQAIJ+FR0ynoejc7g1uFQ== X-IronPort-AV: E=McAfee;i="6800,10657,11949"; a="1900330" X-IronPort-AV: E=Sophos;i="6.27,184,1787036400"; d="scan'208";a="1900330" Received: from fmviesa010.fm.intel.com ([10.60.135.150]) by orvoesa105.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 29 Oct 2026 06:26:28 -0700 X-CSE-ConnectionGUID: L4F2jwAlQWifafO2hhK5lw== X-CSE-MsgGUID: e2862BNQQZmVDsuPODmASQ== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.27,184,1787036400"; d="scan'208";a="5691683" Received: from jraag-z790m-itx-wifi.iind.intel.com ([10.190.239.23]) by fmviesa010.fm.intel.com with ESMTP; 29 Oct 2026 06:26:24 -0700 From: Mallesh Koujalagi To: intel-xe@lists.freedesktop.org, rodrigo.vivi@intel.com, matthew.brost@intel.com Cc: anshuman.gupta@intel.com, badal.nilawar@intel.com, vinay.belgaumkar@intel.com, riana.tauro@intel.com, karthik.poosa@intel.com, sk.anirban@intel.com, raag.jadav@intel.com, michal.wajdeczko@intel.com, aravind.iddamsetty@linux.intel.com, jani.nikula@linux.intel.com, Mallesh Koujalagi Subject: [PATCH v2 2/6] drm/xe/cper: Add software error classification definitions Date: Thu, 29 Oct 2026 18:56:12 +0530 Message-ID: <20261029132609.907017-10-mallesh.koujalagi@intel.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20261029132609.907017-8-mallesh.koujalagi@intel.com> References: <20261029132609.907017-8-mallesh.koujalagi@intel.com> X-Archived-By: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-BeenThere: intel-xe@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Intel Xe graphics driver List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "Intel-xe" X-Spam-Status: No, score=-18.8 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_CR_TRAILER,INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE, SPF_PASS,USER_AGENT_GIT autolearn=ham autolearn_force=no version=4.0.1 X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-26) on aws-us-west-2-korg-listserv-alma10-1 Introduce driver-detected error classification fields and a notification GUID for software CPER records. Store the hardware and software error classifications in a shared union within struct xe_cper_intel_hdr. Signed-off-by: Mallesh Koujalagi --- v2: - Move union inside xe_cper_intel_hdr structure. (Badal) --- drivers/gpu/drm/xe/xe_cper_types.h | 35 ++++++++++++++++++++++++++++-- 1 file changed, 33 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/xe/xe_cper_types.h b/drivers/gpu/drm/xe/xe_cper_types.h index 68e30df0440e..d1c38a96e05d 100644 --- a/drivers/gpu/drm/xe/xe_cper_types.h +++ b/drivers/gpu/drm/xe/xe_cper_types.h @@ -40,11 +40,38 @@ GUID_INIT(0x4ae12aef, 0x8745, 0x5fc7, \ 0xb9, 0x96, 0x71, 0xee, 0xbb, 0x51, 0xf2, 0x23) +#define INTEL_CPER_NOTIFY_DRV_ERROR \ + GUID_INIT(0xcef7e934, 0x51e7, 0x535f, \ + 0xa6, 0x78, 0x5a, 0x4c, 0xcc, 0xb6, 0x96, 0x09) + /* Section Types */ #define INTEL_CPER_SECTION_ACCEL_GENERIC \ GUID_INIT(0xea9d8f84, 0x4258, 0x5227, \ 0x80, 0x28, 0xb9, 0xb1, 0x3e, 0x6d, 0x58, 0xb0) +/** + * struct xe_cper_driver_error_class - Intel GPU CPER driver-detected error classification + */ +struct xe_cper_driver_error_class { + /** @error_type: CPER severity: CPER_SEV_* */ + u8 error_type; + /** @reserved0: Reserved, must be zero */ + u8 reserved0; + /** @error_component: Driver component id: CLASS[7:0].TYPE[15:8] */ + u16 error_component; + /** @tile: Driver location id: TYPE[7:0].ID[15:8] ('tile' and 'GT' field region) */ + u16 tile; + /** @reserved1: Reserved, must be zero */ + u16 reserved1; + /** @cause: errno of the failing operation, or 0 if none */ + u32 cause; +}; + +/* Same size as the counter-sourced error_class */ +#define XE_CPER_ERROR_CLASS_SIZE 12 + +static_assert(sizeof(struct xe_cper_driver_error_class) == XE_CPER_ERROR_CLASS_SIZE); + /** * struct xe_cper_intel_hdr - Intel-specific CPER header * @@ -52,8 +79,12 @@ * All multi-byte fields are little-endian. */ struct xe_cper_intel_hdr { - /** @counter: Error class (severity, component, location, cause) */ - struct xe_ras_error_class counter; + union { + /** @counter: Error class (severity, component, location, cause) */ + struct xe_ras_error_class counter; + /** @driver: Driver-detected (software) error classification */ + struct xe_cper_driver_error_class driver; + }; /** @first_timestamp: First occurrence of this error class, in ticks */ u64 first_timestamp; /** @sig_id: Aggregated error class SIG ID; set to U32_MAX if unknown */ -- 2.48.1