Skip to content

Commit 63a9362

Browse files
MrVanbroonie
authored andcommitted
ASoC: codec: tpa6130a2: Remove tpa6130a2_platform_data
There is no in-tree user to create the device using platform data 'struct tpa6130a2_platform_data', so drop the dead code. Signed-off-by: Peng Fan <[email protected]> Link: https://patch.msgid.link/[email protected] Signed-off-by: Mark Brown <[email protected]>
1 parent b194e82 commit 63a9362

File tree

3 files changed

+1
-31
lines changed

3 files changed

+1
-31
lines changed

MAINTAINERS

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23890,7 +23890,6 @@ F: Documentation/devicetree/bindings/sound/ti,tlv320*.yaml
2389023890
F: Documentation/devicetree/bindings/sound/ti,tlv320adcx140.yaml
2389123891
F: include/sound/tas2*.h
2389223892
F: include/sound/tlv320*.h
23893-
F: include/sound/tpa6130a2-plat.h
2389423893
F: sound/pci/hda/tas2781_hda_i2c.c
2389523894
F: sound/soc/codecs/pcm1681.c
2389623895
F: sound/soc/codecs/pcm1789*.*

include/sound/tpa6130a2-plat.h

Lines changed: 0 additions & 17 deletions
This file was deleted.

sound/soc/codecs/tpa6130a2.c

Lines changed: 1 addition & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,6 @@
1919
#include <linux/slab.h>
2020
#include <sound/soc.h>
2121
#include <sound/tlv.h>
22-
#include <sound/tpa6130a2-plat.h>
2322

2423
#include "tpa6130a2.h"
2524

@@ -209,18 +208,10 @@ static const struct regmap_config tpa6130a2_regmap_config = {
209208
.cache_type = REGCACHE_RBTREE,
210209
};
211210

212-
static const struct i2c_device_id tpa6130a2_id[] = {
213-
{ "tpa6130a2", TPA6130A2 },
214-
{ "tpa6140a2", TPA6140A2 },
215-
{ }
216-
};
217-
MODULE_DEVICE_TABLE(i2c, tpa6130a2_id);
218-
219211
static int tpa6130a2_probe(struct i2c_client *client)
220212
{
221213
struct device *dev;
222214
struct tpa6130a2_data *data;
223-
struct tpa6130a2_platform_data *pdata = client->dev.platform_data;
224215
struct device_node *np = client->dev.of_node;
225216
const char *regulator;
226217
unsigned int version;
@@ -238,9 +229,7 @@ static int tpa6130a2_probe(struct i2c_client *client)
238229
if (IS_ERR(data->regmap))
239230
return PTR_ERR(data->regmap);
240231

241-
if (pdata) {
242-
data->power_gpio = pdata->power_gpio;
243-
} else if (np) {
232+
if (np) {
244233
data->power_gpio = of_get_named_gpio(np, "power-gpio", 0);
245234
} else {
246235
dev_err(dev, "Platform data not set\n");
@@ -318,7 +307,6 @@ static struct i2c_driver tpa6130a2_i2c_driver = {
318307
.of_match_table = of_match_ptr(tpa6130a2_of_match),
319308
},
320309
.probe = tpa6130a2_probe,
321-
.id_table = tpa6130a2_id,
322310
};
323311

324312
module_i2c_driver(tpa6130a2_i2c_driver);

0 commit comments

Comments
 (0)