From: sashiko-bot@kernel.org
To: "Triet Hoang" <triet.hoang.dev@gmail.com>
Cc: dmitry.torokhov@gmail.com, linux-input@vger.kernel.org
Subject: Re: [PATCH] input: touchscreen: Convert to DEFINE_SIMPLE_DEV_PM_OPS()
Date: Fri, 21 Aug 2026 02:55:13 +0000 [thread overview]
Message-ID: <20260821025514.31AE01F000E9@smtp.kernel.org> (raw)
In-Reply-To: <20260821024450.57369-1-triet.hoang.dev@gmail.com>
Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
- [Low] The patch introduces a strict C compiler redefinition error for `ad7879_pm_ops` when `CONFIG_PM_SLEEP` is enabled.
--
--- Patch [1]: [PATCH] input: touchscreen: Convert to DEFINE_SIMPLE_DEV_PM_OPS() ---
commit 44d9a5ca9f2aa03594a9658d8105747b57b227ba
Author: Triet Hoang <triet.hoang.dev@gmail.com>
input: touchscreen: Convert to DEFINE_SIMPLE_DEV_PM_OPS()
This commit updates several touchscreen drivers to use the newer
DEFINE_SIMPLE_DEV_PM_OPS and pm_sleep_ptr() macros instead of the deprecated
SIMPLE_DEV_PM_OPS. This allows the removal of __maybe_unused annotations on
suspend and resume callbacks.
> diff --git a/drivers/input/touchscreen/ad7879.c b/drivers/input/touchscreen/ad7879.c
> index 31d2a3029d5f6..f686f028d4bc9 100644
> --- a/drivers/input/touchscreen/ad7879.c
> +++ b/drivers/input/touchscreen/ad7879.c
[ ... ]
> @@ -329,8 +329,8 @@ static int __maybe_unused ad7879_resume(struct device *dev)
> return 0;
> }
>
> -SIMPLE_DEV_PM_OPS(ad7879_pm_ops, ad7879_suspend, ad7879_resume);
> -EXPORT_SYMBOL(ad7879_pm_ops);
> +DEFINE_SIMPLE_DEV_PM_OPS(ad7879_pm_ops, ad7879_suspend, ad7879_resume);
> +EXPORT_SIMPLE_DEV_PM_OPS(ad7879_pm_ops, ad7879_suspend, ad7879_resume);
[Severity: Low]
Does this cause a compilation error when CONFIG_PM_SLEEP is enabled?
Both DEFINE_SIMPLE_DEV_PM_OPS and EXPORT_SIMPLE_DEV_PM_OPS expand to a
complete initialization of the ad7879_pm_ops struct. Using both sequentially
redefines the same global variable, which will result in a build failure.
Should this just be EXPORT_SIMPLE_DEV_PM_OPS by itself?
--
Sashiko AI review · https://sashiko.dev/#/patchset/20260821024450.57369-1-triet.hoang.dev@gmail.com?part=1
next prev parent reply other threads:[~2026-08-21 2:55 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-08-21 2:44 [PATCH] input: touchscreen: Convert to DEFINE_SIMPLE_DEV_PM_OPS() Triet Hoang
2026-08-21 2:55 ` sashiko-bot [this message]
2026-08-21 4:09 ` [PATCH v2] " Triet Hoang
2026-08-21 4:19 ` sashiko-bot
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=20260821025514.31AE01F000E9@smtp.kernel.org \
--to=sashiko-bot@kernel.org \
--cc=dmitry.torokhov@gmail.com \
--cc=linux-input@vger.kernel.org \
--cc=sashiko-reviews@lists.linux.dev \
--cc=triet.hoang.dev@gmail.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