android_kernel_oneplus_msm8998/drivers/iio/accel
Michael Nosthoff 8e1f1062d9 iio: st_pressure: st_accel: pass correct platform data to init
commit 8b438686a001db64c21782d04ef68111e53c45d9 upstream.

Commit 7383d44b added a pointer pdata which get set to the default
platform_data when non was defined in the device. But it did not
pass this pointer to the st_sensors_init_sensor call but still
used the maybe uninitialized platform_data from dev.

This breaks initialization when no platform_data is given and
the optional st,drdy-int-pin devicetree option is not set.

This commit fixes this.

Cc: stable@vger.kernel.org
Fixes: 7383d44b ("iio: st_pressure: st_accel: Initialise sensor platform data properly")
Signed-off-by: Michael Nosthoff <committed@heine.so>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-03-28 18:40:12 +02:00
..
bma180.c
bmc150-accel-core.c
bmc150-accel-i2c.c
bmc150-accel-spi.c
bmc150-accel.h
hid-sensor-accel-3d.c
Kconfig
kxcjk-1013.c
kxsd9.c
Makefile
mma8452.c
mma9551.c
mma9551_core.c
mma9551_core.h
mma9553.c
mxc4005.c
ssp_accel_sensor.c
st_accel.h
st_accel_buffer.c
st_accel_core.c iio: st_pressure: st_accel: pass correct platform data to init 2018-03-28 18:40:12 +02:00
st_accel_i2c.c
st_accel_spi.c
stk8ba50.c
stk8312.c