]> git.baikalelectronics.ru Git - kernel.git/commitdiff
net: dsa: lan9303: remove unnecessary i2c_set_clientdata()
authorYang Yingliang <yangyingliang@huawei.com>
Fri, 23 Sep 2022 14:37:40 +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/lan9303_i2c.c

index 8ca4713310fa3d821297c6607137209398489ba9..79be5fc044bd48a7690b4753fba904544cd554c1 100644 (file)
@@ -74,8 +74,6 @@ static int lan9303_i2c_remove(struct i2c_client *client)
 
        lan9303_remove(&sw_dev->chip);
 
-       i2c_set_clientdata(client, NULL);
-
        return 0;
 }