Home
last modified time | relevance | path

Searched hist:"09 d5135b" (Results 1 – 1 of 1) sorted by relevance

/openbmc/linux/drivers/iio/proximity/
H A Drfd77402.c09d5135b Wed Jun 30 08:16:35 CDT 2021 Alexandru Ardelean <aardelean@deviqon.com> iio: proximity: rfd77402: use i2c_client for rfd77402_{init,powerdown}()

These 2 functions only do I2C reads/writes and don't require any of the
private data of the driver.

They're also used in the PM suspend/resume part of the driver.

Converting them to take an i2c_client object as parameter simplifies things
a bit (especially in the suspend/resume) as the driver mostly needs the
reference for i2c_client, so no need to jump through hoops to get it from
the private data (as was done in many places).

The rfd77402_measure() function has also been converted to take an
i2c_client object, since it also does only I2C ops.

Signed-off-by: Alexandru Ardelean <aardelean@deviqon.com>
Link: https://lore.kernel.org/r/20210630131636.1563148-1-aardelean@deviqon.com
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>