summaryrefslogtreecommitdiffstats
path: root/drivers/iio/pressure/ms5611_i2c.c
diff options
context:
space:
mode:
authorTomasz Duszynski2015-06-23 20:45:48 +0200
committerJonathan Cameron2015-07-05 15:34:00 +0200
commit9690d81a02dc4eea78de1686c3bf23a8dd4c0f28 (patch)
treed4c0d6c0703927b9d0f4bf2d228833c676e25102 /drivers/iio/pressure/ms5611_i2c.c
parentiio: pressure: ms5611: remove IIO_CHAN_INFO_SCALE from mask (diff)
downloadkernel-qcow2-linux-9690d81a02dc4eea78de1686c3bf23a8dd4c0f28.tar.gz
kernel-qcow2-linux-9690d81a02dc4eea78de1686c3bf23a8dd4c0f28.tar.xz
kernel-qcow2-linux-9690d81a02dc4eea78de1686c3bf23a8dd4c0f28.zip
iio: pressure: ms5611: add support for MS5607 temperature and pressure sensor
MS5607 is temperature and pressure sensor which hardware is similar to MS5611. Both sensors share command protocol and support both I2C and SPI serial protocols. They only differ in compensation algorithms. Signed-off-by: Tomasz Duszynski <tduszyns@gmail.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org>
Diffstat (limited to 'drivers/iio/pressure/ms5611_i2c.c')
-rw-r--r--drivers/iio/pressure/ms5611_i2c.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/iio/pressure/ms5611_i2c.c b/drivers/iio/pressure/ms5611_i2c.c
index 748fd9acaad8..9d504f17669b 100644
--- a/drivers/iio/pressure/ms5611_i2c.c
+++ b/drivers/iio/pressure/ms5611_i2c.c
@@ -104,11 +104,12 @@ static int ms5611_i2c_probe(struct i2c_client *client,
st->read_adc_temp_and_pressure = ms5611_i2c_read_adc_temp_and_pressure;
st->client = client;
- return ms5611_probe(indio_dev, &client->dev);
+ return ms5611_probe(indio_dev, &client->dev, id->driver_data);
}
static const struct i2c_device_id ms5611_id[] = {
- { "ms5611", 0 },
+ { "ms5611", MS5611 },
+ { "ms5607", MS5607 },
{ }
};
MODULE_DEVICE_TABLE(i2c, ms5611_id);