Intel-XE Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v1] drm/xe/ras: Distinguish between detailed and aggregate counters
@ 2026-11-02  9:04 Raag Jadav
  2026-11-02  9:32 ` ✓ CI.KUnit: success for " Patchwork
                   ` (6 more replies)
  0 siblings, 7 replies; 10+ messages in thread
From: Raag Jadav @ 2026-11-02  9:04 UTC (permalink / raw)
  To: intel-xe; +Cc: riana.tauro, Raag Jadav

xe_ras_get_counter_response() only logs counter value, severity and
component. Also log the type of counter for easier debugging.

Signed-off-by: Raag Jadav <raag.jadav@intel.com>
---
 drivers/gpu/drm/xe/xe_ras.c | 9 +++++++--
 1 file changed, 7 insertions(+), 2 deletions(-)

diff --git a/drivers/gpu/drm/xe/xe_ras.c b/drivers/gpu/drm/xe/xe_ras.c
index 2c01c183d02b..381ea19a8b4a 100644
--- a/drivers/gpu/drm/xe/xe_ras.c
+++ b/drivers/gpu/drm/xe/xe_ras.c
@@ -772,7 +772,9 @@ int xe_ras_get_counter_response(struct xe_device *xe, const struct xe_ras_error_
 {
 	struct xe_ras_get_counter_request request = {0};
 	struct xe_sysctrl_mailbox_command command = {0};
+	const struct xe_ras_error_product product = {0};
 	struct xe_ras_error_common *common;
+	bool detailed;
 	size_t rlen;
 	int ret;
 
@@ -798,8 +800,11 @@ int xe_ras_get_counter_response(struct xe_device *xe, const struct xe_ras_error_
 
 	common = &response->counter.common;
 
-	xe_dbg(xe, "[RAS]: get counter %u for %s %s\n", response->value,
-	       comp_to_str(common->component), sev_to_str(common->severity));
+	BUILD_BUG_ON(sizeof(*counter) != sizeof(counter->common) + sizeof(counter->product));
+	detailed = memcmp(&response->counter.product, &product, sizeof(product));
+
+	xe_dbg(xe, "[RAS]: get %s counter %u for %s %s\n", detailed ? "detailed" : "aggregate",
+	       response->value, comp_to_str(common->component), sev_to_str(common->severity));
 
 	return 0;
 }
-- 
2.43.0


^ permalink raw reply related	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2026-11-23  8:17 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-11-02  9:04 [PATCH v1] drm/xe/ras: Distinguish between detailed and aggregate counters Raag Jadav
2026-11-02  9:32 ` ✓ CI.KUnit: success for " Patchwork
2026-11-02 10:06 ` ✗ Xe.CI.BAT: failure " Patchwork
2026-11-02 10:37 ` ✗ Xe.CI.FULL: " Patchwork
2026-11-03  6:16 ` ✓ CI.KUnit: success for drm/xe/ras: Distinguish between detailed and aggregate counters (rev2) Patchwork
2026-11-03  6:49 ` ✓ Xe.CI.BAT: " Patchwork
2026-11-03 11:55 ` ✓ Xe.CI.FULL: " Patchwork
2026-11-23  6:46 ` [PATCH v1] drm/xe/ras: Distinguish between detailed and aggregate counters Tauro, Riana
2026-11-23  8:03   ` Raag Jadav
2026-11-23  8:17     ` Tauro, Riana

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox