Pull sound fixes from Takashi Iwai: "Slightly bigger than I wished, but here we go, a collection of fixes for 6.5. The only change in the core side is the ease for repeated ASoC error messages, and the rest are all pretty device-specific small fixes (including regression fixes) for ASoC Intel and HD-audio / USB-audio quirks" * tag 'sound-6.5-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound: ALSA: hda/realtek - Remodified 3k pull low procedure ASoC: rt1308-sdw: fix random louder sound ALSA: hda/cs8409: Support new Dell Dolphin Variants ALSA: hda/realtek: Switch Dell Oasis models to use SPI ALSA: hda/realtek: Add quirks for HP G11 Laptops ASoC: meson: axg-tdm-formatter: fix channel slot allocation ASoC: SOF: ipc4-topology: Update the basecfg for copier earlier ASoC: SOF: intel: hda: Clean up link DMA for IPC3 during stop ASoC: Intel: sof-sdw-cs42142: fix for codec button mapping ASoC: Intel: sof-sdw: update jack detection quirk for LunarLake RVP ASoC: SOF: Fix incorrect use of sizeof in sof_ipc3_do_rx_work() ASoC: lower "no backend DAIs enabled for ... Port" log severity ASoC: rt5665: add missed regulator_bulk_disable ASoC: max98363: don't return on success reading revision ID ALSA: usb-audio: Add support for Mythware XA001AU capture and playback interfaces. ASoC: fsl: micfil: Use dual license micfil code
Unified · Split
| @@ -550,6 +550,10 @@ const struct snd_pci_quirk cs8409_fixup_tbl[] = { · 549 unmodified lines | |||
| 550 | SND_PCI_QUIRK(0x1028, 0x0C50, "Dolphin", CS8409_DOLPHIN), | 550 | SND_PCI_QUIRK(0x1028, 0x0C50, "Dolphin", CS8409_DOLPHIN), |
| 551 | SND_PCI_QUIRK(0x1028, 0x0C51, "Dolphin", CS8409_DOLPHIN), | 551 | SND_PCI_QUIRK(0x1028, 0x0C51, "Dolphin", CS8409_DOLPHIN), |
| 552 | SND_PCI_QUIRK(0x1028, 0x0C52, "Dolphin", CS8409_DOLPHIN), | 552 | SND_PCI_QUIRK(0x1028, 0x0C52, "Dolphin", CS8409_DOLPHIN), |
| 553 | SND_PCI_QUIRK(0x1028, 0x0C73, "Dolphin", CS8409_DOLPHIN), | ||
| 554 | SND_PCI_QUIRK(0x1028, 0x0C75, "Dolphin", CS8409_DOLPHIN), | ||
| 555 | SND_PCI_QUIRK(0x1028, 0x0C7D, "Dolphin", CS8409_DOLPHIN), | ||
| 556 | SND_PCI_QUIRK(0x1028, 0x0C7F, "Dolphin", CS8409_DOLPHIN), | ||
| 553 | {} /* terminator */ | 557 | {} /* terminator */ |
| 554 | }; | 558 | }; |
| 555 | 559 | ||
| @@ -9422,11 +9422,10 @@ static const struct snd_pci_quirk alc269_fixup_tbl[] = { · 9421 unmodified lines | |||
| 9422 | SND_PCI_QUIRK(0x1028, 0x0cbd, "Dell Oasis 13 CS MTL-U", ALC245_FIXUP_CS35L41_SPI_2), | 9422 | SND_PCI_QUIRK(0x1028, 0x0cbd, "Dell Oasis 13 CS MTL-U", ALC245_FIXUP_CS35L41_SPI_2), |
| 9423 | SND_PCI_QUIRK(0x1028, 0x0cbe, "Dell Oasis 13 2-IN-1 MTL-U", ALC245_FIXUP_CS35L41_SPI_2), | 9423 | SND_PCI_QUIRK(0x1028, 0x0cbe, "Dell Oasis 13 2-IN-1 MTL-U", ALC245_FIXUP_CS35L41_SPI_2), |
| 9424 | SND_PCI_QUIRK(0x1028, 0x0cbf, "Dell Oasis 13 Low Weight MTU-L", ALC245_FIXUP_CS35L41_SPI_2), | 9424 | SND_PCI_QUIRK(0x1028, 0x0cbf, "Dell Oasis 13 Low Weight MTU-L", ALC245_FIXUP_CS35L41_SPI_2), |
| 9425 | SND_PCI_QUIRK(0x1028, 0x0cc1, "Dell Oasis 14 MTL-H/U", ALC287_FIXUP_CS35L41_I2C_2), | 9425 | SND_PCI_QUIRK(0x1028, 0x0cc1, "Dell Oasis 14 MTL-H/U", ALC245_FIXUP_CS35L41_SPI_2), |
| 9426 | SND_PCI_QUIRK(0x1028, 0x0cc2, "Dell Oasis 14 2-in-1 MTL-H/U", ALC287_FIXUP_CS35L41_I2C_2), | 9426 | SND_PCI_QUIRK(0x1028, 0x0cc2, "Dell Oasis 14 2-in-1 MTL-H/U", ALC245_FIXUP_CS35L41_SPI_2), |
| 9427 | SND_PCI_QUIRK(0x1028, 0x0cc3, "Dell Oasis 14 Low Weight MTL-U", ALC287_FIXUP_CS35L41_I2C_2), | 9427 | SND_PCI_QUIRK(0x1028, 0x0cc3, "Dell Oasis 14 Low Weight MTL-U", ALC245_FIXUP_CS35L41_SPI_2), |
| 9428 | SND_PCI_QUIRK(0x1028, 0x0cc4, "Dell Oasis 16 MTL-H/U", ALC287_FIXUP_CS35L41_I2C_2), | 9428 | SND_PCI_QUIRK(0x1028, 0x0cc4, "Dell Oasis 16 MTL-H/U", ALC245_FIXUP_CS35L41_SPI_2), |
| 9429 | SND_PCI_QUIRK(0x1028, 0x0cc5, "Dell Oasis MLK 14 RPL-P", ALC287_FIXUP_CS35L41_I2C_2), | ||
| 9430 | SND_PCI_QUIRK(0x1028, 0x164a, "Dell", ALC293_FIXUP_DELL1_MIC_NO_PRESENCE), | 9429 | SND_PCI_QUIRK(0x1028, 0x164a, "Dell", ALC293_FIXUP_DELL1_MIC_NO_PRESENCE), |
| 9431 | SND_PCI_QUIRK(0x1028, 0x164b, "Dell", ALC293_FIXUP_DELL1_MIC_NO_PRESENCE), | 9430 | SND_PCI_QUIRK(0x1028, 0x164b, "Dell", ALC293_FIXUP_DELL1_MIC_NO_PRESENCE), |
| 9432 | SND_PCI_QUIRK(0x103c, 0x1586, "HP", ALC269_FIXUP_HP_MUTE_LED_MIC2), | 9431 | SND_PCI_QUIRK(0x103c, 0x1586, "HP", ALC269_FIXUP_HP_MUTE_LED_MIC2), |
| @@ -9617,7 +9616,13 @@ static const struct snd_pci_quirk alc269_fixup_tbl[] = { · 184 unmodified lines | |||
| 9617 | SND_PCI_QUIRK(0x103c, 0x8b96, "HP", ALC236_FIXUP_HP_MUTE_LED_MICMUTE_VREF), | 9616 | SND_PCI_QUIRK(0x103c, 0x8b96, "HP", ALC236_FIXUP_HP_MUTE_LED_MICMUTE_VREF), |
| 9618 | SND_PCI_QUIRK(0x103c, 0x8b97, "HP", ALC236_FIXUP_HP_MUTE_LED_MICMUTE_VREF), | 9617 | SND_PCI_QUIRK(0x103c, 0x8b97, "HP", ALC236_FIXUP_HP_MUTE_LED_MICMUTE_VREF), |
| 9619 | SND_PCI_QUIRK(0x103c, 0x8bf0, "HP", ALC236_FIXUP_HP_GPIO_LED), | 9618 | SND_PCI_QUIRK(0x103c, 0x8bf0, "HP", ALC236_FIXUP_HP_GPIO_LED), |
| 9620 | SND_PCI_QUIRK(0x103c, 0x8c26, "HP HP EliteBook 800G11", ALC245_FIXUP_CS35L41_SPI_2_HP_GPIO_LED), | 9619 | SND_PCI_QUIRK(0x103c, 0x8c46, "HP EliteBook 830 G11", ALC245_FIXUP_CS35L41_SPI_2_HP_GPIO_LED), |
| 9620 | SND_PCI_QUIRK(0x103c, 0x8c47, "HP EliteBook 840 G11", ALC245_FIXUP_CS35L41_SPI_2_HP_GPIO_LED), | ||
| 9621 | SND_PCI_QUIRK(0x103c, 0x8c48, "HP EliteBook 860 G11", ALC245_FIXUP_CS35L41_SPI_2_HP_GPIO_LED), | ||
| 9622 | SND_PCI_QUIRK(0x103c, 0x8c49, "HP Elite x360 830 2-in-1 G11", ALC245_FIXUP_CS35L41_SPI_2_HP_GPIO_LED), | ||
| 9623 | SND_PCI_QUIRK(0x103c, 0x8c70, "HP EliteBook 835 G11", ALC287_FIXUP_CS35L41_I2C_2_HP_GPIO_LED), | ||
| 9624 | SND_PCI_QUIRK(0x103c, 0x8c71, "HP EliteBook 845 G11", ALC287_FIXUP_CS35L41_I2C_2_HP_GPIO_LED), | ||
| 9625 | SND_PCI_QUIRK(0x103c, 0x8c72, "HP EliteBook 865 G11", ALC287_FIXUP_CS35L41_I2C_2_HP_GPIO_LED), | ||
| 9621 | SND_PCI_QUIRK(0x1043, 0x103e, "ASUS X540SA", ALC256_FIXUP_ASUS_MIC), | 9626 | SND_PCI_QUIRK(0x1043, 0x103e, "ASUS X540SA", ALC256_FIXUP_ASUS_MIC), |
| 9622 | SND_PCI_QUIRK(0x1043, 0x103f, "ASUS TX300", ALC282_FIXUP_ASUS_TX300), | 9627 | SND_PCI_QUIRK(0x1043, 0x103f, "ASUS TX300", ALC282_FIXUP_ASUS_TX300), |
| 9623 | SND_PCI_QUIRK(0x1043, 0x106d, "Asus K53BE", ALC269_FIXUP_LIMIT_INT_MIC_BOOST), | 9628 | SND_PCI_QUIRK(0x1043, 0x106d, "Asus K53BE", ALC269_FIXUP_LIMIT_INT_MIC_BOOST), |
| @@ -10638,6 +10643,7 @@ static int patch_alc269(struct hda_codec *codec) · 1014 unmodified lines | |||
| 10638 | spec = codec->spec; | 10643 | spec = codec->spec; |
| 10639 | spec->gen.shared_mic_vref_pin = 0x18; | 10644 | spec->gen.shared_mic_vref_pin = 0x18; |
| 10640 | codec->power_save_node = 0; | 10645 | codec->power_save_node = 0; |
| 10646 | spec->en_3kpull_low = true; | ||
| 10641 | 10647 | ||
| 10642 | #ifdef CONFIG_PM | 10648 | #ifdef CONFIG_PM |
| 10643 | codec->patch_ops.suspend = alc269_suspend; | 10649 | codec->patch_ops.suspend = alc269_suspend; |
| @@ -10720,14 +10726,16 @@ static int patch_alc269(struct hda_codec *codec) · 76 unmodified lines | |||
| 10720 | spec->shutup = alc256_shutup; | 10726 | spec->shutup = alc256_shutup; |
| 10721 | spec->init_hook = alc256_init; | 10727 | spec->init_hook = alc256_init; |
| 10722 | spec->gen.mixer_nid = 0; /* ALC256 does not have any loopback mixer path */ | 10728 | spec->gen.mixer_nid = 0; /* ALC256 does not have any loopback mixer path */ |
| 10723 | if (codec->bus->pci->vendor == PCI_VENDOR_ID_AMD) | 10729 | if (codec->core.vendor_id == 0x10ec0236 && |
| 10724 | spec->en_3kpull_low = true; | 10730 | codec->bus->pci->vendor != PCI_VENDOR_ID_AMD) |
| 10731 | spec->en_3kpull_low = false; | ||
| 10725 | break; | 10732 | break; |
| 10726 | case 0x10ec0257: | 10733 | case 0x10ec0257: |
| 10727 | spec->codec_variant = ALC269_TYPE_ALC257; | 10734 | spec->codec_variant = ALC269_TYPE_ALC257; |
| 10728 | spec->shutup = alc256_shutup; | 10735 | spec->shutup = alc256_shutup; |
| 10729 | spec->init_hook = alc256_init; | 10736 | spec->init_hook = alc256_init; |
| 10730 | spec->gen.mixer_nid = 0; | 10737 | spec->gen.mixer_nid = 0; |
| 10738 | spec->en_3kpull_low = false; | ||
| 10731 | break; | 10739 | break; |
| 10732 | case 0x10ec0215: | 10740 | case 0x10ec0215: |
| 10733 | case 0x10ec0245: | 10741 | case 0x10ec0245: |
| @@ -185,10 +185,10 @@ static int max98363_io_init(struct sdw_slave *slave) · 184 unmodified lines | |||
| 185 | pm_runtime_get_noresume(dev); | 185 | pm_runtime_get_noresume(dev); |
| 186 | 186 | ||
| 187 | ret = regmap_read(max98363->regmap, MAX98363_R21FF_REV_ID, ®); | 187 | ret = regmap_read(max98363->regmap, MAX98363_R21FF_REV_ID, ®); |
| 188 | if (!ret) { | 188 | if (!ret) |
| 189 | dev_info(dev, "Revision ID: %X\n", reg); | 189 | dev_info(dev, "Revision ID: %X\n", reg); |
| 190 | return ret; | 190 | else |
| 191 | } | 191 | goto out; |
| 192 | 192 | ||
| 193 | if (max98363->first_hw_init) { | 193 | if (max98363->first_hw_init) { |
| 194 | regcache_cache_bypass(max98363->regmap, false); | 194 | regcache_cache_bypass(max98363->regmap, false); |
| @@ -198,10 +198,11 @@ static int max98363_io_init(struct sdw_slave *slave) · 3 unmodified lines | |||
| 198 | max98363->first_hw_init = true; | 198 | max98363->first_hw_init = true; |
| 199 | max98363->hw_init = true; | 199 | max98363->hw_init = true; |
| 200 | 200 | ||
| 201 | out: | ||
| 201 | pm_runtime_mark_last_busy(dev); | 202 | pm_runtime_mark_last_busy(dev); |
| 202 | pm_runtime_put_autosuspend(dev); | 203 | pm_runtime_put_autosuspend(dev); |
| 203 | 204 | ||
| 204 | return 0; | 205 | return ret; |
| 205 | } | 206 | } |
| 206 | 207 | ||
| 207 | #define MAX98363_RATES SNDRV_PCM_RATE_8000_192000 | 208 | #define MAX98363_RATES SNDRV_PCM_RATE_8000_192000 |
| @@ -52,6 +52,7 @@ static bool rt1308_volatile_register(struct device *dev, unsigned int reg) · 51 unmodified lines | |||
| 52 | case 0x300a: | 52 | case 0x300a: |
| 53 | case 0xc000: | 53 | case 0xc000: |
| 54 | case 0xc710: | 54 | case 0xc710: |
| 55 | case 0xcf01: | ||
| 55 | case 0xc860 ... 0xc863: | 56 | case 0xc860 ... 0xc863: |
| 56 | case 0xc870 ... 0xc873: | 57 | case 0xc870 ... 0xc873: |
| 57 | return true; | 58 | return true; |
| @@ -213,7 +214,7 @@ static int rt1308_io_init(struct device *dev, struct sdw_slave *slave) · 155 unmodified lines | |||
| 213 | { | 214 | { |
| 214 | struct rt1308_sdw_priv *rt1308 = dev_get_drvdata(dev); | 215 | struct rt1308_sdw_priv *rt1308 = dev_get_drvdata(dev); |
| 215 | int ret = 0; | 216 | int ret = 0; |
| 216 | unsigned int tmp; | 217 | unsigned int tmp, hibernation_flag; |
| 217 | 218 | ||
| 218 | if (rt1308->hw_init) | 219 | if (rt1308->hw_init) |
| 219 | return 0; | 220 | return 0; |
| @@ -242,6 +243,10 @@ static int rt1308_io_init(struct device *dev, struct sdw_slave *slave) · 22 unmodified lines | |||
| 242 | 243 | ||
| 243 | pm_runtime_get_noresume(&slave->dev); | 244 | pm_runtime_get_noresume(&slave->dev); |
| 244 | 245 | ||
| 246 | regmap_read(rt1308->regmap, 0xcf01, &hibernation_flag); | ||
| 247 | if ((hibernation_flag != 0x00) && rt1308->first_hw_init) | ||
| 248 | goto _preset_ready_; | ||
| 249 | |||
| 245 | /* sw reset */ | 250 | /* sw reset */ |
| 246 | regmap_write(rt1308->regmap, RT1308_SDW_RESET, 0); | 251 | regmap_write(rt1308->regmap, RT1308_SDW_RESET, 0); |
| 247 | 252 | ||
| @@ -282,6 +287,12 @@ static int rt1308_io_init(struct device *dev, struct sdw_slave *slave) · 34 unmodified lines | |||
| 282 | regmap_write(rt1308->regmap, 0xc100, 0xd7); | 287 | regmap_write(rt1308->regmap, 0xc100, 0xd7); |
| 283 | regmap_write(rt1308->regmap, 0xc101, 0xd7); | 288 | regmap_write(rt1308->regmap, 0xc101, 0xd7); |
| 284 | 289 | ||
| 290 | /* apply BQ params */ | ||
| 291 | rt1308_apply_bq_params(rt1308); | ||
| 292 | |||
| 293 | regmap_write(rt1308->regmap, 0xcf01, 0x01); | ||
| 294 | |||
| 295 | _preset_ready_: | ||
| 285 | if (rt1308->first_hw_init) { | 296 | if (rt1308->first_hw_init) { |
| 286 | regcache_cache_bypass(rt1308->regmap, false); | 297 | regcache_cache_bypass(rt1308->regmap, false); |
| 287 | regcache_mark_dirty(rt1308->regmap); | 298 | regcache_mark_dirty(rt1308->regmap); |
| @@ -4472,6 +4472,8 @@ static void rt5665_remove(struct snd_soc_component *component) · 4471 unmodified lines | |||
| 4472 | struct rt5665_priv *rt5665 = snd_soc_component_get_drvdata(component); | 4472 | struct rt5665_priv *rt5665 = snd_soc_component_get_drvdata(component); |
| 4473 | 4473 | ||
| 4474 | regmap_write(rt5665->regmap, RT5665_RESET, 0); | 4474 | regmap_write(rt5665->regmap, RT5665_RESET, 0); |
| 4475 | |||
| 4476 | regulator_bulk_disable(ARRAY_SIZE(rt5665->supplies), rt5665->supplies); | ||
| 4475 | } | 4477 | } |
| 4476 | 4478 | ||
| 4477 | #ifdef CONFIG_PM | 4479 | #ifdef CONFIG_PM |
| @@ -1,4 +1,4 @@ | |||
| 1 | // SPDX-License-Identifier: GPL-2.0 | 1 | // SPDX-License-Identifier: GPL-2.0 OR BSD-3-Clause |
| 2 | // Copyright 2018 NXP | 2 | // Copyright 2018 NXP |
| 3 | 3 | ||
| 4 | #include <linux/bitfield.h> | 4 | #include <linux/bitfield.h> |
| @@ -1254,4 +1254,4 @@ module_platform_driver(fsl_micfil_driver); · 1249 unmodified lines | |||
| 1254 | 1254 | ||
| 1255 | MODULE_AUTHOR("Cosmin-Gabriel Samoila <cosmin.samoila@nxp.com>"); | 1255 | MODULE_AUTHOR("Cosmin-Gabriel Samoila <cosmin.samoila@nxp.com>"); |
| 1256 | MODULE_DESCRIPTION("NXP PDM Microphone Interface (MICFIL) driver"); | 1256 | MODULE_DESCRIPTION("NXP PDM Microphone Interface (MICFIL) driver"); |
| 1257 | MODULE_LICENSE("GPL v2"); | 1257 | MODULE_LICENSE("Dual BSD/GPL"); |
| @@ -1,4 +1,4 @@ | |||
| 1 | /* SPDX-License-Identifier: GPL-2.0 */ | 1 | /* SPDX-License-Identifier: GPL-2.0 OR BSD-3-Clause */ |
| 2 | /* | 2 | /* |
| 3 | * PDM Microphone Interface for the NXP i.MX SoC | 3 | * PDM Microphone Interface for the NXP i.MX SoC |
| 4 | * Copyright 2018 NXP | 4 | * Copyright 2018 NXP |
| @@ -476,7 +476,7 @@ static const struct dmi_system_id sof_sdw_quirk_table[] = { · 475 unmodified lines | |||
| 476 | DMI_MATCH(DMI_SYS_VENDOR, "Intel Corporation"), | 476 | DMI_MATCH(DMI_SYS_VENDOR, "Intel Corporation"), |
| 477 | DMI_MATCH(DMI_PRODUCT_NAME, "Lunar Lake Client Platform"), | 477 | DMI_MATCH(DMI_PRODUCT_NAME, "Lunar Lake Client Platform"), |
| 478 | }, | 478 | }, |
| 479 | .driver_data = (void *)(RT711_JD2_100K), | 479 | .driver_data = (void *)(RT711_JD2), |
| 480 | }, | 480 | }, |
| 481 | {} | 481 | {} |
| 482 | }; | 482 | }; |
| @@ -99,9 +99,9 @@ static int cs42l42_rtd_init(struct snd_soc_pcm_runtime *rtd) · 98 unmodified lines | |||
| 99 | jack = &ctx->sdw_headset; | 99 | jack = &ctx->sdw_headset; |
| 100 | 100 | ||
| 101 | snd_jack_set_key(jack->jack, SND_JACK_BTN_0, KEY_PLAYPAUSE); | 101 | snd_jack_set_key(jack->jack, SND_JACK_BTN_0, KEY_PLAYPAUSE); |
| 102 | snd_jack_set_key(jack->jack, SND_JACK_BTN_1, KEY_VOICECOMMAND); | 102 | snd_jack_set_key(jack->jack, SND_JACK_BTN_1, KEY_VOLUMEUP); |
| 103 | snd_jack_set_key(jack->jack, SND_JACK_BTN_2, KEY_VOLUMEUP); | 103 | snd_jack_set_key(jack->jack, SND_JACK_BTN_2, KEY_VOLUMEDOWN); |
| 104 | snd_jack_set_key(jack->jack, SND_JACK_BTN_3, KEY_VOLUMEDOWN); | 104 | snd_jack_set_key(jack->jack, SND_JACK_BTN_3, KEY_VOICECOMMAND); |
| 105 | 105 | ||
| 106 | ret = snd_soc_component_set_jack(component, jack, NULL); | 106 | ret = snd_soc_component_set_jack(component, jack, NULL); |
| 107 | 107 | ||
| @@ -30,27 +30,32 @@ int axg_tdm_formatter_set_channel_masks(struct regmap *map, · 29 unmodified lines | |||
| 30 | struct axg_tdm_stream *ts, | 30 | struct axg_tdm_stream *ts, |
| 31 | unsigned int offset) | 31 | unsigned int offset) |
| 32 | { | 32 | { |
| 33 | unsigned int val, ch = ts->channels; | 33 | unsigned int ch = ts->channels; |
| 34 | unsigned long mask; | 34 | u32 val[AXG_TDM_NUM_LANES]; |
| 35 | int i, j; | 35 | int i, j, k; |
| 36 | |||
| 37 | /* | ||
| 38 | * We need to mimick the slot distribution used by the HW to keep the | ||
| 39 | * channel placement consistent regardless of the number of channel | ||
| 40 | * in the stream. This is why the odd algorithm below is used. | ||
| 41 | */ | ||
| 42 | memset(val, 0, sizeof(*val) * AXG_TDM_NUM_LANES); | ||
| 36 | 43 | ||
| 37 | /* | 44 | /* |
| 38 | * Distribute the channels of the stream over the available slots | 45 | * Distribute the channels of the stream over the available slots |
| 39 | * of each TDM lane | 46 | * of each TDM lane. We need to go over the 32 slots ... |
| 40 | */ | 47 | */ |
| 41 | for (i = 0; i < AXG_TDM_NUM_LANES; i++) { | 48 | for (i = 0; (i < 32) && ch; i += 2) { |
| 42 | val = 0; | 49 | /* ... of all the lanes ... */ |
| 43 | mask = ts->mask[i]; | 50 | for (j = 0; j < AXG_TDM_NUM_LANES; j++) { |
| 44 | 51 | /* ... then distribute the channels in pairs */ | |
| 45 | for (j = find_first_bit(&mask, 32); | 52 | for (k = 0; k < 2; k++) { |
| 46 | (j < 32) && ch; | 53 | if ((BIT(i + k) & ts->mask[j]) && ch) { |
| 47 | j = find_next_bit(&mask, 32, j + 1)) { | 54 | val[j] |= BIT(i + k); |
| 48 | val |= 1 << j; | 55 | ch -= 1; |
| 49 | ch -= 1; | 56 | } |
| 57 | } | ||
| 50 | } | 58 | } |
| 51 | |||
| 52 | regmap_write(map, offset, val); | ||
| 53 | offset += regmap_get_reg_stride(map); | ||
| 54 | } | 59 | } |
| 55 | 60 | ||
| 56 | /* | 61 | /* |
| @@ -63,6 +68,11 @@ int axg_tdm_formatter_set_channel_masks(struct regmap *map, · 6 unmodified lines | |||
| 63 | return -EINVAL; | 68 | return -EINVAL; |
| 64 | } | 69 | } |
| 65 | 70 | ||
| 71 | for (i = 0; i < AXG_TDM_NUM_LANES; i++) { | ||
| 72 | regmap_write(map, offset, val[i]); | ||
| 73 | offset += regmap_get_reg_stride(map); | ||
| 74 | } | ||
| 75 | |||
| 66 | return 0; | 76 | return 0; |
| 67 | } | 77 | } |
| 68 | EXPORT_SYMBOL_GPL(axg_tdm_formatter_set_channel_masks); | 78 | EXPORT_SYMBOL_GPL(axg_tdm_formatter_set_channel_masks); |
| @@ -38,6 +38,7 @@ static inline int _soc_pcm_ret(struct snd_soc_pcm_runtime *rtd, · 37 unmodified lines | |||
| 38 | switch (ret) { | 38 | switch (ret) { |
| 39 | case -EPROBE_DEFER: | 39 | case -EPROBE_DEFER: |
| 40 | case -ENOTSUPP: | 40 | case -ENOTSUPP: |
| 41 | case -EINVAL: | ||
| 41 | break; | 42 | break; |
| 42 | default: | 43 | default: |
| 43 | dev_err(rtd->dev, | 44 | dev_err(rtd->dev, |
| @@ -2466,8 +2467,11 @@ static int dpcm_fe_dai_prepare(struct snd_pcm_substream *substream) · 2422 unmodified lines | |||
| 2466 | 2467 | ||
| 2467 | /* there is no point preparing this FE if there are no BEs */ | 2468 | /* there is no point preparing this FE if there are no BEs */ |
| 2468 | if (list_empty(&fe->dpcm[stream].be_clients)) { | 2469 | if (list_empty(&fe->dpcm[stream].be_clients)) { |
| 2469 | dev_err(fe->dev, "ASoC: no backend DAIs enabled for %s\n", | 2470 | /* dev_err_once() for visibility, dev_dbg() for debugging UCM profiles */ |
| 2470 | fe->dai_link->name); | 2471 | dev_err_once(fe->dev, "ASoC: no backend DAIs enabled for %s, possibly missing ALSA mixer-based routing or UCM profile\n", |
| 2472 | fe->dai_link->name); | ||
| 2473 | dev_dbg(fe->dev, "ASoC: no backend DAIs enabled for %s\n", | ||
| 2474 | fe->dai_link->name); | ||
| 2471 | ret = -EINVAL; | 2475 | ret = -EINVAL; |
| 2472 | goto out; | 2476 | goto out; |
| 2473 | } | 2477 | } |
| @@ -372,6 +372,7 @@ static const struct hda_dai_widget_dma_ops hda_ipc4_chain_dma_ops = { · 371 unmodified lines | |||
| 372 | static int hda_ipc3_post_trigger(struct snd_sof_dev *sdev, struct snd_soc_dai *cpu_dai, | 372 | static int hda_ipc3_post_trigger(struct snd_sof_dev *sdev, struct snd_soc_dai *cpu_dai, |
| 373 | struct snd_pcm_substream *substream, int cmd) | 373 | struct snd_pcm_substream *substream, int cmd) |
| 374 | { | 374 | { |
| 375 | struct hdac_ext_stream *hext_stream = hda_get_hext_stream(sdev, cpu_dai, substream); | ||
| 375 | struct snd_soc_dapm_widget *w = snd_soc_dai_get_widget(cpu_dai, substream->stream); | 376 | struct snd_soc_dapm_widget *w = snd_soc_dai_get_widget(cpu_dai, substream->stream); |
| 376 | 377 | ||
| 377 | switch (cmd) { | 378 | switch (cmd) { |
| @@ -379,9 +380,17 @@ static int hda_ipc3_post_trigger(struct snd_sof_dev *sdev, struct snd_soc_dai *c · 1 unmodified line | |||
| 379 | case SNDRV_PCM_TRIGGER_STOP: | 380 | case SNDRV_PCM_TRIGGER_STOP: |
| 380 | { | 381 | { |
| 381 | struct snd_sof_dai_config_data data = { 0 }; | 382 | struct snd_sof_dai_config_data data = { 0 }; |
| 383 | int ret; | ||
| 382 | 384 | ||
| 383 | data.dai_data = DMA_CHAN_INVALID; | 385 | data.dai_data = DMA_CHAN_INVALID; |
| 384 | return hda_dai_config(w, SOF_DAI_CONFIG_FLAGS_HW_FREE, &data); | 386 | ret = hda_dai_config(w, SOF_DAI_CONFIG_FLAGS_HW_FREE, &data); |
| 387 | if (ret < 0) | ||
| 388 | return ret; | ||
| 389 | |||
| 390 | if (cmd == SNDRV_PCM_TRIGGER_STOP) | ||
| 391 | return hda_link_dma_cleanup(substream, hext_stream, cpu_dai); | ||
| 392 | |||
| 393 | break; | ||
| 385 | } | 394 | } |
| 386 | case SNDRV_PCM_TRIGGER_PAUSE_PUSH: | 395 | case SNDRV_PCM_TRIGGER_PAUSE_PUSH: |
| 387 | return hda_dai_config(w, SOF_DAI_CONFIG_FLAGS_PAUSE, NULL); | 396 | return hda_dai_config(w, SOF_DAI_CONFIG_FLAGS_PAUSE, NULL); |
| @@ -107,9 +107,8 @@ hda_dai_get_ops(struct snd_pcm_substream *substream, struct snd_soc_dai *cpu_dai · 106 unmodified lines | |||
| 107 | return sdai->platform_private; | 107 | return sdai->platform_private; |
| 108 | } | 108 | } |
| 109 | 109 | ||
| 110 | static int hda_link_dma_cleanup(struct snd_pcm_substream *substream, | 110 | int hda_link_dma_cleanup(struct snd_pcm_substream *substream, struct hdac_ext_stream *hext_stream, |
| 111 | struct hdac_ext_stream *hext_stream, | 111 | struct snd_soc_dai *cpu_dai) |
| 112 | struct snd_soc_dai *cpu_dai) | ||
| 113 | { | 112 | { |
| 114 | const struct hda_dai_widget_dma_ops *ops = hda_dai_get_ops(substream, cpu_dai); | 113 | const struct hda_dai_widget_dma_ops *ops = hda_dai_get_ops(substream, cpu_dai); |
| 115 | struct sof_intel_hda_stream *hda_stream; | 114 | struct sof_intel_hda_stream *hda_stream; |
| @@ -963,5 +963,7 @@ const struct hda_dai_widget_dma_ops * · 962 unmodified lines | |||
| 963 | hda_select_dai_widget_ops(struct snd_sof_dev *sdev, struct snd_sof_widget *swidget); | 963 | hda_select_dai_widget_ops(struct snd_sof_dev *sdev, struct snd_sof_widget *swidget); |
| 964 | int hda_dai_config(struct snd_soc_dapm_widget *w, unsigned int flags, | 964 | int hda_dai_config(struct snd_soc_dapm_widget *w, unsigned int flags, |
| 965 | struct snd_sof_dai_config_data *data); | 965 | struct snd_sof_dai_config_data *data); |
| 966 | int hda_link_dma_cleanup(struct snd_pcm_substream *substream, struct hdac_ext_stream *hext_stream, | ||
| 967 | struct snd_soc_dai *cpu_dai); | ||
| 966 | 968 | ||
| 967 | #endif | 969 | #endif |
| @@ -1001,7 +1001,7 @@ void sof_ipc3_do_rx_work(struct snd_sof_dev *sdev, struct sof_ipc_cmd_hdr *hdr, · 1000 unmodified lines | |||
| 1001 | 1001 | ||
| 1002 | ipc3_log_header(sdev->dev, "ipc rx", hdr->cmd); | 1002 | ipc3_log_header(sdev->dev, "ipc rx", hdr->cmd); |
| 1003 | 1003 | ||
| 1004 | if (hdr->size < sizeof(hdr) || hdr->size > SOF_IPC_MSG_MAX_SIZE) { | 1004 | if (hdr->size < sizeof(*hdr) || hdr->size > SOF_IPC_MSG_MAX_SIZE) { |
| 1005 | dev_err(sdev->dev, "The received message size is invalid: %u\n", | 1005 | dev_err(sdev->dev, "The received message size is invalid: %u\n", |
| 1006 | hdr->size); | 1006 | hdr->size); |
| 1007 | return; | 1007 | return; |
| @@ -1731,6 +1731,9 @@ sof_ipc4_prepare_copier_module(struct snd_sof_widget *swidget, · 1730 unmodified lines | |||
| 1731 | 1731 | ||
| 1732 | *ipc_config_size = ipc_size; | 1732 | *ipc_config_size = ipc_size; |
| 1733 | 1733 | ||
| 1734 | /* update pipeline memory usage */ | ||
| 1735 | sof_ipc4_update_resource_usage(sdev, swidget, &copier_data->base_config); | ||
| 1736 | |||
| 1734 | /* copy IPC data */ | 1737 | /* copy IPC data */ |
| 1735 | memcpy(*ipc_config_data, (void *)copier_data, sizeof(*copier_data)); | 1738 | memcpy(*ipc_config_data, (void *)copier_data, sizeof(*copier_data)); |
| 1736 | if (gtw_cfg_config_length) | 1739 | if (gtw_cfg_config_length) |
| @@ -1743,9 +1746,6 @@ sof_ipc4_prepare_copier_module(struct snd_sof_widget *swidget, · 6 unmodified lines | |||
| 1743 | gtw_cfg_config_length, | 1746 | gtw_cfg_config_length, |
| 1744 | &ipc4_copier->dma_config_tlv, dma_config_tlv_size); | 1747 | &ipc4_copier->dma_config_tlv, dma_config_tlv_size); |
| 1745 | 1748 | ||
| 1746 | /* update pipeline memory usage */ | ||
| 1747 | sof_ipc4_update_resource_usage(sdev, swidget, &copier_data->base_config); | ||
| 1748 | |||
| 1749 | return 0; | 1749 | return 0; |
| 1750 | } | 1750 | } |
| 1751 | 1751 | ||
| @@ -4507,6 +4507,35 @@ YAMAHA_DEVICE(0x7010, "UB99"), · 4506 unmodified lines | |||
| 4507 | } | 4507 | } |
| 4508 | } | 4508 | } |
| 4509 | }, | 4509 | }, |
| 4510 | { | ||
| 4511 | /* Advanced modes of the Mythware XA001AU. | ||
| 4512 | * For the standard mode, Mythware XA001AU has ID ffad:a001 | ||
| 4513 | */ | ||
| 4514 | USB_DEVICE_VENDOR_SPEC(0xffad, 0xa001), | ||
| 4515 | .driver_info = (unsigned long) &(const struct snd_usb_audio_quirk) { | ||
| 4516 | .vendor_name = "Mythware", | ||
| 4517 | .product_name = "XA001AU", | ||
| 4518 | .ifnum = QUIRK_ANY_INTERFACE, | ||
| 4519 | .type = QUIRK_COMPOSITE, | ||
| 4520 | .data = (const struct snd_usb_audio_quirk[]) { | ||
| 4521 | { | ||
| 4522 | .ifnum = 0, | ||
| 4523 | .type = QUIRK_IGNORE_INTERFACE, | ||
| 4524 | }, | ||
| 4525 | { | ||
| 4526 | .ifnum = 1, | ||
| 4527 | .type = QUIRK_AUDIO_STANDARD_INTERFACE, | ||
| 4528 | }, | ||
| 4529 | { | ||
| 4530 | .ifnum = 2, | ||
| 4531 | .type = QUIRK_AUDIO_STANDARD_INTERFACE, | ||
| 4532 | }, | ||
| 4533 | { | ||
| 4534 | .ifnum = -1 | ||
| 4535 | } | ||
| 4536 | } | ||
| 4537 | } | ||
| 4538 | }, | ||
| 4510 | 4539 | ||
| 4511 | #undef USB_DEVICE_VENDOR_SPEC | 4540 | #undef USB_DEVICE_VENDOR_SPEC |
| 4512 | #undef USB_AUDIO_DEVICE | 4541 | #undef USB_AUDIO_DEVICE |