diff options
author | Takashi Iwai <tiwai@suse.de> | 2013-08-23 08:12:22 -0400 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2013-08-23 08:12:22 -0400 |
commit | 68538bf2bce557c3b5fe8c59b034d45352500db1 (patch) | |
tree | a84b68990cadcbfc277acc7b7f2b75716750e203 /sound/pci | |
parent | a8cc20999799a94929a56393ff39b32245e33d64 (diff) | |
parent | 43bcb402f84fe459102120b4e2d28d7117f16cd0 (diff) |
Merge tag 'asoc-v3.12' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into for-next
ASoC: Updates for v3.12
- DAPM is now mandatory for CODEC drivers in order to avoid the repeated
regressions in the special cases for non-DAPM CODECs and make it
easier to integrate with other components on boards. All existing
drivers have had some level of DAPM support added.
- A lot of cleanups in DAPM plus support for maintaining controls in a
specific state while a DAPM widget all contributed by Lars-Peter Clausen.
- Core helpers for bitbanged AC'97 reset from Markus Pargmann.
- New drivers and support for Analog Devices ADAU1702 and ADAU1401(a),
Asahi Kasei Microdevices AK4554, Atmel AT91ASM9x5 and WM8904 based
machines, Freescale S/PDIF and SSI AC'97, Renesas R-Car SoCs, Samsung
Exynos5420 SoCs, Texas Instruments PCM1681 and PCM1792A and Wolfson
Microelectronics WM8997.
- Support for building drivers that can support it cross-platform for
compile test.
Diffstat (limited to 'sound/pci')
-rw-r--r-- | sound/pci/asihpi/asihpi.c | 3 | ||||
-rw-r--r-- | sound/pci/atiixp.c | 2 | ||||
-rw-r--r-- | sound/pci/atiixp_modem.c | 2 | ||||
-rw-r--r-- | sound/pci/hda/hda_auto_parser.c | 2 | ||||
-rw-r--r-- | sound/pci/hda/hda_generic.c | 6 | ||||
-rw-r--r-- | sound/pci/hda/patch_hdmi.c | 2 | ||||
-rw-r--r-- | sound/pci/hda/patch_realtek.c | 11 | ||||
-rw-r--r-- | sound/pci/hda/patch_sigmatel.c | 14 |
8 files changed, 32 insertions, 10 deletions
diff --git a/sound/pci/asihpi/asihpi.c b/sound/pci/asihpi/asihpi.c index 185d54a5cb1a..dc632cdc3870 100644 --- a/sound/pci/asihpi/asihpi.c +++ b/sound/pci/asihpi/asihpi.c | |||
@@ -769,7 +769,10 @@ static void snd_card_asihpi_timer_function(unsigned long data) | |||
769 | s->number); | 769 | s->number); |
770 | ds->drained_count++; | 770 | ds->drained_count++; |
771 | if (ds->drained_count > 20) { | 771 | if (ds->drained_count > 20) { |
772 | unsigned long flags; | ||
773 | snd_pcm_stream_lock_irqsave(s, flags); | ||
772 | snd_pcm_stop(s, SNDRV_PCM_STATE_XRUN); | 774 | snd_pcm_stop(s, SNDRV_PCM_STATE_XRUN); |
775 | snd_pcm_stream_unlock_irqrestore(s, flags); | ||
773 | continue; | 776 | continue; |
774 | } | 777 | } |
775 | } else { | 778 | } else { |
diff --git a/sound/pci/atiixp.c b/sound/pci/atiixp.c index fe4c61bdb8ba..f6dec3ea371f 100644 --- a/sound/pci/atiixp.c +++ b/sound/pci/atiixp.c | |||
@@ -689,7 +689,9 @@ static void snd_atiixp_xrun_dma(struct atiixp *chip, struct atiixp_dma *dma) | |||
689 | if (! dma->substream || ! dma->running) | 689 | if (! dma->substream || ! dma->running) |
690 | return; | 690 | return; |
691 | snd_printdd("atiixp: XRUN detected (DMA %d)\n", dma->ops->type); | 691 | snd_printdd("atiixp: XRUN detected (DMA %d)\n", dma->ops->type); |
692 | snd_pcm_stream_lock(dma->substream); | ||
692 | snd_pcm_stop(dma->substream, SNDRV_PCM_STATE_XRUN); | 693 | snd_pcm_stop(dma->substream, SNDRV_PCM_STATE_XRUN); |
694 | snd_pcm_stream_unlock(dma->substream); | ||
693 | } | 695 | } |
694 | 696 | ||
695 | /* | 697 | /* |
diff --git a/sound/pci/atiixp_modem.c b/sound/pci/atiixp_modem.c index cf29b9a1d65d..289563ecb6dd 100644 --- a/sound/pci/atiixp_modem.c +++ b/sound/pci/atiixp_modem.c | |||
@@ -638,7 +638,9 @@ static void snd_atiixp_xrun_dma(struct atiixp_modem *chip, | |||
638 | if (! dma->substream || ! dma->running) | 638 | if (! dma->substream || ! dma->running) |
639 | return; | 639 | return; |
640 | snd_printdd("atiixp-modem: XRUN detected (DMA %d)\n", dma->ops->type); | 640 | snd_printdd("atiixp-modem: XRUN detected (DMA %d)\n", dma->ops->type); |
641 | snd_pcm_stream_lock(dma->substream); | ||
641 | snd_pcm_stop(dma->substream, SNDRV_PCM_STATE_XRUN); | 642 | snd_pcm_stop(dma->substream, SNDRV_PCM_STATE_XRUN); |
643 | snd_pcm_stream_unlock(dma->substream); | ||
642 | } | 644 | } |
643 | 645 | ||
644 | /* | 646 | /* |
diff --git a/sound/pci/hda/hda_auto_parser.c b/sound/pci/hda/hda_auto_parser.c index 7c11d46b84d3..48a9d004d6d9 100644 --- a/sound/pci/hda/hda_auto_parser.c +++ b/sound/pci/hda/hda_auto_parser.c | |||
@@ -860,7 +860,7 @@ void snd_hda_pick_fixup(struct hda_codec *codec, | |||
860 | } | 860 | } |
861 | } | 861 | } |
862 | if (id < 0 && quirk) { | 862 | if (id < 0 && quirk) { |
863 | for (q = quirk; q->subvendor; q++) { | 863 | for (q = quirk; q->subvendor || q->subdevice; q++) { |
864 | unsigned int vendorid = | 864 | unsigned int vendorid = |
865 | q->subdevice | (q->subvendor << 16); | 865 | q->subdevice | (q->subvendor << 16); |
866 | unsigned int mask = 0xffff0000 | q->subdevice_mask; | 866 | unsigned int mask = 0xffff0000 | q->subdevice_mask; |
diff --git a/sound/pci/hda/hda_generic.c b/sound/pci/hda/hda_generic.c index fd1965c8cda9..ac41e9cdc976 100644 --- a/sound/pci/hda/hda_generic.c +++ b/sound/pci/hda/hda_generic.c | |||
@@ -525,7 +525,7 @@ static bool same_amp_caps(struct hda_codec *codec, hda_nid_t nid1, | |||
525 | } | 525 | } |
526 | 526 | ||
527 | #define nid_has_mute(codec, nid, dir) \ | 527 | #define nid_has_mute(codec, nid, dir) \ |
528 | check_amp_caps(codec, nid, dir, AC_AMPCAP_MUTE) | 528 | check_amp_caps(codec, nid, dir, (AC_AMPCAP_MUTE | AC_AMPCAP_MIN_MUTE)) |
529 | #define nid_has_volume(codec, nid, dir) \ | 529 | #define nid_has_volume(codec, nid, dir) \ |
530 | check_amp_caps(codec, nid, dir, AC_AMPCAP_NUM_STEPS) | 530 | check_amp_caps(codec, nid, dir, AC_AMPCAP_NUM_STEPS) |
531 | 531 | ||
@@ -627,7 +627,7 @@ static int get_amp_val_to_activate(struct hda_codec *codec, hda_nid_t nid, | |||
627 | if (enable) | 627 | if (enable) |
628 | val = (caps & AC_AMPCAP_OFFSET) >> AC_AMPCAP_OFFSET_SHIFT; | 628 | val = (caps & AC_AMPCAP_OFFSET) >> AC_AMPCAP_OFFSET_SHIFT; |
629 | } | 629 | } |
630 | if (caps & AC_AMPCAP_MUTE) { | 630 | if (caps & (AC_AMPCAP_MUTE | AC_AMPCAP_MIN_MUTE)) { |
631 | if (!enable) | 631 | if (!enable) |
632 | val |= HDA_AMP_MUTE; | 632 | val |= HDA_AMP_MUTE; |
633 | } | 633 | } |
@@ -651,7 +651,7 @@ static unsigned int get_amp_mask_to_modify(struct hda_codec *codec, | |||
651 | { | 651 | { |
652 | unsigned int mask = 0xff; | 652 | unsigned int mask = 0xff; |
653 | 653 | ||
654 | if (caps & AC_AMPCAP_MUTE) { | 654 | if (caps & (AC_AMPCAP_MUTE | AC_AMPCAP_MIN_MUTE)) { |
655 | if (is_ctl_associated(codec, nid, dir, idx, NID_PATH_MUTE_CTL)) | 655 | if (is_ctl_associated(codec, nid, dir, idx, NID_PATH_MUTE_CTL)) |
656 | mask &= ~0x80; | 656 | mask &= ~0x80; |
657 | } | 657 | } |
diff --git a/sound/pci/hda/patch_hdmi.c b/sound/pci/hda/patch_hdmi.c index 540bdef2f904..030ca8652a1c 100644 --- a/sound/pci/hda/patch_hdmi.c +++ b/sound/pci/hda/patch_hdmi.c | |||
@@ -2622,6 +2622,7 @@ static const struct hda_codec_preset snd_hda_preset_hdmi[] = { | |||
2622 | { .id = 0x10de0043, .name = "GPU 43 HDMI/DP", .patch = patch_generic_hdmi }, | 2622 | { .id = 0x10de0043, .name = "GPU 43 HDMI/DP", .patch = patch_generic_hdmi }, |
2623 | { .id = 0x10de0044, .name = "GPU 44 HDMI/DP", .patch = patch_generic_hdmi }, | 2623 | { .id = 0x10de0044, .name = "GPU 44 HDMI/DP", .patch = patch_generic_hdmi }, |
2624 | { .id = 0x10de0051, .name = "GPU 51 HDMI/DP", .patch = patch_generic_hdmi }, | 2624 | { .id = 0x10de0051, .name = "GPU 51 HDMI/DP", .patch = patch_generic_hdmi }, |
2625 | { .id = 0x10de0060, .name = "GPU 60 HDMI/DP", .patch = patch_generic_hdmi }, | ||
2625 | { .id = 0x10de0067, .name = "MCP67 HDMI", .patch = patch_nvhdmi_2ch }, | 2626 | { .id = 0x10de0067, .name = "MCP67 HDMI", .patch = patch_nvhdmi_2ch }, |
2626 | { .id = 0x10de8001, .name = "MCP73 HDMI", .patch = patch_nvhdmi_2ch }, | 2627 | { .id = 0x10de8001, .name = "MCP73 HDMI", .patch = patch_nvhdmi_2ch }, |
2627 | { .id = 0x11069f80, .name = "VX900 HDMI/DP", .patch = patch_via_hdmi }, | 2628 | { .id = 0x11069f80, .name = "VX900 HDMI/DP", .patch = patch_via_hdmi }, |
@@ -2674,6 +2675,7 @@ MODULE_ALIAS("snd-hda-codec-id:10de0042"); | |||
2674 | MODULE_ALIAS("snd-hda-codec-id:10de0043"); | 2675 | MODULE_ALIAS("snd-hda-codec-id:10de0043"); |
2675 | MODULE_ALIAS("snd-hda-codec-id:10de0044"); | 2676 | MODULE_ALIAS("snd-hda-codec-id:10de0044"); |
2676 | MODULE_ALIAS("snd-hda-codec-id:10de0051"); | 2677 | MODULE_ALIAS("snd-hda-codec-id:10de0051"); |
2678 | MODULE_ALIAS("snd-hda-codec-id:10de0060"); | ||
2677 | MODULE_ALIAS("snd-hda-codec-id:10de0067"); | 2679 | MODULE_ALIAS("snd-hda-codec-id:10de0067"); |
2678 | MODULE_ALIAS("snd-hda-codec-id:10de8001"); | 2680 | MODULE_ALIAS("snd-hda-codec-id:10de8001"); |
2679 | MODULE_ALIAS("snd-hda-codec-id:11069f80"); | 2681 | MODULE_ALIAS("snd-hda-codec-id:11069f80"); |
diff --git a/sound/pci/hda/patch_realtek.c b/sound/pci/hda/patch_realtek.c index 134fbe86d8c3..4a909170b59e 100644 --- a/sound/pci/hda/patch_realtek.c +++ b/sound/pci/hda/patch_realtek.c | |||
@@ -1033,6 +1033,7 @@ enum { | |||
1033 | ALC880_FIXUP_GPIO2, | 1033 | ALC880_FIXUP_GPIO2, |
1034 | ALC880_FIXUP_MEDION_RIM, | 1034 | ALC880_FIXUP_MEDION_RIM, |
1035 | ALC880_FIXUP_LG, | 1035 | ALC880_FIXUP_LG, |
1036 | ALC880_FIXUP_LG_LW25, | ||
1036 | ALC880_FIXUP_W810, | 1037 | ALC880_FIXUP_W810, |
1037 | ALC880_FIXUP_EAPD_COEF, | 1038 | ALC880_FIXUP_EAPD_COEF, |
1038 | ALC880_FIXUP_TCL_S700, | 1039 | ALC880_FIXUP_TCL_S700, |
@@ -1091,6 +1092,14 @@ static const struct hda_fixup alc880_fixups[] = { | |||
1091 | { } | 1092 | { } |
1092 | } | 1093 | } |
1093 | }, | 1094 | }, |
1095 | [ALC880_FIXUP_LG_LW25] = { | ||
1096 | .type = HDA_FIXUP_PINS, | ||
1097 | .v.pins = (const struct hda_pintbl[]) { | ||
1098 | { 0x1a, 0x0181344f }, /* line-in */ | ||
1099 | { 0x1b, 0x0321403f }, /* headphone */ | ||
1100 | { } | ||
1101 | } | ||
1102 | }, | ||
1094 | [ALC880_FIXUP_W810] = { | 1103 | [ALC880_FIXUP_W810] = { |
1095 | .type = HDA_FIXUP_PINS, | 1104 | .type = HDA_FIXUP_PINS, |
1096 | .v.pins = (const struct hda_pintbl[]) { | 1105 | .v.pins = (const struct hda_pintbl[]) { |
@@ -1343,6 +1352,7 @@ static const struct snd_pci_quirk alc880_fixup_tbl[] = { | |||
1343 | SND_PCI_QUIRK(0x1854, 0x003b, "LG", ALC880_FIXUP_LG), | 1352 | SND_PCI_QUIRK(0x1854, 0x003b, "LG", ALC880_FIXUP_LG), |
1344 | SND_PCI_QUIRK(0x1854, 0x005f, "LG P1 Express", ALC880_FIXUP_LG), | 1353 | SND_PCI_QUIRK(0x1854, 0x005f, "LG P1 Express", ALC880_FIXUP_LG), |
1345 | SND_PCI_QUIRK(0x1854, 0x0068, "LG w1", ALC880_FIXUP_LG), | 1354 | SND_PCI_QUIRK(0x1854, 0x0068, "LG w1", ALC880_FIXUP_LG), |
1355 | SND_PCI_QUIRK(0x1854, 0x0077, "LG LW25", ALC880_FIXUP_LG_LW25), | ||
1346 | SND_PCI_QUIRK(0x19db, 0x4188, "TCL S700", ALC880_FIXUP_TCL_S700), | 1356 | SND_PCI_QUIRK(0x19db, 0x4188, "TCL S700", ALC880_FIXUP_TCL_S700), |
1347 | 1357 | ||
1348 | /* Below is the copied entries from alc880_quirks.c. | 1358 | /* Below is the copied entries from alc880_quirks.c. |
@@ -4483,6 +4493,7 @@ static const struct snd_pci_quirk alc662_fixup_tbl[] = { | |||
4483 | SND_PCI_QUIRK(0x1025, 0x0308, "Acer Aspire 8942G", ALC662_FIXUP_ASPIRE), | 4493 | SND_PCI_QUIRK(0x1025, 0x0308, "Acer Aspire 8942G", ALC662_FIXUP_ASPIRE), |
4484 | SND_PCI_QUIRK(0x1025, 0x031c, "Gateway NV79", ALC662_FIXUP_SKU_IGNORE), | 4494 | SND_PCI_QUIRK(0x1025, 0x031c, "Gateway NV79", ALC662_FIXUP_SKU_IGNORE), |
4485 | SND_PCI_QUIRK(0x1025, 0x0349, "eMachines eM250", ALC662_FIXUP_INV_DMIC), | 4495 | SND_PCI_QUIRK(0x1025, 0x0349, "eMachines eM250", ALC662_FIXUP_INV_DMIC), |
4496 | SND_PCI_QUIRK(0x1025, 0x034a, "Gateway LT27", ALC662_FIXUP_INV_DMIC), | ||
4486 | SND_PCI_QUIRK(0x1025, 0x038b, "Acer Aspire 8943G", ALC662_FIXUP_ASPIRE), | 4497 | SND_PCI_QUIRK(0x1025, 0x038b, "Acer Aspire 8943G", ALC662_FIXUP_ASPIRE), |
4487 | SND_PCI_QUIRK(0x1028, 0x05d8, "Dell", ALC668_FIXUP_DELL_MIC_NO_PRESENCE), | 4498 | SND_PCI_QUIRK(0x1028, 0x05d8, "Dell", ALC668_FIXUP_DELL_MIC_NO_PRESENCE), |
4488 | SND_PCI_QUIRK(0x1028, 0x05db, "Dell", ALC668_FIXUP_DELL_MIC_NO_PRESENCE), | 4499 | SND_PCI_QUIRK(0x1028, 0x05db, "Dell", ALC668_FIXUP_DELL_MIC_NO_PRESENCE), |
diff --git a/sound/pci/hda/patch_sigmatel.c b/sound/pci/hda/patch_sigmatel.c index 8f6c35753810..fba0cef1c47f 100644 --- a/sound/pci/hda/patch_sigmatel.c +++ b/sound/pci/hda/patch_sigmatel.c | |||
@@ -418,9 +418,11 @@ static void stac_update_outputs(struct hda_codec *codec) | |||
418 | val &= ~spec->eapd_mask; | 418 | val &= ~spec->eapd_mask; |
419 | else | 419 | else |
420 | val |= spec->eapd_mask; | 420 | val |= spec->eapd_mask; |
421 | if (spec->gpio_data != val) | 421 | if (spec->gpio_data != val) { |
422 | spec->gpio_data = val; | ||
422 | stac_gpio_set(codec, spec->gpio_mask, spec->gpio_dir, | 423 | stac_gpio_set(codec, spec->gpio_mask, spec->gpio_dir, |
423 | val); | 424 | val); |
425 | } | ||
424 | } | 426 | } |
425 | } | 427 | } |
426 | 428 | ||
@@ -2818,6 +2820,7 @@ static const struct hda_pintbl ecs202_pin_configs[] = { | |||
2818 | 2820 | ||
2819 | /* codec SSIDs for Intel Mac sharing the same PCI SSID 8384:7680 */ | 2821 | /* codec SSIDs for Intel Mac sharing the same PCI SSID 8384:7680 */ |
2820 | static const struct snd_pci_quirk stac922x_intel_mac_fixup_tbl[] = { | 2822 | static const struct snd_pci_quirk stac922x_intel_mac_fixup_tbl[] = { |
2823 | SND_PCI_QUIRK(0x0000, 0x0100, "Mac Mini", STAC_INTEL_MAC_V3), | ||
2821 | SND_PCI_QUIRK(0x106b, 0x0800, "Mac", STAC_INTEL_MAC_V1), | 2824 | SND_PCI_QUIRK(0x106b, 0x0800, "Mac", STAC_INTEL_MAC_V1), |
2822 | SND_PCI_QUIRK(0x106b, 0x0600, "Mac", STAC_INTEL_MAC_V2), | 2825 | SND_PCI_QUIRK(0x106b, 0x0600, "Mac", STAC_INTEL_MAC_V2), |
2823 | SND_PCI_QUIRK(0x106b, 0x0700, "Mac", STAC_INTEL_MAC_V2), | 2826 | SND_PCI_QUIRK(0x106b, 0x0700, "Mac", STAC_INTEL_MAC_V2), |
@@ -3230,7 +3233,7 @@ static const struct hda_fixup stac927x_fixups[] = { | |||
3230 | .type = HDA_FIXUP_PINS, | 3233 | .type = HDA_FIXUP_PINS, |
3231 | .v.pins = (const struct hda_pintbl[]) { | 3234 | .v.pins = (const struct hda_pintbl[]) { |
3232 | /* correct the front output jack as a hp out */ | 3235 | /* correct the front output jack as a hp out */ |
3233 | { 0x0f, 0x0227011f }, | 3236 | { 0x0f, 0x0221101f }, |
3234 | /* correct the front input jack as a mic */ | 3237 | /* correct the front input jack as a mic */ |
3235 | { 0x0e, 0x02a79130 }, | 3238 | { 0x0e, 0x02a79130 }, |
3236 | {} | 3239 | {} |
@@ -3622,20 +3625,18 @@ static int stac_parse_auto_config(struct hda_codec *codec) | |||
3622 | static int stac_init(struct hda_codec *codec) | 3625 | static int stac_init(struct hda_codec *codec) |
3623 | { | 3626 | { |
3624 | struct sigmatel_spec *spec = codec->spec; | 3627 | struct sigmatel_spec *spec = codec->spec; |
3625 | unsigned int gpio; | ||
3626 | int i; | 3628 | int i; |
3627 | 3629 | ||
3628 | /* override some hints */ | 3630 | /* override some hints */ |
3629 | stac_store_hints(codec); | 3631 | stac_store_hints(codec); |
3630 | 3632 | ||
3631 | /* set up GPIO */ | 3633 | /* set up GPIO */ |
3632 | gpio = spec->gpio_data; | ||
3633 | /* turn on EAPD statically when spec->eapd_switch isn't set. | 3634 | /* turn on EAPD statically when spec->eapd_switch isn't set. |
3634 | * otherwise, unsol event will turn it on/off dynamically | 3635 | * otherwise, unsol event will turn it on/off dynamically |
3635 | */ | 3636 | */ |
3636 | if (!spec->eapd_switch) | 3637 | if (!spec->eapd_switch) |
3637 | gpio |= spec->eapd_mask; | 3638 | spec->gpio_data |= spec->eapd_mask; |
3638 | stac_gpio_set(codec, spec->gpio_mask, spec->gpio_dir, gpio); | 3639 | stac_gpio_set(codec, spec->gpio_mask, spec->gpio_dir, spec->gpio_data); |
3639 | 3640 | ||
3640 | snd_hda_gen_init(codec); | 3641 | snd_hda_gen_init(codec); |
3641 | 3642 | ||
@@ -3925,6 +3926,7 @@ static void stac_setup_gpio(struct hda_codec *codec) | |||
3925 | { | 3926 | { |
3926 | struct sigmatel_spec *spec = codec->spec; | 3927 | struct sigmatel_spec *spec = codec->spec; |
3927 | 3928 | ||
3929 | spec->gpio_mask |= spec->eapd_mask; | ||
3928 | if (spec->gpio_led) { | 3930 | if (spec->gpio_led) { |
3929 | if (!spec->vref_mute_led_nid) { | 3931 | if (!spec->vref_mute_led_nid) { |
3930 | spec->gpio_mask |= spec->gpio_led; | 3932 | spec->gpio_mask |= spec->gpio_led; |