diff options
| author | Jean Delvare <khali@linux-fr.org> | 2008-09-27 14:30:52 -0400 |
|---|---|---|
| committer | Takashi Iwai <tiwai@suse.de> | 2008-09-29 06:53:24 -0400 |
| commit | 9778e9a0eafe796c2affcd1fa1fa8a3765e026e6 (patch) | |
| tree | 14cd62ae3a35a74d16fd770bf89af7ac311ab45c | |
| parent | ec2cd95f340fb07b905839ee219b3846ecf58396 (diff) | |
ALSA: ASoC: Fix another cs4270 error path
Conversion to new-style i2c driver missed the error path of the
probe function. Fix it.
Signed-off-by: Jean Delvare <khali@linux-fr.org>
Cc: Timur Tabi <timur@freescale.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
| -rw-r--r-- | sound/soc/codecs/cs4270.c | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/sound/soc/codecs/cs4270.c b/sound/soc/codecs/cs4270.c index 82d94f00aa45..d68650de39bc 100644 --- a/sound/soc/codecs/cs4270.c +++ b/sound/soc/codecs/cs4270.c | |||
| @@ -610,17 +610,12 @@ static int cs4270_i2c_probe(struct i2c_client *i2c_client, | |||
| 610 | return 0; | 610 | return 0; |
| 611 | 611 | ||
| 612 | error: | 612 | error: |
| 613 | if (codec->control_data) { | 613 | codec->control_data = NULL; |
| 614 | i2c_detach_client(i2c_client); | ||
| 615 | codec->control_data = NULL; | ||
| 616 | } | ||
| 617 | 614 | ||
| 618 | kfree(codec->reg_cache); | 615 | kfree(codec->reg_cache); |
| 619 | codec->reg_cache = NULL; | 616 | codec->reg_cache = NULL; |
| 620 | codec->reg_cache_size = 0; | 617 | codec->reg_cache_size = 0; |
| 621 | 618 | ||
| 622 | kfree(i2c_client); | ||
| 623 | |||
| 624 | return ret; | 619 | return ret; |
| 625 | } | 620 | } |
| 626 | 621 | ||
