[PATCH v1 8/8] ASoC: pcm6240: remove support for taac5x1x family

From: Niranjan H Y

Date: Thu Mar 12 2026 - 14:51:50 EST


Remove TAC5X1X support from the legacy pcm6240 codec driver. The TAC5X1X
family now uses a dedicated MFD-based driver for better code organization
and maintainability.

Signed-off-by: Niranjan H Y <niranjan.hy@xxxxxx>
---
sound/soc/codecs/pcm6240.c | 126 +------------------------------------
sound/soc/codecs/pcm6240.h | 4 --
2 files changed, 3 insertions(+), 127 deletions(-)

diff --git a/sound/soc/codecs/pcm6240.c b/sound/soc/codecs/pcm6240.c
index 78b21fbfad50..b1902b9e9f32 100644
--- a/sound/soc/codecs/pcm6240.c
+++ b/sound/soc/codecs/pcm6240.c
@@ -44,10 +44,6 @@ static const struct i2c_device_id pcmdevice_i2c_id[] = {
{ "pcmd3140", PCMD3140 },
{ "pcmd3180", PCMD3180 },
{ "pcmd512x", PCMD512X },
- { "taa5212", TAA5212 },
- { "taa5412", TAA5412 },
- { "tad5212", TAD5212 },
- { "tad5412", TAD5412 },
{}
};
MODULE_DEVICE_TABLE(i2c, pcmdevice_i2c_id);
@@ -442,60 +438,6 @@ static const struct pcmdevice_mixer_control pcmd3180_fine_gain_ctl[] = {
}
};

-static const struct pcmdevice_mixer_control taa5412_digi_vol_ctl[] = {
- {
- .shift = 0,
- .reg = TAA5412_REG_CH1_DIGITAL_VOLUME,
- .max = 0xff,
- .invert = 0,
- },
- {
- .shift = 0,
- .reg = TAA5412_REG_CH2_DIGITAL_VOLUME,
- .max = 0xff,
- .invert = 0,
- },
- {
- .shift = 0,
- .reg = TAA5412_REG_CH3_DIGITAL_VOLUME,
- .max = 0xff,
- .invert = 0,
- },
- {
- .shift = 0,
- .reg = TAA5412_REG_CH4_DIGITAL_VOLUME,
- .max = 0xff,
- .invert = 0,
- }
-};
-
-static const struct pcmdevice_mixer_control taa5412_fine_gain_ctl[] = {
- {
- .shift = 4,
- .reg = TAA5412_REG_CH1_FINE_GAIN,
- .max = 0xf,
- .invert = 0,
- },
- {
- .shift = 4,
- .reg = TAA5412_REG_CH2_FINE_GAIN,
- .max = 0xf,
- .invert = 0,
- },
- {
- .shift = 4,
- .reg = TAA5412_REG_CH3_FINE_GAIN,
- .max = 0xf,
- .invert = 4,
- },
- {
- .shift = 0,
- .reg = TAA5412_REG_CH4_FINE_GAIN,
- .max = 0xf,
- .invert = 4,
- }
-};
-
static const DECLARE_TLV_DB_MINMAX_MUTE(pcmd3140_dig_gain_tlv,
-10000, 2700);
static const DECLARE_TLV_DB_MINMAX_MUTE(pcm1690_fine_dig_gain_tlv,
@@ -510,9 +452,7 @@ static const DECLARE_TLV_DB_LINEAR(adc5120_chgain_tlv, 0, 4200);
static const DECLARE_TLV_DB_MINMAX_MUTE(pcm6260_fgain_tlv,
-10000, 2700);
static const DECLARE_TLV_DB_LINEAR(pcm6260_chgain_tlv, 0, 4200);
-static const DECLARE_TLV_DB_MINMAX_MUTE(taa5412_dig_vol_tlv,
- -8050, 4700);
-static const DECLARE_TLV_DB_LINEAR(taa5412_fine_gain_tlv,
+static const DECLARE_TLV_DB_LINEAR(pcmd31x0_fine_gain_tlv,
-80, 70);

static int pcmdev_change_dev(struct pcmdevice_priv *pcm_priv,
@@ -981,7 +921,7 @@ static const struct pcmdev_ctrl_info pcmdev_gain_ctl_info[][2] = {
// PCMD3140
{
{
- .gain = taa5412_fine_gain_tlv,
+ .gain = pcmd31x0_fine_gain_tlv,
.pcmdev_ctrl = pcmd3140_fine_gain_ctl,
.ctrl_array_size = ARRAY_SIZE(pcmd3140_fine_gain_ctl),
.get = pcmdevice_get_volsw,
@@ -1000,7 +940,7 @@ static const struct pcmdev_ctrl_info pcmdev_gain_ctl_info[][2] = {
// PCMD3180
{
{
- .gain = taa5412_fine_gain_tlv,
+ .gain = pcmd31x0_fine_gain_tlv,
.pcmdev_ctrl = pcmd3180_fine_gain_ctl,
.ctrl_array_size = ARRAY_SIZE(pcmd3180_fine_gain_ctl),
.get = pcmdevice_get_volsw,
@@ -1025,62 +965,6 @@ static const struct pcmdev_ctrl_info pcmdev_gain_ctl_info[][2] = {
.ctrl_array_size = 0,
},
},
- // TAA5212
- {
- {
- .gain = taa5412_fine_gain_tlv,
- .pcmdev_ctrl = taa5412_fine_gain_ctl,
- .ctrl_array_size = ARRAY_SIZE(taa5412_fine_gain_ctl),
- .get = pcmdevice_get_volsw,
- .put = pcmdevice_put_volsw,
- .pcmdev_ctrl_name_id = 2,
- },
- {
- .gain = taa5412_dig_vol_tlv,
- .pcmdev_ctrl = taa5412_digi_vol_ctl,
- .ctrl_array_size = ARRAY_SIZE(taa5412_digi_vol_ctl),
- .get = pcmdevice_get_volsw,
- .put = pcmdevice_put_volsw,
- .pcmdev_ctrl_name_id = 1,
- },
- },
- // TAA5412
- {
- {
- .gain = taa5412_fine_gain_tlv,
- .pcmdev_ctrl = taa5412_fine_gain_ctl,
- .ctrl_array_size = ARRAY_SIZE(taa5412_fine_gain_ctl),
- .get = pcmdevice_get_volsw,
- .put = pcmdevice_put_volsw,
- .pcmdev_ctrl_name_id = 2,
- },
- {
- .gain = taa5412_dig_vol_tlv,
- .pcmdev_ctrl = taa5412_digi_vol_ctl,
- .ctrl_array_size = ARRAY_SIZE(taa5412_digi_vol_ctl),
- .get = pcmdevice_get_volsw,
- .put = pcmdevice_put_volsw,
- .pcmdev_ctrl_name_id = 1,
- },
- },
- // TAD5212
- {
- {
- .ctrl_array_size = 0,
- },
- {
- .ctrl_array_size = 0,
- },
- },
- // TAD5412
- {
- {
- .ctrl_array_size = 0,
- },
- {
- .ctrl_array_size = 0,
- },
- },
};

static int pcmdev_dev_bulk_write(struct pcmdevice_priv *pcm_dev,
@@ -1998,10 +1882,6 @@ static const struct of_device_id pcmdevice_of_match[] = {
{ .compatible = "ti,pcmd3140" },
{ .compatible = "ti,pcmd3180" },
{ .compatible = "ti,pcmd512x" },
- { .compatible = "ti,taa5212" },
- { .compatible = "ti,taa5412" },
- { .compatible = "ti,tad5212" },
- { .compatible = "ti,tad5412" },
{},
};
MODULE_DEVICE_TABLE(of, pcmdevice_of_match);
diff --git a/sound/soc/codecs/pcm6240.h b/sound/soc/codecs/pcm6240.h
index 2d8f9e798139..86b1ef734a3d 100644
--- a/sound/soc/codecs/pcm6240.h
+++ b/sound/soc/codecs/pcm6240.h
@@ -33,10 +33,6 @@ enum pcm_device {
PCMD3140,
PCMD3180,
PCMD512X,
- TAA5212,
- TAA5412,
- TAD5212,
- TAD5412,
MAX_DEVICE,
};

--
2.34.1