]> git.itanic.dy.fi Git - linux-stable/commit
thermal: amlogic: Use DEFINE_SIMPLE_DEV_PM_OPS for PM functions
authorUwe Kleine-König <u.kleine-koenig@pengutronix.de>
Thu, 16 Nov 2023 11:26:36 +0000 (12:26 +0100)
committerDaniel Lezcano <daniel.lezcano@linaro.org>
Tue, 2 Jan 2024 08:33:18 +0000 (09:33 +0100)
commitac99b129630efa14efe176e968045cde9d442e55
tree440463c8e01d4ac6ce4c2387cdedf505ed3b07cd
parent720f8db834a31009d8d11893278ca3f8072a575e
thermal: amlogic: Use DEFINE_SIMPLE_DEV_PM_OPS for PM functions

This macro has the advantage over SIMPLE_DEV_PM_OPS that we don't have to
care about when the functions are actually used, so the corresponding
__maybe_unused can be dropped.

Also make use of pm_ptr() to discard all PM related stuff if CONFIG_PM
isn't enabled.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org>
Link: https://lore.kernel.org/r/20231116112633.668826-3-u.kleine-koenig@pengutronix.de
drivers/thermal/amlogic_thermal.c