aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/iio/common
diff options
context:
space:
mode:
authorDenis CIOCCA <denis.ciocca@st.com>2014-10-03 11:35:41 -0400
committerJonathan Cameron <jic23@kernel.org>2014-10-04 06:26:21 -0400
commit7be178bb48bc3ed5af2f6cfdb69074dba4bd87b9 (patch)
treed496c59b2d909757276601a35c722b830f81e955 /drivers/iio/common
parenta1dcf42927a3eebe749b14178441889ef3887ceb (diff)
iio:common: Set the device pointer into ST common sensors library
Signed-off-by: Denis Ciocca <denis.ciocca@st.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org>
Diffstat (limited to 'drivers/iio/common')
-rw-r--r--drivers/iio/common/st_sensors/st_sensors_i2c.c1
-rw-r--r--drivers/iio/common/st_sensors/st_sensors_spi.c1
2 files changed, 2 insertions, 0 deletions
diff --git a/drivers/iio/common/st_sensors/st_sensors_i2c.c b/drivers/iio/common/st_sensors/st_sensors_i2c.c
index bb6f3085f57b..98cfee296d46 100644
--- a/drivers/iio/common/st_sensors/st_sensors_i2c.c
+++ b/drivers/iio/common/st_sensors/st_sensors_i2c.c
@@ -72,6 +72,7 @@ void st_sensors_i2c_configure(struct iio_dev *indio_dev,
72 indio_dev->dev.parent = &client->dev; 72 indio_dev->dev.parent = &client->dev;
73 indio_dev->name = client->name; 73 indio_dev->name = client->name;
74 74
75 sdata->dev = &client->dev;
75 sdata->tf = &st_sensors_tf_i2c; 76 sdata->tf = &st_sensors_tf_i2c;
76 sdata->get_irq_data_ready = st_sensors_i2c_get_irq; 77 sdata->get_irq_data_ready = st_sensors_i2c_get_irq;
77} 78}
diff --git a/drivers/iio/common/st_sensors/st_sensors_spi.c b/drivers/iio/common/st_sensors/st_sensors_spi.c
index 251baf6abc25..78a6a1ab3ece 100644
--- a/drivers/iio/common/st_sensors/st_sensors_spi.c
+++ b/drivers/iio/common/st_sensors/st_sensors_spi.c
@@ -111,6 +111,7 @@ void st_sensors_spi_configure(struct iio_dev *indio_dev,
111 indio_dev->dev.parent = &spi->dev; 111 indio_dev->dev.parent = &spi->dev;
112 indio_dev->name = spi->modalias; 112 indio_dev->name = spi->modalias;
113 113
114 sdata->dev = &spi->dev;
114 sdata->tf = &st_sensors_tf_spi; 115 sdata->tf = &st_sensors_tf_spi;
115 sdata->get_irq_data_ready = st_sensors_spi_get_irq; 116 sdata->get_irq_data_ready = st_sensors_spi_get_irq;
116} 117}