Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge tag 'sound-fix-5.19-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound

Pull sound fixes from Takashi Iwai:
"A collection of small fixes for 5.19 merge window. Nothing particular
stands out, as most changes are device-specific fixes and quirks"

* tag 'sound-fix-5.19-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound:
selftests: alsa: Handle pkg-config failure more gracefully
ALSA: usb-audio: Optimize TEAC clock quirk
ASoC: da7219: cancel AAD related work earlier for jack removal
ASoC: da7219: Fix pole orientation detection on certain headsets
ASoC: Intel: avs: Fix build error on arc, m68k and sparc
ALSA: hda/realtek - Fix microphone noise on ASUS TUF B550M-PLUS
ALSA: hda/via: Delete does not require return
ALSA: hda/realtek: Enable 4-speaker output for Dell XPS 15 9520 laptop
ASoC: Intel: common: fix typo for tplg naming
ALSA: usb-audio: Cancel pending work at closing a MIDI substream
ALSA: usb-audio: Add mixer mapping for Gigabyte B450/550 Mobos
ASoC: rt5640: Do not manipulate pin "Platform Clock" if the "Platform Clock" is not in the DAPM
ASoC: SOF: amd: Fixed Build error
ASoC: fsl_sai: Fix FSL_SAI_xDR/xFR definition
ASoC: soc-pcm: fix BE transition for TRIGGER_START

+89 -17
+11
sound/pci/hda/patch_realtek.c
··· 1981 1981 ALC1220_FIXUP_CLEVO_PB51ED_PINS, 1982 1982 ALC887_FIXUP_ASUS_AUDIO, 1983 1983 ALC887_FIXUP_ASUS_HMIC, 1984 + ALCS1200A_FIXUP_MIC_VREF, 1984 1985 }; 1985 1986 1986 1987 static void alc889_fixup_coef(struct hda_codec *codec, ··· 2527 2526 .chained = true, 2528 2527 .chain_id = ALC887_FIXUP_ASUS_AUDIO, 2529 2528 }, 2529 + [ALCS1200A_FIXUP_MIC_VREF] = { 2530 + .type = HDA_FIXUP_PINCTLS, 2531 + .v.pins = (const struct hda_pintbl[]) { 2532 + { 0x18, PIN_VREF50 }, /* rear mic */ 2533 + { 0x19, PIN_VREF50 }, /* front mic */ 2534 + {} 2535 + } 2536 + }, 2530 2537 }; 2531 2538 2532 2539 static const struct snd_pci_quirk alc882_fixup_tbl[] = { ··· 2572 2563 SND_PCI_QUIRK(0x1043, 0x835f, "Asus Eee 1601", ALC888_FIXUP_EEE1601), 2573 2564 SND_PCI_QUIRK(0x1043, 0x84bc, "ASUS ET2700", ALC887_FIXUP_ASUS_BASS), 2574 2565 SND_PCI_QUIRK(0x1043, 0x8691, "ASUS ROG Ranger VIII", ALC882_FIXUP_GPIO3), 2566 + SND_PCI_QUIRK(0x1043, 0x8797, "ASUS TUF B550M-PLUS", ALCS1200A_FIXUP_MIC_VREF), 2575 2567 SND_PCI_QUIRK(0x104d, 0x9043, "Sony Vaio VGC-LN51JGB", ALC882_FIXUP_NO_PRIMARY_HP), 2576 2568 SND_PCI_QUIRK(0x104d, 0x9044, "Sony VAIO AiO", ALC882_FIXUP_NO_PRIMARY_HP), 2577 2569 SND_PCI_QUIRK(0x104d, 0x9047, "Sony Vaio TT", ALC889_FIXUP_VAIO_TT), ··· 8915 8905 SND_PCI_QUIRK(0x1028, 0x0a62, "Dell Precision 5560", ALC289_FIXUP_DUAL_SPK), 8916 8906 SND_PCI_QUIRK(0x1028, 0x0a9d, "Dell Latitude 5430", ALC269_FIXUP_DELL4_MIC_NO_PRESENCE), 8917 8907 SND_PCI_QUIRK(0x1028, 0x0a9e, "Dell Latitude 5430", ALC269_FIXUP_DELL4_MIC_NO_PRESENCE), 8908 + SND_PCI_QUIRK(0x1028, 0x0b19, "Dell XPS 15 9520", ALC289_FIXUP_DUAL_SPK), 8918 8909 SND_PCI_QUIRK(0x1028, 0x164a, "Dell", ALC293_FIXUP_DELL1_MIC_NO_PRESENCE), 8919 8910 SND_PCI_QUIRK(0x1028, 0x164b, "Dell", ALC293_FIXUP_DELL1_MIC_NO_PRESENCE), 8920 8911 SND_PCI_QUIRK(0x103c, 0x1586, "HP", ALC269_FIXUP_HP_MUTE_LED_MIC2),
-2
sound/pci/hda/patch_via.c
··· 449 449 def_conf = def_conf & (~(AC_JACK_PORT_BOTH << 30)); 450 450 snd_hda_codec_set_pincfg(codec, nid, def_conf); 451 451 } 452 - 453 - return; 454 452 } 455 453 456 454 static int vt1708_jack_detect_get(struct snd_kcontrol *kcontrol,
+1
sound/soc/amd/acp/acp-pci.c
··· 16 16 #include <linux/pci.h> 17 17 #include <linux/platform_device.h> 18 18 #include <linux/pm_runtime.h> 19 + #include <linux/module.h> 19 20 20 21 #include "amd.h" 21 22 #include "../mach-config.h"
+15 -3
sound/soc/codecs/da7219-aad.c
··· 60 60 bool micbias_up = false; 61 61 int retries = 0; 62 62 63 + /* Disable ground switch */ 64 + snd_soc_component_update_bits(component, 0xFB, 0x01, 0x00); 65 + 63 66 /* Drive headphones/lineout */ 64 67 snd_soc_component_update_bits(component, DA7219_HP_L_CTRL, 65 68 DA7219_HP_L_AMP_OE_MASK, ··· 155 152 } else { 156 153 tonegen_freq_hptest = cpu_to_le16(DA7219_AAD_HPTEST_RAMP_FREQ_INT_OSC); 157 154 } 155 + 156 + /* Disable ground switch */ 157 + snd_soc_component_update_bits(component, 0xFB, 0x01, 0x00); 158 158 159 159 /* Ensure gain ramping at fastest rate */ 160 160 gain_ramp_ctrl = snd_soc_component_read(component, DA7219_GAIN_RAMP_CTRL); ··· 434 428 mask |= DA7219_AAD_REPORT_ALL_MASK; 435 429 da7219_aad->jack_inserted = false; 436 430 431 + /* Cancel any pending work */ 432 + cancel_work_sync(&da7219_aad->btn_det_work); 433 + cancel_work_sync(&da7219_aad->hptest_work); 434 + 437 435 /* Un-drive headphones/lineout */ 438 436 snd_soc_component_update_bits(component, DA7219_HP_R_CTRL, 439 437 DA7219_HP_R_AMP_OE_MASK, 0); ··· 454 444 snd_soc_dapm_disable_pin(dapm, "Mic Bias"); 455 445 snd_soc_dapm_sync(dapm); 456 446 457 - /* Cancel any pending work */ 458 - cancel_work_sync(&da7219_aad->btn_det_work); 459 - cancel_work_sync(&da7219_aad->hptest_work); 447 + /* Enable ground switch */ 448 + snd_soc_component_update_bits(component, 0xFB, 0x01, 0x01); 460 449 } 461 450 } 462 451 ··· 907 898 /* Disable button detection */ 908 899 snd_soc_component_update_bits(component, DA7219_ACCDET_CONFIG_1, 909 900 DA7219_BUTTON_CONFIG_MASK, 0); 901 + 902 + /* Enable ground switch */ 903 + snd_soc_component_update_bits(component, 0xFB, 0x01, 0x01); 910 904 911 905 INIT_WORK(&da7219_aad->btn_det_work, da7219_aad_btn_det_work); 912 906 INIT_WORK(&da7219_aad->hptest_work, da7219_aad_hptest_work);
+9 -2
sound/soc/codecs/rt5640.c
··· 2094 2094 void rt5640_enable_micbias1_for_ovcd(struct snd_soc_component *component) 2095 2095 { 2096 2096 struct snd_soc_dapm_context *dapm = snd_soc_component_get_dapm(component); 2097 + struct rt5640_priv *rt5640 = snd_soc_component_get_drvdata(component); 2097 2098 2098 2099 snd_soc_dapm_mutex_lock(dapm); 2099 2100 snd_soc_dapm_force_enable_pin_unlocked(dapm, "LDO2"); 2100 2101 snd_soc_dapm_force_enable_pin_unlocked(dapm, "MICBIAS1"); 2101 2102 /* OVCD is unreliable when used with RCCLK as sysclk-source */ 2102 - snd_soc_dapm_force_enable_pin_unlocked(dapm, "Platform Clock"); 2103 + if (rt5640->use_platform_clock) 2104 + snd_soc_dapm_force_enable_pin_unlocked(dapm, "Platform Clock"); 2103 2105 snd_soc_dapm_sync_unlocked(dapm); 2104 2106 snd_soc_dapm_mutex_unlock(dapm); 2105 2107 } ··· 2110 2108 void rt5640_disable_micbias1_for_ovcd(struct snd_soc_component *component) 2111 2109 { 2112 2110 struct snd_soc_dapm_context *dapm = snd_soc_component_get_dapm(component); 2111 + struct rt5640_priv *rt5640 = snd_soc_component_get_drvdata(component); 2113 2112 2114 2113 snd_soc_dapm_mutex_lock(dapm); 2115 - snd_soc_dapm_disable_pin_unlocked(dapm, "Platform Clock"); 2114 + if (rt5640->use_platform_clock) 2115 + snd_soc_dapm_disable_pin_unlocked(dapm, "Platform Clock"); 2116 2116 snd_soc_dapm_disable_pin_unlocked(dapm, "MICBIAS1"); 2117 2117 snd_soc_dapm_disable_pin_unlocked(dapm, "LDO2"); 2118 2118 snd_soc_dapm_sync_unlocked(dapm); ··· 2538 2534 } 2539 2535 rt5640->jd_gpio_irq_requested = true; 2540 2536 } 2537 + 2538 + if (jack_data && jack_data->use_platform_clock) 2539 + rt5640->use_platform_clock = jack_data->use_platform_clock; 2541 2540 2542 2541 ret = request_irq(rt5640->irq, rt5640_irq, 2543 2542 IRQF_TRIGGER_RISING | IRQF_TRIGGER_FALLING | IRQF_ONESHOT,
+2
sound/soc/codecs/rt5640.h
··· 2155 2155 bool jd_inverted; 2156 2156 unsigned int ovcd_th; 2157 2157 unsigned int ovcd_sf; 2158 + bool use_platform_clock; 2158 2159 }; 2159 2160 2160 2161 struct rt5640_set_jack_data { 2161 2162 int codec_irq_override; 2162 2163 struct gpio_desc *jd_gpio; 2164 + bool use_platform_clock; 2163 2165 }; 2164 2166 2165 2167 int rt5640_dmic_enable(struct snd_soc_component *component,
+2 -2
sound/soc/fsl/fsl_sai.h
··· 80 80 #define FSL_SAI_xCR3(tx, ofs) (tx ? FSL_SAI_TCR3(ofs) : FSL_SAI_RCR3(ofs)) 81 81 #define FSL_SAI_xCR4(tx, ofs) (tx ? FSL_SAI_TCR4(ofs) : FSL_SAI_RCR4(ofs)) 82 82 #define FSL_SAI_xCR5(tx, ofs) (tx ? FSL_SAI_TCR5(ofs) : FSL_SAI_RCR5(ofs)) 83 - #define FSL_SAI_xDR(tx, ofs) (tx ? FSL_SAI_TDR(ofs) : FSL_SAI_RDR(ofs)) 84 - #define FSL_SAI_xFR(tx, ofs) (tx ? FSL_SAI_TFR(ofs) : FSL_SAI_RFR(ofs)) 83 + #define FSL_SAI_xDR0(tx) (tx ? FSL_SAI_TDR0 : FSL_SAI_RDR0) 84 + #define FSL_SAI_xFR0(tx) (tx ? FSL_SAI_TFR0 : FSL_SAI_RFR0) 85 85 #define FSL_SAI_xMR(tx) (tx ? FSL_SAI_TMR : FSL_SAI_RMR) 86 86 87 87 /* SAI Transmit/Receive Control Register */
+2 -1
sound/soc/intel/avs/board_selection.c
··· 326 326 num_ssps = adev->hw_cfg.i2s_caps.ctrl_count; 327 327 if (fls(mach->mach_params.i2s_link_mask) > num_ssps) { 328 328 dev_err(adev->dev, "Platform supports %d SSPs but board %s requires SSP%ld\n", 329 - num_ssps, mach->drv_name, __fls(mach->mach_params.i2s_link_mask)); 329 + num_ssps, mach->drv_name, 330 + (unsigned long)__fls(mach->mach_params.i2s_link_mask)); 330 331 return -ENODEV; 331 332 } 332 333
+2
sound/soc/intel/boards/bytcr_rt5640.c
··· 1191 1191 { 1192 1192 struct snd_soc_card *card = runtime->card; 1193 1193 struct byt_rt5640_private *priv = snd_soc_card_get_drvdata(card); 1194 + struct rt5640_set_jack_data *jack_data = &priv->jack_data; 1194 1195 struct snd_soc_component *component = asoc_rtd_to_codec(runtime, 0)->component; 1195 1196 const struct snd_soc_dapm_route *custom_map = NULL; 1196 1197 int num_routes = 0; 1197 1198 int ret; 1198 1199 1199 1200 card->dapm.idle_bias_off = true; 1201 + jack_data->use_platform_clock = true; 1200 1202 1201 1203 /* Start with RC clk for jack-detect (we disable MCLK below) */ 1202 1204 if (byt_rt5640_quirk & BYT_RT5640_MCLK_EN)
+1 -1
sound/soc/intel/common/soc-acpi-intel-adl-match.c
··· 453 453 .drv_name = "adl_mx98360a_nau8825", 454 454 .machine_quirk = snd_soc_acpi_codec_list, 455 455 .quirk_data = &adl_max98360a_amp, 456 - .sof_tplg_filename = "sof-adl-mx98360a-nau8825.tplg", 456 + .sof_tplg_filename = "sof-adl-max98360a-nau8825.tplg", 457 457 }, 458 458 { 459 459 .id = "RTL5682",
-2
sound/soc/soc-pcm.c
··· 2128 2128 else 2129 2129 ret = soc_pcm_trigger(be_substream, 2130 2130 SNDRV_PCM_TRIGGER_START); 2131 - 2132 - ret = soc_pcm_trigger(be_substream, cmd); 2133 2131 if (ret) { 2134 2132 be->dpcm[stream].be_start--; 2135 2133 goto next;
+8 -4
sound/usb/clock.c
··· 573 573 } 574 574 575 575 /* FIXME - TEAC devices require the immediate interface setup */ 576 - if (rate != prev_rate && USB_ID_VENDOR(chip->usb_id) == 0x0644) { 577 - usb_set_interface(chip->dev, fmt->iface, fmt->altsetting); 578 - if (chip->quirk_flags & QUIRK_FLAG_IFACE_DELAY) 579 - msleep(50); 576 + if (USB_ID_VENDOR(chip->usb_id) == 0x0644) { 577 + bool cur_base_48k = (rate % 48000 == 0); 578 + bool prev_base_48k = (prev_rate % 48000 == 0); 579 + if (cur_base_48k != prev_base_48k) { 580 + usb_set_interface(chip->dev, fmt->iface, fmt->altsetting); 581 + if (chip->quirk_flags & QUIRK_FLAG_IFACE_DELAY) 582 + msleep(50); 583 + } 580 584 } 581 585 582 586 validation:
+3
sound/usb/midi.c
··· 1145 1145 1146 1146 static int snd_usbmidi_output_close(struct snd_rawmidi_substream *substream) 1147 1147 { 1148 + struct usbmidi_out_port *port = substream->runtime->private_data; 1149 + 1150 + cancel_work_sync(&port->ep->work); 1148 1151 return substream_open(substream, 0, 0); 1149 1152 } 1150 1153
+30
sound/usb/mixer_maps.c
··· 439 439 {} 440 440 }; 441 441 442 + /* Gigabyte B450/550 Mobo */ 443 + static const struct usbmix_name_map gigabyte_b450_map[] = { 444 + { 24, NULL }, /* OT, IEC958?, disabled */ 445 + { 21, "Speaker" }, /* OT */ 446 + { 29, "Speaker Playback" }, /* FU */ 447 + { 22, "Headphone" }, /* OT */ 448 + { 30, "Headphone Playback" }, /* FU */ 449 + { 11, "Line" }, /* IT */ 450 + { 27, "Line Capture" }, /* FU */ 451 + { 12, "Mic" }, /* IT */ 452 + { 28, "Mic Capture" }, /* FU */ 453 + { 9, "Front Mic" }, /* IT */ 454 + { 25, "Front Mic Capture" }, /* FU */ 455 + {} 456 + }; 457 + 458 + static const struct usbmix_connector_map gigabyte_b450_connector_map[] = { 459 + { 13, 21 }, /* Speaker */ 460 + { 14, 22 }, /* Headphone */ 461 + { 19, 11 }, /* Line */ 462 + { 20, 12 }, /* Mic */ 463 + { 17, 9 }, /* Front Mic */ 464 + {} 465 + }; 466 + 442 467 /* 443 468 * Control map entries 444 469 */ ··· 605 580 .id = USB_ID(0x0414, 0xa002), 606 581 .map = trx40_mobo_map, 607 582 .connector_map = trx40_mobo_connector_map, 583 + }, 584 + { /* Gigabyte B450/550 Mobo */ 585 + .id = USB_ID(0x0414, 0xa00d), 586 + .map = gigabyte_b450_map, 587 + .connector_map = gigabyte_b450_connector_map, 608 588 }, 609 589 { /* ASUS ROG Zenith II */ 610 590 .id = USB_ID(0x0b05, 0x1916),
+3
tools/testing/selftests/alsa/Makefile
··· 3 3 4 4 CFLAGS += $(shell pkg-config --cflags alsa) 5 5 LDLIBS += $(shell pkg-config --libs alsa) 6 + ifeq ($(LDLIBS),) 7 + LDLIBS += -lasound 8 + endif 6 9 7 10 TEST_GEN_PROGS := mixer-test 8 11