* [PATCH v3] auxdisplay: arm-charlcd: Use DEFINE_SIMPLE_DEV_PM_OPS for power management
@ 2026-08-20 1:38 Li Jun
2026-08-20 5:04 ` Uwe Kleine-König
0 siblings, 1 reply; 4+ messages in thread
From: Li Jun @ 2026-08-20 1:38 UTC (permalink / raw)
To: lijun01, andy, geert, fourier.thomas, bhelgaas, u.kleine-koenig,
linux-kernel
Replace the manually defined dev_pm_ops structure with the
DEFINE_SIMPLE_DEV_PM_OPS macro to simplify the power management code.
This macro automatically handles CONFIG_PM_SLEEP configuration
and generates freeze/thaw/poweroff/restore callbacks, reducing
boilerplate code.
Changes:
-Replace SIMPLE-DEV-PM-OPS() in v1 v2 with DEFINE_SIMPLE_deV_PM-OPS() for pm.
-Corrected grammar errors in v1 comment.
Signed-off-by: Li Jun <lijun01@kylinos.cn>
---
drivers/auxdisplay/arm-charlcd.c | 5 +----
1 file changed, 1 insertion(+), 4 deletions(-)
diff --git a/drivers/auxdisplay/arm-charlcd.c b/drivers/auxdisplay/arm-charlcd.c
index 70efda4f767e..cdd6a0bfca05 100644
--- a/drivers/auxdisplay/arm-charlcd.c
+++ b/drivers/auxdisplay/arm-charlcd.c
@@ -306,10 +306,7 @@ static int charlcd_resume(struct device *dev)
return 0;
}
-static const struct dev_pm_ops charlcd_pm_ops = {
- .suspend = charlcd_suspend,
- .resume = charlcd_resume,
-};
+static DEFINE_SIMPLE_DEV_PM_OPS(charlcd_pm_ops, charlcd_suspend, charlcd_resume);
static const struct of_device_id charlcd_match[] = {
{ .compatible = "arm,versatile-lcd", },
--
2.25.1
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH v3] auxdisplay: arm-charlcd: Use DEFINE_SIMPLE_DEV_PM_OPS for power management
2026-08-20 1:38 [PATCH v3] auxdisplay: arm-charlcd: Use DEFINE_SIMPLE_DEV_PM_OPS for power management Li Jun
@ 2026-08-20 5:04 ` Uwe Kleine-König
2026-08-20 6:04 ` lijun
0 siblings, 1 reply; 4+ messages in thread
From: Uwe Kleine-König @ 2026-08-20 5:04 UTC (permalink / raw)
To: Li Jun; +Cc: andy, geert, fourier.thomas, bhelgaas, linux-kernel
[-- Attachment #1: Type: text/plain, Size: 1816 bytes --]
hello,
On Thu, Aug 20, 2026 at 09:38:26AM +0800, Li Jun wrote:
> Replace the manually defined dev_pm_ops structure with the
> DEFINE_SIMPLE_DEV_PM_OPS macro to simplify the power management code.
> This macro automatically handles CONFIG_PM_SLEEP configuration
> and generates freeze/thaw/poweroff/restore callbacks, reducing
> boilerplate code.
>
> Changes:
> -Replace SIMPLE-DEV-PM-OPS() in v1 v2 with DEFINE_SIMPLE_deV_PM-OPS() for pm.
It only matters a little, but it's DEFINE_SIMPLE_DEV_PM_OPS().
> -Corrected grammar errors in v1 comment.
The description of changes between different revisions of the seris
should be located after the tripple-dash below to not let it go into git
when applied.
I fail to see what changed for v3, the changelog seems to match that of
v2. Also there is already a v4 before you got any feedback for v3, even
before someone had a chance to give feedback. Maintainer-Opinions differ
about the minimal interval between revisions, but three submissions
within a day is too much for any maintainer I think.
Additionally Andy requested the use of pm_sleep_ptr() which isn't even
in v4.
I think the same is needed for your firmware/arm_scmi patch and also for
the bluetooth one.
The usage of DEFINE_SIMPLE_DEV_PM_OPS() is an improvement, but now you
have (at least) three series in flight and the trivial feedback you
received here applies to all three. As someone who also sends many
patches, I recommend to get up to speed slowly. Work on a single patch
first, and only once you get that in---or at least positive feedback on
it---address one or two further drivers. When you have a handful of
patches in, you can speed up. But as it is now, you only occupy many
people finding the same issues in your patches. :-\
Best regards
Uwe
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH v3] auxdisplay: arm-charlcd: Use DEFINE_SIMPLE_DEV_PM_OPS for power management
2026-08-20 5:04 ` Uwe Kleine-König
@ 2026-08-20 6:04 ` lijun
2026-08-20 7:31 ` Uwe Kleine-König
0 siblings, 1 reply; 4+ messages in thread
From: lijun @ 2026-08-20 6:04 UTC (permalink / raw)
To: Uwe Kleine-König; +Cc: andy, geert, fourier.thomas, bhelgaas, linux-kernel
Thank you! This suggestion is very useful to me.
--------
I think the same is needed for your firmware/arm_scmi patch and also for
the bluetooth one.
The usage of DEFINE_SIMPLE_DEV_PM_OPS() is an improvement, but now you
have (at least) three series in flight and the trivial feedback you
received here applies to all three. As someone who also sends many
patches, I recommend to get up to speed slowly. Work on a single patch
first, and only once you get that in---or at least positive feedback on
it---address one or two further drivers. When you have a handful of
patches in, you can speed up. But as it is now, you only occupy many
people finding the same issues in your patches.
2026/8/20 13:04, Uwe Kleine-König :
> I think the same is needed for your firmware/arm_scmi patch and also for
> the bluetooth one.
>
> The usage of DEFINE_SIMPLE_DEV_PM_OPS() is an improvement, but now you
> have (at least) three series in flight and the trivial feedback you
> received here applies to all three. As someone who also sends many
> patches, I recommend to get up to speed slowly. Work on a single patch
> first, and only once you get that in---or at least positive feedback on
> it---address one or two further drivers. When you have a handful of
> patches in, you can speed up. But as it is now, you only occupy many
> people finding the same issues in your patches.
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH v3] auxdisplay: arm-charlcd: Use DEFINE_SIMPLE_DEV_PM_OPS for power management
2026-08-20 6:04 ` lijun
@ 2026-08-20 7:31 ` Uwe Kleine-König
0 siblings, 0 replies; 4+ messages in thread
From: Uwe Kleine-König @ 2026-08-20 7:31 UTC (permalink / raw)
To: lijun; +Cc: andy, geert, fourier.thomas, bhelgaas, linux-kernel
[-- Attachment #1: Type: text/plain, Size: 1048 bytes --]
On Thu, Aug 20, 2026 at 02:04:46PM +0800, lijun wrote:
> Thank you! This suggestion is very useful to me.
> --------
> I think the same is needed for your firmware/arm_scmi patch and also for
> the bluetooth one.
>
> The usage of DEFINE_SIMPLE_DEV_PM_OPS() is an improvement, but now you
> have (at least) three series in flight and the trivial feedback you
> received here applies to all three. As someone who also sends many
> patches, I recommend to get up to speed slowly. Work on a single patch
> first, and only once you get that in---or at least positive feedback on
> it---address one or two further drivers. When you have a handful of
> patches in, you can speed up. But as it is now, you only occupy many
> people finding the same issues in your patches.
Please also fix your mail user agent to use proper quoting. (For
Thunderbird maybe: "Account Settings" -> "Composition & Adressing" ->
[x] "Automatically quote the original message when replying" + "When
quoting start my reply below the quote".)
Thanks
Uwe
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2026-08-20 7:31 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-08-20 1:38 [PATCH v3] auxdisplay: arm-charlcd: Use DEFINE_SIMPLE_DEV_PM_OPS for power management Li Jun
2026-08-20 5:04 ` Uwe Kleine-König
2026-08-20 6:04 ` lijun
2026-08-20 7:31 ` Uwe Kleine-König
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.