diff options
author | Takashi Iwai <tiwai@suse.de> | 2011-10-27 10:43:40 +0200 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2011-10-27 10:43:40 +0200 |
commit | bb14eb0da72afb69be261b28ec858cbd5a35e089 (patch) | |
tree | fa72a87d21e506c990b63657d782936311cfa7cf /sound/soc/codecs/tpa6130a2.c | |
parent | 9430148d800dd929ad73da4c6afb67f793f8af43 (diff) | |
parent | 5927f94700e860ae27ff24e7f3bc9e4f7b9922eb (diff) | |
download | blackbird-op-linux-bb14eb0da72afb69be261b28ec858cbd5a35e089.tar.gz blackbird-op-linux-bb14eb0da72afb69be261b28ec858cbd5a35e089.zip |
Merge branch 'topic/asoc' into for-linus
Diffstat (limited to 'sound/soc/codecs/tpa6130a2.c')
-rw-r--r-- | sound/soc/codecs/tpa6130a2.c | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/sound/soc/codecs/tpa6130a2.c b/sound/soc/codecs/tpa6130a2.c index b2572c451c35..7eeca79d7387 100644 --- a/sound/soc/codecs/tpa6130a2.c +++ b/sound/soc/codecs/tpa6130a2.c @@ -33,6 +33,11 @@ #include "tpa6130a2.h" +enum tpa_model { + TPA6130A2, + TPA6140A2, +}; + static struct i2c_client *tpa6130a2_client; /* This struct is used to save the context */ @@ -383,7 +388,7 @@ static int __devinit tpa6130a2_probe(struct i2c_client *client, pdata = client->dev.platform_data; data->power_gpio = pdata->power_gpio; - data->id = pdata->id; + data->id = id->driver_data; mutex_init(&data->mutex); @@ -405,7 +410,7 @@ static int __devinit tpa6130a2_probe(struct i2c_client *client, switch (data->id) { default: dev_warn(dev, "Unknown TPA model (%d). Assuming 6130A2\n", - pdata->id); + data->id); case TPA6130A2: regulator = "Vdd"; break; @@ -469,7 +474,8 @@ static int __devexit tpa6130a2_remove(struct i2c_client *client) } static const struct i2c_device_id tpa6130a2_id[] = { - { "tpa6130a2", 0 }, + { "tpa6130a2", TPA6130A2 }, + { "tpa6140a2", TPA6140A2 }, { } }; MODULE_DEVICE_TABLE(i2c, tpa6130a2_id); |