Messages in this thread | | | Date | Fri, 18 Sep 2020 23:09:11 +0200 | From | <> | Subject | Re: [PATCH] i2c: Switch to using the new API kobj_to_dev() |
| |
> 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);
Can't we make this a oneliner then merging the last two lines?
[unhandled content-type:application/pgp-signature]
| |