sound fixes for 7.0-rc3

Again a collection of device-specific fixes.  Most of changes are
 fairly small device-specific quirks of fixes for HD- and USB-audio,
 ASoC Intel, AMD, fsl, Cirrus and co.  The only large LOC is for
 plumbing ASoC ACP driver to add the Cirrus Logic codec support, so
 this one is also just adding some tables.
 -----BEGIN PGP SIGNATURE-----
 
 iQJCBAABCAAsFiEEIXTw5fNLNI7mMiVaLtJE4w1nLE8FAmmqllkOHHRpd2FpQHN1
 c2UuZGUACgkQLtJE4w1nLE+9Xg/8DTw0q54yrvKUulV/czdgjs3GevM0hn3D9FQs
 znHo8uYLGBeOFO2M+gTkASQM8j/HObhevcSPmhOqiLOXctmmqAm5nGkeL2mCUoW0
 mBkIu0YDeoQq++A0l+prdJ9nweEyjNyyizi0wxqw+6Igj6ykm7V2TLS++I3YXxyP
 Om5+E4Rq0xLI4ywbc2MPVcTLGJU3rW9Ygg4bLTxz5dQb36v3+V4RtuyyIu+cdD52
 m1tAw6NasN5OSB5fcCnP427zfUZ9kvv+d3Fh23jagXKDUarXUDJxS5i27/pocCyt
 lEeU3ukSaQ73FajyfdHpXbUYBUIN7vS91qITX2orqPAelhTDi1Iq2mt2B4dfM+U4
 FguphGFz1wnqKvfCaXeA11EUGOeLUIbgxBLyphbDquVPSr4T19lscTSq0G+xwHoG
 s1CxkYqh4uvgavo5pSiMUADfXIZC2Fla8aiEtZIfqXfOw4oWERMPg0l7xMhGsnHP
 FpqXMGA/3u/ow6i/LLWCA5U8Xp946/OZIP6pzLyUbla9Aha4q9Uf7MzFeYdG73BX
 z8XCdG72oaiEnLHeYIxzYj1P8Ms6C7LhEPhjCMcoPyEwBDfdTI4olgRNF/6gKt+V
 kEd2sUZQCsSzaa8NcsMKGDEzXbzJfD0JYLG8/aF5coy9u+FFX8tuJsYuvaG2grcz
 W0r1kpw=
 =NRtj
 -----END PGP SIGNATURE-----

Merge tag 'sound-7.0-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound

Pull sound fixes from Takashi Iwai:
 "Again a collection of device-specific fixes. Most of changes are
  fairly small device-specific quirks of fixes for HD- and USB-audio,
  ASoC Intel, AMD, fsl, Cirrus and co.

  The only large LOC is for plumbing ASoC ACP driver to add the Cirrus
  Logic codec support, so this one is also just adding some tables"

* tag 'sound-7.0-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound: (21 commits)
  ALSA: us122l: drop redundant interface references
  ASoC: amd: yc: Add DMI quirk for ASUS EXPERTBOOK PM1503CDA
  ASoC: dt-bindings: renesas,rz-ssi: Document RZ/G3L SoC
  ASoC: SDCA: Add allocation failure check for Entity name
  ALSA: hda/senary: Ensure EAPD is enabled during init
  ALSA: hda/senary: Use codec->core.afg for GPIO access
  ALSA: doc: usb-audio: Add doc for QUIRK_FLAG_SKIP_IFACE_SETUP
  ASoC: dt-bindings: tegra: Add compatible for Tegra238 sound card
  ALSA: hda/hdmi: Add Tegra238 HDA codec device ID
  ASoC: cs35l56: Suppress pointless warning about number of GPIO pulls
  ASoC: amd: acp: Add ACP6.3 match entries for Cirrus Logic parts
  ASoC: Intel: sof_sdw: Add quirk for Alienware Area 51 (2025) 0CCD SKU
  ASoC: rt1321: fix DMIC ch2/3 mask issue
  ASoC: cs35l56: Only patch ASP registers if the DAI is part of a DAIlink
  ASoC: fsl_easrc: Fix event generation in fsl_easrc_iec958_set_reg()
  ASoC: fsl_easrc: Fix event generation in fsl_easrc_iec958_put_bits()
  ALSA: firewire: dice: Fix printf warning with W=1
  ALSA: hda/tas2781: A workaround solution to lower-vol issue among lower calibrated-impedance micro-speaker on TAS2781
  ALSA: hda/realtek: Add quirk for HP Pavilion 15-eh1xxx to enable mute LED
  ALSA: usb-audio: Add iface reset and delay quirk for AB13X USB Audio
  ...
This commit is contained in:
Linus Torvalds 2026-03-06 10:06:04 -08:00
commit d249037ac4
22 changed files with 599 additions and 39 deletions

View file

@ -23,6 +23,7 @@ properties:
enum:
- nvidia,tegra210-audio-graph-card
- nvidia,tegra186-audio-graph-card
- nvidia,tegra238-audio-graph-card
- nvidia,tegra264-audio-graph-card
clocks:

View file

@ -20,6 +20,7 @@ properties:
- renesas,r9a07g044-ssi # RZ/G2{L,LC}
- renesas,r9a07g054-ssi # RZ/V2L
- renesas,r9a08g045-ssi # RZ/G3S
- renesas,r9a08g046-ssi # RZ/G3L
- const: renesas,rz-ssi
reg:

View file

@ -2372,6 +2372,10 @@ quirk_flags
audible volume
* bit 25: ``mixer_capture_min_mute``
Similar to bit 24 but for capture streams
* bit 26: ``skip_iface_setup``
Skip the probe-time interface setup (usb_set_interface,
init_pitch, init_sample_rate); redundant with
snd_usb_endpoint_prepare() at stream-open time
This module supports multiple devices, autoprobe and hotplugging.

View file

@ -406,6 +406,7 @@ extern const char * const cs35l56_cal_set_status_text[3];
extern const char * const cs35l56_tx_input_texts[CS35L56_NUM_INPUT_SRC];
extern const unsigned int cs35l56_tx_input_values[CS35L56_NUM_INPUT_SRC];
int cs35l56_set_asp_patch(struct cs35l56_base *cs35l56_base);
int cs35l56_set_patch(struct cs35l56_base *cs35l56_base);
int cs35l56_mbox_send(struct cs35l56_base *cs35l56_base, unsigned int command);
int cs35l56_firmware_shutdown(struct cs35l56_base *cs35l56_base);

View file

@ -151,6 +151,7 @@ struct tasdevice {
struct bulk_reg_val *cali_data_backup;
struct bulk_reg_val alp_cali_bckp;
struct tasdevice_fw *cali_data_fmw;
void *cali_specific;
unsigned int dev_addr;
unsigned int err_code;
unsigned char cur_book;

View file

@ -122,7 +122,7 @@ static void dice_card_strings(struct snd_dice *dice)
fw_csr_string(dev->config_rom + 5, CSR_VENDOR, vendor, sizeof(vendor));
strscpy(model, "?");
fw_csr_string(dice->unit->directory, CSR_MODEL, model, sizeof(model));
snprintf(card->longname, sizeof(card->longname),
scnprintf(card->longname, sizeof(card->longname),
"%s %s (serial %u) at %s, S%d",
vendor, model, dev->config_rom[4] & 0x3fffff,
dev_name(&dice->unit->device), 100 << dev->max_speed);

View file

@ -9816,6 +9816,15 @@ static void ca0132_config(struct hda_codec *codec)
spec->dig_in = 0x09;
break;
}
/* Default HP/Speaker auto-detect from headphone pin verb: enable if the
* pin config indicates presence detect (not AC_DEFCFG_MISC_NO_PRESENCE).
*/
if (spec->unsol_tag_hp &&
(snd_hda_query_pin_caps(codec, spec->unsol_tag_hp) & AC_PINCAP_PRES_DETECT) &&
!(get_defcfg_misc(snd_hda_codec_get_pincfg(codec, spec->unsol_tag_hp)) &
AC_DEFCFG_MISC_NO_PRESENCE))
spec->vnode_lswitch[VNID_HP_ASEL - VNODE_START_NID] = 1;
}
static int ca0132_prepare_verbs(struct hda_codec *codec)

View file

@ -299,6 +299,7 @@ static const struct hda_device_id snd_hda_id_tegrahdmi[] = {
HDA_CODEC_ID_MODEL(0x10de002f, "Tegra194 HDMI/DP2", MODEL_TEGRA),
HDA_CODEC_ID_MODEL(0x10de0030, "Tegra194 HDMI/DP3", MODEL_TEGRA),
HDA_CODEC_ID_MODEL(0x10de0031, "Tegra234 HDMI/DP", MODEL_TEGRA234),
HDA_CODEC_ID_MODEL(0x10de0032, "Tegra238 HDMI/DP", MODEL_TEGRA234),
HDA_CODEC_ID_MODEL(0x10de0033, "SoC 33 HDMI/DP", MODEL_TEGRA234),
HDA_CODEC_ID_MODEL(0x10de0034, "Tegra264 HDMI/DP", MODEL_TEGRA234),
HDA_CODEC_ID_MODEL(0x10de0035, "SoC 35 HDMI/DP", MODEL_TEGRA234),

View file

@ -6904,6 +6904,7 @@ static const struct hda_quirk alc269_fixup_tbl[] = {
SND_PCI_QUIRK(0x103c, 0x8898, "HP EliteBook 845 G8 Notebook PC", ALC285_FIXUP_HP_LIMIT_INT_MIC_BOOST),
SND_PCI_QUIRK(0x103c, 0x88b3, "HP ENVY x360 Convertible 15-es0xxx", ALC245_FIXUP_HP_ENVY_X360_MUTE_LED),
SND_PCI_QUIRK(0x103c, 0x88d0, "HP Pavilion 15-eh1xxx (mainboard 88D0)", ALC287_FIXUP_HP_GPIO_LED),
SND_PCI_QUIRK(0x103c, 0x88d1, "HP Pavilion 15-eh1xxx (mainboard 88D1)", ALC245_FIXUP_HP_MUTE_LED_V1_COEFBIT),
SND_PCI_QUIRK(0x103c, 0x88dd, "HP Pavilion 15z-ec200", ALC285_FIXUP_HP_MUTE_LED),
SND_PCI_QUIRK(0x103c, 0x88eb, "HP Victus 16-e0xxx", ALC245_FIXUP_HP_MUTE_LED_V2_COEFBIT),
SND_PCI_QUIRK(0x103c, 0x8902, "HP OMEN 16", ALC285_FIXUP_HP_MUTE_LED),

View file

@ -19,15 +19,13 @@
#include "hda_jack.h"
#include "generic.h"
/* GPIO node ID */
#define SENARY_GPIO_NODE 0x01
struct senary_spec {
struct hda_gen_spec gen;
/* extra EAPD pins */
unsigned int num_eapds;
hda_nid_t eapds[4];
bool dynamic_eapd;
hda_nid_t mute_led_eapd;
unsigned int parse_flags; /* flag for snd_hda_parse_pin_defcfg() */
@ -123,19 +121,23 @@ static void senary_init_gpio_led(struct hda_codec *codec)
unsigned int mask = spec->gpio_mute_led_mask | spec->gpio_mic_led_mask;
if (mask) {
snd_hda_codec_write(codec, SENARY_GPIO_NODE, 0, AC_VERB_SET_GPIO_MASK,
snd_hda_codec_write(codec, codec->core.afg, 0, AC_VERB_SET_GPIO_MASK,
mask);
snd_hda_codec_write(codec, SENARY_GPIO_NODE, 0, AC_VERB_SET_GPIO_DIRECTION,
snd_hda_codec_write(codec, codec->core.afg, 0, AC_VERB_SET_GPIO_DIRECTION,
mask);
snd_hda_codec_write(codec, SENARY_GPIO_NODE, 0, AC_VERB_SET_GPIO_DATA,
snd_hda_codec_write(codec, codec->core.afg, 0, AC_VERB_SET_GPIO_DATA,
spec->gpio_led);
}
}
static int senary_init(struct hda_codec *codec)
{
struct senary_spec *spec = codec->spec;
snd_hda_gen_init(codec);
senary_init_gpio_led(codec);
if (!spec->dynamic_eapd)
senary_auto_turn_eapd(codec, spec->num_eapds, spec->eapds, true);
snd_hda_apply_fixup(codec, HDA_FIXUP_ACT_INIT);
return 0;

View file

@ -60,7 +60,6 @@ struct tas2781_hda_i2c_priv {
int (*save_calibration)(struct tas2781_hda *h);
int hda_chip_id;
bool skip_calibration;
};
static int tas2781_get_i2c_res(struct acpi_resource *ares, void *data)
@ -479,7 +478,6 @@ static void tasdevice_dspfw_init(void *context)
/* If calibrated data occurs error, dsp will still works with default
* calibrated data inside algo.
*/
if (!hda_priv->skip_calibration)
hda_priv->save_calibration(tas_hda);
}
@ -535,7 +533,6 @@ static int tas2781_hda_bind(struct device *dev, struct device *master,
void *master_data)
{
struct tas2781_hda *tas_hda = dev_get_drvdata(dev);
struct tas2781_hda_i2c_priv *hda_priv = tas_hda->hda_priv;
struct hda_component_parent *parent = master_data;
struct hda_component *comp;
struct hda_codec *codec;
@ -564,14 +561,6 @@ static int tas2781_hda_bind(struct device *dev, struct device *master,
break;
}
/*
* Using ASUS ROG Xbox Ally X (RC73XA) UEFI calibration data
* causes audio dropouts during playback, use fallback data
* from DSP firmware as a workaround.
*/
if (codec->core.subsystem_id == 0x10431384)
hda_priv->skip_calibration = true;
guard(pm_runtime_active_auto)(dev);
comp->dev = dev;
@ -643,6 +632,7 @@ static int tas2781_hda_i2c_probe(struct i2c_client *clt)
*/
device_name = "TIAS2781";
hda_priv->hda_chip_id = HDA_TAS2781;
tas_hda->priv->chip_id = TAS2781;
hda_priv->save_calibration = tas2781_save_calibration;
tas_hda->priv->global_addr = TAS2781_GLOBAL_ADDR;
} else if (strstarts(dev_name(&clt->dev), "i2c-TXNW2770")) {
@ -656,6 +646,7 @@ static int tas2781_hda_i2c_probe(struct i2c_client *clt)
"i2c-TXNW2781:00-tas2781-hda.0")) {
device_name = "TXNW2781";
hda_priv->hda_chip_id = HDA_TAS2781;
tas_hda->priv->chip_id = TAS2781;
hda_priv->save_calibration = tas2781_save_calibration;
tas_hda->priv->global_addr = TAS2781_GLOBAL_ADDR;
} else if (strstr(dev_name(&clt->dev), "INT8866")) {

View file

@ -30,6 +30,20 @@ static const struct snd_soc_acpi_endpoint spk_r_endpoint = {
.group_id = 1
};
static const struct snd_soc_acpi_endpoint spk_2_endpoint = {
.num = 0,
.aggregated = 1,
.group_position = 2,
.group_id = 1
};
static const struct snd_soc_acpi_endpoint spk_3_endpoint = {
.num = 0,
.aggregated = 1,
.group_position = 3,
.group_id = 1
};
static const struct snd_soc_acpi_adr_device rt711_rt1316_group_adr[] = {
{
.adr = 0x000030025D071101ull,
@ -103,6 +117,345 @@ static const struct snd_soc_acpi_adr_device rt722_0_single_adr[] = {
}
};
static const struct snd_soc_acpi_endpoint cs42l43_endpoints[] = {
{ /* Jack Playback Endpoint */
.num = 0,
.aggregated = 0,
.group_position = 0,
.group_id = 0,
},
{ /* DMIC Capture Endpoint */
.num = 1,
.aggregated = 0,
.group_position = 0,
.group_id = 0,
},
{ /* Jack Capture Endpoint */
.num = 2,
.aggregated = 0,
.group_position = 0,
.group_id = 0,
},
{ /* Speaker Playback Endpoint */
.num = 3,
.aggregated = 0,
.group_position = 0,
.group_id = 0,
},
};
static const struct snd_soc_acpi_adr_device cs35l56x4_l1u3210_adr[] = {
{
.adr = 0x00013301FA355601ull,
.num_endpoints = 1,
.endpoints = &spk_l_endpoint,
.name_prefix = "AMP1"
},
{
.adr = 0x00013201FA355601ull,
.num_endpoints = 1,
.endpoints = &spk_r_endpoint,
.name_prefix = "AMP2"
},
{
.adr = 0x00013101FA355601ull,
.num_endpoints = 1,
.endpoints = &spk_2_endpoint,
.name_prefix = "AMP3"
},
{
.adr = 0x00013001FA355601ull,
.num_endpoints = 1,
.endpoints = &spk_3_endpoint,
.name_prefix = "AMP4"
},
};
static const struct snd_soc_acpi_adr_device cs35l63x2_l0u01_adr[] = {
{
.adr = 0x00003001FA356301ull,
.num_endpoints = 1,
.endpoints = &spk_l_endpoint,
.name_prefix = "AMP1"
},
{
.adr = 0x00003101FA356301ull,
.num_endpoints = 1,
.endpoints = &spk_r_endpoint,
.name_prefix = "AMP2"
},
};
static const struct snd_soc_acpi_adr_device cs35l63x2_l1u01_adr[] = {
{
.adr = 0x00013001FA356301ull,
.num_endpoints = 1,
.endpoints = &spk_l_endpoint,
.name_prefix = "AMP1"
},
{
.adr = 0x00013101FA356301ull,
.num_endpoints = 1,
.endpoints = &spk_r_endpoint,
.name_prefix = "AMP2"
},
};
static const struct snd_soc_acpi_adr_device cs35l63x2_l1u13_adr[] = {
{
.adr = 0x00013101FA356301ull,
.num_endpoints = 1,
.endpoints = &spk_l_endpoint,
.name_prefix = "AMP1"
},
{
.adr = 0x00013301FA356301ull,
.num_endpoints = 1,
.endpoints = &spk_r_endpoint,
.name_prefix = "AMP2"
},
};
static const struct snd_soc_acpi_adr_device cs35l63x4_l0u0246_adr[] = {
{
.adr = 0x00003001FA356301ull,
.num_endpoints = 1,
.endpoints = &spk_l_endpoint,
.name_prefix = "AMP1"
},
{
.adr = 0x00003201FA356301ull,
.num_endpoints = 1,
.endpoints = &spk_r_endpoint,
.name_prefix = "AMP2"
},
{
.adr = 0x00003401FA356301ull,
.num_endpoints = 1,
.endpoints = &spk_2_endpoint,
.name_prefix = "AMP3"
},
{
.adr = 0x00003601FA356301ull,
.num_endpoints = 1,
.endpoints = &spk_3_endpoint,
.name_prefix = "AMP4"
},
};
static const struct snd_soc_acpi_adr_device cs42l43_l0u0_adr[] = {
{
.adr = 0x00003001FA424301ull,
.num_endpoints = ARRAY_SIZE(cs42l43_endpoints),
.endpoints = cs42l43_endpoints,
.name_prefix = "cs42l43"
}
};
static const struct snd_soc_acpi_adr_device cs42l43_l0u1_adr[] = {
{
.adr = 0x00003101FA424301ull,
.num_endpoints = ARRAY_SIZE(cs42l43_endpoints),
.endpoints = cs42l43_endpoints,
.name_prefix = "cs42l43"
}
};
static const struct snd_soc_acpi_adr_device cs42l43b_l0u1_adr[] = {
{
.adr = 0x00003101FA2A3B01ull,
.num_endpoints = ARRAY_SIZE(cs42l43_endpoints),
.endpoints = cs42l43_endpoints,
.name_prefix = "cs42l43"
}
};
static const struct snd_soc_acpi_adr_device cs42l43_l1u0_cs35l56x4_l1u0123_adr[] = {
{
.adr = 0x00013001FA424301ull,
.num_endpoints = ARRAY_SIZE(cs42l43_endpoints),
.endpoints = cs42l43_endpoints,
.name_prefix = "cs42l43"
},
{
.adr = 0x00013001FA355601ull,
.num_endpoints = 1,
.endpoints = &spk_l_endpoint,
.name_prefix = "AMP1"
},
{
.adr = 0x00013101FA355601ull,
.num_endpoints = 1,
.endpoints = &spk_r_endpoint,
.name_prefix = "AMP2"
},
{
.adr = 0x00013201FA355601ull,
.num_endpoints = 1,
.endpoints = &spk_2_endpoint,
.name_prefix = "AMP3"
},
{
.adr = 0x00013301FA355601ull,
.num_endpoints = 1,
.endpoints = &spk_3_endpoint,
.name_prefix = "AMP4"
},
};
static const struct snd_soc_acpi_adr_device cs42l45_l0u0_adr[] = {
{
.adr = 0x00003001FA424501ull,
/* Re-use endpoints, but cs42l45 has no speaker */
.num_endpoints = ARRAY_SIZE(cs42l43_endpoints) - 1,
.endpoints = cs42l43_endpoints,
.name_prefix = "cs42l45"
}
};
static const struct snd_soc_acpi_adr_device cs42l45_l1u0_adr[] = {
{
.adr = 0x00013001FA424501ull,
/* Re-use endpoints, but cs42l45 has no speaker */
.num_endpoints = ARRAY_SIZE(cs42l43_endpoints) - 1,
.endpoints = cs42l43_endpoints,
.name_prefix = "cs42l45"
}
};
static const struct snd_soc_acpi_link_adr acp63_cs35l56x4_l1u3210[] = {
{
.mask = BIT(1),
.num_adr = ARRAY_SIZE(cs35l56x4_l1u3210_adr),
.adr_d = cs35l56x4_l1u3210_adr,
},
{}
};
static const struct snd_soc_acpi_link_adr acp63_cs35l63x4_l0u0246[] = {
{
.mask = BIT(0),
.num_adr = ARRAY_SIZE(cs35l63x4_l0u0246_adr),
.adr_d = cs35l63x4_l0u0246_adr,
},
{}
};
static const struct snd_soc_acpi_link_adr acp63_cs42l43_l0u1[] = {
{
.mask = BIT(0),
.num_adr = ARRAY_SIZE(cs42l43_l0u1_adr),
.adr_d = cs42l43_l0u1_adr,
},
{}
};
static const struct snd_soc_acpi_link_adr acp63_cs42l43b_l0u1[] = {
{
.mask = BIT(0),
.num_adr = ARRAY_SIZE(cs42l43b_l0u1_adr),
.adr_d = cs42l43b_l0u1_adr,
},
{}
};
static const struct snd_soc_acpi_link_adr acp63_cs42l43_l0u0_cs35l56x4_l1u3210[] = {
{
.mask = BIT(0),
.num_adr = ARRAY_SIZE(cs42l43_l0u0_adr),
.adr_d = cs42l43_l0u0_adr,
},
{
.mask = BIT(1),
.num_adr = ARRAY_SIZE(cs35l56x4_l1u3210_adr),
.adr_d = cs35l56x4_l1u3210_adr,
},
{}
};
static const struct snd_soc_acpi_link_adr acp63_cs42l43_l1u0_cs35l56x4_l1u0123[] = {
{
.mask = BIT(1),
.num_adr = ARRAY_SIZE(cs42l43_l1u0_cs35l56x4_l1u0123_adr),
.adr_d = cs42l43_l1u0_cs35l56x4_l1u0123_adr,
},
{}
};
static const struct snd_soc_acpi_link_adr acp63_cs42l45_l0u0[] = {
{
.mask = BIT(0),
.num_adr = ARRAY_SIZE(cs42l45_l0u0_adr),
.adr_d = cs42l45_l0u0_adr,
},
{}
};
static const struct snd_soc_acpi_link_adr acp63_cs42l45_l0u0_cs35l63x2_l1u01[] = {
{
.mask = BIT(0),
.num_adr = ARRAY_SIZE(cs42l45_l0u0_adr),
.adr_d = cs42l45_l0u0_adr,
},
{
.mask = BIT(1),
.num_adr = ARRAY_SIZE(cs35l63x2_l1u01_adr),
.adr_d = cs35l63x2_l1u01_adr,
},
{}
};
static const struct snd_soc_acpi_link_adr acp63_cs42l45_l0u0_cs35l63x2_l1u13[] = {
{
.mask = BIT(0),
.num_adr = ARRAY_SIZE(cs42l45_l0u0_adr),
.adr_d = cs42l45_l0u0_adr,
},
{
.mask = BIT(1),
.num_adr = ARRAY_SIZE(cs35l63x2_l1u13_adr),
.adr_d = cs35l63x2_l1u13_adr,
},
{}
};
static const struct snd_soc_acpi_link_adr acp63_cs42l45_l1u0[] = {
{
.mask = BIT(1),
.num_adr = ARRAY_SIZE(cs42l45_l1u0_adr),
.adr_d = cs42l45_l1u0_adr,
},
{}
};
static const struct snd_soc_acpi_link_adr acp63_cs42l45_l1u0_cs35l63x2_l0u01[] = {
{
.mask = BIT(1),
.num_adr = ARRAY_SIZE(cs42l45_l1u0_adr),
.adr_d = cs42l45_l1u0_adr,
},
{
.mask = BIT(0),
.num_adr = ARRAY_SIZE(cs35l63x2_l0u01_adr),
.adr_d = cs35l63x2_l0u01_adr,
},
{}
};
static const struct snd_soc_acpi_link_adr acp63_cs42l45_l1u0_cs35l63x4_l0u0246[] = {
{
.mask = BIT(1),
.num_adr = ARRAY_SIZE(cs42l45_l1u0_adr),
.adr_d = cs42l45_l1u0_adr,
},
{
.mask = BIT(0),
.num_adr = ARRAY_SIZE(cs35l63x4_l0u0246_adr),
.adr_d = cs35l63x4_l0u0246_adr,
},
{}
};
static const struct snd_soc_acpi_link_adr acp63_rt722_only[] = {
{
.mask = BIT(0),
@ -135,6 +488,66 @@ struct snd_soc_acpi_mach snd_soc_acpi_amd_acp63_sdw_machines[] = {
.links = acp63_4_in_1_sdca,
.drv_name = "amd_sdw",
},
{
.link_mask = BIT(0) | BIT(1),
.links = acp63_cs42l43_l0u0_cs35l56x4_l1u3210,
.drv_name = "amd_sdw",
},
{
.link_mask = BIT(0) | BIT(1),
.links = acp63_cs42l45_l1u0_cs35l63x4_l0u0246,
.drv_name = "amd_sdw",
},
{
.link_mask = BIT(0) | BIT(1),
.links = acp63_cs42l45_l0u0_cs35l63x2_l1u01,
.drv_name = "amd_sdw",
},
{
.link_mask = BIT(0) | BIT(1),
.links = acp63_cs42l45_l0u0_cs35l63x2_l1u13,
.drv_name = "amd_sdw",
},
{
.link_mask = BIT(0) | BIT(1),
.links = acp63_cs42l45_l1u0_cs35l63x2_l0u01,
.drv_name = "amd_sdw",
},
{
.link_mask = BIT(1),
.links = acp63_cs42l43_l1u0_cs35l56x4_l1u0123,
.drv_name = "amd_sdw",
},
{
.link_mask = BIT(1),
.links = acp63_cs35l56x4_l1u3210,
.drv_name = "amd_sdw",
},
{
.link_mask = BIT(0),
.links = acp63_cs35l63x4_l0u0246,
.drv_name = "amd_sdw",
},
{
.link_mask = BIT(0),
.links = acp63_cs42l43_l0u1,
.drv_name = "amd_sdw",
},
{
.link_mask = BIT(0),
.links = acp63_cs42l43b_l0u1,
.drv_name = "amd_sdw",
},
{
.link_mask = BIT(0),
.links = acp63_cs42l45_l0u0,
.drv_name = "amd_sdw",
},
{
.link_mask = BIT(1),
.links = acp63_cs42l45_l1u0,
.drv_name = "amd_sdw",
},
{},
};
EXPORT_SYMBOL(snd_soc_acpi_amd_acp63_sdw_machines);

View file

@ -710,6 +710,13 @@ static const struct dmi_system_id yc_acp_quirk_table[] = {
DMI_MATCH(DMI_PRODUCT_NAME, "ASUS EXPERTBOOK BM1503CDA"),
}
},
{
.driver_data = &acp6x_card,
.matches = {
DMI_MATCH(DMI_BOARD_VENDOR, "ASUSTeK COMPUTER INC."),
DMI_MATCH(DMI_BOARD_NAME, "PM1503CDA"),
}
},
{}
};

View file

@ -26,7 +26,7 @@
#include "cs35l56.h"
static const struct reg_sequence cs35l56_patch[] = {
static const struct reg_sequence cs35l56_asp_patch[] = {
/*
* Firmware can change these to non-defaults to satisfy SDCA.
* Ensure that they are at known defaults.
@ -43,6 +43,20 @@ static const struct reg_sequence cs35l56_patch[] = {
{ CS35L56_ASP1TX2_INPUT, 0x00000000 },
{ CS35L56_ASP1TX3_INPUT, 0x00000000 },
{ CS35L56_ASP1TX4_INPUT, 0x00000000 },
};
int cs35l56_set_asp_patch(struct cs35l56_base *cs35l56_base)
{
return regmap_register_patch(cs35l56_base->regmap, cs35l56_asp_patch,
ARRAY_SIZE(cs35l56_asp_patch));
}
EXPORT_SYMBOL_NS_GPL(cs35l56_set_asp_patch, "SND_SOC_CS35L56_SHARED");
static const struct reg_sequence cs35l56_patch[] = {
/*
* Firmware can change these to non-defaults to satisfy SDCA.
* Ensure that they are at known defaults.
*/
{ CS35L56_SWIRE_DP3_CH1_INPUT, 0x00000018 },
{ CS35L56_SWIRE_DP3_CH2_INPUT, 0x00000019 },
{ CS35L56_SWIRE_DP3_CH3_INPUT, 0x00000029 },

View file

@ -348,6 +348,13 @@ static int cs35l56_dsp_event(struct snd_soc_dapm_widget *w,
return wm_adsp_event(w, kcontrol, event);
}
static int cs35l56_asp_dai_probe(struct snd_soc_dai *codec_dai)
{
struct cs35l56_private *cs35l56 = snd_soc_component_get_drvdata(codec_dai->component);
return cs35l56_set_asp_patch(&cs35l56->base);
}
static int cs35l56_asp_dai_set_fmt(struct snd_soc_dai *codec_dai, unsigned int fmt)
{
struct cs35l56_private *cs35l56 = snd_soc_component_get_drvdata(codec_dai->component);
@ -552,6 +559,7 @@ static int cs35l56_asp_dai_set_sysclk(struct snd_soc_dai *dai,
}
static const struct snd_soc_dai_ops cs35l56_ops = {
.probe = cs35l56_asp_dai_probe,
.set_fmt = cs35l56_asp_dai_set_fmt,
.set_tdm_slot = cs35l56_asp_dai_set_tdm_slot,
.hw_params = cs35l56_asp_dai_hw_params,
@ -1617,7 +1625,7 @@ static int cs35l56_process_xu_onchip_speaker_id(struct cs35l56_private *cs35l56,
if (num_pulls < 0)
return num_pulls;
if (num_pulls != num_gpios) {
if (num_pulls && (num_pulls != num_gpios)) {
dev_warn(cs35l56->base.dev, "%s count(%d) != %s count(%d)\n",
pull_name, num_pulls, gpio_name, num_gpios);
}

View file

@ -2629,7 +2629,7 @@ static int rt1320_sdw_hw_params(struct snd_pcm_substream *substream,
struct sdw_port_config port_config;
struct sdw_port_config dmic_port_config[2];
struct sdw_stream_runtime *sdw_stream;
int retval;
int retval, num_channels;
unsigned int sampling_rate;
dev_dbg(dai->dev, "%s %s", __func__, dai->name);
@ -2661,7 +2661,8 @@ static int rt1320_sdw_hw_params(struct snd_pcm_substream *substream,
dmic_port_config[1].num = 10;
break;
case RT1321_DEV_ID:
dmic_port_config[0].ch_mask = BIT(0) | BIT(1);
num_channels = params_channels(params);
dmic_port_config[0].ch_mask = GENMASK(num_channels - 1, 0);
dmic_port_config[0].num = 8;
break;
default:

View file

@ -32,6 +32,10 @@
#define TAS2781_YRAM1_PAGE 42
#define TAS2781_YRAM1_START_REG 88
#define TAS2781_PG_REG TASDEVICE_REG(0x00, 0x00, 0x7c)
#define TAS2781_PG_1_0 0xA0
#define TAS2781_PG_2_0 0xA8
#define TAS2781_YRAM2_START_PAGE 43
#define TAS2781_YRAM2_END_PAGE 49
#define TAS2781_YRAM2_START_REG 8
@ -98,6 +102,12 @@ struct blktyp_devidx_map {
unsigned char dev_idx;
};
struct tas2781_cali_specific {
unsigned char sin_gni[4];
int sin_gni_reg;
bool is_sin_gn_flush;
};
static const char deviceNumber[TASDEVICE_DSP_TAS_MAX_DEVICE] = {
1, 2, 1, 2, 1, 1, 0, 2, 4, 3, 1, 2, 3, 4, 1, 2
};
@ -2454,6 +2464,84 @@ static int tasdevice_load_data(struct tasdevice_priv *tas_priv,
return ret;
}
static int tas2781_cali_preproc(struct tasdevice_priv *priv, int i)
{
struct tas2781_cali_specific *spec = priv->tasdevice[i].cali_specific;
struct calidata *cali_data = &priv->cali_data;
struct cali_reg *p = &cali_data->cali_reg_array;
unsigned char *data = cali_data->data;
int rc;
/*
* On TAS2781, if the Speaker calibrated impedance is lower than
* default value hard-coded inside the TAS2781, it will cuase vol
* lower than normal. In order to fix this issue, the parameter of
* SineGainI need updating.
*/
if (spec == NULL) {
int k = i * (cali_data->cali_dat_sz_per_dev + 1);
int re_org, re_cal, corrected_sin_gn, pg_id;
unsigned char r0_deflt[4];
spec = devm_kzalloc(priv->dev, sizeof(*spec), GFP_KERNEL);
if (spec == NULL)
return -ENOMEM;
priv->tasdevice[i].cali_specific = spec;
rc = tasdevice_dev_bulk_read(priv, i, p->r0_reg, r0_deflt, 4);
if (rc < 0) {
dev_err(priv->dev, "invalid RE from %d = %d\n", i, rc);
return rc;
}
/*
* SineGainI need to be re-calculated, calculate the high 16
* bits.
*/
re_org = r0_deflt[0] << 8 | r0_deflt[1];
re_cal = data[k + 1] << 8 | data[k + 2];
if (re_org > re_cal) {
rc = tasdevice_dev_read(priv, i, TAS2781_PG_REG,
&pg_id);
if (rc < 0) {
dev_err(priv->dev, "invalid PG id %d = %d\n",
i, rc);
return rc;
}
spec->sin_gni_reg = (pg_id == TAS2781_PG_1_0) ?
TASDEVICE_REG(0, 0x1b, 0x34) :
TASDEVICE_REG(0, 0x18, 0x1c);
rc = tasdevice_dev_bulk_read(priv, i,
spec->sin_gni_reg,
spec->sin_gni, 4);
if (rc < 0) {
dev_err(priv->dev, "wrong sinegaini %d = %d\n",
i, rc);
return rc;
}
corrected_sin_gn = re_org * ((spec->sin_gni[0] << 8) +
spec->sin_gni[1]);
corrected_sin_gn /= re_cal;
spec->sin_gni[0] = corrected_sin_gn >> 8;
spec->sin_gni[1] = corrected_sin_gn & 0xff;
spec->is_sin_gn_flush = true;
}
}
if (spec->is_sin_gn_flush) {
rc = tasdevice_dev_bulk_write(priv, i, spec->sin_gni_reg,
spec->sin_gni, 4);
if (rc < 0) {
dev_err(priv->dev, "update failed %d = %d\n",
i, rc);
return rc;
}
}
return 0;
}
static void tasdev_load_calibrated_data(struct tasdevice_priv *priv, int i)
{
struct calidata *cali_data = &priv->cali_data;
@ -2469,6 +2557,12 @@ static void tasdev_load_calibrated_data(struct tasdevice_priv *priv, int i)
}
k++;
if (priv->chip_id == TAS2781) {
rc = tas2781_cali_preproc(priv, i);
if (rc < 0)
return;
}
rc = tasdevice_dev_bulk_write(priv, i, p->r0_reg, &(data[k]), 4);
if (rc < 0) {
dev_err(priv->dev, "chn %d r0_reg bulk_wr err = %d\n", i, rc);

View file

@ -52,10 +52,13 @@ static int fsl_easrc_iec958_put_bits(struct snd_kcontrol *kcontrol,
struct soc_mreg_control *mc =
(struct soc_mreg_control *)kcontrol->private_value;
unsigned int regval = ucontrol->value.integer.value[0];
int ret;
ret = (easrc_priv->bps_iec958[mc->regbase] != regval);
easrc_priv->bps_iec958[mc->regbase] = regval;
return 0;
return ret;
}
static int fsl_easrc_iec958_get_bits(struct snd_kcontrol *kcontrol,
@ -93,14 +96,17 @@ static int fsl_easrc_set_reg(struct snd_kcontrol *kcontrol,
struct snd_soc_component *component = snd_kcontrol_chip(kcontrol);
struct soc_mreg_control *mc =
(struct soc_mreg_control *)kcontrol->private_value;
struct fsl_asrc *easrc = snd_soc_component_get_drvdata(component);
unsigned int regval = ucontrol->value.integer.value[0];
bool changed;
int ret;
ret = snd_soc_component_write(component, mc->regbase, regval);
if (ret < 0)
ret = regmap_update_bits_check(easrc->regmap, mc->regbase,
GENMASK(31, 0), regval, &changed);
if (ret != 0)
return ret;
return 0;
return changed;
}
#define SOC_SINGLE_REG_RW(xname, xreg) \

View file

@ -763,6 +763,14 @@ static const struct dmi_system_id sof_sdw_quirk_table[] = {
},
.driver_data = (void *)(SOC_SDW_CODEC_SPKR),
},
{
.callback = sof_sdw_quirk_cb,
.matches = {
DMI_MATCH(DMI_SYS_VENDOR, "Alienware"),
DMI_EXACT_MATCH(DMI_PRODUCT_SKU, "0CCD")
},
.driver_data = (void *)(SOC_SDW_CODEC_SPKR),
},
/* Pantherlake devices*/
{
.callback = sof_sdw_quirk_cb,

View file

@ -1156,9 +1156,12 @@ static int find_sdca_entity_iot(struct device *dev,
if (!terminal->is_dataport) {
const char *type_name = sdca_find_terminal_name(terminal->type);
if (type_name)
if (type_name) {
entity->label = devm_kasprintf(dev, GFP_KERNEL, "%s %s",
entity->label, type_name);
if (!entity->label)
return -ENOMEM;
}
}
ret = fwnode_property_read_u32(entity_node,

View file

@ -2219,6 +2219,8 @@ static const struct usb_audio_quirk_flags_table quirk_flags_table[] = {
QUIRK_FLAG_ALIGN_TRANSFER),
DEVICE_FLG(0x05e1, 0x0480, /* Hauppauge Woodbury */
QUIRK_FLAG_SHARE_MEDIA_DEVICE | QUIRK_FLAG_ALIGN_TRANSFER),
DEVICE_FLG(0x0624, 0x3d3f, /* AB13X USB Audio */
QUIRK_FLAG_FORCE_IFACE_RESET | QUIRK_FLAG_IFACE_DELAY),
DEVICE_FLG(0x0644, 0x8043, /* TEAC UD-501/UD-501V2/UD-503/NT-503 */
QUIRK_FLAG_ITF_USB_DSD_DAC | QUIRK_FLAG_CTL_MSG_DELAY |
QUIRK_FLAG_IFACE_DELAY),

View file

@ -520,8 +520,6 @@ static int us122l_usb_probe(struct usb_interface *intf,
return err;
}
usb_get_intf(usb_ifnum_to_if(device, 0));
usb_get_dev(device);
*cardp = card;
return 0;
}
@ -542,11 +540,9 @@ static int snd_us122l_probe(struct usb_interface *intf,
if (intf->cur_altsetting->desc.bInterfaceNumber != 1)
return 0;
err = us122l_usb_probe(usb_get_intf(intf), id, &card);
if (err < 0) {
usb_put_intf(intf);
err = us122l_usb_probe(intf, id, &card);
if (err < 0)
return err;
}
usb_set_intfdata(intf, card);
return 0;
@ -574,10 +570,6 @@ static void snd_us122l_disconnect(struct usb_interface *intf)
snd_usbmidi_disconnect(p);
}
usb_put_intf(usb_ifnum_to_if(us122l->dev, 0));
usb_put_intf(usb_ifnum_to_if(us122l->dev, 1));
usb_put_dev(us122l->dev);
snd_card_free_when_closed(card);
}