summaryrefslogtreecommitdiff
path: root/drivers/media/i2c/sony-btf-mpx.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/media/i2c/sony-btf-mpx.c')
-rw-r--r--drivers/media/i2c/sony-btf-mpx.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/media/i2c/sony-btf-mpx.c b/drivers/media/i2c/sony-btf-mpx.c
index 38cbea98764c..32d82320b485 100644
--- a/drivers/media/i2c/sony-btf-mpx.c
+++ b/drivers/media/i2c/sony-btf-mpx.c
@@ -30,7 +30,7 @@ MODULE_LICENSE("GPL v2");
static int debug;
module_param(debug, int, 0644);
-MODULE_PARM_DESC(debug, "debug level 0=off(default) 1=on\n");
+MODULE_PARM_DESC(debug, "debug level 0=off(default) 1=on");
/* #define MPX_DEBUG */
@@ -355,7 +355,7 @@ static int sony_btf_mpx_probe(struct i2c_client *client,
v4l_info(client, "chip found @ 0x%x (%s)\n",
client->addr << 1, client->adapter->name);
- t = kzalloc(sizeof(struct sony_btf_mpx), GFP_KERNEL);
+ t = devm_kzalloc(&client->dev, sizeof(*t), GFP_KERNEL);
if (t == NULL)
return -ENOMEM;
@@ -374,7 +374,6 @@ static int sony_btf_mpx_remove(struct i2c_client *client)
struct v4l2_subdev *sd = i2c_get_clientdata(client);
v4l2_device_unregister_subdev(sd);
- kfree(to_state(sd));
return 0;
}