Stefan Brüns e794bf6751 iio: light: vl6180: Cleanup als_gain lookup, avoid register readback
Instead of manually iterating the array of allowed gain values, use
find_closest. Storing the current gain setting avoids accessing the
hardware on each query.

Signed-off-by: Stefan Brüns <stefan.bruens@rwth-aachen.de>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
2017-10-09 20:50:15 +01:00
..
2017-10-04 17:34:41 +01:00
2017-10-03 08:57:07 -07:00
2017-09-10 20:40:00 -07:00
2017-09-07 14:03:05 -07:00
2017-09-07 13:51:13 -07:00
2017-10-09 09:02:35 +02:00
2017-09-05 11:08:17 -07:00
2017-10-04 17:11:53 -07:00
2017-09-10 20:40:00 -07:00
2017-10-09 09:02:35 +02:00
2017-08-29 13:46:35 +02:00
2017-09-12 13:30:06 -07:00
2017-09-05 11:08:17 -07:00
2017-10-09 09:02:35 +02:00
2017-09-11 13:04:32 -07:00
2017-09-07 13:51:13 -07:00
2017-09-09 14:34:38 -07:00
2017-09-13 10:56:00 -07:00
2017-09-19 08:36:19 +02:00
2017-10-07 12:34:16 -07:00
2017-09-05 12:45:03 -07:00
2017-10-09 09:02:35 +02:00
2017-09-05 12:45:03 -07:00
2017-10-09 09:02:35 +02:00
2017-08-30 14:03:42 -06:00
2017-09-14 13:33:33 -07:00
2017-09-07 21:11:05 -07:00
2017-09-29 12:24:28 -07:00