From: sashiko-bot@kernel.org
To: "Kees Cook" <kees@kernel.org>
Cc: vkoul@kernel.org, dmaengine@vger.kernel.org,
linux-modules@vger.kernel.org, Frank.Li@kernel.org,
linux-pci@vger.kernel.org, kvm@vger.kernel.org,
linux-media@vger.kernel.org
Subject: Re: [PATCH 05/11] moduleparam: Rename .get field to .get_str
Date: Sat, 30 May 2026 00:45:59 +0000 [thread overview]
Message-ID: <20260530004559.6D6711F00898@smtp.kernel.org> (raw)
In-Reply-To: <20260521133326.2465264-5-kees@kernel.org>
Thank you for your contribution! Sashiko AI review found 2 potential issue(s) to consider:
- [Low] The commit message claims that all `kernel_param_ops` initializers in the tree now use the `DEFINE_KERNEL_PARAM_OPS` macro, but several files (e.g., `arch/xtensa/platforms/iss/simdisk.c`, `drivers/video/fbdev/uvesafb.c`, `drivers/mtd/ubi/block.c`, `drivers/target/target_core_user.c`) still use direct struct initialization.
- [Low] Renaming the `.get` field to `.get_str` in `struct kernel_param_ops` breaks the kernel build when Rust is enabled (`CONFIG_RUST=y`).
--
commit 1952ed67c747da9c1d8185a27ee2651d4cdb0689
Author: Kees Cook <kees@kernel.org>
moduleparam: Rename .get field to .get_str
This commit renames the .get callback in struct kernel_param_ops to
.get_str. It frees up the .get name for a future commit that will re-add
it as a seq_buf-based callback.
> Now that every kernel_param_ops initializer in the tree goes through
> DEFINE_KERNEL_PARAM_OPS, no source file outside kernel/params.c and
[Severity: Low]
This isn't a bug, but is this description entirely accurate?
Several files like arch/xtensa/platforms/iss/simdisk.c,
drivers/video/fbdev/uvesafb.c, and drivers/mtd/ubi/block.c still use direct
struct initialization because they only define .set.
> include/linux/moduleparam.h references the .get field by name. Take
> advantage of that to rename the field to .get_str.
[ ... ]
> diff --git a/include/linux/moduleparam.h b/include/linux/moduleparam.h
> index 26bf45b36d023..f5f4148e25049 100644
> --- a/include/linux/moduleparam.h
> +++ b/include/linux/moduleparam.h
> @@ -63,7 +63,7 @@ struct kernel_param_ops {
> /* Returns 0, or -errno. arg is in kp->arg. */
> int (*set)(const char *val, const struct kernel_param *kp);
> /* Returns length written or -errno. Buffer is 4k (ie. be short!) */
> - int (*get)(char *buffer, const struct kernel_param *kp);
> + int (*get_str)(char *buffer, const struct kernel_param *kp);
[Severity: Low]
Does this break the kernel build when CONFIG_RUST=y?
In rust/kernel/module_param.rs, the make_param_ops! macro explicitly
initializes the generated C struct with get: None. When bindgen reflects
the renamed field, compilation will fail because the get field no longer
exists and the new get_str field is uninitialized.
Even though this is resolved later in the series by removing the get_str
field entirely, does this intermediate breakage cause issues for git bisect?
--
Sashiko AI review · https://sashiko.dev/#/patchset/20260521133315.work.845-kees@kernel.org?part=5
next prev parent reply other threads:[~2026-05-30 0:46 UTC|newest]
Thread overview: 31+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-05-21 13:33 [PATCH 00/11] Convert moduleparams to seq_buf Kees Cook
2026-05-21 13:33 ` [PATCH 01/11] params: bound array element output to the caller's page buffer Kees Cook
2026-05-21 16:46 ` David Laight
2026-05-21 13:33 ` [PATCH 02/11] panic: Replace panic_print_get() with generic helper Kees Cook
2026-05-21 13:33 ` [PATCH 03/11] moduleparam: Add DEFINE_KERNEL_PARAM_OPS macro family Kees Cook
2026-05-25 13:27 ` Petr Pavlu
2026-05-21 13:33 ` [PATCH 04/11] treewide: Convert struct kernel_param_ops initializers to DEFINE_KERNEL_PARAM_OPS Kees Cook
2026-05-21 13:59 ` Sean Christopherson
2026-05-22 17:01 ` Rafael J. Wysocki
2026-05-23 0:38 ` SeongJae Park
2026-05-25 13:35 ` Petr Pavlu
2026-05-21 13:33 ` [PATCH 05/11] moduleparam: Rename .get field to .get_str Kees Cook
2026-05-30 0:45 ` sashiko-bot [this message]
2026-05-21 13:33 ` [PATCH 06/11] moduleparam: Add seq_buf-based .get callback alongside .get_str Kees Cook
2026-05-25 16:19 ` Petr Pavlu
2026-05-30 0:45 ` sashiko-bot
2026-05-21 13:33 ` [PATCH 07/11] moduleparam: Route DEFINE_KERNEL_PARAM_OPS get pointer via _Generic Kees Cook
2026-05-25 16:24 ` Petr Pavlu
2026-05-21 13:33 ` [PATCH 08/11] params: Convert generic kernel_param_ops .get helpers to seq_buf Kees Cook
2026-05-25 17:10 ` Petr Pavlu
2026-05-30 0:45 ` sashiko-bot
2026-05-21 13:33 ` [PATCH 09/11] treewide: Convert custom kernel_param_ops .get callbacks to seq_buf via cocci Kees Cook
2026-05-21 13:45 ` Sean Christopherson
2026-05-22 17:03 ` Rafael J. Wysocki
2026-05-23 0:45 ` SeongJae Park
2026-05-21 13:33 ` [PATCH 10/11] treewide: Manually convert custom kernel_param_ops .get callbacks Kees Cook
2026-05-21 17:44 ` Jani Nikula
2026-05-22 17:05 ` Rafael J. Wysocki
2026-05-21 13:33 ` [PATCH 11/11] moduleparam: Drop legacy kernel_param_ops .get_str field and dispatch logic Kees Cook
2026-05-30 0:46 ` sashiko-bot
2026-05-26 6:53 ` [PATCH 00/11] Convert moduleparams to seq_buf Petr Pavlu
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=20260530004559.6D6711F00898@smtp.kernel.org \
--to=sashiko-bot@kernel.org \
--cc=Frank.Li@kernel.org \
--cc=dmaengine@vger.kernel.org \
--cc=kees@kernel.org \
--cc=kvm@vger.kernel.org \
--cc=linux-media@vger.kernel.org \
--cc=linux-modules@vger.kernel.org \
--cc=linux-pci@vger.kernel.org \
--cc=sashiko-reviews@lists.linux.dev \
--cc=vkoul@kernel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox