aboutsummaryrefslogtreecommitdiffstats
path: root/sound/pci/hda
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2012-05-09 04:31:08 -0400
committerTakashi Iwai <tiwai@suse.de>2012-05-09 04:32:35 -0400
commit607d4f7f0551eb591fbaca4bf44a8d6251e82f00 (patch)
treec317cf8a3496cb534a28e7993bc4fe71bb497caf /sound/pci/hda
parent128bc4ba8c52194eae5a80594ec9b7f6b35ba88f (diff)
ALSA: hda - Remove pre_resume and post_suspend ops
Since the recent commit, the resume procedure is always performed at the resume time. This makes the pre_resume hack for VREF mute LED on some HP laptops superfluous. As this is the only user of pre_resume (and there is no user of post_suspend) ops, let's kill them again. Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/pci/hda')
-rw-r--r--sound/pci/hda/hda_codec.c4
-rw-r--r--sound/pci/hda/hda_codec.h2
-rw-r--r--sound/pci/hda/patch_sigmatel.c21
3 files changed, 0 insertions, 27 deletions
diff --git a/sound/pci/hda/hda_codec.c b/sound/pci/hda/hda_codec.c
index f2bdf38be39..e0f8667ae22 100644
--- a/sound/pci/hda/hda_codec.c
+++ b/sound/pci/hda/hda_codec.c
@@ -4930,8 +4930,6 @@ int snd_hda_suspend(struct hda_bus *bus)
4930 list_for_each_entry(codec, &bus->codec_list, list) { 4930 list_for_each_entry(codec, &bus->codec_list, list) {
4931 if (hda_codec_is_power_on(codec)) 4931 if (hda_codec_is_power_on(codec))
4932 hda_call_codec_suspend(codec); 4932 hda_call_codec_suspend(codec);
4933 if (codec->patch_ops.post_suspend)
4934 codec->patch_ops.post_suspend(codec);
4935 } 4933 }
4936 return 0; 4934 return 0;
4937} 4935}
@@ -4951,8 +4949,6 @@ int snd_hda_resume(struct hda_bus *bus)
4951 struct hda_codec *codec; 4949 struct hda_codec *codec;
4952 4950
4953 list_for_each_entry(codec, &bus->codec_list, list) { 4951 list_for_each_entry(codec, &bus->codec_list, list) {
4954 if (codec->patch_ops.pre_resume)
4955 codec->patch_ops.pre_resume(codec);
4956 hda_call_codec_resume(codec); 4952 hda_call_codec_resume(codec);
4957 } 4953 }
4958 return 0; 4954 return 0;
diff --git a/sound/pci/hda/hda_codec.h b/sound/pci/hda/hda_codec.h
index 77cd99531aa..78f89147d62 100644
--- a/sound/pci/hda/hda_codec.h
+++ b/sound/pci/hda/hda_codec.h
@@ -704,8 +704,6 @@ struct hda_codec_ops {
704 unsigned int power_state); 704 unsigned int power_state);
705#ifdef CONFIG_PM 705#ifdef CONFIG_PM
706 int (*suspend)(struct hda_codec *codec, pm_message_t state); 706 int (*suspend)(struct hda_codec *codec, pm_message_t state);
707 int (*post_suspend)(struct hda_codec *codec);
708 int (*pre_resume)(struct hda_codec *codec);
709 int (*resume)(struct hda_codec *codec); 707 int (*resume)(struct hda_codec *codec);
710#endif 708#endif
711#ifdef CONFIG_SND_HDA_POWER_SAVE 709#ifdef CONFIG_SND_HDA_POWER_SAVE
diff --git a/sound/pci/hda/patch_sigmatel.c b/sound/pci/hda/patch_sigmatel.c
index baf1edde244..b04179be620 100644
--- a/sound/pci/hda/patch_sigmatel.c
+++ b/sound/pci/hda/patch_sigmatel.c
@@ -4986,20 +4986,6 @@ static int stac92xx_suspend(struct hda_codec *codec, pm_message_t state)
4986 return 0; 4986 return 0;
4987} 4987}
4988 4988
4989static int stac92xx_pre_resume(struct hda_codec *codec)
4990{
4991 struct sigmatel_spec *spec = codec->spec;
4992
4993 /* sync mute LED */
4994 if (spec->vref_mute_led_nid)
4995 stac_vrefout_set(codec, spec->vref_mute_led_nid,
4996 spec->vref_led);
4997 else if (spec->gpio_led)
4998 stac_gpio_set(codec, spec->gpio_mask,
4999 spec->gpio_dir, spec->gpio_data);
5000 return 0;
5001}
5002
5003static void stac92xx_set_power_state(struct hda_codec *codec, hda_nid_t fg, 4989static void stac92xx_set_power_state(struct hda_codec *codec, hda_nid_t fg,
5004 unsigned int power_state) 4990 unsigned int power_state)
5005{ 4991{
@@ -5023,7 +5009,6 @@ static void stac92xx_set_power_state(struct hda_codec *codec, hda_nid_t fg,
5023#else 5009#else
5024#define stac92xx_suspend NULL 5010#define stac92xx_suspend NULL
5025#define stac92xx_resume NULL 5011#define stac92xx_resume NULL
5026#define stac92xx_pre_resume NULL
5027#define stac92xx_set_power_state NULL 5012#define stac92xx_set_power_state NULL
5028#endif /* CONFIG_PM */ 5013#endif /* CONFIG_PM */
5029 5014
@@ -5569,9 +5554,6 @@ again:
5569 codec->patch_ops.set_power_state = 5554 codec->patch_ops.set_power_state =
5570 stac92xx_set_power_state; 5555 stac92xx_set_power_state;
5571 } 5556 }
5572#ifdef CONFIG_PM
5573 codec->patch_ops.pre_resume = stac92xx_pre_resume;
5574#endif
5575 } 5557 }
5576 5558
5577 err = stac92xx_parse_auto_config(codec); 5559 err = stac92xx_parse_auto_config(codec);
@@ -5878,9 +5860,6 @@ again:
5878 codec->patch_ops.set_power_state = 5860 codec->patch_ops.set_power_state =
5879 stac92xx_set_power_state; 5861 stac92xx_set_power_state;
5880 } 5862 }
5881#ifdef CONFIG_PM
5882 codec->patch_ops.pre_resume = stac92xx_pre_resume;
5883#endif
5884 } 5863 }
5885 5864
5886 spec->multiout.dac_nids = spec->dac_nids; 5865 spec->multiout.dac_nids = spec->dac_nids;