Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 284020
b: refs/heads/master
c: 306bf6b
h: refs/heads/master
v: v3
  • Loading branch information
Axel Lin authored and Mark Brown committed Dec 27, 2011
1 parent 3b604e9 commit 433244f
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 6 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 2c9d9b6fa70e1881c411d45d2f3d2ab28bd58c75
refs/heads/master: 306bf6b19ee3da824fbdbdb2dc4e5d62a8983a2c
7 changes: 2 additions & 5 deletions trunk/sound/soc/codecs/da7210.c
Original file line number Diff line number Diff line change
Expand Up @@ -944,7 +944,8 @@ static int __devinit da7210_i2c_probe(struct i2c_client *i2c,
struct da7210_priv *da7210;
int ret;

da7210 = kzalloc(sizeof(struct da7210_priv), GFP_KERNEL);
da7210 = devm_kzalloc(&i2c->dev, sizeof(struct da7210_priv),
GFP_KERNEL);
if (!da7210)
return -ENOMEM;

Expand All @@ -953,16 +954,12 @@ static int __devinit da7210_i2c_probe(struct i2c_client *i2c,

ret = snd_soc_register_codec(&i2c->dev,
&soc_codec_dev_da7210, &da7210_dai, 1);
if (ret < 0)
kfree(da7210);

return ret;
}

static int __devexit da7210_i2c_remove(struct i2c_client *client)
{
snd_soc_unregister_codec(&client->dev);
kfree(i2c_get_clientdata(client));
return 0;
}

Expand Down

0 comments on commit 433244f

Please sign in to comment.