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

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

Pull sound fixes from Takashi Iwai:
"A few small remaining wrap-up for this merge window.

Most of patches are device-specific (HD-audio and USB-audio quirks,
FireWire, pcm316a, fsl, rsnd, Atmel, and TI fixes), while there is a
simple fix (actually two commits) for ASoC core"

* tag 'sound-fix-5.4-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound:
ALSA: usb-audio: Add DSD support for EVGA NU Audio
ALSA: hda - Add laptop imic fixup for ASUS M9V laptop
ASoC: ti: fix SND_SOC_DM365_VOICE_CODEC dependencies
ASoC: pcm3168a: The codec does not support S32_LE
ASoC: core: use list_del_init and move it back to soc_cleanup_component
ALSA: hda/realtek - PCI quirk for Medion E4254
ALSA: hda - Apply AMD controller workaround for Raven platform
ASoC: rsnd: do error check after rsnd_channel_normalization()
ASoC: atmel_ssc_dai: Remove wrong spinlock usage
ASoC: core: delete component->card_list in soc_remove_component only
ASoC: fsl_sai: Fix noise when using EDMA
ALSA: usb-audio: Add Hiby device family to quirks for native DSD support
ALSA: hda/realtek - Fix alienware headset mic
ALSA: dice: fix wrong packet parameter for Alesis iO26

+67 -24
+1 -1
sound/firewire/dice/dice-alesis.c
··· 15 15 16 16 static const unsigned int 17 17 alesis_io26_tx_pcm_chs[MAX_STREAMS][SND_DICE_RATE_MODE_COUNT] = { 18 - {10, 10, 8}, /* Tx0 = Analog + S/PDIF. */ 18 + {10, 10, 4}, /* Tx0 = Analog + S/PDIF. */ 19 19 {16, 8, 0}, /* Tx1 = ADAT1 + ADAT2. */ 20 20 }; 21 21
+1 -2
sound/pci/hda/hda_intel.c
··· 2485 2485 AZX_DCAPS_PM_RUNTIME }, 2486 2486 /* AMD Raven */ 2487 2487 { PCI_DEVICE(0x1022, 0x15e3), 2488 - .driver_data = AZX_DRIVER_GENERIC | AZX_DCAPS_PRESET_ATI_SB | 2489 - AZX_DCAPS_PM_RUNTIME }, 2488 + .driver_data = AZX_DRIVER_GENERIC | AZX_DCAPS_PRESET_AMD_SB }, 2490 2489 /* ATI HDMI */ 2491 2490 { PCI_DEVICE(0x1002, 0x0002), 2492 2491 .driver_data = AZX_DRIVER_ATIHDMI_NS | AZX_DCAPS_PRESET_ATI_HDMI_NS },
+1
sound/pci/hda/patch_analog.c
··· 357 357 358 358 static const struct snd_pci_quirk ad1986a_fixup_tbl[] = { 359 359 SND_PCI_QUIRK(0x103c, 0x30af, "HP B2800", AD1986A_FIXUP_LAPTOP_IMIC), 360 + SND_PCI_QUIRK(0x1043, 0x1153, "ASUS M9V", AD1986A_FIXUP_LAPTOP_IMIC), 360 361 SND_PCI_QUIRK(0x1043, 0x1443, "ASUS Z99He", AD1986A_FIXUP_EAPD), 361 362 SND_PCI_QUIRK(0x1043, 0x1447, "ASUS A8JN", AD1986A_FIXUP_EAPD), 362 363 SND_PCI_QUIRK_MASK(0x1043, 0xff00, 0x8100, "ASUS P5", AD1986A_FIXUP_3STACK),
+28
sound/pci/hda/patch_realtek.c
··· 5817 5817 ALC292_FIXUP_DELL_E7X, 5818 5818 ALC292_FIXUP_DISABLE_AAMIX, 5819 5819 ALC293_FIXUP_DISABLE_AAMIX_MULTIJACK, 5820 + ALC298_FIXUP_ALIENWARE_MIC_NO_PRESENCE, 5820 5821 ALC298_FIXUP_DELL1_MIC_NO_PRESENCE, 5821 5822 ALC298_FIXUP_DELL_AIO_MIC_NO_PRESENCE, 5822 5823 ALC275_FIXUP_DELL_XPS, ··· 5872 5871 ALC256_FIXUP_ASUS_MIC_NO_PRESENCE, 5873 5872 ALC299_FIXUP_PREDATOR_SPK, 5874 5873 ALC294_FIXUP_ASUS_INTSPK_HEADSET_MIC, 5874 + ALC256_FIXUP_MEDION_HEADSET_NO_PRESENCE, 5875 5875 }; 5876 5876 5877 5877 static const struct hda_fixup alc269_fixups[] = { ··· 6508 6506 .chained = true, 6509 6507 .chain_id = ALC292_FIXUP_DISABLE_AAMIX 6510 6508 }, 6509 + [ALC298_FIXUP_ALIENWARE_MIC_NO_PRESENCE] = { 6510 + .type = HDA_FIXUP_PINS, 6511 + .v.pins = (const struct hda_pintbl[]) { 6512 + { 0x18, 0x01a1913c }, /* headset mic w/o jack detect */ 6513 + { } 6514 + }, 6515 + .chained_before = true, 6516 + .chain_id = ALC269_FIXUP_HEADSET_MODE, 6517 + }, 6511 6518 [ALC298_FIXUP_DELL1_MIC_NO_PRESENCE] = { 6512 6519 .type = HDA_FIXUP_PINS, 6513 6520 .v.pins = (const struct hda_pintbl[]) { ··· 6938 6927 .chained = true, 6939 6928 .chain_id = ALC269_FIXUP_HEADSET_MODE_NO_HP_MIC 6940 6929 }, 6930 + [ALC256_FIXUP_MEDION_HEADSET_NO_PRESENCE] = { 6931 + .type = HDA_FIXUP_PINS, 6932 + .v.pins = (const struct hda_pintbl[]) { 6933 + { 0x19, 0x04a11040 }, 6934 + { 0x21, 0x04211020 }, 6935 + { } 6936 + }, 6937 + .chained = true, 6938 + .chain_id = ALC256_FIXUP_ASUS_HEADSET_MODE 6939 + }, 6941 6940 }; 6942 6941 6943 6942 static const struct snd_pci_quirk alc269_fixup_tbl[] = { ··· 7211 7190 SND_PCI_QUIRK(0x17aa, 0x9e54, "LENOVO NB", ALC269_FIXUP_LENOVO_EAPD), 7212 7191 SND_PCI_QUIRK(0x19e5, 0x3204, "Huawei MACH-WX9", ALC256_FIXUP_HUAWEI_MACH_WX9_PINS), 7213 7192 SND_PCI_QUIRK(0x1b7d, 0xa831, "Ordissimo EVE2 ", ALC269VB_FIXUP_ORDISSIMO_EVE2), /* Also known as Malata PC-B1303 */ 7193 + SND_PCI_QUIRK(0x10ec, 0x118c, "Medion EE4254 MD62100", ALC256_FIXUP_MEDION_HEADSET_NO_PRESENCE), 7214 7194 7215 7195 #if 0 7216 7196 /* Below is a quirk table taken from the old code. ··· 7380 7358 {.id = ALC295_FIXUP_CHROME_BOOK, .name = "alc-chrome-book"}, 7381 7359 {.id = ALC299_FIXUP_PREDATOR_SPK, .name = "predator-spk"}, 7382 7360 {.id = ALC298_FIXUP_HUAWEI_MBX_STEREO, .name = "huawei-mbx-stereo"}, 7361 + {.id = ALC256_FIXUP_MEDION_HEADSET_NO_PRESENCE, .name = "alc256-medion-headset"}, 7383 7362 {} 7384 7363 }; 7385 7364 #define ALC225_STANDARD_PINS \ ··· 7793 7770 {0x17, 0x90170110}, 7794 7771 {0x1a, 0x03011020}, 7795 7772 {0x21, 0x03211030}), 7773 + SND_HDA_PIN_QUIRK(0x10ec0298, 0x1028, "Dell", ALC298_FIXUP_ALIENWARE_MIC_NO_PRESENCE, 7774 + {0x12, 0xb7a60140}, 7775 + {0x17, 0x90170110}, 7776 + {0x1a, 0x03a11030}, 7777 + {0x21, 0x03211020}), 7796 7778 SND_HDA_PIN_QUIRK(0x10ec0299, 0x1028, "Dell", ALC269_FIXUP_DELL4_MIC_NO_PRESENCE, 7797 7779 ALC225_STANDARD_PINS, 7798 7780 {0x12, 0xb7a60130},
+2 -10
sound/soc/atmel/atmel_ssc_dai.c
··· 116 116 static struct atmel_ssc_info ssc_info[NUM_SSC_DEVICES] = { 117 117 { 118 118 .name = "ssc0", 119 - .lock = __SPIN_LOCK_UNLOCKED(ssc_info[0].lock), 120 119 .dir_mask = SSC_DIR_MASK_UNUSED, 121 120 .initialized = 0, 122 121 }, 123 122 { 124 123 .name = "ssc1", 125 - .lock = __SPIN_LOCK_UNLOCKED(ssc_info[1].lock), 126 124 .dir_mask = SSC_DIR_MASK_UNUSED, 127 125 .initialized = 0, 128 126 }, 129 127 { 130 128 .name = "ssc2", 131 - .lock = __SPIN_LOCK_UNLOCKED(ssc_info[2].lock), 132 129 .dir_mask = SSC_DIR_MASK_UNUSED, 133 130 .initialized = 0, 134 131 }, ··· 314 317 315 318 snd_soc_dai_set_dma_data(dai, substream, dma_params); 316 319 317 - spin_lock_irq(&ssc_p->lock); 318 - if (ssc_p->dir_mask & dir_mask) { 319 - spin_unlock_irq(&ssc_p->lock); 320 + if (ssc_p->dir_mask & dir_mask) 320 321 return -EBUSY; 321 - } 322 + 322 323 ssc_p->dir_mask |= dir_mask; 323 - spin_unlock_irq(&ssc_p->lock); 324 324 325 325 return 0; 326 326 } ··· 349 355 350 356 dir_mask = 1 << dir; 351 357 352 - spin_lock_irq(&ssc_p->lock); 353 358 ssc_p->dir_mask &= ~dir_mask; 354 359 if (!ssc_p->dir_mask) { 355 360 if (ssc_p->initialized) { ··· 362 369 ssc_p->cmr_div = ssc_p->tcmr_period = ssc_p->rcmr_period = 0; 363 370 ssc_p->forced_divider = 0; 364 371 } 365 - spin_unlock_irq(&ssc_p->lock); 366 372 367 373 /* Shutdown the SSC clock. */ 368 374 pr_debug("atmel_ssc_dai: Stopping clock\n");
-1
sound/soc/atmel/atmel_ssc_dai.h
··· 93 93 struct atmel_ssc_info { 94 94 char *name; 95 95 struct ssc_device *ssc; 96 - spinlock_t lock; /* lock for dir_mask */ 97 96 unsigned short dir_mask; /* 0=unused, 1=playback, 2=capture */ 98 97 unsigned short initialized; /* true if SSC has been initialized */ 99 98 unsigned short daifmt;
+1 -2
sound/soc/codecs/pcm3168a.c
··· 21 21 22 22 #define PCM3168A_FORMATS (SNDRV_PCM_FMTBIT_S16_LE | \ 23 23 SNDRV_PCM_FMTBIT_S24_3LE | \ 24 - SNDRV_PCM_FMTBIT_S24_LE | \ 25 - SNDRV_PCM_FMTBIT_S32_LE) 24 + SNDRV_PCM_FMTBIT_S24_LE) 26 25 27 26 #define PCM3168A_FMT_I2S 0x0 28 27 #define PCM3168A_FMT_LEFT_J 0x1
+15
sound/soc/fsl/fsl_sai.c
··· 628 628 FSL_SAI_CR3_TRCE_MASK, 629 629 FSL_SAI_CR3_TRCE); 630 630 631 + /* 632 + * EDMA controller needs period size to be a multiple of 633 + * tx/rx maxburst 634 + */ 635 + if (sai->soc_data->use_edma) 636 + snd_pcm_hw_constraint_step(substream->runtime, 0, 637 + SNDRV_PCM_HW_PARAM_PERIOD_SIZE, 638 + tx ? sai->dma_params_tx.maxburst : 639 + sai->dma_params_rx.maxburst); 640 + 631 641 ret = snd_pcm_hw_constraint_list(substream->runtime, 0, 632 642 SNDRV_PCM_HW_PARAM_RATE, &fsl_sai_rate_constraints); 633 643 ··· 1036 1026 1037 1027 static const struct fsl_sai_soc_data fsl_sai_vf610_data = { 1038 1028 .use_imx_pcm = false, 1029 + .use_edma = false, 1039 1030 .fifo_depth = 32, 1040 1031 .reg_offset = 0, 1041 1032 }; 1042 1033 1043 1034 static const struct fsl_sai_soc_data fsl_sai_imx6sx_data = { 1044 1035 .use_imx_pcm = true, 1036 + .use_edma = false, 1045 1037 .fifo_depth = 32, 1046 1038 .reg_offset = 0, 1047 1039 }; 1048 1040 1049 1041 static const struct fsl_sai_soc_data fsl_sai_imx7ulp_data = { 1050 1042 .use_imx_pcm = true, 1043 + .use_edma = false, 1051 1044 .fifo_depth = 16, 1052 1045 .reg_offset = 8, 1053 1046 }; 1054 1047 1055 1048 static const struct fsl_sai_soc_data fsl_sai_imx8mq_data = { 1056 1049 .use_imx_pcm = true, 1050 + .use_edma = false, 1057 1051 .fifo_depth = 128, 1058 1052 .reg_offset = 8, 1059 1053 }; 1060 1054 1061 1055 static const struct fsl_sai_soc_data fsl_sai_imx8qm_data = { 1062 1056 .use_imx_pcm = true, 1057 + .use_edma = true, 1063 1058 .fifo_depth = 64, 1064 1059 .reg_offset = 0, 1065 1060 };
+1
sound/soc/fsl/fsl_sai.h
··· 157 157 158 158 struct fsl_sai_soc_data { 159 159 bool use_imx_pcm; 160 + bool use_edma; 160 161 unsigned int fifo_depth; 161 162 unsigned int reg_offset; 162 163 };
+5 -5
sound/soc/sh/rcar/ssi.c
··· 286 286 if (rsnd_ssi_is_multi_slave(mod, io)) 287 287 return 0; 288 288 289 + if (rsnd_runtime_is_tdm_split(io)) 290 + chan = rsnd_io_converted_chan(io); 291 + 292 + chan = rsnd_channel_normalization(chan); 293 + 289 294 if (ssi->usrcnt > 0) { 290 295 if (ssi->rate != rate) { 291 296 dev_err(dev, "SSI parent/child should use same rate\n"); ··· 304 299 305 300 return 0; 306 301 } 307 - 308 - if (rsnd_runtime_is_tdm_split(io)) 309 - chan = rsnd_io_converted_chan(io); 310 - 311 - chan = rsnd_channel_normalization(chan); 312 302 313 303 main_rate = rsnd_ssi_clk_query(rdai, rate, chan, &idx); 314 304 if (!main_rate) {
+1 -1
sound/soc/soc-core.c
··· 978 978 /* For framework level robustness */ 979 979 snd_soc_component_set_jack(component, NULL, NULL); 980 980 981 - list_del(&component->card_list); 981 + list_del_init(&component->card_list); 982 982 snd_soc_dapm_free(snd_soc_component_get_dapm(component)); 983 983 soc_cleanup_component_debugfs(component); 984 984 component->card = NULL;
+9 -2
sound/soc/ti/Kconfig
··· 200 200 201 201 config SND_SOC_DM365_VOICE_CODEC 202 202 bool "Voice Codec - CQ93VC" 203 - select MFD_DAVINCI_VOICECODEC 204 - select SND_SOC_CQ0093VC 205 203 help 206 204 Say Y if you want to add support for SoC On-chip voice codec 207 205 endchoice 206 + 207 + config SND_SOC_DM365_VOICE_CODEC_MODULE 208 + def_tristate y 209 + depends on SND_SOC_DM365_VOICE_CODEC && SND_SOC 210 + select MFD_DAVINCI_VOICECODEC 211 + select SND_SOC_CQ0093VC 212 + help 213 + The is an internal symbol needed to ensure that the codec 214 + and MFD driver can be built as loadable modules if necessary. 208 215 209 216 endmenu 210 217
+2
sound/usb/quirks.c
··· 1658 1658 case 0x25ce: /* Mytek devices */ 1659 1659 case 0x278b: /* Rotel? */ 1660 1660 case 0x2ab6: /* T+A devices */ 1661 + case 0x3842: /* EVGA */ 1662 + case 0xc502: /* HiBy devices */ 1661 1663 if (fp->dsd_raw) 1662 1664 return SNDRV_PCM_FMTBIT_DSD_U32_BE; 1663 1665 break;