Changeset 678


Ignore:
Timestamp:
Mar 5, 2021, 9:43:24 AM (4 years ago)
Author:
Paul Smedley
Message:

Update sound code to 5.10.20

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  
    1515#include <linux/pm.h>
    1616#include <linux/completion.h>
     17#include <linux/interrupt.h>
    1718
    1819#include <sound/core.h>
     
    426427        snd_device_disconnect_all(card);
    427428
     429        if (card->sync_irq > 0)
     430                synchronize_irq(card->sync_irq);
     431
    428432        snd_info_card_disconnect(card);
    429433        if (card->registered) {
  • GPL/branches/uniaud32-next/alsa-kernel/core/pcm.c

    r629 r678  
    11211121        }
    11221122
     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
    11231127        pcm_call_notify(pcm, n_disconnect);
    11241128        for (cidx = 0; cidx < 2; cidx++) {
  • GPL/branches/uniaud32-next/alsa-kernel/core/pcm_local.h

    r629 r678  
    6464void __snd_pcm_xrun(struct snd_pcm_substream *substream);
    6565void snd_pcm_group_init(struct snd_pcm_group *group);
     66void snd_pcm_sync_stop(struct snd_pcm_substream *substream, bool sync_irq);
    6667
    6768#ifdef CONFIG_SND_DMA_SGBUF
  • GPL/branches/uniaud32-next/alsa-kernel/core/pcm_native.c

    r644 r678  
    588588}
    589589
    590 static void snd_pcm_sync_stop(struct snd_pcm_substream *substream)
    591 {
    592         if (substream->runtime->stop_operating) {
     590void snd_pcm_sync_stop(struct snd_pcm_substream *substream, bool sync_irq)
     591{
     592        if (substream->runtime && substream->runtime->stop_operating) {
    593593                substream->runtime->stop_operating = false;
    594                 if (substream->ops->sync_stop)
     594                if (substream->ops && substream->ops->sync_stop)
    595595                        substream->ops->sync_stop(substream);
    596                 else if (substream->pcm->card->sync_irq > 0)
     596                else if (sync_irq && substream->pcm->card->sync_irq > 0)
    597597                        synchronize_irq(substream->pcm->card->sync_irq);
    598598        }
     
    691691                        return -EBADFD;
    692692
    693         snd_pcm_sync_stop(substream);
     693        snd_pcm_sync_stop(substream, true);
    694694
    695695        params->rmask = ~0U;
     
    814814        int result = 0;
    815815
    816         snd_pcm_sync_stop(substream);
     816        snd_pcm_sync_stop(substream, true);
    817817        if (substream->ops->hw_free)
    818818                result = substream->ops->hw_free(substream);
     
    14471447{
    14481448        if (substream->runtime->trigger_master == substream &&
    1449             snd_pcm_running(substream))
     1449            snd_pcm_running(substream)) {
    14501450                substream->ops->trigger(substream, SNDRV_PCM_TRIGGER_STOP);
     1451                substream->runtime->stop_operating = true;
     1452        }
    14511453        return 0; /* unconditonally stop all substreams */
    14521454}
     
    14611463                snd_pcm_timer_notify(substream, SNDRV_TIMER_EVENT_MSTOP);
    14621464        }
    1463         runtime->stop_operating = true;
    14641465        wake_up(&runtime->sleep);
    14651466        wake_up(&runtime->tsleep);
     
    16411642                return 0;
    16421643        substream->ops->trigger(substream, SNDRV_PCM_TRIGGER_SUSPEND);
     1644        runtime->stop_operating = true;
    16431645        return 0; /* suspend unconditionally */
    16441646}
     
    17171719                }
    17181720        }
     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
    17191727        return 0;
    17201728}
     
    17621770        runtime->status->state = runtime->status->suspended_state;
    17631771        snd_pcm_timer_notify(substream, SNDRV_TIMER_EVENT_MRESUME);
    1764         snd_pcm_sync_stop(substream);
    17651772}
    17661773
     
    18921899{
    18931900        int err;
    1894         snd_pcm_sync_stop(substream);
     1901        snd_pcm_sync_stop(substream, true);
    18951902        err = substream->ops->prepare(substream);
    18961903        if (err < 0)
  • GPL/branches/uniaud32-next/alsa-kernel/include/sound/version.h

    r676 r678  
    11/* include/version.h */
    2 #define CONFIG_SND_VERSION "5.10.17"
     2#define CONFIG_SND_VERSION "5.10.20"
    33#define CONFIG_SND_DATE ""
  • GPL/branches/uniaud32-next/alsa-kernel/pci/hda/hda_intel.c

    r674 r678  
    25302530        /* CometLake-H */
    25312531        { PCI_DEVICE(0x8086, 0x06C8),
     2532          .driver_data = AZX_DRIVER_SKL | AZX_DCAPS_INTEL_SKYLAKE},
     2533        { PCI_DEVICE(0x8086, 0xf1c8),
    25322534          .driver_data = AZX_DRIVER_SKL | AZX_DCAPS_INTEL_SKYLAKE},
    25332535        /* CometLake-S */
  • GPL/branches/uniaud32-next/alsa-kernel/pci/hda/patch_hdmi.c

    r674 r678  
    21412141                }
    21422142                per_cvt = get_cvt(spec, cvt_idx);
    2143                 snd_BUG_ON(!per_cvt->assigned);
    21442143                per_cvt->assigned = 0;
    21452144                hinfo->nid = 0;
  • GPL/branches/uniaud32-next/alsa-kernel/pci/hda/patch_realtek.c

    r673 r678  
    22662266        ALC889_FIXUP_VAIO_TT,
    22672267        ALC888_FIXUP_EEE1601,
     2268        ALC886_FIXUP_EAPD,
    22682269        ALC882_FIXUP_EAPD,
    22692270        ALC883_FIXUP_EAPD,
     
    25782579};
    25792580
     2581static 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
    25802588static const struct hda_verb ALC882_FIXUP_EAPD_VERBS[] = {
    25812589                        /* change to EAPD mode */
     
    27442752#else
    27452753                .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
    27462767#endif
    27472768        },
     
    30483069
    30493070        SND_PCI_QUIRK(0x1071, 0x8258, "Evesham Voyaeger", ALC882_FIXUP_EAPD),
     3071        SND_PCI_QUIRK(0x13fe, 0x1009, "Advantech MIT-W101", ALC886_FIXUP_EAPD),
    30503072        SND_PCI_QUIRK(0x1458, 0xa002, "Gigabyte EP45-DS3/Z87X-UD3H", ALC889_FIXUP_FRONT_HP_NO_PRESENCE),
    30513073        SND_PCI_QUIRK(0x1458, 0xa0b8, "Gigabyte AZ370-Gaming", ALC1220_FIXUP_GB_DUAL_CODECS),
     
    49294951#endif
    49304952                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 */
     4959static 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;
    49314975        }
    49324976}
     
    69426986        ALC269_FIXUP_HP_DOCK_GPIO_MIC1_LED,
    69436987        ALC280_FIXUP_HP_9480M,
     6988        ALC245_FIXUP_HP_X360_AMP,
    69446989        ALC288_FIXUP_DELL_HEADSET_MODE,
    69456990        ALC288_FIXUP_DELL1_MIC_NO_PRESENCE,
     
    79337978                .type = HDA_FIXUP_FUNC,
    79347979                .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,
    79357984        },
    79367985        [ALC288_FIXUP_DELL_HEADSET_MODE] = {
     
    89789027        SND_PCI_QUIRK(0x103c, 0x87f4, "HP", ALC287_FIXUP_HP_GPIO_LED),
    89799028        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),
    89809030        SND_PCI_QUIRK(0x1043, 0x103e, "ASUS X540SA", ALC256_FIXUP_ASUS_MIC),
    89819031        SND_PCI_QUIRK(0x1043, 0x103f, "ASUS TX300", ALC282_FIXUP_ASUS_TX300),
     
    93509400        {.id = ALC255_FIXUP_XIAOMI_HEADSET_MIC, .name = "alc255-xiaomi-headset"},
    93519401        {.id = ALC274_FIXUP_HP_MIC, .name = "alc274-hp-mic-detect"},
     9402        {.id = ALC245_FIXUP_HP_X360_AMP, .name = "alc245-hp-x360-amp"},
    93529403        {0}
    93539404};
Note: See TracChangeset for help on using the changeset viewer.