diff options
author | Takashi Iwai <tiwai@suse.de> | 2024-02-07 16:51:22 +0100 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2024-02-12 11:50:25 +0100 |
commit | bb7e551c403e774f84b382c8ceaffd66be4a88e8 (patch) | |
tree | c065c7a2e263e5243ca98b5e4453e24455600db3 /sound/arm | |
parent | ae69d94f808aba1f6457b474c65d047418c0ce63 (diff) |
ALSA: aaci: Replace with DEFINE_SIMPLE_DEV_PM_OPS()
Use the new DEFINE_SIMPLE_DEV_PM_OPS() instead of SIMPLE_DEV_PM_OPS()
for code-simplification. We need no longer CONFIG_PM_SLEEP ifdefs.
Just a cleanup, no functional changes.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Link: https://lore.kernel.org/r/20240207155140.18238-12-tiwai@suse.de
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/arm')
-rw-r--r-- | sound/arm/aaci.c | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/sound/arm/aaci.c b/sound/arm/aaci.c index 0817ad21af74..f64896564728 100644 --- a/sound/arm/aaci.c +++ b/sound/arm/aaci.c @@ -737,7 +737,6 @@ static const struct snd_pcm_ops aaci_capture_ops = { /* * Power Management. */ -#ifdef CONFIG_PM static int aaci_do_suspend(struct snd_card *card) { struct aaci *aaci = card->private_data; @@ -763,12 +762,7 @@ static int aaci_resume(struct device *dev) return card ? aaci_do_resume(card) : 0; } -static SIMPLE_DEV_PM_OPS(aaci_dev_pm_ops, aaci_suspend, aaci_resume); -#define AACI_DEV_PM_OPS (&aaci_dev_pm_ops) -#else -#define AACI_DEV_PM_OPS NULL -#endif - +static DEFINE_SIMPLE_DEV_PM_OPS(aaci_dev_pm_ops, aaci_suspend, aaci_resume); static const struct ac97_pcm ac97_defs[] = { [0] = { /* Front PCM */ @@ -1081,7 +1075,7 @@ MODULE_DEVICE_TABLE(amba, aaci_ids); static struct amba_driver aaci_driver = { .drv = { .name = DRIVER_NAME, - .pm = AACI_DEV_PM_OPS, + .pm = &aaci_dev_pm_ops, }, .probe = aaci_probe, .remove = aaci_remove, |