Commit 6c832e36 authored by Hans Verkuil's avatar Hans Verkuil Committed by Mauro Carvalho Chehab

V4L/DVB (8789): wm8739: remove wrong kfree

i2c_client is allocated for us, we should never free it ourselves.
Signed-off-by: default avatarHans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@redhat.com>
parent 2389b360
...@@ -274,10 +274,8 @@ static int wm8739_probe(struct i2c_client *client, ...@@ -274,10 +274,8 @@ static int wm8739_probe(struct i2c_client *client,
client->addr << 1, client->adapter->name); client->addr << 1, client->adapter->name);
state = kmalloc(sizeof(struct wm8739_state), GFP_KERNEL); state = kmalloc(sizeof(struct wm8739_state), GFP_KERNEL);
if (state == NULL) { if (state == NULL)
kfree(client);
return -ENOMEM; return -ENOMEM;
}
state->vol_l = 0x17; /* 0dB */ state->vol_l = 0x17; /* 0dB */
state->vol_r = 0x17; /* 0dB */ state->vol_r = 0x17; /* 0dB */
state->muted = 0; state->muted = 0;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment