iio: mxs-lradc: fix divider
authorRobert Hodaszi <robert.hodaszi@digi.com>
Mon, 6 Oct 2014 13:41:00 +0000 (14:41 +0100)
committerJonathan Cameron <jic23@kernel.org>
Sat, 14 Jun 2014 14:01:20 +0000 (15:01 +0100)
commit19bc4981a213d0c5b0e1e8b08815c0b26f01ec54
tree18bc6729e9190cf0536f20b8eed04133c9515ea5
parent8ba42fb7b17649c9ab5b5e79d4e90370a0b4645e
iio: mxs-lradc: fix divider

All channels' single measurement are happening on CH 0. So enabling / disabling
the divider once is not enough, because it has impact on all channels.

Set only a flag, then check this on each measurement, and enable / disable the
divider as required.

Signed-off-by: Robert Hodaszi <robert.hodaszi@digi.com>
Cc: Stable@vger.kernel.org
Acked-by: Alexandre Belloni <alexandre.belloni@free-electrons.com>
Acked-by: Marek Vasut <marex@denx.de>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
drivers/staging/iio/adc/mxs-lradc.c