1
0
Fork 0

i2c: Switch to using the new API kobj_to_dev()

Switch to using the new API kobj_to_dev().

Signed-off-by: Tian Tao <tiantao6@hisilicon.com>
Signed-off-by: Wolfram Sang <wsa@kernel.org>
zero-sugar-mainline-defconfig
Tian Tao 2020-09-15 09:38:18 +08:00 committed by Wolfram Sang
parent c4651f11d0
commit b1d4dc15b2
1 changed files with 1 additions and 1 deletions

View File

@ -344,7 +344,7 @@ const struct i2c_device_id *i2c_match_id(const struct i2c_device_id *id,
static inline struct i2c_client *kobj_to_i2c_client(struct kobject *kobj)
{
struct device * const dev = container_of(kobj, struct device, kobj);
struct device * const dev = kobj_to_dev(kobj);
return to_i2c_client(dev);
}