From: Michal Wajdeczko <michal.wajdeczko@intel.com>
To: Mallesh Koujalagi <mallesh.koujalagi@intel.com>,
<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>, <aravind.iddamsetty@linux.intel.com>,
<umesh.nerlige.ramappa@intel.com>,
<dnyaneshwar.bhadane@intel.com>, <anoop.c.vijay@intel.com>
Subject: Re: [PATCH v4 3/7] drm/xe/sysctrl: Make sysctrl_write_frame() void
Date: Fri, 21 Aug 2026 00:28:48 +0200 [thread overview]
Message-ID: <a04b62f3-2202-44e6-87b9-a6f08726d2a9@intel.com> (raw)
In-Reply-To: <20260820101632.527214-12-mallesh.koujalagi@intel.com>
On 8/20/2026 12:16 PM, Mallesh Koujalagi wrote:
> The function always returned 0, so the int return type is misleading.
> Convert to void and drop the error handling in the caller.
>
> Signed-off-by: Mallesh Koujalagi <mallesh.koujalagi@intel.com>
Reviewed-by: Michal Wajdeczko <michal.wajdeczko@intel.com>
> ---
> drivers/gpu/drm/xe/xe_sysctrl_mailbox.c | 12 +++---------
> 1 file changed, 3 insertions(+), 9 deletions(-)
>
> diff --git a/drivers/gpu/drm/xe/xe_sysctrl_mailbox.c b/drivers/gpu/drm/xe/xe_sysctrl_mailbox.c
> index 3523651b467b..ac58571f2a43 100644
> --- a/drivers/gpu/drm/xe/xe_sysctrl_mailbox.c
> +++ b/drivers/gpu/drm/xe/xe_sysctrl_mailbox.c
> @@ -49,8 +49,8 @@ static int sysctrl_wait_bit_set(struct xe_sysctrl *sc, u32 bit_mask,
> timeout_ms * 1000, NULL, false);
> }
>
> -static int sysctrl_write_frame(struct xe_sysctrl *sc, const void *frame,
> - size_t len)
> +static void sysctrl_write_frame(struct xe_sysctrl *sc, const void *frame,
> + size_t len)
> {
> static const struct xe_reg regs[] = {
> SYSCTRL_MB_DATA0, SYSCTRL_MB_DATA1, SYSCTRL_MB_DATA2, SYSCTRL_MB_DATA3
> @@ -66,8 +66,6 @@ static int sysctrl_write_frame(struct xe_sysctrl *sc, const void *frame,
>
> for (i = 0; i < dw; i++)
> xe_mmio_write32(sc->mmio, regs[i], val[i]);
> -
> - return 0;
> }
>
> static int sysctrl_read_frame(struct xe_sysctrl *sc, void *frame,
> @@ -154,11 +152,7 @@ static int sysctrl_send_frames(struct xe_sysctrl *sc,
> for (frame = 0; frame < total_frames; frame++) {
> frame_size = min_t(size_t, cmd_size - bytes_sent, XE_SYSCTRL_MB_FRAME_SIZE);
>
> - if (sysctrl_write_frame(sc, mbox_cmd + bytes_sent, frame_size)) {
> - xe_err(xe, "sysctrl: Failed to write frame %u\n", frame);
> - sc->phase_bit = 0;
> - return -EIO;
> - }
> + sysctrl_write_frame(sc, mbox_cmd + bytes_sent, frame_size);
>
> ctrl_reg = SYSCTRL_MB_CTRL_RUN_BUSY |
> REG_FIELD_PREP(SYSCTRL_FRAME_CURRENT_MASK, frame) |
next prev parent reply other threads:[~2026-08-20 22:29 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-08-20 10:16 [PATCH v4 0/7] drm/xe/sysctrl: Clean up error handling in Mallesh Koujalagi
2026-08-20 10:16 ` [PATCH v4 1/7] drm/xe/sysctrl: Return error codes from sysctrl_wait_bit_clear() Mallesh Koujalagi
2026-08-20 22:23 ` Michal Wajdeczko
2026-08-24 5:44 ` Tauro, Riana
2026-08-24 11:04 ` Michal Wajdeczko
2026-08-25 7:35 ` Tauro, Riana
2026-08-20 10:16 ` [PATCH v4 2/7] drm/xe/sysctrl: Return error codes from sysctrl_wait_bit_set() Mallesh Koujalagi
2026-08-20 22:26 ` Michal Wajdeczko
2026-08-20 10:16 ` [PATCH v4 3/7] drm/xe/sysctrl: Make sysctrl_write_frame() void Mallesh Koujalagi
2026-08-20 22:28 ` Michal Wajdeczko [this message]
2026-08-20 10:16 ` [PATCH v4 4/7] drm/xe/sysctrl: Use xe_assert() for payload size validation Mallesh Koujalagi
2026-08-20 22:30 ` Michal Wajdeczko
2026-08-20 10:16 ` [PATCH v4 5/7] drm/xe/sysctrl: Improve firmware response error logging Mallesh Koujalagi
2026-08-20 10:28 ` sashiko-bot
2026-08-20 22:40 ` Michal Wajdeczko
2026-08-20 10:16 ` [PATCH v4 6/7] drm/xe/sysctrl: Log group and command ID on mailbox failure Mallesh Koujalagi
2026-08-20 22:44 ` Michal Wajdeczko
2026-08-20 10:16 ` [PATCH v4 7/7] drm/xe/sysctrl: Report 'System Controller event' error using SIGID Mallesh Koujalagi
2026-08-20 22:58 ` Michal Wajdeczko
2026-08-20 10:25 ` ✓ CI.KUnit: success for drm/xe/sysctrl: Clean up error handling in Patchwork
2026-08-20 11:01 ` ✓ Xe.CI.BAT: " Patchwork
2026-08-20 12:14 ` ✓ Xe.CI.FULL: " 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=a04b62f3-2202-44e6-87b9-a6f08726d2a9@intel.com \
--to=michal.wajdeczko@intel.com \
--cc=anoop.c.vijay@intel.com \
--cc=anshuman.gupta@intel.com \
--cc=aravind.iddamsetty@linux.intel.com \
--cc=badal.nilawar@intel.com \
--cc=dnyaneshwar.bhadane@intel.com \
--cc=intel-xe@lists.freedesktop.org \
--cc=karthik.poosa@intel.com \
--cc=mallesh.koujalagi@intel.com \
--cc=matthew.brost@intel.com \
--cc=raag.jadav@intel.com \
--cc=riana.tauro@intel.com \
--cc=rodrigo.vivi@intel.com \
--cc=sk.anirban@intel.com \
--cc=umesh.nerlige.ramappa@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