iio: aspeed-adc: wait for initial sequence.
authorMykola Kostenok <c_mykolak@mellanox.com>
Mon, 17 Jul 2017 09:00:35 +0000 (12:00 +0300)
committerJonathan Cameron <Jonathan.Cameron@huawei.com>
Sun, 23 Jul 2017 11:02:40 +0000 (12:02 +0100)
commit737cc2a593782df6846b3cab7e0f64384f58364a
treefb69bf2503545ac7c43fc0cc045b902248ddbff0
parente59e18989c68a8d7941005f81ad6abc4ca682de0
iio: aspeed-adc: wait for initial sequence.

This patch enables adc engine at initialization time and waits
for the initial sequence completion before enabling adc channels.

Without this code adc channels are not functional and shows
zeros for all connected channels.

Tested on mellanox msn platform.

v1 -> v2:
Pointed by Rick Altherr:
 - Wait init sequence code enabled by bool
from OF match table.

Signed-off-by: Mykola Kostenok <c_mykolak@mellanox.com>
Reviewed-by: Rick Altherr <raltherr@google.com>
Cc: <Stable@vger.kernel.org>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
drivers/iio/adc/aspeed_adc.c