[PATCH v4 11/15] gpio: tqmx86: Use modern PM macros
Andy Shevchenko
andriy.shevchenko at intel.com
Wed Nov 19 09:19:58 PST 2025
On Thu, Nov 20, 2025 at 12:33:23AM +0800, Jisheng Zhang wrote:
> Use the modern PM macros for the suspend and resume functions to be
> automatically dropped by the compiler when CONFIG_PM or
> CONFIG_PM_SLEEP are disabled, without having to use __maybe_unused
...
> static const struct dev_pm_ops tqmx86_gpio_dev_pm_ops = {
> - SET_RUNTIME_PM_OPS(tqmx86_gpio_runtime_suspend,
> - tqmx86_gpio_runtime_resume, NULL)
> + RUNTIME_PM_OPS(tqmx86_gpio_runtime_suspend, tqmx86_gpio_runtime_resume, NULL)
> };
...
> static struct platform_driver tqmx86_gpio_driver = {
> .driver = {
> .name = "tqmx86-gpio",
> - .pm = &tqmx86_gpio_dev_pm_ops,
> + .pm = pm_sleep_ptr(&tqmx86_gpio_dev_pm_ops),
For RPM this should be pm_ptr(), no?
> },
--
With Best Regards,
Andy Shevchenko
More information about the linux-arm-kernel
mailing list