From: Rodrigo Vivi <rodrigo.vivi@intel.com>
To: Mohanram Meenakshisundaram <mohanram.meenakshisundaram@intel.com>
Cc: <intel-xe@lists.freedesktop.org>, <matthew.brost@intel.com>
Subject: Re: [PATCH] drm/xe: Fix return type of disable_late_binding_set() in debugfs
Date: Wed, 20 May 2026 15:16:05 -0400 [thread overview]
Message-ID: <ag4IdWWxBOYcKp1P@intel.com> (raw)
In-Reply-To: <20260520070255.2021100-1-mohanram.meenakshisundaram@intel.com>
On Wed, May 20, 2026 at 12:32:55PM +0530, Mohanram Meenakshisundaram wrote:
> Fix disable_late_binding_set() to declare 'ret' as ssize_t instead of
> int, consistent with the function's return type.
>
> Also remove '0' initializations for the 'len' variable in
If you do both in the same patch, please adjust the subject/title
line to something like:
drm/xe: Adjust variable initialization in xe_debugfs.c
or something like that that is generic enough.
> four debugfs show functions (wedged_mode_show,
> atomic_svm_timeslice_ms_show,
> min_run_period_lr_ms_show, min_run_period_pf_ms_show).
> The variable is updated immediately on next line by scnprintf(), so the
> initialize to '0' not required.
>
> Fixes: 62519b77aeca ("drm/xe: Fix memory leak when handling pagefault vma")
I can't see how this commit 62519b77aeca has anything to do with this patch
here....
Please provide a proper fix or simply remove it.
> Signed-off-by: Mohanram Meenakshisundaram <mohanram.meenakshisundaram@intel.com>
> ---
> drivers/gpu/drm/xe/xe_debugfs.c | 10 +++++-----
> 1 file changed, 5 insertions(+), 5 deletions(-)
>
> diff --git a/drivers/gpu/drm/xe/xe_debugfs.c b/drivers/gpu/drm/xe/xe_debugfs.c
> index 22b471303984..675cc0ddd83b 100644
> --- a/drivers/gpu/drm/xe/xe_debugfs.c
> +++ b/drivers/gpu/drm/xe/xe_debugfs.c
> @@ -282,7 +282,7 @@ static ssize_t wedged_mode_show(struct file *f, char __user *ubuf,
> {
> struct xe_device *xe = file_inode(f)->i_private;
> char buf[32];
> - int len = 0;
> + int len;
>
> len = scnprintf(buf, sizeof(buf), "%d\n", xe->wedged.mode);
>
> @@ -411,7 +411,7 @@ static ssize_t atomic_svm_timeslice_ms_show(struct file *f, char __user *ubuf,
> {
> struct xe_device *xe = file_inode(f)->i_private;
> char buf[32];
> - int len = 0;
> + int len;
>
> len = scnprintf(buf, sizeof(buf), "%d\n", xe->atomic_svm_timeslice_ms);
>
> @@ -446,7 +446,7 @@ static ssize_t min_run_period_lr_ms_show(struct file *f, char __user *ubuf,
> {
> struct xe_device *xe = file_inode(f)->i_private;
> char buf[32];
> - int len = 0;
> + int len;
>
> len = scnprintf(buf, sizeof(buf), "%d\n", xe->min_run_period_lr_ms);
>
> @@ -480,7 +480,7 @@ static ssize_t min_run_period_pf_ms_show(struct file *f, char __user *ubuf,
> {
> struct xe_device *xe = file_inode(f)->i_private;
> char buf[32];
> - int len = 0;
> + int len;
>
> len = scnprintf(buf, sizeof(buf), "%d\n", xe->min_run_period_pf_ms);
>
> @@ -528,7 +528,7 @@ static ssize_t disable_late_binding_set(struct file *f, const char __user *ubuf,
> struct xe_device *xe = file_inode(f)->i_private;
> struct xe_late_bind *late_bind = &xe->late_bind;
> bool val;
> - int ret;
> + ssize_t ret;
>
> ret = kstrtobool_from_user(ubuf, size, &val);
> if (ret)
> --
> 2.34.1
>
next prev parent reply other threads:[~2026-05-20 19:16 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-05-20 7:02 [PATCH] drm/xe: Fix return type of disable_late_binding_set() in debugfs Mohanram Meenakshisundaram
2026-05-20 7:16 ` ✓ CI.KUnit: success for " Patchwork
2026-05-20 7:56 ` ✓ Xe.CI.BAT: " Patchwork
2026-05-20 15:34 ` ✗ Xe.CI.FULL: failure " Patchwork
2026-05-20 19:16 ` Rodrigo Vivi [this message]
2026-05-21 6:09 ` [PATCH v2 0/2] drm/xe: Fix return type and adjust variable Mohanram Meenakshisundaram
2026-05-21 6:09 ` [PATCH v2 1/2] drm/xe: Fix return type of disable_late_binding_set() in debugfs Mohanram Meenakshisundaram
2026-05-21 12:09 ` Michal Wajdeczko
2026-05-25 6:11 ` Mohanram Meenakshisundaram
2026-05-21 6:09 ` [PATCH v2 2/2] drm/xe: Adjust variable initialization in xe_debugfs Mohanram Meenakshisundaram
2026-05-21 6:55 ` ✓ CI.KUnit: success for drm/xe: Fix return type of disable_late_binding_set() in debugfs (rev2) Patchwork
2026-05-21 7:48 ` ✓ Xe.CI.BAT: " Patchwork
2026-05-21 9:44 ` ✗ Xe.CI.FULL: failure " 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=ag4IdWWxBOYcKp1P@intel.com \
--to=rodrigo.vivi@intel.com \
--cc=intel-xe@lists.freedesktop.org \
--cc=matthew.brost@intel.com \
--cc=mohanram.meenakshisundaram@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