Commit dc6641be authored by Wolfram Sang's avatar Wolfram Sang Committed by Jean Delvare

i2c: Remove obsolete cleanup for clientdata

A few new i2c-drivers came into the kernel which clear the clientdata-pointer
on exit. This is obsolete meanwhile, so fix it and hope the word will spread.
Signed-off-by: default avatarWolfram Sang <w.sang@pengutronix.de>
Acked-by: default avatarAlan Cox <alan@linux.intel.com>
Acked-by: default avatarGuennadi Liakhovetski <g.liakhovetski@gmx.de>
Acked-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
Signed-off-by: default avatarJean Delvare <khali@linux-fr.org>
parent 0143832c
...@@ -451,7 +451,6 @@ static int imx074_probe(struct i2c_client *client, ...@@ -451,7 +451,6 @@ static int imx074_probe(struct i2c_client *client,
ret = imx074_video_probe(icd, client); ret = imx074_video_probe(icd, client);
if (ret < 0) { if (ret < 0) {
icd->ops = NULL; icd->ops = NULL;
i2c_set_clientdata(client, NULL);
kfree(priv); kfree(priv);
return ret; return ret;
} }
...@@ -468,7 +467,6 @@ static int imx074_remove(struct i2c_client *client) ...@@ -468,7 +467,6 @@ static int imx074_remove(struct i2c_client *client)
icd->ops = NULL; icd->ops = NULL;
if (icl->free_bus) if (icl->free_bus)
icl->free_bus(icl); icl->free_bus(icl);
i2c_set_clientdata(client, NULL);
client->driver = NULL; client->driver = NULL;
kfree(priv); kfree(priv);
......
...@@ -1174,7 +1174,6 @@ static int ov6650_probe(struct i2c_client *client, ...@@ -1174,7 +1174,6 @@ static int ov6650_probe(struct i2c_client *client,
if (ret) { if (ret) {
icd->ops = NULL; icd->ops = NULL;
i2c_set_clientdata(client, NULL);
kfree(priv); kfree(priv);
} }
...@@ -1185,7 +1184,6 @@ static int ov6650_remove(struct i2c_client *client) ...@@ -1185,7 +1184,6 @@ static int ov6650_remove(struct i2c_client *client)
{ {
struct ov6650 *priv = to_ov6650(client); struct ov6650 *priv = to_ov6650(client);
i2c_set_clientdata(client, NULL);
kfree(priv); kfree(priv);
return 0; return 0;
} }
......
...@@ -251,7 +251,6 @@ static int apds9802als_probe(struct i2c_client *client, ...@@ -251,7 +251,6 @@ static int apds9802als_probe(struct i2c_client *client,
return res; return res;
als_error1: als_error1:
i2c_set_clientdata(client, NULL);
kfree(data); kfree(data);
return res; return res;
} }
......
...@@ -733,7 +733,6 @@ static int dcon_probe(struct i2c_client *client, const struct i2c_device_id *id) ...@@ -733,7 +733,6 @@ static int dcon_probe(struct i2c_client *client, const struct i2c_device_id *id)
edev: edev:
platform_device_unregister(dcon_device); platform_device_unregister(dcon_device);
dcon_device = NULL; dcon_device = NULL;
i2c_set_clientdata(client, NULL);
eirq: eirq:
free_irq(DCON_IRQ, &dcon_driver); free_irq(DCON_IRQ, &dcon_driver);
einit: einit:
...@@ -757,8 +756,6 @@ static int dcon_remove(struct i2c_client *client) ...@@ -757,8 +756,6 @@ static int dcon_remove(struct i2c_client *client)
platform_device_unregister(dcon_device); platform_device_unregister(dcon_device);
cancel_work_sync(&dcon_work); cancel_work_sync(&dcon_work);
i2c_set_clientdata(client, NULL);
return 0; return 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