Commit d6372b70 authored by Wolfram Sang's avatar Wolfram Sang Committed by Dmitry Torokhov

Input: tsc2007 - do not leave dangling clientdata pointer

Do not leave dangling client data pointers when unbinding device from the
driver.
Signed-off-by: default avatarWolfram Sang <w.sang@pengutronix.de>
Signed-off-by: default avatarDmitry Torokhov <dtor@mail.ru>
parent e0785572
...@@ -347,6 +347,8 @@ static int __devexit tsc2007_remove(struct i2c_client *client) ...@@ -347,6 +347,8 @@ static int __devexit tsc2007_remove(struct i2c_client *client)
struct tsc2007 *ts = i2c_get_clientdata(client); struct tsc2007 *ts = i2c_get_clientdata(client);
struct tsc2007_platform_data *pdata = client->dev.platform_data; struct tsc2007_platform_data *pdata = client->dev.platform_data;
i2c_set_clientdata(client, NULL);
tsc2007_free_irq(ts); tsc2007_free_irq(ts);
if (pdata->exit_platform_hw) if (pdata->exit_platform_hw)
......
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