Skip to content

Commit 53a3c6e

Browse files
jimxbj-dotbroonie
authored andcommitted
ASoC: tas2781: Support more newly-released amplifiers tas58xx in the driver
TAS5802/TAS5815/TAS5828 has on-chip DSP without current/voltage feedback. Signed-off-by: Baojun Xu <baojun.xu@ti.com> Link: https://patch.msgid.link/20251002072925.26242-1-baojun.xu@ti.com Signed-off-by: Mark Brown <broonie@kernel.org>
1 parent 3a86608 commit 53a3c6e

File tree

2 files changed

+22
-2
lines changed

2 files changed

+22
-2
lines changed

include/sound/tas2781.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -120,8 +120,11 @@ enum audio_device {
120120
TAS2570,
121121
TAS2572,
122122
TAS2781,
123+
TAS5802,
124+
TAS5815,
123125
TAS5825,
124126
TAS5827,
127+
TAS5828,
125128
TAS_OTHERS,
126129
};
127130

sound/soc/codecs/tas2781-i2c.c

Lines changed: 19 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -108,8 +108,11 @@ static const struct i2c_device_id tasdevice_id[] = {
108108
{ "tas2570", TAS2570 },
109109
{ "tas2572", TAS2572 },
110110
{ "tas2781", TAS2781 },
111+
{ "tas5802", TAS5802 },
112+
{ "tas5815", TAS5815 },
111113
{ "tas5825", TAS5825 },
112114
{ "tas5827", TAS5827 },
115+
{ "tas5828", TAS5828 },
113116
{}
114117
};
115118
MODULE_DEVICE_TABLE(i2c, tasdevice_id);
@@ -124,8 +127,11 @@ static const struct of_device_id tasdevice_of_match[] = {
124127
{ .compatible = "ti,tas2570" },
125128
{ .compatible = "ti,tas2572" },
126129
{ .compatible = "ti,tas2781" },
130+
{ .compatible = "ti,tas5802" },
131+
{ .compatible = "ti,tas5815" },
127132
{ .compatible = "ti,tas5825" },
128133
{ .compatible = "ti,tas5827" },
134+
{ .compatible = "ti,tas5828" },
129135
{},
130136
};
131137
MODULE_DEVICE_TABLE(of, tasdevice_of_match);
@@ -1665,8 +1671,10 @@ static void tasdevice_fw_ready(const struct firmware *fmw,
16651671
}
16661672
tas_priv->fw_state = TASDEVICE_DSP_FW_ALL_OK;
16671673

1668-
/* There is no calibration required for TAS5825/TAS5827. */
1669-
if (tas_priv->chip_id < TAS5825) {
1674+
/* There is no calibration required for
1675+
* TAS5802/TAS5815/TAS5825/TAS5827/TAS5828.
1676+
*/
1677+
if (tas_priv->chip_id < TAS5802) {
16701678
ret = tasdevice_create_cali_ctrls(tas_priv);
16711679
if (ret) {
16721680
dev_err(tas_priv->dev, "cali controls error\n");
@@ -1720,8 +1728,11 @@ static void tasdevice_fw_ready(const struct firmware *fmw,
17201728
switch (tas_priv->chip_id) {
17211729
case TAS2563:
17221730
case TAS2781:
1731+
case TAS5802:
1732+
case TAS5815:
17231733
case TAS5825:
17241734
case TAS5827:
1735+
case TAS5828:
17251736
/* If DSP FW fail, DSP kcontrol won't be created. */
17261737
tasdevice_dsp_remove(tas_priv);
17271738
}
@@ -1882,8 +1893,11 @@ static int tasdevice_codec_probe(struct snd_soc_component *codec)
18821893
p = (struct snd_kcontrol_new *)tas2781_snd_controls;
18831894
size = ARRAY_SIZE(tas2781_snd_controls);
18841895
break;
1896+
case TAS5802:
1897+
case TAS5815:
18851898
case TAS5825:
18861899
case TAS5827:
1900+
case TAS5828:
18871901
p = (struct snd_kcontrol_new *)tas5825_snd_controls;
18881902
size = ARRAY_SIZE(tas5825_snd_controls);
18891903
break;
@@ -2054,8 +2068,11 @@ static const struct acpi_device_id tasdevice_acpi_match[] = {
20542068
{ "TXNW2570", TAS2570 },
20552069
{ "TXNW2572", TAS2572 },
20562070
{ "TXNW2781", TAS2781 },
2071+
{ "TXNW5802", TAS5802 },
2072+
{ "TXNW5815", TAS5815 },
20572073
{ "TXNW5825", TAS5825 },
20582074
{ "TXNW5827", TAS5827 },
2075+
{ "TXNW5828", TAS5828 },
20592076
{},
20602077
};
20612078

0 commit comments

Comments
 (0)