]> asedeno.scripts.mit.edu Git - linux.git/commit
staging: iio: adc: ad7606: Use find_closest() macro
authorStefan Popa <stefan.popa@analog.com>
Thu, 13 Dec 2018 12:46:18 +0000 (14:46 +0200)
committerJonathan Cameron <Jonathan.Cameron@huawei.com>
Sat, 22 Dec 2018 16:58:13 +0000 (16:58 +0000)
commit41f71e5e7dafb4608834d6e3be49b5568639c0c1
treea183b7cf611f094a37242010ce2bcb28c7ba9077
parentc0683bfd3772337353e95decc2bf0421058088f7
staging: iio: adc: ad7606: Use find_closest() macro

When looking for the available scale or oversampling ratio, it is better
to use the find_closest() macro. This simplifies the code and also does
not require an exact value to be entered from the user space.

Signed-off-by: Stefan Popa <stefan.popa@analog.com>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
drivers/staging/iio/adc/ad7606.c