summaryrefslogtreecommitdiffstats
path: root/sound/pci/hda/patch_analog.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2013-07-11 12:45:59 -0700
committerLinus Torvalds <torvalds@linux-foundation.org>2013-07-11 12:45:59 -0700
commit0fb3767b0a5601dd0d528bc8dbefc0567a34b7ec (patch)
tree76eed01d088080863f5bf97e37ae4ec1adf9d0a5 /sound/pci/hda/patch_analog.c
parent0edcd16a4def296bd6492ae0c10a3c4aef9ef7c0 (diff)
parent42d4ab832d843b5a512b373c86e70caa43a041c8 (diff)
downloadop-kernel-dev-0fb3767b0a5601dd0d528bc8dbefc0567a34b7ec.zip
op-kernel-dev-0fb3767b0a5601dd0d528bc8dbefc0567a34b7ec.tar.gz
Merge tag 'sound-3.11' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound
Pull sound fixes from Takashi Iwai: "A few small fixes (and cleanups) for HD-audio, USB-audio and ASoC" * tag 'sound-3.11' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound: ALSA: usb-audio: fix regression for fixed stream quirk ALSA: hda - Keep halting ALC5505 DSP ASoC: wm8962: fix NULL pdata pointer ASoC: imx-sgtl5000: return E_PROBE_DEFER if ssi/codec not found ASoC: Samsung: Remove redundant comment ALSA: hda - Fix EAPD vmaster hook for AD1884 & co ASoC: samsung: Remove obsolete GPIO based DT pinmuxing ASoC: mxs: register saif mclk to clock framework
Diffstat (limited to 'sound/pci/hda/patch_analog.c')
-rw-r--r--sound/pci/hda/patch_analog.c12
1 files changed, 9 insertions, 3 deletions
diff --git a/sound/pci/hda/patch_analog.c b/sound/pci/hda/patch_analog.c
index 977b0d8..d97f0d6 100644
--- a/sound/pci/hda/patch_analog.c
+++ b/sound/pci/hda/patch_analog.c
@@ -2112,6 +2112,9 @@ static void ad_vmaster_eapd_hook(void *private_data, int enabled)
{
struct hda_codec *codec = private_data;
struct ad198x_spec *spec = codec->spec;
+
+ if (!spec->eapd_nid)
+ return;
snd_hda_codec_update_cache(codec, spec->eapd_nid, 0,
AC_VERB_SET_EAPD_BTLENABLE,
enabled ? 0x02 : 0x00);
@@ -3601,13 +3604,16 @@ static void ad1884_fixup_hp_eapd(struct hda_codec *codec,
{
struct ad198x_spec *spec = codec->spec;
- if (action == HDA_FIXUP_ACT_PRE_PROBE) {
+ switch (action) {
+ case HDA_FIXUP_ACT_PRE_PROBE:
+ spec->gen.vmaster_mute.hook = ad_vmaster_eapd_hook;
+ break;
+ case HDA_FIXUP_ACT_PROBE:
if (spec->gen.autocfg.line_out_type == AUTO_PIN_SPEAKER_OUT)
spec->eapd_nid = spec->gen.autocfg.line_out_pins[0];
else
spec->eapd_nid = spec->gen.autocfg.speaker_pins[0];
- if (spec->eapd_nid)
- spec->gen.vmaster_mute.hook = ad_vmaster_eapd_hook;
+ break;
}
}
OpenPOWER on IntegriCloud