diff options
author | Mark Brown <broonie@opensource.wolfsonmicro.com> | 2009-10-09 14:13:47 -0400 |
---|---|---|
committer | Mark Brown <broonie@opensource.wolfsonmicro.com> | 2009-10-09 14:13:47 -0400 |
commit | ebab1b1d07266ab8ca9f65065e68b02f05504c4e (patch) | |
tree | 53a1de5734fa2e8ccacd15d75dd71f052d148903 /sound/soc/codecs | |
parent | 493b67efffc462703d583389aca96f850c18d3b3 (diff) |
ASoC: Minor fixups to tpa6130a2 driver
- Staticise ttpa6130a2_client.
- Remove unneeded cast from void.
- Use explict NULL rather than 0.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Diffstat (limited to 'sound/soc/codecs')
-rw-r--r-- | sound/soc/codecs/tpa6130a2.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/sound/soc/codecs/tpa6130a2.c b/sound/soc/codecs/tpa6130a2.c index 1b77c959e2dc..0a6e7b4ace60 100644 --- a/sound/soc/codecs/tpa6130a2.c +++ b/sound/soc/codecs/tpa6130a2.c | |||
@@ -32,7 +32,7 @@ | |||
32 | 32 | ||
33 | #include "tpa6130a2.h" | 33 | #include "tpa6130a2.h" |
34 | 34 | ||
35 | struct i2c_client *tpa6130a2_client; | 35 | static struct i2c_client *tpa6130a2_client; |
36 | 36 | ||
37 | /* This struct is used to save the context */ | 37 | /* This struct is used to save the context */ |
38 | struct tpa6130a2_data { | 38 | struct tpa6130a2_data { |
@@ -372,7 +372,7 @@ static int tpa6130a2_probe(struct i2c_client *client, | |||
372 | 372 | ||
373 | i2c_set_clientdata(tpa6130a2_client, data); | 373 | i2c_set_clientdata(tpa6130a2_client, data); |
374 | 374 | ||
375 | pdata = (struct tpa6130a2_platform_data *)client->dev.platform_data; | 375 | pdata = client->dev.platform_data; |
376 | data->power_gpio = pdata->power_gpio; | 376 | data->power_gpio = pdata->power_gpio; |
377 | 377 | ||
378 | mutex_init(&data->mutex); | 378 | mutex_init(&data->mutex); |
@@ -410,7 +410,7 @@ static int tpa6130a2_probe(struct i2c_client *client, | |||
410 | fail: | 410 | fail: |
411 | kfree(data); | 411 | kfree(data); |
412 | i2c_set_clientdata(tpa6130a2_client, NULL); | 412 | i2c_set_clientdata(tpa6130a2_client, NULL); |
413 | tpa6130a2_client = 0; | 413 | tpa6130a2_client = NULL; |
414 | 414 | ||
415 | return ret; | 415 | return ret; |
416 | } | 416 | } |
@@ -424,7 +424,7 @@ static int tpa6130a2_remove(struct i2c_client *client) | |||
424 | if (data->power_gpio >= 0) | 424 | if (data->power_gpio >= 0) |
425 | gpio_free(data->power_gpio); | 425 | gpio_free(data->power_gpio); |
426 | kfree(data); | 426 | kfree(data); |
427 | tpa6130a2_client = 0; | 427 | tpa6130a2_client = NULL; |
428 | 428 | ||
429 | return 0; | 429 | return 0; |
430 | } | 430 | } |