Searched hist:b885d0fa6790b8b2c8502dc93fed27ce85e68922 (Results 1 – 1 of 1) sorted by relevance
/linux/drivers/iio/light/ |
H A D | cm32181.c | diff b885d0fa6790b8b2c8502dc93fed27ce85e68922 Tue Apr 28 19:29:17 CEST 2020 Hans de Goede <hdegoede@redhat.com> iio: light: cm32181: Clean up the probe function a bit
3 small cleanups to cm32181_probe():
1. Do not log an error when we fail to allocate memory (as a general rule drivers do not log errors for this as the kernel will already have complained loudly that it could not alloc the mem).
2. Remove the i2c_set_clientdata() call, we never use i2c_get_clientdata() or dev_get_drvdata() anywhere.
3. Add a dev helper variable and use it in various places instead of &client->dev.
Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
|