iio: potentiometer: mcp4131: use of_device_get_match_data()
authorSlawomir Stepien <sst@poczta.fm>
Fri, 16 Nov 2018 09:47:21 +0000 (10:47 +0100)
committerJonathan Cameron <Jonathan.Cameron@huawei.com>
Fri, 16 Nov 2018 18:32:35 +0000 (18:32 +0000)
commit853bfaf43555e6352e4f9d7856603f6443292d05
treee5f8b8c7e1923f6f020a45a7202fb101523681f0
parentcc9c58ef6e0623f92edc2988c8a8ebfb63b40cea
iio: potentiometer: mcp4131: use of_device_get_match_data()

Try to get the device's data using OF API. In case of failure, fallback
to the spi_get_device_id() method.

Signed-off-by: Slawomir Stepien <sst@poczta.fm>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
drivers/iio/potentiometer/mcp4131.c