ASoC: cs35l45: Use modern pm_ops
authorRicardo Rivera-Matos <rriveram@opensource.cirrus.com>
Wed, 6 Dec 2023 16:03:16 +0000 (10:03 -0600)
committerMark Brown <broonie@kernel.org>
Wed, 6 Dec 2023 23:06:55 +0000 (23:06 +0000)
commit12e102b1bd22ee00361559d57a5876445bcb2407
tree692007366df9de5bbcdb4b542add09dc94f83616
parentd20d36755a605a21e737b6b16c566658589b1811
ASoC: cs35l45: Use modern pm_ops

Make use of the recently introduced EXPORT_GPL_DEV_PM_OPS() macro, to
conditionally export the runtime/system PM functions.

Replace the old SET_{RUNTIME,SYSTEM_SLEEP,NOIRQ_SYSTEM_SLEEP}_PM_OPS()
helpers with their modern alternatives and get rid of the now
unnecessary '__maybe_unused' annotations on all PM functions.

Additionally, use the pm_ptr() macro to fix the following errors when
building with CONFIG_PM disabled:

Signed-off-by: Ricardo Rivera-Matos <rriveram@opensource.cirrus.com>
Acked-by: Charles Keepax <ckeepax@opensource.cirrus.com>
Link: https://lore.kernel.org/r/20231206160318.1255034-2-rriveram@opensource.cirrus.com
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/codecs/cs35l45-i2c.c
sound/soc/codecs/cs35l45-spi.c
sound/soc/codecs/cs35l45.c