From: Matthew Brost <matthew.brost@intel.com>
To: Shuicheng Lin <shuicheng.lin@intel.com>
Cc: <intel-xe@lists.freedesktop.org>
Subject: Re: [PATCH 2/2] drm/xe/guc: Refine CT queue checks and log formatting
Date: Mon, 23 Feb 2026 09:05:33 -0800 [thread overview]
Message-ID: <aZyI3Z9MTuwDCl2q@lstrano-desk.jf.intel.com> (raw)
In-Reply-To: <20260223162350.3205364-6-shuicheng.lin@intel.com>
On Mon, Feb 23, 2026 at 04:23:53PM +0000, Shuicheng Lin wrote:
> Fix three code-level cleanups in xe_guc_ct.c:
>
> - Use SZ_4K for the queue size alignment assertion in
> xe_guc_ct_queue_proc_time_jiffies().
> - Drop an unused local variable in guc_ct_send_wait_for_retry().
> - Add missing trailing newlines in CT error/warn log messages.
>
Typically we try to break stuff into smaller patches but I'm fine with
single patch of one line fixes in this case. I can't say no one else
complain though.
Anyways everything in this patch LGTM:
Reviewed-by: Matthew Brost <matthew.brost@intel.com>
> These changes keep behavior unchanged while improving correctness checks
> and log formatting.
>
> Signed-off-by: Shuicheng Lin <shuicheng.lin@intel.com>
> ---
> drivers/gpu/drm/xe/xe_guc_ct.c | 11 +++++------
> 1 file changed, 5 insertions(+), 6 deletions(-)
>
> diff --git a/drivers/gpu/drm/xe/xe_guc_ct.c b/drivers/gpu/drm/xe/xe_guc_ct.c
> index 1c37813d2ccd..d0f0586121bc 100644
> --- a/drivers/gpu/drm/xe/xe_guc_ct.c
> +++ b/drivers/gpu/drm/xe/xe_guc_ct.c
> @@ -275,7 +275,7 @@ static bool g2h_fence_needs_alloc(struct g2h_fence *g2h_fence)
> */
> long xe_guc_ct_queue_proc_time_jiffies(struct xe_guc_ct *ct)
> {
> - BUILD_BUG_ON(!IS_ALIGNED(CTB_H2G_BUFFER_SIZE, SZ_4));
> + BUILD_BUG_ON(!IS_ALIGNED(CTB_H2G_BUFFER_SIZE, SZ_4K));
> return (CTB_H2G_BUFFER_SIZE / SZ_4K) * HZ;
> }
>
> @@ -1126,7 +1126,6 @@ static bool guc_ct_send_wait_for_retry(struct xe_guc_ct *ct, u32 len,
> len + GUC_CTB_HDR_LEN);
> *sleep_total_ms += xe_sleep_exponential_ms(sleep_period_ms, 64);
> } else {
> - struct xe_device *xe = ct_to_xe(ct);
> struct guc_ctb *g2h = &ct->ctbs.g2h;
> int ret;
>
> @@ -1148,7 +1147,7 @@ static bool guc_ct_send_wait_for_retry(struct xe_guc_ct *ct, u32 len,
> ret = dequeue_one_g2h(ct);
> if (ret < 0) {
> if (ret != -ECANCELED)
> - xe_gt_err(ct_to_gt(ct), "CTB receive failed (%pe)",
> + xe_gt_err(ct_to_gt(ct), "CTB receive failed (%pe)\n",
> ERR_PTR(ret));
> return false;
> }
> @@ -1324,7 +1323,7 @@ static int guc_ct_send_recv(struct xe_guc_ct *ct, const u32 *action, u32 len,
> */
> mutex_lock(&ct->lock);
> if (!ret) {
> - xe_gt_err(gt, "Timed out wait for G2H, fence %u, action %04x, done %s",
> + xe_gt_err(gt, "Timed out wait for G2H, fence %u, action %04x, done %s\n",
> g2h_fence.seqno, action[0], str_yes_no(g2h_fence.done));
> xa_erase(&ct->fence_lookup, g2h_fence.seqno);
> mutex_unlock(&ct->lock);
> @@ -1834,7 +1833,7 @@ static void g2h_fast_path(struct xe_guc_ct *ct, u32 *msg, u32 len)
> ret = xe_guc_tlb_inval_done_handler(guc, payload, adj_len);
> break;
> default:
> - xe_gt_warn(gt, "NOT_POSSIBLE");
> + xe_gt_warn(gt, "NOT_POSSIBLE\n");
> }
>
> if (ret) {
> @@ -1937,7 +1936,7 @@ static void receive_g2h(struct xe_guc_ct *ct)
> mutex_unlock(&ct->lock);
>
> if (unlikely(ret == -EPROTO || ret == -EOPNOTSUPP)) {
> - xe_gt_err(ct_to_gt(ct), "CT dequeue failed: %d", ret);
> + xe_gt_err(ct_to_gt(ct), "CT dequeue failed: %d\n", ret);
> CT_DEAD(ct, NULL, G2H_RECV);
> kick_reset(ct);
> }
> --
> 2.50.1
>
next prev parent reply other threads:[~2026-02-23 17:05 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-02-23 16:23 [PATCH 0/2] Misc fix for xe_guc_ct.c Shuicheng Lin
2026-02-23 16:23 ` [PATCH 1/2] drm/xe/guc: Accumulate CT H2G retry sleep budget Shuicheng Lin
2026-02-23 16:59 ` Matthew Brost
2026-02-23 16:23 ` [PATCH 2/2] drm/xe/guc: Refine CT queue checks and log formatting Shuicheng Lin
2026-02-23 17:05 ` Matthew Brost [this message]
2026-02-23 16:35 ` ✓ CI.KUnit: success for Misc fix for xe_guc_ct.c Patchwork
2026-02-24 21:26 ` ✓ CI.KUnit: success for Misc fix for xe_guc_ct.c (rev2) Patchwork
2026-02-24 21:59 ` ✓ Xe.CI.BAT: " Patchwork
2026-02-25 5:48 ` ✗ Xe.CI.FULL: failure " Patchwork
2026-02-25 16:15 ` Lin, Shuicheng
2026-02-25 17:28 ` 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=aZyI3Z9MTuwDCl2q@lstrano-desk.jf.intel.com \
--to=matthew.brost@intel.com \
--cc=intel-xe@lists.freedesktop.org \
--cc=shuicheng.lin@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