Changeset 678
- Timestamp:
- Mar 5, 2021, 9:43:24 AM (4 years ago)
- Location:
- GPL/branches/uniaud32-next/alsa-kernel
- Files:
-
- 8 edited
Legend:
- Unmodified
- Added
- Removed
-
GPL/branches/uniaud32-next/alsa-kernel/core/init.c
r644 r678 15 15 #include <linux/pm.h> 16 16 #include <linux/completion.h> 17 #include <linux/interrupt.h> 17 18 18 19 #include <sound/core.h> … … 426 427 snd_device_disconnect_all(card); 427 428 429 if (card->sync_irq > 0) 430 synchronize_irq(card->sync_irq); 431 428 432 snd_info_card_disconnect(card); 429 433 if (card->registered) { -
GPL/branches/uniaud32-next/alsa-kernel/core/pcm.c
r629 r678 1121 1121 } 1122 1122 1123 for (cidx = 0; cidx < 2; cidx++) 1124 for (substream = pcm->streams[cidx].substream; substream; substream = substream->next) 1125 snd_pcm_sync_stop(substream, false); 1126 1123 1127 pcm_call_notify(pcm, n_disconnect); 1124 1128 for (cidx = 0; cidx < 2; cidx++) { -
GPL/branches/uniaud32-next/alsa-kernel/core/pcm_local.h
r629 r678 64 64 void __snd_pcm_xrun(struct snd_pcm_substream *substream); 65 65 void snd_pcm_group_init(struct snd_pcm_group *group); 66 void snd_pcm_sync_stop(struct snd_pcm_substream *substream, bool sync_irq); 66 67 67 68 #ifdef CONFIG_SND_DMA_SGBUF -
GPL/branches/uniaud32-next/alsa-kernel/core/pcm_native.c
r644 r678 588 588 } 589 589 590 static void snd_pcm_sync_stop(struct snd_pcm_substream *substream)591 { 592 if (substream->runtime ->stop_operating) {590 void snd_pcm_sync_stop(struct snd_pcm_substream *substream, bool sync_irq) 591 { 592 if (substream->runtime && substream->runtime->stop_operating) { 593 593 substream->runtime->stop_operating = false; 594 if (substream->ops ->sync_stop)594 if (substream->ops && substream->ops->sync_stop) 595 595 substream->ops->sync_stop(substream); 596 else if (s ubstream->pcm->card->sync_irq > 0)596 else if (sync_irq && substream->pcm->card->sync_irq > 0) 597 597 synchronize_irq(substream->pcm->card->sync_irq); 598 598 } … … 691 691 return -EBADFD; 692 692 693 snd_pcm_sync_stop(substream );693 snd_pcm_sync_stop(substream, true); 694 694 695 695 params->rmask = ~0U; … … 814 814 int result = 0; 815 815 816 snd_pcm_sync_stop(substream );816 snd_pcm_sync_stop(substream, true); 817 817 if (substream->ops->hw_free) 818 818 result = substream->ops->hw_free(substream); … … 1447 1447 { 1448 1448 if (substream->runtime->trigger_master == substream && 1449 snd_pcm_running(substream)) 1449 snd_pcm_running(substream)) { 1450 1450 substream->ops->trigger(substream, SNDRV_PCM_TRIGGER_STOP); 1451 substream->runtime->stop_operating = true; 1452 } 1451 1453 return 0; /* unconditonally stop all substreams */ 1452 1454 } … … 1461 1463 snd_pcm_timer_notify(substream, SNDRV_TIMER_EVENT_MSTOP); 1462 1464 } 1463 runtime->stop_operating = true;1464 1465 wake_up(&runtime->sleep); 1465 1466 wake_up(&runtime->tsleep); … … 1641 1642 return 0; 1642 1643 substream->ops->trigger(substream, SNDRV_PCM_TRIGGER_SUSPEND); 1644 runtime->stop_operating = true; 1643 1645 return 0; /* suspend unconditionally */ 1644 1646 } … … 1717 1719 } 1718 1720 } 1721 1722 for (stream = 0; stream < 2; stream++) 1723 for (substream = pcm->streams[stream].substream; 1724 substream; substream = substream->next) 1725 snd_pcm_sync_stop(substream, false); 1726 1719 1727 return 0; 1720 1728 } … … 1762 1770 runtime->status->state = runtime->status->suspended_state; 1763 1771 snd_pcm_timer_notify(substream, SNDRV_TIMER_EVENT_MRESUME); 1764 snd_pcm_sync_stop(substream);1765 1772 } 1766 1773 … … 1892 1899 { 1893 1900 int err; 1894 snd_pcm_sync_stop(substream );1901 snd_pcm_sync_stop(substream, true); 1895 1902 err = substream->ops->prepare(substream); 1896 1903 if (err < 0) -
GPL/branches/uniaud32-next/alsa-kernel/include/sound/version.h
r676 r678 1 1 /* include/version.h */ 2 #define CONFIG_SND_VERSION "5.10. 17"2 #define CONFIG_SND_VERSION "5.10.20" 3 3 #define CONFIG_SND_DATE "" -
GPL/branches/uniaud32-next/alsa-kernel/pci/hda/hda_intel.c
r674 r678 2530 2530 /* CometLake-H */ 2531 2531 { PCI_DEVICE(0x8086, 0x06C8), 2532 .driver_data = AZX_DRIVER_SKL | AZX_DCAPS_INTEL_SKYLAKE}, 2533 { PCI_DEVICE(0x8086, 0xf1c8), 2532 2534 .driver_data = AZX_DRIVER_SKL | AZX_DCAPS_INTEL_SKYLAKE}, 2533 2535 /* CometLake-S */ -
GPL/branches/uniaud32-next/alsa-kernel/pci/hda/patch_hdmi.c
r674 r678 2141 2141 } 2142 2142 per_cvt = get_cvt(spec, cvt_idx); 2143 snd_BUG_ON(!per_cvt->assigned);2144 2143 per_cvt->assigned = 0; 2145 2144 hinfo->nid = 0; -
GPL/branches/uniaud32-next/alsa-kernel/pci/hda/patch_realtek.c
r673 r678 2266 2266 ALC889_FIXUP_VAIO_TT, 2267 2267 ALC888_FIXUP_EEE1601, 2268 ALC886_FIXUP_EAPD, 2268 2269 ALC882_FIXUP_EAPD, 2269 2270 ALC883_FIXUP_EAPD, … … 2578 2579 }; 2579 2580 2581 static const struct hda_verb ALC886_FIXUP_EAPD_VERBS[] = { 2582 /* change to EAPD mode */ 2583 { 0x20, AC_VERB_SET_COEF_INDEX, 0x07 }, 2584 { 0x20, AC_VERB_SET_PROC_COEF, 0x0068 }, 2585 {0} 2586 }; 2587 2580 2588 static const struct hda_verb ALC882_FIXUP_EAPD_VERBS[] = { 2581 2589 /* change to EAPD mode */ … … 2744 2752 #else 2745 2753 .v.verbs = ALC888_FIXUP_EEE1601_VERBS 2754 #endif 2755 }, 2756 [ALC886_FIXUP_EAPD] = { 2757 .type = HDA_FIXUP_VERBS, 2758 #ifndef TARGET_OS2 2759 .v.verbs = (const struct hda_verb[]) { 2760 /* change to EAPD mode */ 2761 { 0x20, AC_VERB_SET_COEF_INDEX, 0x07 }, 2762 { 0x20, AC_VERB_SET_PROC_COEF, 0x0068 }, 2763 {0} 2764 } 2765 #else 2766 .v.verbs = ALC886_FIXUP_EAPD_VERBS 2746 2767 #endif 2747 2768 }, … … 3048 3069 3049 3070 SND_PCI_QUIRK(0x1071, 0x8258, "Evesham Voyaeger", ALC882_FIXUP_EAPD), 3071 SND_PCI_QUIRK(0x13fe, 0x1009, "Advantech MIT-W101", ALC886_FIXUP_EAPD), 3050 3072 SND_PCI_QUIRK(0x1458, 0xa002, "Gigabyte EP45-DS3/Z87X-UD3H", ALC889_FIXUP_FRONT_HP_NO_PRESENCE), 3051 3073 SND_PCI_QUIRK(0x1458, 0xa0b8, "Gigabyte AZ370-Gaming", ALC1220_FIXUP_GB_DUAL_CODECS), … … 4929 4951 #endif 4930 4952 codec->power_filter = led_power_filter; 4953 } 4954 } 4955 4956 /* HP Spectre x360 14 model needs a unique workaround for enabling the amp; 4957 * it needs to toggle the GPIO0 once on and off at each time (bko#210633) 4958 */ 4959 static void alc245_fixup_hp_x360_amp(struct hda_codec *codec, 4960 const struct hda_fixup *fix, int action) 4961 { 4962 struct alc_spec *spec = codec->spec; 4963 4964 switch (action) { 4965 case HDA_FIXUP_ACT_PRE_PROBE: 4966 spec->gpio_mask |= 0x01; 4967 spec->gpio_dir |= 0x01; 4968 break; 4969 case HDA_FIXUP_ACT_INIT: 4970 /* need to toggle GPIO to enable the amp */ 4971 alc_update_gpio_data(codec, 0x01, true); 4972 msleep(100); 4973 alc_update_gpio_data(codec, 0x01, false); 4974 break; 4931 4975 } 4932 4976 } … … 6942 6986 ALC269_FIXUP_HP_DOCK_GPIO_MIC1_LED, 6943 6987 ALC280_FIXUP_HP_9480M, 6988 ALC245_FIXUP_HP_X360_AMP, 6944 6989 ALC288_FIXUP_DELL_HEADSET_MODE, 6945 6990 ALC288_FIXUP_DELL1_MIC_NO_PRESENCE, … … 7933 7978 .type = HDA_FIXUP_FUNC, 7934 7979 .v.func = alc280_fixup_hp_9480m, 7980 }, 7981 [ALC245_FIXUP_HP_X360_AMP] = { 7982 .type = HDA_FIXUP_FUNC, 7983 .v.func = alc245_fixup_hp_x360_amp, 7935 7984 }, 7936 7985 [ALC288_FIXUP_DELL_HEADSET_MODE] = { … … 8978 9027 SND_PCI_QUIRK(0x103c, 0x87f4, "HP", ALC287_FIXUP_HP_GPIO_LED), 8979 9028 SND_PCI_QUIRK(0x103c, 0x87f5, "HP", ALC287_FIXUP_HP_GPIO_LED), 9029 SND_PCI_QUIRK(0x103c, 0x87f7, "HP Spectre x360 14", ALC245_FIXUP_HP_X360_AMP), 8980 9030 SND_PCI_QUIRK(0x1043, 0x103e, "ASUS X540SA", ALC256_FIXUP_ASUS_MIC), 8981 9031 SND_PCI_QUIRK(0x1043, 0x103f, "ASUS TX300", ALC282_FIXUP_ASUS_TX300), … … 9350 9400 {.id = ALC255_FIXUP_XIAOMI_HEADSET_MIC, .name = "alc255-xiaomi-headset"}, 9351 9401 {.id = ALC274_FIXUP_HP_MIC, .name = "alc274-hp-mic-detect"}, 9402 {.id = ALC245_FIXUP_HP_X360_AMP, .name = "alc245-hp-x360-amp"}, 9352 9403 {0} 9353 9404 };
Note:
See TracChangeset
for help on using the changeset viewer.