All of lore.kernel.org
 help / color / mirror / Atom feed
From: Michal Wajdeczko <michal.wajdeczko@intel.com>
To: intel-gfx@lists.freedesktop.org
Cc: Michal Wajdeczko <michal.wajdeczko@intel.com>,
	Daniel Vetter <daniel.vetter@ffwll.ch>
Subject: [Intel-gfx] [CI v2 2/4] drm/i915/guc: Print error name on CTB (de)registration failure
Date: Sun, 26 Sep 2021 20:45:43 +0200	[thread overview]
Message-ID: <20210926184545.1407-3-michal.wajdeczko@intel.com> (raw)
In-Reply-To: <20210926184545.1407-1-michal.wajdeczko@intel.com>

Instead of plain error value (%d) print more user friendly error
name (%pe).

Signed-off-by: Michal Wajdeczko <michal.wajdeczko@intel.com>
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
---
 drivers/gpu/drm/i915/gt/uc/intel_guc_ct.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/drivers/gpu/drm/i915/gt/uc/intel_guc_ct.c b/drivers/gpu/drm/i915/gt/uc/intel_guc_ct.c
index c39abb010181..b6c2f2a11dc5 100644
--- a/drivers/gpu/drm/i915/gt/uc/intel_guc_ct.c
+++ b/drivers/gpu/drm/i915/gt/uc/intel_guc_ct.c
@@ -191,8 +191,8 @@ static int ct_register_buffer(struct intel_guc_ct *ct, u32 type,
 	err = guc_action_register_ct_buffer(ct_to_guc(ct), type,
 					    desc_addr, buff_addr, size);
 	if (unlikely(err))
-		CT_ERROR(ct, "Failed to register %s buffer (err=%d)\n",
-			 guc_ct_buffer_type_to_str(type), err);
+		CT_ERROR(ct, "Failed to register %s buffer (%pe)\n",
+			 guc_ct_buffer_type_to_str(type), ERR_PTR(err));
 	return err;
 }
 
@@ -219,8 +219,8 @@ static int ct_deregister_buffer(struct intel_guc_ct *ct, u32 type)
 	int err = guc_action_deregister_ct_buffer(ct_to_guc(ct), type);
 
 	if (unlikely(err))
-		CT_ERROR(ct, "Failed to deregister %s buffer (err=%d)\n",
-			 guc_ct_buffer_type_to_str(type), err);
+		CT_ERROR(ct, "Failed to deregister %s buffer (%pe)\n",
+			 guc_ct_buffer_type_to_str(type), ERR_PTR(err));
 	return err;
 }
 
-- 
2.25.1


  parent reply	other threads:[~2021-09-26 18:46 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-09-26 18:45 [Intel-gfx] [CI v2 0/4] drm/i915/guc: Improve CTB error handling Michal Wajdeczko
2021-09-26 18:45 ` [Intel-gfx] [CI v2 1/4] drm/i915/guc: Verify result from CTB (de)register action Michal Wajdeczko
2021-09-26 18:45 ` Michal Wajdeczko [this message]
2021-09-26 18:45 ` [Intel-gfx] [CI v2 3/4] drm/i915/guc: Print error name on CTB send failure Michal Wajdeczko
2021-09-26 18:45 ` [Intel-gfx] [CI v2 4/4] drm/i915/guc: Move and improve error message for missed CTB reply Michal Wajdeczko
2021-09-26 19:26 ` [Intel-gfx] ✓ Fi.CI.BAT: success for drm/i915/guc: Improve CTB error handling (rev3) Patchwork
2021-09-26 20:31 ` [Intel-gfx] ✓ Fi.CI.IGT: " Patchwork
2021-10-01 19:08   ` Matt Roper

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=20210926184545.1407-3-michal.wajdeczko@intel.com \
    --to=michal.wajdeczko@intel.com \
    --cc=daniel.vetter@ffwll.ch \
    --cc=intel-gfx@lists.freedesktop.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.