]> git.baikalelectronics.ru Git - kernel.git/commitdiff
net: dsa: xrs700x: remove unnecessary i2c_set_clientdata()
authorYang Yingliang <yangyingliang@huawei.com>
Fri, 23 Sep 2022 14:37:42 +0000 (22:37 +0800)
committerJakub Kicinski <kuba@kernel.org>
Tue, 27 Sep 2022 00:44:28 +0000 (17:44 -0700)
Remove unnecessary i2c_set_clientdata() in ->remove(), the driver_data
will be set to NULL in device_unbind_cleanup() after calling ->remove().

Signed-off-by: Yang Yingliang <yangyingliang@huawei.com>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/dsa/xrs700x/xrs700x_i2c.c

index 6deae388a0d6f89809fab4df62478a263fa85231..cd533b9e17eca444bbca4e3017f5fa1eacb9355c 100644 (file)
@@ -114,8 +114,6 @@ static int xrs700x_i2c_remove(struct i2c_client *i2c)
 
        xrs700x_switch_remove(priv);
 
-       i2c_set_clientdata(i2c, NULL);
-
        return 0;
 }