Changeset 760


Ignore:
Timestamp:
Sep 1, 2024, 10:57:46 AM (11 months ago)
Author:
Paul Smedley
Message:

Update source to 6.1.107

Location:
GPL/branches/uniaud32-exp
Files:
21 edited

Legend:

Unmodified
Added
Removed
  • GPL/branches/uniaud32-exp/alsa-kernel/core/info.c

    r750 r760  
    5757
    5858static int snd_info_version_init(void);
    59 static void snd_info_disconnect(struct snd_info_entry *entry);
     59static void snd_info_clear_entries(struct snd_info_entry *entry);
    6060
    6161/*
     
    572572        if (!card)
    573573                return;
     574
     575        proc_remove(card->proc_root_link);
     576        if (card->proc_root)
     577                proc_remove(card->proc_root->p);
     578
    574579        mutex_lock(&info_mutex);
    575         proc_remove(card->proc_root_link);
     580        if (card->proc_root)
     581                snd_info_clear_entries(card->proc_root);
    576582        card->proc_root_link = NULL;
    577         if (card->proc_root)
    578                 snd_info_disconnect(card->proc_root);
     583        card->proc_root = NULL;
    579584        mutex_unlock(&info_mutex);
    580585}
     
    748753EXPORT_SYMBOL(snd_info_create_card_entry);
    749754
    750 static void snd_info_disconnect(struct snd_info_entry *entry)
     755static void snd_info_clear_entries(struct snd_info_entry *entry)
    751756{
    752757        struct snd_info_entry *p;
     
    755760                return;
    756761        list_for_each_entry(p, &entry->children, list, struct snd_info_entry)
    757                 snd_info_disconnect(p);
    758         proc_remove(entry->p);
     762                snd_info_clear_entries(p);
    759763        entry->p = NULL;
    760764}
     
    773777                return;
    774778        if (entry->p) {
     779                proc_remove(entry->p);
    775780                mutex_lock(&info_mutex);
    776                 snd_info_disconnect(entry);
     781                snd_info_clear_entries(entry);
    777782                mutex_unlock(&info_mutex);
    778783        }
  • GPL/branches/uniaud32-exp/alsa-kernel/core/init.c

    r750 r760  
    312312#ifdef MODULE
    313313        WARN_ON(!module);
     314#endif
    314315        card->module = module;
    315 #endif
    316316        INIT_LIST_HEAD(&card->devices);
    317317        init_rwsem(&card->controls_rwsem);
     
    526526        spin_unlock(&card->files_lock);
    527527
     528#ifdef CONFIG_PM
     529        /* wake up sleepers here before other callbacks for avoiding potential
     530         * deadlocks with other locks (e.g. in kctls);
     531         * then this notifies the shutdown and sleepers would abort immediately
     532         */
     533        wake_up_all(&card->power_sleep);
     534#endif
     535
    528536        /* notify all connected devices about disconnection */
    529537        /* at this point, they cannot respond to any calls except release() */
     
    541549
    542550        snd_info_card_disconnect(card);
     551#ifdef CONFIG_SND_DEBUG
     552        debugfs_remove(card->debugfs_root);
     553        card->debugfs_root = NULL;
     554#endif
     555
    543556        if (card->registered) {
    544557                device_del(&card->card_dev);
     
    553566
    554567#ifdef CONFIG_PM
    555         wake_up(&card->power_sleep);
    556568        snd_power_sync_ref(card);
    557569#endif
     
    603615                /* Not fatal error */
    604616        }
    605 #ifdef CONFIG_SND_DEBUG
    606         debugfs_remove(card->debugfs_root);
    607         card->debugfs_root = NULL;
    608 #endif
    609617        if (card->release_completion)
    610618                complete(card->release_completion);
  • GPL/branches/uniaud32-exp/alsa-kernel/core/jack.c

    r759 r760  
    3838#endif /* CONFIG_SND_JACK_INPUT_DEV */
    3939
     40static void snd_jack_remove_debugfs(struct snd_jack *jack);
     41
    4042static int snd_jack_dev_disconnect(struct snd_device *device)
    4143{
    42 #ifdef CONFIG_SND_JACK_INPUT_DEV
    4344        struct snd_jack *jack = device->device_data;
    4445
    45         mutex_lock(&jack->input_dev_lock);
    46         if (!jack->input_dev) {
    47                 mutex_unlock(&jack->input_dev_lock);
     46        snd_jack_remove_debugfs(jack);
     47
     48#ifdef CONFIG_SND_JACK_INPUT_DEV
     49        guard(mutex)(&jack->input_dev_lock);
     50        if (!jack->input_dev)
    4851                return 0;
    49         }
    5052
    5153        /* If the input device is registered with the input subsystem
     
    5658                input_free_device(jack->input_dev);
    5759        jack->input_dev = NULL;
    58         mutex_unlock(&jack->input_dev_lock);
    5960#endif /* CONFIG_SND_JACK_INPUT_DEV */
    6061        return 0;
     
    9596                 card->shortname, jack->id);
    9697
    97         mutex_lock(&jack->input_dev_lock);
    98         if (!jack->input_dev) {
    99                 mutex_unlock(&jack->input_dev_lock);
     98        guard(mutex)(&jack->input_dev_lock);
     99        if (!jack->input_dev)
    100100                return 0;
    101         }
    102101
    103102        jack->input_dev->name = jack->name;
     
    124123                jack->registered = 1;
    125124
    126         mutex_unlock(&jack->input_dev_lock);
    127125        return err;
    128126}
     
    390388}
    391389
    392 static void snd_jack_debugfs_clear_inject_node(struct snd_jack_kctl *jack_kctl)
    393 {
    394         debugfs_remove(jack_kctl->jack_debugfs_root);
    395         jack_kctl->jack_debugfs_root = NULL;
     390static void snd_jack_remove_debugfs(struct snd_jack *jack)
     391{
     392        struct snd_jack_kctl *jack_kctl;
     393
     394        list_for_each_entry(jack_kctl, &jack->kctl_list, list) {
     395                debugfs_remove(jack_kctl->jack_debugfs_root);
     396                jack_kctl->jack_debugfs_root = NULL;
     397        }
    396398}
    397399#else /* CONFIG_SND_JACK_INJECTION_DEBUG */
     
    402404}
    403405
    404 static void snd_jack_debugfs_clear_inject_node(struct snd_jack_kctl *jack_kctl)
     406static void snd_jack_remove_debugfs(struct snd_jack *jack)
    405407{
    406408}
     
    413415        jack_kctl = kctl->private_data;
    414416        if (jack_kctl) {
    415                 snd_jack_debugfs_clear_inject_node(jack_kctl);
    416417                list_del(&jack_kctl->list);
    417418                kfree(jack_kctl);
     
    506507#ifdef CONFIG_SND_JACK_INPUT_DEV
    507508                .dev_register = snd_jack_dev_register,
     509#endif /* CONFIG_SND_JACK_INPUT_DEV */
    508510                .dev_disconnect = snd_jack_dev_disconnect,
    509 #endif /* CONFIG_SND_JACK_INPUT_DEV */
    510511        };
    511512
     
    589590{
    590591        WARN_ON(jack->registered);
    591         mutex_lock(&jack->input_dev_lock);
    592         if (!jack->input_dev) {
    593                 mutex_unlock(&jack->input_dev_lock);
    594                 return;
    595         }
    596 
    597         jack->input_dev->dev.parent = parent;
    598         mutex_unlock(&jack->input_dev_lock);
     592        guard(mutex)(&jack->input_dev_lock);
     593        if (jack->input_dev)
     594                jack->input_dev->dev.parent = parent;
    599595}
    600596EXPORT_SYMBOL(snd_jack_set_parent);
  • GPL/branches/uniaud32-exp/alsa-kernel/core/pcm.c

    r756 r760  
    257257        STATE(PAUSED),
    258258        STATE(SUSPENDED),
     259        STATE(DISCONNECTED),
    259260};
    260261
  • GPL/branches/uniaud32-exp/alsa-kernel/core/pcm_native.c

    r757 r760  
    18091809{
    18101810        struct snd_pcm_runtime *runtime = substream->runtime;
     1811        if (runtime->state != SNDRV_PCM_STATE_SUSPENDED)
     1812                return -EBADFD;
    18111813        if (!(runtime->info & SNDRV_PCM_INFO_RESUME))
    18121814                return -ENOSYS;
  • GPL/branches/uniaud32-exp/alsa-kernel/core/seq/seq_midi.c

    r697 r760  
    117117}
    118118
     119/* callback for snd_seq_dump_var_event(), bridging to dump_midi() */
     120static int __dump_midi(void *ptr, void *buf, int count)
     121{
     122        return dump_midi(ptr, buf, count);
     123}
     124
    119125static int event_process_midi(struct snd_seq_event *ev, int direct,
    120126                              void *private_data, int atomic, int hop)
     
    136142                        return 0;
    137143                }
    138                 snd_seq_dump_var_event(ev, (snd_seq_dump_func_t)dump_midi, substream);
     144                snd_seq_dump_var_event(ev, __dump_midi, substream);
    139145                snd_midi_event_reset_decode(msynth->parser);
    140146        } else {
  • GPL/branches/uniaud32-exp/alsa-kernel/core/timer.c

    r739 r760  
    553553                result = -EBUSY;
    554554                goto unlock;
     555        }
     556
     557        /* check the actual time for the start tick;
     558         * bail out as error if it's way too low (< 100us)
     559         */
     560        if (start && !(timer->hw.flags & SNDRV_TIMER_HW_SLAVE)) {
     561                if ((u64)snd_timer_hw_resolution(timer) * ticks < 100000) {
     562                        result = -EINVAL;
     563                        goto unlock;
     564                }
    555565        }
    556566
  • GPL/branches/uniaud32-exp/alsa-kernel/hda/hdac_stream.c

    r756 r760  
    368368
    369369        /* make a non-zero unique key for the substream */
    370         int key = (substream->pcm->device << 16) | (substream->number << 2) |
    371                 (substream->stream + 1);
     370        int key = (substream->number << 2) | (substream->stream + 1);
     371
     372        if (substream->pcm)
     373                key |= (substream->pcm->device << 16);
    372374
    373375        spin_lock_irq(&bus->reg_lock);
     
    671673        bool inited = false;
    672674        u64 cycle_last = 0;
    673         int i = 0;
    674675
    675676        list_for_each_entry(s, &bus->stream_list, list, struct hdac_stream) {
    676                 if (streams & (1 << i)) {
     677                if ((streams & (1 << s->index))) {
    677678                        azx_timecounter_init(s, inited, cycle_last);
    678679                        if (!inited) {
     
    681682                        }
    682683                }
    683                 i++;
    684684        }
    685685
     
    726726{
    727727        struct hdac_bus *bus = azx_dev->bus;
    728         int i, nwait, timeout;
     728        int nwait, timeout;
    729729        struct hdac_stream *s;
    730730
    731731        for (timeout = 5000; timeout; timeout--) {
    732732                nwait = 0;
    733                 i = 0;
    734733                list_for_each_entry(s, &bus->stream_list, list, struct hdac_stream) {
    735                         if (!(streams & (1 << i++)))
     734                        if (!(streams & (1 << s->index)))
    736735                                continue;
    737736
  • GPL/branches/uniaud32-exp/alsa-kernel/include/sound/dmaengine_pcm.h

    r750 r760  
    3737        struct dma_chan *chan);
    3838int snd_dmaengine_pcm_close(struct snd_pcm_substream *substream);
     39int snd_dmaengine_pcm_sync_stop(struct snd_pcm_substream *substream);
    3940
    4041int snd_dmaengine_pcm_open_request_chan(struct snd_pcm_substream *substream,
  • GPL/branches/uniaud32-exp/alsa-kernel/include/sound/soc-acpi.h

    r759 r760  
    6868 * @num_dai_drivers: number of elements in @dai_drivers
    6969 * @dai_drivers: pointer to dai_drivers, used e.g. in nocodec mode
     70 * @subsystem_vendor: optional PCI SSID vendor value
     71 * @subsystem_device: optional PCI SSID device value
     72 * @subsystem_id_set: true if a value has been written to
     73 *                    subsystem_vendor and subsystem_device.
    7074 */
    7175struct snd_soc_acpi_mach_params {
     
    8084        u32 num_dai_drivers;
    8185        struct snd_soc_dai_driver *dai_drivers;
     86        unsigned short subsystem_vendor;
     87        unsigned short subsystem_device;
     88        bool subsystem_id_set;
    8289};
    8390
  • GPL/branches/uniaud32-exp/alsa-kernel/include/sound/soc.h

    r756 r760  
    912912        char dmi_longname[80];
    913913#endif /* CONFIG_DMI */
     914
     915#ifdef CONFIG_PCI
     916        /*
     917         * PCI does not define 0 as invalid, so pci_subsystem_set indicates
     918         * whether a value has been written to these fields.
     919         */
     920        unsigned short pci_subsystem_vendor;
     921        unsigned short pci_subsystem_device;
     922        bool pci_subsystem_set;
     923#endif /* CONFIG_PCI */
     924
    914925        char topology_shortname[32];
    915926
  • GPL/branches/uniaud32-exp/alsa-kernel/include/sound/sof.h

    r756 r760  
    6363        const char *name;
    6464        const char *platform;
     65
     66        /*
     67         * PCI SSID. As PCI does not define 0 as invalid, the subsystem_id_set
     68         * flag indicates that a value has been written to these members.
     69         */
     70        unsigned short subsystem_vendor;
     71        unsigned short subsystem_device;
     72        bool subsystem_id_set;
    6573
    6674        struct device *dev;
  • GPL/branches/uniaud32-exp/alsa-kernel/include/sound/version.h

    r759 r760  
    11/* include/version.h */
    2 #define CONFIG_SND_VERSION "6.1.62"
     2#define CONFIG_SND_VERSION "6.1.107"
    33#define CONFIG_SND_DATE ""
  • GPL/branches/uniaud32-exp/alsa-kernel/pci/hda/hda_controller.h

    r757 r760  
    2929#define AZX_DCAPS_I915_COMPONENT 0              /* NOP */
    3030#endif
    31 /* 14 unused */
     31#define AZX_DCAPS_AMD_ALLOC_FIX (1 << 14)       /* AMD allocation workaround */
    3232#define AZX_DCAPS_CTX_WORKAROUND (1 << 15)      /* X-Fi workaround */
    3333#define AZX_DCAPS_POSFIX_LPIB   (1 << 16)       /* Use LPIB as default */
  • GPL/branches/uniaud32-exp/alsa-kernel/pci/hda/hda_intel.c

    r759 r760  
    4646#ifdef CONFIG_X86
    4747/* for snoop control */
     48#include <linux/dma-map-ops.h>
    4849#include <asm/set_memory.h>
    4950#include <asm/cpufeature.h>
     
    323324/* quirks for ATI HDMI with snoop off */
    324325#define AZX_DCAPS_PRESET_ATI_HDMI_NS \
    325         (AZX_DCAPS_PRESET_ATI_HDMI | AZX_DCAPS_SNOOP_OFF)
     326        (AZX_DCAPS_PRESET_ATI_HDMI | AZX_DCAPS_AMD_ALLOC_FIX)
    326327
    327328/* quirks for AMD SB */
     
    17551756        if (chip->driver_caps & AZX_DCAPS_SNOOP_OFF)
    17561757                snoop = false;
     1758
     1759#ifdef CONFIG_X86
     1760        /* check the presence of DMA ops (i.e. IOMMU), disable snoop conditionally */
     1761        if ((chip->driver_caps & AZX_DCAPS_AMD_ALLOC_FIX) &&
     1762            !get_dma_ops(chip->card->dev))
     1763                snoop = false;
     1764#endif
    17571765
    17581766        chip->snoop = snoop;
     
    22712279        /* https://bugs.launchpad.net/bugs/1821663 */
    22722280        SND_PCI_QUIRK(0x1631, 0xe017, "Packard Bell NEC IMEDIA 5204", 0),
     2281        /* KONTRON SinglePC may cause a stall at runtime resume */
     2282        SND_PCI_QUIRK(0x1734, 0x1232, "KONTRON SinglePC", 0),
    22732283        {0}
    22742284};
     
    26032613        { PCI_DEVICE(0x8086, 0xa828),
    26042614          .driver_data = AZX_DRIVER_SKL | AZX_DCAPS_INTEL_SKYLAKE},
     2615        /* Arrow Lake */
     2616        { PCI_DEVICE_DATA(INTEL, HDA_ARL, AZX_DRIVER_SKL | AZX_DCAPS_INTEL_SKYLAKE) },
    26052617        /* Broxton-P(Apollolake) */
    26062618        { PCI_DEVICE(0x8086, 0x5a98),
  • GPL/branches/uniaud32-exp/alsa-kernel/pci/hda/patch_conexant.c

    r759 r760  
    4747        unsigned int gpio_mute_led_mask;
    4848        unsigned int gpio_mic_led_mask;
    49 
     49        bool is_cx8070_sn6140;
    5050};
    5151
     
    171171}
    172172
     173static void cx_fixup_headset_recog(struct hda_codec *codec)
     174{
     175        unsigned int mic_persent;
     176
     177        /* fix some headset type recognize fail issue, such as EDIFIER headset */
     178        /* set micbiasd output current comparator threshold from 66% to 55%. */
     179        snd_hda_codec_write(codec, 0x1c, 0, 0x320, 0x010);
     180        /* set OFF voltage for DFET from -1.2V to -0.8V, set headset micbias registor
     181         * value adjustment trim from 2.2K ohms to 2.0K ohms.
     182         */
     183        snd_hda_codec_write(codec, 0x1c, 0, 0x3b0, 0xe10);
     184        /* fix reboot headset type recognize fail issue */
     185        mic_persent = snd_hda_codec_read(codec, 0x19, 0, AC_VERB_GET_PIN_SENSE, 0x0);
     186        if (mic_persent & AC_PINSENSE_PRESENCE)
     187                /* enable headset mic VREF */
     188                snd_hda_codec_write(codec, 0x19, 0, AC_VERB_SET_PIN_WIDGET_CONTROL, 0x24);
     189        else
     190                /* disable headset mic VREF */
     191                snd_hda_codec_write(codec, 0x19, 0, AC_VERB_SET_PIN_WIDGET_CONTROL, 0x20);
     192}
     193
    173194static int cx_auto_init(struct hda_codec *codec)
    174195{
     
    181202        snd_hda_apply_fixup(codec, HDA_FIXUP_ACT_INIT);
    182203
     204        if (spec->is_cx8070_sn6140)
     205                cx_fixup_headset_recog(codec);
     206
    183207        return 0;
    184208}
     
    197221        cx_auto_shutdown(codec);
    198222        snd_hda_gen_free(codec);
     223}
     224
     225static void cx_process_headset_plugin(struct hda_codec *codec)
     226{
     227        unsigned int val;
     228        unsigned int count = 0;
     229
     230        /* Wait headset detect done. */
     231        do {
     232                val = snd_hda_codec_read(codec, 0x1c, 0, 0xca0, 0x0);
     233                if (val & 0x080) {
     234                        codec_dbg(codec, "headset type detect done!\n");
     235                        break;
     236                }
     237                msleep(20);
     238                count++;
     239        } while (count < 3);
     240        val = snd_hda_codec_read(codec, 0x1c, 0, 0xcb0, 0x0);
     241        if (val & 0x800) {
     242                codec_dbg(codec, "headset plugin, type is CTIA\n");
     243                snd_hda_codec_write(codec, 0x19, 0, AC_VERB_SET_PIN_WIDGET_CONTROL, 0x24);
     244        } else if (val & 0x400) {
     245                codec_dbg(codec, "headset plugin, type is OMTP\n");
     246                snd_hda_codec_write(codec, 0x19, 0, AC_VERB_SET_PIN_WIDGET_CONTROL, 0x24);
     247        } else {
     248                codec_dbg(codec, "headphone plugin\n");
     249        }
     250}
     251
     252static void cx_update_headset_mic_vref(struct hda_codec *codec, struct hda_jack_callback *event)
     253{
     254        unsigned int mic_present;
     255
     256        /* In cx8070 and sn6140, the node 16 can only be config to headphone or disabled,
     257         * the node 19 can only be config to microphone or disabled.
     258         * Check hp&mic tag to process headset pulgin&plugout.
     259         */
     260        mic_present = snd_hda_codec_read(codec, 0x19, 0, AC_VERB_GET_PIN_SENSE, 0x0);
     261        if (!(mic_present & AC_PINSENSE_PRESENCE)) /* mic plugout */
     262                snd_hda_codec_write(codec, 0x19, 0, AC_VERB_SET_PIN_WIDGET_CONTROL, 0x20);
     263        else
     264                cx_process_headset_plugin(codec);
    199265}
    200266
     
    249315        CXT_FIXUP_HEADSET_MIC,
    250316        CXT_FIXUP_HP_MIC_NO_PRESENCE,
     317        CXT_PINCFG_SWS_JS201D,
    251318};
    252319
     
    778845#endif
    779846
     847/* SuoWoSi/South-holding JS201D with sn6140 */
     848static const struct hda_pintbl cxt_pincfg_sws_js201d[] = {
     849        { 0x16, 0x03211040 }, /* hp out */
     850        { 0x17, 0x91170110 }, /* SPK/Class_D */
     851        { 0x18, 0x95a70130 }, /* Internal mic */
     852        { 0x19, 0x03a11020 }, /* Headset Mic */
     853        { 0x1a, 0x40f001f0 }, /* Not used */
     854        { 0x21, 0x40f001f0 }, /* Not used */
     855        {0}
     856};
     857
    780858static const struct hda_fixup cxt_fixups[] = {
    781859        [CXT_PINCFG_LENOVO_X200] = {
     
    9551033                .chained = true,
    9561034                .chain_id = CXT_FIXUP_HEADSET_MIC,
     1035        },
     1036        [CXT_PINCFG_SWS_JS201D] = {
     1037                .type = HDA_FIXUP_PINS,
     1038                .v.pins = cxt_pincfg_sws_js201d,
    9571039        },
    9581040#endif
     
    10301112        SND_PCI_QUIRK(0x103c, 0x8458, "HP Z2 G4 mini premium", CXT_FIXUP_HP_MIC_NO_PRESENCE),
    10311113        SND_PCI_QUIRK(0x1043, 0x138d, "Asus", CXT_FIXUP_HEADPHONE_MIC_PIN),
     1114        SND_PCI_QUIRK(0x14f1, 0x0265, "SWS JS201D", CXT_PINCFG_SWS_JS201D),
    10321115        SND_PCI_QUIRK(0x152d, 0x0833, "OLPC XO-1.5", CXT_FIXUP_OLPC_XO),
    10331116        SND_PCI_QUIRK(0x17aa, 0x20f2, "Lenovo T400", CXT_PINCFG_LENOVO_TP410),
     
    10701153        { .id = CXT_FIXUP_HP_MIC_NO_PRESENCE, .name = "hp-mic-fix" },
    10711154        { .id = CXT_PINCFG_LENOVO_NOTEBOOK, .name = "lenovo-20149" },
     1155        { .id = CXT_PINCFG_SWS_JS201D, .name = "sws-js201d" },
    10721156        {0}
    10731157};
     
    11041188        codec->spec = spec;
    11051189        codec->patch_ops = cx_auto_patch_ops;
     1190
     1191        /* init cx8070/sn6140 flag and reset headset_present_flag */
     1192        switch (codec->core.vendor_id) {
     1193        case 0x14f11f86:
     1194        case 0x14f11f87:
     1195                spec->is_cx8070_sn6140 = true;
     1196                snd_hda_jack_detect_enable_callback(codec, 0x19, cx_update_headset_mic_vref);
     1197                break;
     1198        }
    11061199
    11071200        cx_auto_parse_eapd(codec);
  • GPL/branches/uniaud32-exp/alsa-kernel/pci/hda/patch_hdmi.c

    r759 r760  
    20062006
    20072007static const struct snd_pci_quirk force_connect_list[] = {
     2008        SND_PCI_QUIRK(0x103c, 0x83e2, "HP EliteDesk 800 G4", 1),
     2009        SND_PCI_QUIRK(0x103c, 0x83ef, "HP MP9 G4 Retail System AMS", 1),
    20082010        SND_PCI_QUIRK(0x103c, 0x870f, "HP", 1),
    20092011        SND_PCI_QUIRK(0x103c, 0x871a, "HP", 1),
    20102012        SND_PCI_QUIRK(0x103c, 0x8711, "HP", 1),
    20112013        SND_PCI_QUIRK(0x103c, 0x8715, "HP", 1),
     2014        SND_PCI_QUIRK(0x1043, 0x86ae, "ASUS", 1),  /* Z170 PRO */
     2015        SND_PCI_QUIRK(0x1043, 0x86c7, "ASUS", 1),  /* Z170M PLUS */
    20122016        SND_PCI_QUIRK(0x1462, 0xec94, "MS-7C94", 1),
     2017        SND_PCI_QUIRK(0x8086, 0x2060, "Intel NUC5CPYB", 1),
    20132018        SND_PCI_QUIRK(0x8086, 0x2081, "Intel NUC 10", 1),
    20142019        {0}
  • GPL/branches/uniaud32-exp/alsa-kernel/pci/hda/patch_realtek.c

    r759 r760  
    597597        case 0x19e58326:
    598598        case 0x10ec0283:
     599        case 0x10ec0285:
    599600        case 0x10ec0286:
     601        case 0x10ec0287:
    600602        case 0x10ec0288:
     603        case 0x10ec0295:
    601604        case 0x10ec0298:
    602605                alc_headset_mic_no_shutup(codec);
     
    23512354        ALC887_FIXUP_ASUS_HMIC,
    23522355        ALCS1200A_FIXUP_MIC_VREF,
     2356        ALC888VD_FIXUP_MIC_100VREF,
    23532357};
    23542358
     
    31633167
    31643168        SND_PCI_QUIRK(0x1071, 0x8258, "Evesham Voyaeger", ALC882_FIXUP_EAPD),
     3169        SND_PCI_QUIRK(0x10ec, 0x12d8, "iBase Elo Touch", ALC888VD_FIXUP_MIC_100VREF),
    31653170        SND_PCI_QUIRK(0x13fe, 0x1009, "Advantech MIT-W101", ALC886_FIXUP_EAPD),
    31663171        SND_PCI_QUIRK(0x1458, 0xa002, "Gigabyte EP45-DS3/Z87X-UD3H", ALC889_FIXUP_FRONT_HP_NO_PRESENCE),
     
    35083513                .v.func = alc_fixup_no_depop_delay,
    35093514        },
     3515#ifdef NOT_USED
     3516        [ALC888VD_FIXUP_MIC_100VREF] = {
     3517                .type = HDA_FIXUP_PINCTLS,
     3518                .v.pins = (const struct hda_pintbl[]) {
     3519                        { 0x18, PIN_VREF100 }, /* headset mic */
     3520                        {}
     3521                }
     3522        },
     3523#endif
    35103524};
    35113525
     
    39053919        case 0x10ec0236:
    39063920        case 0x10ec0256:
     3921        case 0x10ec0257:
    39073922        case 0x19e58326:
    39083923                alc_write_coef_idx(codec, 0x48, 0x0);
     
    39343949        case 0x10ec0236:
    39353950        case 0x10ec0256:
     3951        case 0x10ec0257:
    39363952        case 0x19e58326:
    39373953                alc_write_coef_idx(codec, 0x48, 0xd011);
     
    43204336        int coef38, coef0d, coef36;
    43214337
     4338        alc_write_coefex_idx(codec, 0x58, 0x00, 0x1888); /* write default value */
    43224339        alc_update_coef_idx(codec, 0x4a, 1<<15, 1<<15); /* Reset HP JD */
    43234340        coef38 = alc_read_coef_idx(codec, 0x38); /* Amp control */
     
    71997216        case 0x10ec0255:
    72007217        case 0x10ec0256:
     7218        case 0x10ec0257:
    72017219        case 0x19e58326:
    72027220                alc_update_coef_idx(codec, 0x1b, 0x8000, 1 << 15); /* Reset HP JD */
     
    73827400                /* force front speaker to DAC1 */
    73837401                snd_hda_override_conn_list(codec, 0x17, ARRAY_SIZE(conn), conn);
     7402                break;
     7403        }
     7404}
     7405
     7406static void alc285_fixup_hp_envy_x360(struct hda_codec *codec,
     7407                                      const struct hda_fixup *fix,
     7408                                      int action)
     7409{
     7410        static const struct coef_fw coefs[] = {
     7411                WRITE_COEF(0x08, 0x6a0c), WRITE_COEF(0x0d, 0xa023),
     7412                WRITE_COEF(0x10, 0x0320), WRITE_COEF(0x1a, 0x8c03),
     7413                WRITE_COEF(0x25, 0x1800), WRITE_COEF(0x26, 0x003a),
     7414                WRITE_COEF(0x28, 0x1dfe), WRITE_COEF(0x29, 0xb014),
     7415                WRITE_COEF(0x2b, 0x1dfe), WRITE_COEF(0x37, 0xfe15),
     7416                WRITE_COEF(0x38, 0x7909), WRITE_COEF(0x45, 0xd489),
     7417                WRITE_COEF(0x46, 0x00f4), WRITE_COEF(0x4a, 0x21e0),
     7418                WRITE_COEF(0x66, 0x03f0), WRITE_COEF(0x67, 0x1000),
     7419                WRITE_COEF(0x6e, 0x1005), {0}
     7420        };
     7421
     7422        static const struct hda_pintbl pincfgs[] = {
     7423                { 0x12, 0xb7a60130 },  /* Internal microphone*/
     7424                { 0x14, 0x90170150 },  /* B&O soundbar speakers */
     7425                { 0x17, 0x90170153 },  /* Side speakers */
     7426                { 0x19, 0x03a11040 },  /* Headset microphone */
     7427                {0}
     7428        };
     7429
     7430        switch (action) {
     7431        case HDA_FIXUP_ACT_PRE_PROBE:
     7432                snd_hda_apply_pincfgs(codec, pincfgs);
     7433
     7434                /* Fixes volume control problem for side speakers */
     7435                alc295_fixup_disable_dac3(codec, fix, action);
     7436
     7437                /* Fixes no sound from headset speaker */
     7438                snd_hda_codec_amp_stereo(codec, 0x21, HDA_OUTPUT, 0, -1, 0);
     7439
     7440                /* Auto-enable headset mic when plugged */
     7441                snd_hda_jack_set_gating_jack(codec, 0x19, 0x21);
     7442
     7443                /* Headset mic volume enhancement */
     7444                snd_hda_codec_set_pin_target(codec, 0x19, PIN_VREF50);
     7445                break;
     7446        case HDA_FIXUP_ACT_INIT:
     7447                alc_process_coef_fw(codec, coefs);
     7448                break;
     7449        case HDA_FIXUP_ACT_BUILD:
     7450                rename_ctl(codec, "Bass Speaker Playback Volume",
     7451                           "B&O-Tuned Playback Volume");
     7452                rename_ctl(codec, "Front Playback Switch",
     7453                           "B&O Soundbar Playback Switch");
     7454                rename_ctl(codec, "Bass Speaker Playback Switch",
     7455                           "Side Speaker Playback Switch");
    73847456                break;
    73857457        }
     
    78027874        ALC269_FIXUP_THINKPAD_ACPI,
    78037875        ALC269_FIXUP_DMIC_THINKPAD_ACPI,
     7876        ALC269VB_FIXUP_CHUWI_COREBOOK_XPRO,
    78047877        ALC255_FIXUP_ACER_MIC_NO_PRESENCE,
    78057878        ALC255_FIXUP_ASUS_MIC_NO_PRESENCE,
     
    78237896        ALC245_FIXUP_HP_X360_AMP,
    78247897        ALC285_FIXUP_HP_SPECTRE_X360_EB1,
     7898        ALC285_FIXUP_HP_ENVY_X360,
    78257899        ALC288_FIXUP_DELL_HEADSET_MODE,
    78267900        ALC288_FIXUP_DELL1_MIC_NO_PRESENCE,
     
    78447918        ALC285_FIXUP_ASUS_SPEAKER2_TO_DAC1,
    78457919        ALC285_FIXUP_ASUS_HEADSET_MIC,
     7920        ALC285_FIXUP_ASUS_SPI_REAR_SPEAKERS,
    78467921        ALC285_FIXUP_ASUS_I2C_SPEAKER2_TO_DAC1,
    78477922        ALC285_FIXUP_ASUS_I2C_HEADSET_MIC,
     
    83488423                .v.func = alc269_fixup_pincfg_U7x7_headset_mic,
    83498424        },
     8425#ifdef NOT_USED
     8426        [ALC269VB_FIXUP_CHUWI_COREBOOK_XPRO] = {
     8427                .type = HDA_FIXUP_PINS,
     8428                .v.pins = (const struct hda_pintbl[]) {
     8429                        { 0x18, 0x03a19020 }, /* headset mic */
     8430                        { 0x1b, 0x90170150 }, /* speaker */
     8431                        { }
     8432                },
     8433        },
     8434#endif
    83508435        [ALC269_FIXUP_AMIC] = {
    83518436                .type = HDA_FIXUP_PINS,
     
    91449229                .chained = true,
    91459230                .chain_id = ALC285_FIXUP_ASUS_SPEAKER2_TO_DAC1
     9231        },
     9232        [ALC285_FIXUP_ASUS_SPI_REAR_SPEAKERS] = {
     9233                .type = HDA_FIXUP_PINS,
     9234                .v.pins = (const struct hda_pintbl[]) {
     9235                        { 0x14, 0x90170120 },
     9236                        { }
     9237                },
     9238                .chained = true,
     9239                .chain_id = ALC285_FIXUP_ASUS_HEADSET_MIC
    91469240        },
    91479241#endif
     
    1005610150                .type = HDA_FIXUP_FUNC,
    1005710151                .v.func = alc285_fixup_hp_spectre_x360_eb1
     10152        },
     10153        [ALC285_FIXUP_HP_ENVY_X360] = {
     10154                .type = HDA_FIXUP_FUNC,
     10155                .v.func = alc285_fixup_hp_envy_x360,
     10156                .chained = true,
     10157                .chain_id = ALC285_FIXUP_HP_GPIO_AMP_INIT,
    1005810158        },
    1005910159        [ALC287_FIXUP_IDEAPAD_BASS_SPK_AMP] = {
     
    1039310493                .v.func = cs35l41_fixup_i2c_two,
    1039410494                .chained = true,
    10395                 .chain_id = ALC269_FIXUP_THINKPAD_ACPI,
     10495                .chain_id = ALC285_FIXUP_THINKPAD_NO_BASS_SPK_HEADSET_JACK,
    1039610496        },
    1039710497        [ALC245_FIXUP_HP_MUTE_LED_COEFBIT] = {
     
    1040810508                .type = HDA_FIXUP_FUNC,
    1040910509                .v.func = alc287_fixup_bind_dacs,
     10510                .chained = true,
     10511                .chain_id = ALC285_FIXUP_THINKPAD_NO_BASS_SPK_HEADSET_JACK,
    1041010512        },
    1041110513        [ALC287_FIXUP_MG_RTKC_CSAMP_CS35L41_I2C_THINKPAD] = {
     
    1043410536        SND_PCI_QUIRK(0x1025, 0x080d, "Acer Aspire V5-122P", ALC269_FIXUP_ASPIRE_HEADSET_MIC),
    1043510537        SND_PCI_QUIRK(0x1025, 0x0840, "Acer Aspire E1", ALC269VB_FIXUP_ASPIRE_E1_COEF),
     10538        SND_PCI_QUIRK(0x1025, 0x100c, "Acer Aspire E5-574G", ALC255_FIXUP_ACER_LIMIT_INT_MIC_BOOST),
    1043610539        SND_PCI_QUIRK(0x1025, 0x101c, "Acer Veriton N2510G", ALC269_FIXUP_LIFEBOOK),
    1043710540        SND_PCI_QUIRK(0x1025, 0x102b, "Acer Aspire C24-860", ALC286_FIXUP_ACER_AIO_MIC_NO_PRESENCE),
     
    1044710550        SND_PCI_QUIRK(0x1025, 0x1248, "Acer Veriton N4660G", ALC269VC_FIXUP_ACER_MIC_NO_PRESENCE),
    1044810551        SND_PCI_QUIRK(0x1025, 0x1269, "Acer SWIFT SF314-54", ALC256_FIXUP_ACER_HEADSET_MIC),
     10552        SND_PCI_QUIRK(0x1025, 0x126a, "Acer Swift SF114-32", ALC256_FIXUP_ACER_MIC_NO_PRESENCE),
    1044910553        SND_PCI_QUIRK(0x1025, 0x128f, "Acer Veriton Z6860G", ALC286_FIXUP_ACER_AIO_HEADSET_MIC),
    1045010554        SND_PCI_QUIRK(0x1025, 0x1290, "Acer Veriton Z4860G", ALC286_FIXUP_ACER_AIO_HEADSET_MIC),
     
    1060210706        SND_PCI_QUIRK(0x103c, 0x841c, "HP Pavilion 15-CK0xx", ALC269_FIXUP_HP_MUTE_LED_MIC3),
    1060310707        SND_PCI_QUIRK(0x103c, 0x8497, "HP Envy x360", ALC269_FIXUP_HP_MUTE_LED_MIC3),
     10708        SND_PCI_QUIRK(0x103c, 0x84a6, "HP 250 G7 Notebook PC", ALC269_FIXUP_HP_LINE1_MIC1_LED),
     10709        SND_PCI_QUIRK(0x103c, 0x84ae, "HP 15-db0403ng", ALC236_FIXUP_HP_MUTE_LED_COEFBIT2),
    1060410710        SND_PCI_QUIRK(0x103c, 0x84da, "HP OMEN dc0019-ur", ALC295_FIXUP_HP_OMEN),
    1060510711        SND_PCI_QUIRK(0x103c, 0x84e7, "HP Pavilion 15", ALC269_FIXUP_HP_MUTE_LED_MIC3),
    1060610712        SND_PCI_QUIRK(0x103c, 0x8519, "HP Spectre x360 15-df0xxx", ALC285_FIXUP_HP_SPECTRE_X360),
     10713        SND_PCI_QUIRK(0x103c, 0x8537, "HP ProBook 440 G6", ALC236_FIXUP_HP_MUTE_LED_MICMUTE_VREF),
     10714        SND_PCI_QUIRK(0x103c, 0x85de, "HP Envy x360 13-ar0xxx", ALC285_FIXUP_HP_ENVY_X360),
    1060710715        SND_PCI_QUIRK(0x103c, 0x860f, "HP ZBook 15 G6", ALC285_FIXUP_HP_GPIO_AMP_INIT),
    1060810716        SND_PCI_QUIRK(0x103c, 0x861f, "HP Elite Dragonfly G1", ALC285_FIXUP_HP_GPIO_AMP_INIT),
    1060910717        SND_PCI_QUIRK(0x103c, 0x869d, "HP", ALC236_FIXUP_HP_MUTE_LED),
     10718        SND_PCI_QUIRK(0x103c, 0x86c1, "HP Laptop 15-da3001TU", ALC236_FIXUP_HP_MUTE_LED_COEFBIT2),
    1061010719        SND_PCI_QUIRK(0x103c, 0x86c7, "HP Envy AiO 32", ALC274_FIXUP_HP_ENVY_GPIO),
    1061110720        SND_PCI_QUIRK(0x103c, 0x86e7, "HP Spectre x360 15-eb0xxx", ALC285_FIXUP_HP_SPECTRE_X360_EB1),
     
    1062110730        SND_PCI_QUIRK(0x103c, 0x8736, "HP", ALC285_FIXUP_HP_GPIO_AMP_INIT),
    1062210731        SND_PCI_QUIRK(0x103c, 0x8760, "HP", ALC285_FIXUP_HP_MUTE_LED),
     10732        SND_PCI_QUIRK(0x103c, 0x876e, "HP ENVY x360 Convertible 13-ay0xxx", ALC245_FIXUP_HP_X360_MUTE_LEDS),
    1062310733        SND_PCI_QUIRK(0x103c, 0x877a, "HP", ALC285_FIXUP_HP_MUTE_LED),
    1062410734        SND_PCI_QUIRK(0x103c, 0x877d, "HP", ALC236_FIXUP_HP_MUTE_LED),
     
    1063010740        SND_PCI_QUIRK(0x103c, 0x8787, "HP OMEN 15", ALC285_FIXUP_HP_MUTE_LED),
    1063110741        SND_PCI_QUIRK(0x103c, 0x8788, "HP OMEN 15", ALC285_FIXUP_HP_MUTE_LED),
     10742        SND_PCI_QUIRK(0x103c, 0x87b7, "HP Laptop 14-fq0xxx", ALC236_FIXUP_HP_MUTE_LED_COEFBIT2),
    1063210743        SND_PCI_QUIRK(0x103c, 0x87c8, "HP", ALC287_FIXUP_HP_GPIO_LED),
     10744        SND_PCI_QUIRK(0x103c, 0x87d3, "HP Laptop 15-gw0xxx", ALC236_FIXUP_HP_MUTE_LED_COEFBIT2),
    1063310745        SND_PCI_QUIRK(0x103c, 0x87e5, "HP ProBook 440 G8 Notebook PC", ALC236_FIXUP_HP_GPIO_LED),
    1063410746        SND_PCI_QUIRK(0x103c, 0x87e7, "HP ProBook 450 G8 Notebook PC", ALC236_FIXUP_HP_GPIO_LED),
     
    1063910751        SND_PCI_QUIRK(0x103c, 0x87f6, "HP Spectre x360 14", ALC245_FIXUP_HP_X360_AMP),
    1064010752        SND_PCI_QUIRK(0x103c, 0x87f7, "HP Spectre x360 14", ALC245_FIXUP_HP_X360_AMP),
     10753        SND_PCI_QUIRK(0x103c, 0x87fe, "HP Laptop 15s-fq2xxx", ALC236_FIXUP_HP_MUTE_LED_COEFBIT2),
    1064110754        SND_PCI_QUIRK(0x103c, 0x8805, "HP ProBook 650 G8 Notebook PC", ALC236_FIXUP_HP_GPIO_LED),
    1064210755        SND_PCI_QUIRK(0x103c, 0x880d, "HP EliteBook 830 G8 Notebook PC", ALC285_FIXUP_HP_GPIO_LED),
     
    1066110774        SND_PCI_QUIRK(0x103c, 0x88d0, "HP Pavilion 15-eh1xxx (mainboard 88D0)", ALC287_FIXUP_HP_GPIO_LED),
    1066210775        SND_PCI_QUIRK(0x103c, 0x8902, "HP OMEN 16", ALC285_FIXUP_HP_MUTE_LED),
     10776        SND_PCI_QUIRK(0x103c, 0x890e, "HP 255 G8 Notebook PC", ALC236_FIXUP_HP_MUTE_LED_COEFBIT2),
    1066310777        SND_PCI_QUIRK(0x103c, 0x8919, "HP Pavilion Aero Laptop 13-be0xxx", ALC287_FIXUP_HP_GPIO_LED),
    1066410778        SND_PCI_QUIRK(0x103c, 0x896d, "HP ZBook Firefly 16 G9", ALC245_FIXUP_CS35L41_SPI_2_HP_GPIO_LED),
     
    1066910783        SND_PCI_QUIRK(0x103c, 0x8974, "HP EliteBook 840 Aero G9", ALC245_FIXUP_CS35L41_SPI_2_HP_GPIO_LED),
    1067010784        SND_PCI_QUIRK(0x103c, 0x8975, "HP EliteBook x360 840 Aero G9", ALC245_FIXUP_CS35L41_SPI_2_HP_GPIO_LED),
     10785        SND_PCI_QUIRK(0x103c, 0x897d, "HP mt440 Mobile Thin Client U74", ALC236_FIXUP_HP_GPIO_LED),
    1067110786        SND_PCI_QUIRK(0x103c, 0x8981, "HP Elite Dragonfly G3", ALC245_FIXUP_CS35L41_SPI_4),
    1067210787        SND_PCI_QUIRK(0x103c, 0x898e, "HP EliteBook 835 G9", ALC287_FIXUP_CS35L41_I2C_2),
     
    1068610801        SND_PCI_QUIRK(0x103c, 0x89ca, "HP", ALC236_FIXUP_HP_MUTE_LED_MICMUTE_VREF),
    1068710802        SND_PCI_QUIRK(0x103c, 0x89d3, "HP EliteBook 645 G9 (MB 89D2)", ALC236_FIXUP_HP_MUTE_LED_MICMUTE_VREF),
     10803        SND_PCI_QUIRK(0x103c, 0x8a0f, "HP Pavilion 14-ec1xxx", ALC287_FIXUP_HP_GPIO_LED),
    1068810804        SND_PCI_QUIRK(0x103c, 0x8a20, "HP Laptop 15s-fq5xxx", ALC236_FIXUP_HP_MUTE_LED_COEFBIT2),
    1068910805        SND_PCI_QUIRK(0x103c, 0x8a25, "HP Victus 16-d1xxx (MB 8A25)", ALC245_FIXUP_HP_MUTE_LED_COEFBIT),
     
    1069310809        SND_PCI_QUIRK(0x103c, 0x8aa8, "HP EliteBook 640 G9 (MB 8AA6)", ALC236_FIXUP_HP_GPIO_LED),
    1069410810        SND_PCI_QUIRK(0x103c, 0x8aab, "HP EliteBook 650 G9 (MB 8AA9)", ALC236_FIXUP_HP_GPIO_LED),
     10811        SND_PCI_QUIRK(0x103c, 0x8ab9, "HP EliteBook 840 G8 (MB 8AB8)", ALC285_FIXUP_HP_GPIO_LED),
    1069510812        SND_PCI_QUIRK(0x103c, 0x8abb, "HP ZBook Firefly 14 G9", ALC245_FIXUP_CS35L41_SPI_2_HP_GPIO_LED),
    1069610813        SND_PCI_QUIRK(0x103c, 0x8ad1, "HP EliteBook 840 14 inch G9 Notebook PC", ALC245_FIXUP_CS35L41_SPI_2_HP_GPIO_LED),
    1069710814        SND_PCI_QUIRK(0x103c, 0x8ad2, "HP EliteBook 860 16 inch G9 Notebook PC", ALC245_FIXUP_CS35L41_SPI_2_HP_GPIO_LED),
     10815        SND_PCI_QUIRK(0x103c, 0x8b0f, "HP Elite mt645 G7 Mobile Thin Client U81", ALC236_FIXUP_HP_MUTE_LED_MICMUTE_VREF),
     10816        SND_PCI_QUIRK(0x103c, 0x8b2f, "HP 255 15.6 inch G10 Notebook PC", ALC236_FIXUP_HP_MUTE_LED_COEFBIT2),
     10817        SND_PCI_QUIRK(0x103c, 0x8b3f, "HP mt440 Mobile Thin Client U91", ALC236_FIXUP_HP_GPIO_LED),
    1069810818        SND_PCI_QUIRK(0x103c, 0x8b42, "HP", ALC245_FIXUP_CS35L41_SPI_2_HP_GPIO_LED),
    1069910819        SND_PCI_QUIRK(0x103c, 0x8b43, "HP", ALC245_FIXUP_CS35L41_SPI_2_HP_GPIO_LED),
     
    1070210822        SND_PCI_QUIRK(0x103c, 0x8b46, "HP", ALC245_FIXUP_CS35L41_SPI_2_HP_GPIO_LED),
    1070310823        SND_PCI_QUIRK(0x103c, 0x8b47, "HP", ALC245_FIXUP_CS35L41_SPI_2_HP_GPIO_LED),
     10824        SND_PCI_QUIRK(0x103c, 0x8b59, "HP Elite mt645 G7 Mobile Thin Client U89", ALC236_FIXUP_HP_MUTE_LED_MICMUTE_VREF),
    1070410825        SND_PCI_QUIRK(0x103c, 0x8b5d, "HP", ALC236_FIXUP_HP_MUTE_LED_MICMUTE_VREF),
    1070510826        SND_PCI_QUIRK(0x103c, 0x8b5e, "HP", ALC236_FIXUP_HP_MUTE_LED_MICMUTE_VREF),
     
    1072910850        SND_PCI_QUIRK(0x103c, 0x8c71, "HP EliteBook 845 G11", ALC287_FIXUP_CS35L41_I2C_2_HP_GPIO_LED),
    1073010851        SND_PCI_QUIRK(0x103c, 0x8c72, "HP EliteBook 865 G11", ALC287_FIXUP_CS35L41_I2C_2_HP_GPIO_LED),
     10852        SND_PCI_QUIRK(0x103c, 0x8c7b, "HP ProBook 445 G11", ALC236_FIXUP_HP_MUTE_LED_MICMUTE_VREF),
     10853        SND_PCI_QUIRK(0x103c, 0x8c7c, "HP ProBook 445 G11", ALC236_FIXUP_HP_MUTE_LED_MICMUTE_VREF),
     10854        SND_PCI_QUIRK(0x103c, 0x8c7d, "HP ProBook 465 G11", ALC236_FIXUP_HP_MUTE_LED_MICMUTE_VREF),
     10855        SND_PCI_QUIRK(0x103c, 0x8c7e, "HP ProBook 465 G11", ALC236_FIXUP_HP_MUTE_LED_MICMUTE_VREF),
     10856        SND_PCI_QUIRK(0x103c, 0x8c7f, "HP EliteBook 645 G11", ALC236_FIXUP_HP_MUTE_LED_MICMUTE_VREF),
     10857        SND_PCI_QUIRK(0x103c, 0x8c80, "HP EliteBook 645 G11", ALC236_FIXUP_HP_MUTE_LED_MICMUTE_VREF),
     10858        SND_PCI_QUIRK(0x103c, 0x8c81, "HP EliteBook 665 G11", ALC236_FIXUP_HP_MUTE_LED_MICMUTE_VREF),
     10859        SND_PCI_QUIRK(0x103c, 0x8c89, "HP ProBook 460 G11", ALC236_FIXUP_HP_GPIO_LED),
     10860        SND_PCI_QUIRK(0x103c, 0x8c8a, "HP EliteBook 630", ALC236_FIXUP_HP_GPIO_LED),
     10861        SND_PCI_QUIRK(0x103c, 0x8c8c, "HP EliteBook 660", ALC236_FIXUP_HP_GPIO_LED),
     10862        SND_PCI_QUIRK(0x103c, 0x8c8d, "HP ProBook 440 G11", ALC236_FIXUP_HP_GPIO_LED),
     10863        SND_PCI_QUIRK(0x103c, 0x8c8e, "HP ProBook 460 G11", ALC236_FIXUP_HP_GPIO_LED),
     10864        SND_PCI_QUIRK(0x103c, 0x8c90, "HP EliteBook 640", ALC236_FIXUP_HP_GPIO_LED),
     10865        SND_PCI_QUIRK(0x103c, 0x8c91, "HP EliteBook 660", ALC236_FIXUP_HP_GPIO_LED),
     10866        SND_PCI_QUIRK(0x103c, 0x8c96, "HP", ALC236_FIXUP_HP_MUTE_LED_MICMUTE_VREF),
     10867        SND_PCI_QUIRK(0x103c, 0x8c97, "HP ZBook", ALC236_FIXUP_HP_MUTE_LED_MICMUTE_VREF),
     10868        SND_PCI_QUIRK(0x103c, 0x8ca1, "HP ZBook Power", ALC236_FIXUP_HP_GPIO_LED),
     10869        SND_PCI_QUIRK(0x103c, 0x8ca2, "HP ZBook Power", ALC236_FIXUP_HP_GPIO_LED),
     10870        SND_PCI_QUIRK(0x103c, 0x8ca4, "HP ZBook Fury", ALC245_FIXUP_CS35L41_SPI_2_HP_GPIO_LED),
     10871        SND_PCI_QUIRK(0x103c, 0x8ca7, "HP ZBook Fury", ALC245_FIXUP_CS35L41_SPI_2_HP_GPIO_LED),
     10872        SND_PCI_QUIRK(0x103c, 0x8cf5, "HP ZBook Studio 16", ALC245_FIXUP_CS35L41_SPI_4_HP_GPIO_LED),
    1073110873        SND_PCI_QUIRK(0x1043, 0x103e, "ASUS X540SA", ALC256_FIXUP_ASUS_MIC),
    1073210874        SND_PCI_QUIRK(0x1043, 0x103f, "ASUS TX300", ALC282_FIXUP_ASUS_TX300),
     
    1073510877        SND_PCI_QUIRK(0x1043, 0x10c0, "ASUS X540SA", ALC256_FIXUP_ASUS_MIC),
    1073610878        SND_PCI_QUIRK(0x1043, 0x10d0, "ASUS X540LA/X540LJ", ALC255_FIXUP_ASUS_MIC_NO_PRESENCE),
     10879        SND_PCI_QUIRK(0x1043, 0x10d3, "ASUS K6500ZC", ALC294_FIXUP_ASUS_SPK),
    1073710880        SND_PCI_QUIRK(0x1043, 0x115d, "Asus 1015E", ALC269_FIXUP_LIMIT_INT_MIC_BOOST),
    1073810881        SND_PCI_QUIRK(0x1043, 0x11c0, "ASUS X556UR", ALC255_FIXUP_ASUS_MIC_NO_PRESENCE),
     
    1075310896        SND_PCI_QUIRK(0x1043, 0x1483, "ASUS GU603V", ALC285_FIXUP_ASUS_HEADSET_MIC),
    1075410897        SND_PCI_QUIRK(0x1043, 0x1517, "Asus Zenbook UX31A", ALC269VB_FIXUP_ASUS_ZENBOOK_UX31A),
     10898        SND_PCI_QUIRK(0x1043, 0x1533, "ASUS GV302XA", ALC287_FIXUP_CS35L41_I2C_2),
    1075510899        SND_PCI_QUIRK(0x1043, 0x1573, "ASUS GZ301V", ALC285_FIXUP_ASUS_HEADSET_MIC),
    1075610900        SND_PCI_QUIRK(0x1043, 0x1662, "ASUS GV301QH", ALC294_FIXUP_ASUS_DUAL_SPK),
     
    1078010924        SND_PCI_QUIRK(0x1043, 0x1c62, "ASUS GU603", ALC289_FIXUP_ASUS_GA401),
    1078110925        SND_PCI_QUIRK(0x1043, 0x1c92, "ASUS ROG Strix G15", ALC285_FIXUP_ASUS_G533Z_PINS),
     10926        SND_PCI_QUIRK(0x1043, 0x1caf, "ASUS G634JYR/JZR", ALC285_FIXUP_ASUS_SPI_REAR_SPEAKERS),
    1078210927        SND_PCI_QUIRK(0x1043, 0x1ccd, "ASUS X555UB", ALC256_FIXUP_ASUS_MIC),
    1078310928        SND_PCI_QUIRK(0x1043, 0x1d1f, "ASUS ROG Strix G17 2023 (G713PV)", ALC287_FIXUP_CS35L41_I2C_2),
    1078410929        SND_PCI_QUIRK(0x1043, 0x1d42, "ASUS Zephyrus G14 2022", ALC289_FIXUP_ASUS_GA401),
    1078510930        SND_PCI_QUIRK(0x1043, 0x1d4e, "ASUS TM420", ALC256_FIXUP_ASUS_HPE),
     10931        SND_PCI_QUIRK(0x1043, 0x1da2, "ASUS UP6502ZA/ZD", ALC245_FIXUP_CS35L41_SPI_2),
    1078610932        SND_PCI_QUIRK(0x1043, 0x1e02, "ASUS UX3402ZA", ALC245_FIXUP_CS35L41_SPI_2),
    1078710933        SND_PCI_QUIRK(0x1043, 0x16a3, "ASUS UX3402VA", ALC245_FIXUP_CS35L41_SPI_2),
     10934        SND_PCI_QUIRK(0x1043, 0x1f62, "ASUS UX7602ZM", ALC245_FIXUP_CS35L41_SPI_2),
    1078810935        SND_PCI_QUIRK(0x1043, 0x1e11, "ASUS Zephyrus G15", ALC289_FIXUP_ASUS_GA502),
    10789         SND_PCI_QUIRK(0x1043, 0x1e12, "ASUS UM3402", ALC287_FIXUP_CS35L41_I2C_2),
     10936        SND_PCI_QUIRK(0x1043, 0x1e12, "ASUS UM6702RA/RC", ALC287_FIXUP_CS35L41_I2C_2),
    1079010937        SND_PCI_QUIRK(0x1043, 0x1e51, "ASUS Zephyrus M15", ALC294_FIXUP_ASUS_GU502_PINS),
    1079110938        SND_PCI_QUIRK(0x1043, 0x1e5e, "ASUS ROG Strix G513", ALC294_FIXUP_ASUS_G513_PINS),
    1079210939        SND_PCI_QUIRK(0x1043, 0x1e8e, "ASUS Zephyrus G15", ALC289_FIXUP_ASUS_GA401),
     10940        SND_PCI_QUIRK(0x1043, 0x1ee2, "ASUS UM3402", ALC287_FIXUP_CS35L41_I2C_2),
    1079310941        SND_PCI_QUIRK(0x1043, 0x1c52, "ASUS Zephyrus G15 2022", ALC289_FIXUP_ASUS_GA401),
    1079410942        SND_PCI_QUIRK(0x1043, 0x1f11, "ASUS Zephyrus G14", ALC289_FIXUP_ASUS_GA401),
    1079510943        SND_PCI_QUIRK(0x1043, 0x1f12, "ASUS UM5302", ALC287_FIXUP_CS35L41_I2C_2),
     10944        SND_PCI_QUIRK(0x1043, 0x1f62, "ASUS UX7602ZM", ALC245_FIXUP_CS35L41_SPI_2),
    1079610945        SND_PCI_QUIRK(0x1043, 0x1f92, "ASUS ROG Flow X16", ALC289_FIXUP_ASUS_GA401),
    1079710946        SND_PCI_QUIRK(0x1043, 0x3030, "ASUS ZN270IE", ALC256_FIXUP_ASUS_AIO_GPIO2),
    1079810947        SND_PCI_QUIRK(0x1043, 0x3a20, "ASUS G614JZR", ALC245_FIXUP_CS35L41_SPI_2),
    1079910948        SND_PCI_QUIRK(0x1043, 0x3a30, "ASUS G814JVR/JIR", ALC245_FIXUP_CS35L41_SPI_2),
    10800         SND_PCI_QUIRK(0x1043, 0x3a40, "ASUS G814JZR", ALC245_FIXUP_CS35L41_SPI_2),
     10949        SND_PCI_QUIRK(0x1043, 0x3a40, "ASUS G814JZR", ALC285_FIXUP_ASUS_SPI_REAR_SPEAKERS),
    1080110950        SND_PCI_QUIRK(0x1043, 0x3a50, "ASUS G834JYR/JZR", ALC245_FIXUP_CS35L41_SPI_2),
    1080210951        SND_PCI_QUIRK(0x1043, 0x3a60, "ASUS G634JYR/JZR", ALC245_FIXUP_CS35L41_SPI_2),
     
    1082010969        SND_PCI_QUIRK(0x10ec, 0x10f2, "Intel Reference board", ALC700_FIXUP_INTEL_REFERENCE),
    1082110970        SND_PCI_QUIRK(0x10ec, 0x118c, "Medion EE4254 MD62100", ALC256_FIXUP_MEDION_HEADSET_NO_PRESENCE),
     10971        SND_PCI_QUIRK(0x10ec, 0x119e, "Positivo SU C1400", ALC269_FIXUP_ASPIRE_HEADSET_MIC),
     10972        SND_PCI_QUIRK(0x10ec, 0x11bc, "VAIO VJFE-IL", ALC269_FIXUP_LIMIT_INT_MIC_BOOST),
    1082210973        SND_PCI_QUIRK(0x10ec, 0x1230, "Intel Reference board", ALC295_FIXUP_CHROME_BOOK),
    1082310974        SND_PCI_QUIRK(0x10ec, 0x124c, "Intel Reference board", ALC295_FIXUP_CHROME_BOOK),
     
    1082510976        SND_PCI_QUIRK(0x10ec, 0x1254, "Intel Reference board", ALC295_FIXUP_CHROME_BOOK),
    1082610977        SND_PCI_QUIRK(0x10ec, 0x12cc, "Intel Reference board", ALC295_FIXUP_CHROME_BOOK),
    10827         SND_PCI_QUIRK(0x10f7, 0x8338, "Panasonic CF-SZ6", ALC269_FIXUP_HEADSET_MODE),
     10978        SND_PCI_QUIRK(0x10f7, 0x8338, "Panasonic CF-SZ6", ALC269_FIXUP_ASPIRE_HEADSET_MIC),
    1082810979        SND_PCI_QUIRK(0x144d, 0xc109, "Samsung Ativ book 9 (NP900X3G)", ALC269_FIXUP_INV_DMIC),
    1082910980        SND_PCI_QUIRK(0x144d, 0xc169, "Samsung Notebook 9 Pen (NP930SBE-K01US)", ALC298_FIXUP_SAMSUNG_AMP),
     
    1083210983        SND_PCI_QUIRK(0x144d, 0xc18a, "Samsung Galaxy Book Ion (NP930XCJ-K01US)", ALC298_FIXUP_SAMSUNG_AMP),
    1083310984        SND_PCI_QUIRK(0x144d, 0xc1a3, "Samsung Galaxy Book Pro (NP935XDB-KC1SE)", ALC298_FIXUP_SAMSUNG_AMP),
     10985        SND_PCI_QUIRK(0x144d, 0xc1a4, "Samsung Galaxy Book Pro 360 (NT935QBD)", ALC298_FIXUP_SAMSUNG_AMP),
    1083410986        SND_PCI_QUIRK(0x144d, 0xc1a6, "Samsung Galaxy Book Pro 360 (NP930QBD)", ALC298_FIXUP_SAMSUNG_AMP),
    1083510987        SND_PCI_QUIRK(0x144d, 0xc740, "Samsung Ativ book 8 (NP870Z5G)", ALC269_FIXUP_ATIV_BOOK_8),
     
    1091311065        SND_PCI_QUIRK(0x1558, 0xa650, "Clevo NP[567]0SN[CD]", ALC256_FIXUP_SYSTEM76_MIC_NO_PRESENCE),
    1091411066        SND_PCI_QUIRK(0x1558, 0xa671, "Clevo NP70SN[CDE]", ALC256_FIXUP_SYSTEM76_MIC_NO_PRESENCE),
     11067        SND_PCI_QUIRK(0x1558, 0xa763, "Clevo V54x_6x_TU", ALC256_FIXUP_SYSTEM76_MIC_NO_PRESENCE),
    1091511068        SND_PCI_QUIRK(0x1558, 0xb018, "Clevo NP50D[BE]", ALC293_FIXUP_SYSTEM76_MIC_NO_PRESENCE),
    1091611069        SND_PCI_QUIRK(0x1558, 0xb019, "Clevo NH77D[BE]Q", ALC293_FIXUP_SYSTEM76_MIC_NO_PRESENCE),
     
    1092011073        SND_PCI_QUIRK(0x1558, 0xc022, "Clevo NH77[DC][QW]", ALC293_FIXUP_SYSTEM76_MIC_NO_PRESENCE),
    1092111074        SND_PCI_QUIRK(0x17aa, 0x1036, "Lenovo P520", ALC233_FIXUP_LENOVO_MULTI_CODECS),
     11075        SND_PCI_QUIRK(0x17aa, 0x3882, "Lenovo Yoga Pro 7 14APH8", ALC287_FIXUP_YOGA9_14IAP7_BASS_SPK_PIN),
    1092211076        SND_PCI_QUIRK(0x17aa, 0x1048, "ThinkCentre Station", ALC623_FIXUP_LENOVO_THINKSTATION_P340),
    1092311077        SND_PCI_QUIRK(0x17aa, 0x20f2, "Thinkpad SL410/510", ALC269_FIXUP_SKU_IGNORE),
     
    1097711131        SND_PCI_QUIRK(0x17aa, 0x3178, "ThinkCentre Station", ALC283_FIXUP_HEADSET_MIC),
    1097811132        SND_PCI_QUIRK(0x17aa, 0x31af, "ThinkCentre Station", ALC623_FIXUP_LENOVO_THINKSTATION_P340),
     11133        SND_PCI_QUIRK(0x17aa, 0x334b, "Lenovo ThinkCentre M70 Gen5", ALC283_FIXUP_HEADSET_MIC),
    1097911134        SND_PCI_QUIRK(0x17aa, 0x3801, "Lenovo Yoga9 14IAP7", ALC287_FIXUP_YOGA9_14IAP7_BASS_SPK_PIN),
    1098011135        SND_PCI_QUIRK(0x17aa, 0x3802, "Lenovo Yoga DuetITL 2021", ALC287_FIXUP_YOGA7_14ITL_SPEAKERS),
     
    1098211137        SND_PCI_QUIRK(0x17aa, 0x3818, "Lenovo C940 / Yoga Duet 7", ALC298_FIXUP_LENOVO_C940_DUET7),
    1098311138        SND_PCI_QUIRK(0x17aa, 0x3819, "Lenovo 13s Gen2 ITL", ALC287_FIXUP_13S_GEN2_SPEAKERS),
    10984         SND_PCI_QUIRK(0x17aa, 0x3820, "Yoga Duet 7 13ITL6", ALC287_FIXUP_YOGA7_14ITL_SPEAKERS),
     11139        SND_PCI_QUIRK(0x17aa, 0x3820, "IdeaPad 330-17IKB 81DM", ALC269_FIXUP_ASPIRE_HEADSET_MIC),
    1098511140        SND_PCI_QUIRK(0x17aa, 0x3824, "Legion Y9000X 2020", ALC285_FIXUP_LEGION_Y9000X_SPEAKERS),
    1098611141        SND_PCI_QUIRK(0x17aa, 0x3827, "Ideapad S740", ALC285_FIXUP_IDEAPAD_S740_COEF),
     
    1099311148        SND_PCI_QUIRK(0x17aa, 0x3853, "Lenovo Yoga 7 15ITL5", ALC287_FIXUP_YOGA7_14ITL_SPEAKERS),
    1099411149        SND_PCI_QUIRK(0x17aa, 0x3855, "Legion 7 16ITHG6", ALC287_FIXUP_LEGION_16ITHG6),
     11150        SND_PCI_QUIRK(0x17aa, 0x3865, "Lenovo 13X", ALC287_FIXUP_CS35L41_I2C_2),
     11151        SND_PCI_QUIRK(0x17aa, 0x3866, "Lenovo 13X", ALC287_FIXUP_CS35L41_I2C_2),
    1099511152        SND_PCI_QUIRK(0x17aa, 0x3869, "Lenovo Yoga7 14IAL7", ALC287_FIXUP_YOGA9_14IAP7_BASS_SPK_PIN),
    1099611153        SND_PCI_QUIRK(0x17aa, 0x3902, "Lenovo E50-80", ALC269_FIXUP_DMIC_THINKPAD_ACPI),
     
    1102911186        SND_PCI_QUIRK(0x1c06, 0x2013, "Lemote A1802", ALC269_FIXUP_LEMOTE_A1802),
    1103011187        SND_PCI_QUIRK(0x1c06, 0x2015, "Lemote A190X", ALC269_FIXUP_LEMOTE_A190X),
     11188        SND_PCI_QUIRK(0x1c6c, 0x122a, "Positivo N14AP7", ALC269_FIXUP_LIMIT_INT_MIC_BOOST),
    1103111189        SND_PCI_QUIRK(0x1c6c, 0x1251, "Positivo N14KP6-TG", ALC288_FIXUP_DELL1_MIC_NO_PRESENCE),
    1103211190        SND_PCI_QUIRK(0x1d05, 0x1132, "TongFang PHxTxX1", ALC256_FIXUP_SET_COEF_DEFAULTS),
     
    1103911197        SND_PCI_QUIRK(0x1d05, 0x115c, "TongFang GMxTGxx", ALC269_FIXUP_NO_SHUTUP),
    1104011198        SND_PCI_QUIRK(0x1d05, 0x121b, "TongFang GMxAGxx", ALC269_FIXUP_NO_SHUTUP),
     11199        SND_PCI_QUIRK(0x1d05, 0x1387, "TongFang GMxIXxx", ALC2XX_FIXUP_HEADSET_MIC),
     11200        SND_PCI_QUIRK(0x1d17, 0x3288, "Haier Boyue G42", ALC269VC_FIXUP_ACER_VCOPPERBOX_PINS),
    1104111201        SND_PCI_QUIRK(0x1d72, 0x1602, "RedmiBook", ALC255_FIXUP_XIAOMI_HEADSET_MIC),
    1104211202        SND_PCI_QUIRK(0x1d72, 0x1701, "XiaomiNotebook Pro", ALC298_FIXUP_DELL1_MIC_NO_PRESENCE),
     
    1104411204        SND_PCI_QUIRK(0x1d72, 0x1945, "Redmi G", ALC256_FIXUP_ASUS_HEADSET_MIC),
    1104511205        SND_PCI_QUIRK(0x1d72, 0x1947, "RedmiBook Air", ALC255_FIXUP_XIAOMI_HEADSET_MIC),
     11206        SND_PCI_QUIRK(0x2782, 0x0214, "VAIO VJFE-CL", ALC269_FIXUP_LIMIT_INT_MIC_BOOST),
     11207        SND_PCI_QUIRK(0x2782, 0x0232, "CHUWI CoreBook XPro", ALC269VB_FIXUP_CHUWI_COREBOOK_XPRO),
     11208        SND_PCI_QUIRK(0x2782, 0x1707, "Vaio VJFE-ADL", ALC298_FIXUP_SPK_VOLUME),
    1104611209        SND_PCI_QUIRK(0x8086, 0x2074, "Intel NUC 8", ALC233_FIXUP_INTEL_NUC8_DMIC),
    1104711210        SND_PCI_QUIRK(0x8086, 0x2080, "Intel NUC 8 Rugged", ALC256_FIXUP_INTEL_NUC8_RUGGED),
     
    1104911212        SND_PCI_QUIRK(0x8086, 0x3038, "Intel NUC 13", ALC295_FIXUP_CHROME_BOOK),
    1105011213        SND_PCI_QUIRK(0xf111, 0x0001, "Framework Laptop", ALC295_FIXUP_FRAMEWORK_LAPTOP_MIC_NO_PRESENCE),
     11214        SND_PCI_QUIRK(0xf111, 0x0006, "Framework Laptop", ALC295_FIXUP_FRAMEWORK_LAPTOP_MIC_NO_PRESENCE),
     11215        SND_PCI_QUIRK(0xf111, 0x0009, "Framework Laptop", ALC295_FIXUP_FRAMEWORK_LAPTOP_MIC_NO_PRESENCE),
    1105111216
    1105211217#if 0
     
    1122911394        {.id = ALC285_FIXUP_HP_SPECTRE_X360, .name = "alc285-hp-spectre-x360"},
    1123011395        {.id = ALC285_FIXUP_HP_SPECTRE_X360_EB1, .name = "alc285-hp-spectre-x360-eb1"},
     11396        {.id = ALC285_FIXUP_HP_ENVY_X360, .name = "alc285-hp-envy-x360"},
    1123111397        {.id = ALC287_FIXUP_IDEAPAD_BASS_SPK_AMP, .name = "alc287-ideapad-bass-spk-amp"},
    1123211398        {.id = ALC287_FIXUP_YOGA9_14IAP7_BASS_SPK_PIN, .name = "alc287-yoga9-bass-spk-pin"},
     
    1162811794                {0x17, 0x90170110},
    1162911795                {0x21, 0x03211020}),
    11630         SND_HDA_PIN_QUIRK(0x10ec0295, 0x1028, "Dell", ALC269_FIXUP_DELL4_MIC_NO_PRESENCE,
    11631                 {0x14, 0x90170110},
    11632                 {0x21, 0x04211020}),
    11633         SND_HDA_PIN_QUIRK(0x10ec0295, 0x1028, "Dell", ALC269_FIXUP_DELL4_MIC_NO_PRESENCE,
    11634                 {0x14, 0x90170110},
    11635                 {0x21, 0x04211030}),
    11636         SND_HDA_PIN_QUIRK(0x10ec0295, 0x1028, "Dell", ALC269_FIXUP_DELL1_MIC_NO_PRESENCE,
    11637                 ALC295_STANDARD_PINS,
    11638                 {0x17, 0x21014020},
    11639                 {0x18, 0x21a19030}),
    11640         SND_HDA_PIN_QUIRK(0x10ec0295, 0x1028, "Dell", ALC269_FIXUP_DELL1_MIC_NO_PRESENCE,
    11641                 ALC295_STANDARD_PINS,
    11642                 {0x17, 0x21014040},
    11643                 {0x18, 0x21a19050}),
    11644         SND_HDA_PIN_QUIRK(0x10ec0295, 0x1028, "Dell", ALC269_FIXUP_DELL1_MIC_NO_PRESENCE,
    11645                 ALC295_STANDARD_PINS),
    1164611796        SND_HDA_PIN_QUIRK(0x10ec0298, 0x1028, "Dell", ALC298_FIXUP_DELL1_MIC_NO_PRESENCE,
    1164711797                ALC298_STANDARD_PINS,
     
    1168611836static const struct snd_hda_pin_quirk alc269_fallback_pin_fixup_tbl[] = {
    1168711837#ifdef NOT_USED
     11838        SND_HDA_PIN_QUIRK(0x10ec0256, 0x1025, "Acer", ALC2XX_FIXUP_HEADSET_MIC,
     11839                {0x19, 0x40000000}),
    1168811840        SND_HDA_PIN_QUIRK(0x10ec0289, 0x1028, "Dell", ALC269_FIXUP_DELL4_MIC_NO_PRESENCE,
     11841                {0x19, 0x40000000},
     11842                {0x1b, 0x40000000}),
     11843        SND_HDA_PIN_QUIRK(0x10ec0295, 0x1028, "Dell", ALC269_FIXUP_DELL4_MIC_NO_PRESENCE,
    1168911844                {0x19, 0x40000000},
    1169011845                {0x1b, 0x40000000}),
     
    1241212567        snd_hda_gen_hp_automute(codec, jack);
    1241312568        vref = spec->gen.hp_jack_present ? (PIN_HP | AC_PINCTL_VREF_100) : PIN_HP;
    12414         snd_hda_codec_write(codec, 0x1b, 0, AC_VERB_SET_PIN_WIDGET_CONTROL,
    12415                             vref);
     12569        snd_hda_set_pin_ctl(codec, 0x1b, vref);
    1241612570}
    1241712571
     
    1242212576        if (action == HDA_FIXUP_ACT_PRE_PROBE) {
    1242312577                spec->gen.hp_automute_hook = alc897_hp_automute_hook;
     12578                spec->no_shutup_pins = 1;
     12579        }
     12580        if (action == HDA_FIXUP_ACT_PROBE) {
     12581                snd_hda_set_pin_ctl_cache(codec, 0x1a, PIN_IN | AC_PINCTL_VREF_100);
    1242412582        }
    1242512583}
     
    1252212680        ALC897_FIXUP_HEADSET_MIC_PIN2,
    1252312681        ALC897_FIXUP_UNIS_H3C_X500S,
     12682        ALC897_FIXUP_HEADSET_MIC_PIN3,
    1252412683};
    1252512684
     
    1315813317                },
    1315913318        },
     13319        [ALC897_FIXUP_HEADSET_MIC_PIN3] = {
     13320                .type = HDA_FIXUP_PINS,
     13321                .v.pins = (const struct hda_pintbl[]) {
     13322                        { 0x19, 0x03a11050 }, /* use as headset mic */
     13323                        { }
     13324                },
     13325        },
    1316013326#endif
    1316113327};
     
    1316313329static const struct snd_pci_quirk alc662_fixup_tbl[] = {
    1316413330        SND_PCI_QUIRK(0x1019, 0x9087, "ECS", ALC662_FIXUP_ASUS_MODE2),
     13331        SND_PCI_QUIRK(0x1019, 0x9859, "JP-IK LEAP W502", ALC897_FIXUP_HEADSET_MIC_PIN3),
    1316513332        SND_PCI_QUIRK(0x1025, 0x022f, "Acer Aspire One", ALC662_FIXUP_INV_DMIC),
    1316613333        SND_PCI_QUIRK(0x1025, 0x0241, "Packard Bell DOTS", ALC662_FIXUP_INV_DMIC),
     
    1321713384        SND_PCI_QUIRK(0x17aa, 0x3321, "Lenovo ThinkCentre M70 Gen4", ALC897_FIXUP_HEADSET_MIC_PIN),
    1321813385        SND_PCI_QUIRK(0x17aa, 0x331b, "Lenovo ThinkCentre M90 Gen4", ALC897_FIXUP_HEADSET_MIC_PIN),
     13386        SND_PCI_QUIRK(0x17aa, 0x3364, "Lenovo ThinkCentre M90 Gen5", ALC897_FIXUP_HEADSET_MIC_PIN),
    1321913387        SND_PCI_QUIRK(0x17aa, 0x3742, "Lenovo TianYi510Pro-14IOB", ALC897_FIXUP_HEADSET_MIC_PIN2),
    1322013388        SND_PCI_QUIRK(0x17aa, 0x38af, "Lenovo Ideapad Y550P", ALC662_FIXUP_IDEAPAD),
  • GPL/branches/uniaud32-exp/alsa-kernel/synth/emux/soundfont.c

    r697 r760  
    704704        struct soundfont_sample_info sample_info;
    705705        struct snd_sf_sample *sp;
    706         long off;
    707706
    708707        /* patch must be opened */
     
    714713                return -EINVAL;
    715714
     715        if (count < (long)sizeof(sample_info)) {
     716                return -EINVAL;
     717        }
    716718        if (copy_from_user(&sample_info, data, sizeof(sample_info)))
    717719                return -EFAULT;
    718 
    719         off = sizeof(sample_info);
    720 
    721         if (sample_info.size != (count-off)/2)
     720        data += sizeof(sample_info);
     721        count -= sizeof(sample_info);
     722
     723        // SoundFont uses S16LE samples.
     724        if (sample_info.size * 2 != count)
    722725                return -EINVAL;
    723726
     
    747750                rc = sflist->callback.sample_new
    748751                        (sflist->callback.private_data, sp, sflist->memhdr,
    749                          data + off, count - off);
     752                         data, count);
    750753                if (rc < 0) {
    751754                        sf_sample_delete(sflist, sf, sp);
     
    960963        if (copy_from_user(&patch, data, sizeof(patch)))
    961964                return -EFAULT;
    962        
    963965        count -= sizeof(patch);
    964966        data += sizeof(patch);
     967
     968        if ((patch.len << (patch.mode & WAVE_16_BITS ? 1 : 0)) != count)
     969                return -EINVAL;
    965970
    966971        sf = newsf(sflist, SNDRV_SFNT_PAT_TYPE_GUS|SNDRV_SFNT_PAT_SHARED, NULL);
  • GPL/branches/uniaud32-exp/include/linux/pci.h

    r753 r760  
    794794#define for_each_pci_dev(d) while ((d = pci_get_device(PCI_ANY_ID, PCI_ANY_ID, d)) != NULL)
    795795
     796/**
     797 * PCI_DEVICE_DATA - macro used to describe a specific PCI device in very short form
     798 * @vend: the vendor name (without PCI_VENDOR_ID_ prefix)
     799 * @dev: the device name (without PCI_DEVICE_ID_<vend>_ prefix)
     800 * @data: the driver data to be filled
     801 *
     802 * This macro is used to create a struct pci_device_id that matches a
     803 * specific PCI device.  The subvendor, and subdevice fields will be set
     804 * to PCI_ANY_ID.
     805 */
     806#define PCI_DEVICE_DATA(vend, dev, data) \
     807        .vendor = PCI_VENDOR_ID_##vend, .device = PCI_DEVICE_ID_##vend##_##dev, \
     808        .subvendor = PCI_ANY_ID, .subdevice = PCI_ANY_ID, 0, 0, \
     809        .driver_data = (unsigned long)(data)
     810
    796811#endif /* LINUX_PCI_H */
  • GPL/branches/uniaud32-exp/include/linux/pci_ids.h

    r615 r760  
    29512951#define PCI_DEVICE_ID_INTEL_82443GX_2   0x71a2
    29522952#define PCI_DEVICE_ID_INTEL_82372FB_1   0x7601
     2953#define PCI_DEVICE_ID_INTEL_HDA_ARL     0x7728
    29532954#define PCI_DEVICE_ID_INTEL_SCH_LPC     0x8119
    29542955#define PCI_DEVICE_ID_INTEL_SCH_IDE     0x811a
Note: See TracChangeset for help on using the changeset viewer.