iio: move 3-wire spi initialization to st_sensors_spi
authorDenis Ciocca <denis.ciocca@st.com>
Thu, 18 Jul 2019 22:53:52 +0000 (15:53 -0700)
committerJonathan Cameron <Jonathan.Cameron@huawei.com>
Sat, 27 Jul 2019 21:52:06 +0000 (22:52 +0100)
commit1ecd245e0eb23d1c3803474eba75589743d0d1fe
tree4bb5bd28226e91b1a69bcb8a6b556dd29a245697
parent570c2c55ef364ef6aed531e554be4c989fb1a49c
iio: move 3-wire spi initialization to st_sensors_spi

Some devices need to be configured with special bit in order to
use spi 3-wire. This was done during device identification phase.
Instead, let's move this part as spi specific.
Doing this the check_device_support function becomes a simple
device id check, so let's rename it.

Signed-off-by: Denis Ciocca <denis.ciocca@st.com>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
12 files changed:
drivers/iio/accel/st_accel_core.c
drivers/iio/accel/st_accel_spi.c
drivers/iio/common/st_sensors/st_sensors_core.c
drivers/iio/common/st_sensors/st_sensors_spi.c
drivers/iio/gyro/st_gyro_core.c
drivers/iio/gyro/st_gyro_spi.c
drivers/iio/magnetometer/st_magn_core.c
drivers/iio/magnetometer/st_magn_spi.c
drivers/iio/pressure/st_pressure_core.c
drivers/iio/pressure/st_pressure_spi.c
include/linux/iio/common/st_sensors.h
include/linux/iio/common/st_sensors_spi.h