Commit 4e0549ff authored by Takashi Iwai's avatar Takashi Iwai

ALSA: hda: cs4809: Reduce CONFIG_PM dependencies

CONFIG_PM dependencies got reduced in HD-audio codec core driver, and
now it's time to reduce in HD-audio generic cs8409 driver, too.

Simply drop CONFIG_PM ifdefs.
Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
Link: https://lore.kernel.org/r/20240506161359.6960-9-tiwai@suse.de
parent 29d57f6d
...@@ -909,7 +909,6 @@ static void cs42l42_resume(struct sub_codec *cs42l42) ...@@ -909,7 +909,6 @@ static void cs42l42_resume(struct sub_codec *cs42l42)
cs42l42_enable_jack_detect(cs42l42); cs42l42_enable_jack_detect(cs42l42);
} }
#ifdef CONFIG_PM
static void cs42l42_suspend(struct sub_codec *cs42l42) static void cs42l42_suspend(struct sub_codec *cs42l42)
{ {
struct hda_codec *codec = cs42l42->codec; struct hda_codec *codec = cs42l42->codec;
...@@ -948,7 +947,6 @@ static void cs42l42_suspend(struct sub_codec *cs42l42) ...@@ -948,7 +947,6 @@ static void cs42l42_suspend(struct sub_codec *cs42l42)
spec->gpio_data &= ~cs42l42->reset_gpio; spec->gpio_data &= ~cs42l42->reset_gpio;
snd_hda_codec_write(codec, CS8409_PIN_AFG, 0, AC_VERB_SET_GPIO_DATA, spec->gpio_data); snd_hda_codec_write(codec, CS8409_PIN_AFG, 0, AC_VERB_SET_GPIO_DATA, spec->gpio_data);
} }
#endif
static void cs8409_free(struct hda_codec *codec) static void cs8409_free(struct hda_codec *codec)
{ {
...@@ -1003,7 +1001,6 @@ static void cs8409_cs42l42_jack_unsol_event(struct hda_codec *codec, unsigned in ...@@ -1003,7 +1001,6 @@ static void cs8409_cs42l42_jack_unsol_event(struct hda_codec *codec, unsigned in
} }
} }
#ifdef CONFIG_PM
/* Manage PDREF, when transition to D3hot */ /* Manage PDREF, when transition to D3hot */
static int cs8409_cs42l42_suspend(struct hda_codec *codec) static int cs8409_cs42l42_suspend(struct hda_codec *codec)
{ {
...@@ -1025,7 +1022,6 @@ static int cs8409_cs42l42_suspend(struct hda_codec *codec) ...@@ -1025,7 +1022,6 @@ static int cs8409_cs42l42_suspend(struct hda_codec *codec)
return 0; return 0;
} }
#endif
/* Vendor specific HW configuration /* Vendor specific HW configuration
* PLL, ASP, I2C, SPI, GPIOs, DMIC etc... * PLL, ASP, I2C, SPI, GPIOs, DMIC etc...
...@@ -1080,9 +1076,7 @@ static const struct hda_codec_ops cs8409_cs42l42_patch_ops = { ...@@ -1080,9 +1076,7 @@ static const struct hda_codec_ops cs8409_cs42l42_patch_ops = {
.init = cs8409_init, .init = cs8409_init,
.free = cs8409_free, .free = cs8409_free,
.unsol_event = cs8409_cs42l42_jack_unsol_event, .unsol_event = cs8409_cs42l42_jack_unsol_event,
#ifdef CONFIG_PM
.suspend = cs8409_cs42l42_suspend, .suspend = cs8409_cs42l42_suspend,
#endif
}; };
static int cs8409_cs42l42_exec_verb(struct hdac_device *dev, unsigned int cmd, unsigned int flags, static int cs8409_cs42l42_exec_verb(struct hdac_device *dev, unsigned int cmd, unsigned int flags,
...@@ -1310,9 +1304,7 @@ static const struct hda_codec_ops cs8409_dolphin_patch_ops = { ...@@ -1310,9 +1304,7 @@ static const struct hda_codec_ops cs8409_dolphin_patch_ops = {
.init = cs8409_init, .init = cs8409_init,
.free = cs8409_free, .free = cs8409_free,
.unsol_event = dolphin_jack_unsol_event, .unsol_event = dolphin_jack_unsol_event,
#ifdef CONFIG_PM
.suspend = cs8409_cs42l42_suspend, .suspend = cs8409_cs42l42_suspend,
#endif
}; };
static int dolphin_exec_verb(struct hdac_device *dev, unsigned int cmd, unsigned int flags, static int dolphin_exec_verb(struct hdac_device *dev, unsigned int cmd, unsigned int flags,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment