Signed-off-by: Axel Lin <axel.lin@gmail.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
dev_dbg(&client->dev, "Found codec id : alc56%02x\n", vid2);
alc5623 = kzalloc(sizeof(struct alc5623_priv), GFP_KERNEL);
- if (alc5623 == NULL) {
- ret = -ENOMEM;
- goto err;
- }
+ if (alc5623 == NULL)
+ return -ENOMEM;
pdata = client->dev.platform_data;
if (pdata) {
&soc_codec_device_alc5623, &alc5623_dai, 1);
if (ret != 0) {
dev_err(&client->dev, "Failed to register codec: %d\n", ret);
- goto err;
+ kfree(alc5623);
}
- return 0;
-
-err:
return ret;
}