Staging: iio: meter: ade7758_core: implement IIO_CHAN_INFO_SAMP_FREQ
authorSandhya Bankar <bankarsandhya512@gmail.com>
Mon, 3 Oct 2016 20:59:06 +0000 (02:29 +0530)
committerJonathan Cameron <jic23@kernel.org>
Tue, 11 Oct 2016 18:40:25 +0000 (19:40 +0100)
commit73d2ad96fd9cdb8efff6844368610dcb72dcf7ba
tree9dcbd0bf4b4a5df43f0d0c30e22a0d9111dbde6c
parenteceb04609b3f7dc79b41e46ca7da7df85e0bd8fa
Staging: iio: meter: ade7758_core: implement IIO_CHAN_INFO_SAMP_FREQ

This driver predates the availability of IIO_CHAN_INFO_SAMP_FREQ attribute
wherein usage has some advantages like it can be accessed by in-kernel
consumers as well as reduces the code size.

Hence moving functionality from IIO_DEV_ATTR_SAMP_FREQ attribute into
IIO_CHAN_INFO_SAMP_FREQ handlers. Also Adding ade7758_read_raw() and
ade7758_write_raw() to allow reading/writing the element as well.

Signed-off-by: Sandhya Bankar <bankarsandhya512@gmail.com>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
drivers/staging/iio/meter/ade7758_core.c