History log of /linux-master/drivers/iio/pressure/ms5637.c
Revision Date Author Comments
# 22da192f 03-Sep-2023 Biju Das <biju.das.jz@bp.renesas.com>

iio: pressure: ms5637: Use i2c_get_match_data()

Simplify probe() by replacing id lookup for retrieving match data and
device_get_match_data() by i2c_get_match_data().

Signed-off-by: Biju Das <biju.das.jz@bp.renesas.com>
Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Link: https://lore.kernel.org/r/20230903145926.66855-1-biju.das.jz@bp.renesas.com
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>


# 7cf15f42 15-May-2023 Uwe Kleine-König <u.kleine-koenig@pengutronix.de>

iio: Switch i2c drivers back to use .probe()

After commit b8a1a4cd5a98 ("i2c: Provide a temporary .probe_new()
call-back type"), all drivers being converted to .probe_new() and then
03c835f498b5 ("i2c: Switch .probe() to not take an id parameter") convert
back to (the new) .probe() to be able to eventually drop .probe_new() from
struct i2c_driver.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Link: https://lore.kernel.org/r/20230515205048.19561-1-u.kleine-koenig@pengutronix.de
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>


# f80ccc71 18-Nov-2022 Uwe Kleine-König <u.kleine-koenig@pengutronix.de>

iio: pressure: ms5637: Convert to i2c's .probe_new()

.probe_new() doesn't get the i2c_device_id * parameter, so determine
that explicitly in the probe function.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Link: https://lore.kernel.org/r/20221118224540.619276-176-uwe@kleine-koenig.org
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>


# a7f6cecf 30-Jan-2022 Jonathan Cameron <Jonathan.Cameron@huawei.com>

iio:common:meas-spec: Move exports into IIO_MEAS_SPEC_SENSORS

The obvious choice of ms_sensors felt rather too likely to clash with other
namespaces introduced in future, hence the longer abbreviation.

In order to avoid unnecessary pollution of the global symbol namespace
move the common/library functions into a specific namespace and import
that into the various specific device drivers that use them.

For more information see https://lwn.net/Articles/760045/

Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Cc: Alexandre Belloni <alexandre.belloni@bootlin.com>
Cc: William Markezana <william.markezana@meas-spec.com>
Cc: Ludovic Tancerel <ludovic.tancerel@maplehightech.com>
Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com>
Link: https://lore.kernel.org/r/20220130205701.334592-5-jic23@kernel.org


# 649ef114 09-Jan-2021 Alexandre Belloni <alexandre.belloni@bootlin.com>

iio:pressure:ms5637: add ms5803 support

The ms5803 is very similar to the ms5805 but has less resolution options
and has the 128bit PROM layout.

Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
Acked-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/20210109231148.1168104-7-alexandre.belloni@bootlin.com
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>


# 07498719 09-Jan-2021 Alexandre Belloni <alexandre.belloni@bootlin.com>

iio:pressure:ms5637: limit available sample frequencies

Avoid exposing all the sampling frequencies for chip that only support a
subset.

Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
Link: https://lore.kernel.org/r/20210109231148.1168104-4-alexandre.belloni@bootlin.com
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>


# 8c125f5f 09-Jan-2021 Alexandre Belloni <alexandre.belloni@bootlin.com>

iio:pressure:ms5637: introduce hardware differentiation

Some sensors in the ms58xx family have a different PROM length and a
different number of available resolution. introduce struct ms_tp_hw_data to
handle those differences.

Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
Link: https://lore.kernel.org/r/20210109231148.1168104-3-alexandre.belloni@bootlin.com
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>


# 444f5f85 10-Sep-2020 Jonathan Cameron <Jonathan.Cameron@huawei.com>

iio:pressure:ms5637: Drop of_match_ptr protection

This prevents use of this driver with ACPI via PRP0001 and is
an example of an anti pattern I'm trying to remove from IIO.
Hence drop from this driver.

Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com>
Cc: Ludovic Tancerel <ludovic.tancerel@maplehightech.com>
Link: https://lore.kernel.org/r/20200910173242.621168-20-jic23@kernel.org


# d3be8324 22-May-2020 Alexandru Ardelean <alexandru.ardelean@analog.com>

iio: remove explicit IIO device parent assignment

This patch applies the semantic patch:
@@
expression I, P, SP;
@@
I = devm_iio_device_alloc(P, SP);
...
- I->dev.parent = P;

It updates 302 files and does 307 deletions.
This semantic patch also removes some comments like
'/* Establish that the iio_dev is a child of the i2c device */'

But this is is only done in case where the block is left empty.

The patch does not seem to cover all cases. It looks like in some cases a
different variable is used in some cases to assign the parent, but it
points to the same reference.
In other cases, the block covered by ... may be just too big to be covered
by the semantic patch.

However, this looks pretty good as well, as it does cover a big bulk of the
drivers that should remove the parent assignment.

Signed-off-by: Alexandru Ardelean <alexandru.ardelean@analog.com>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>


# fda8d26e 28-May-2019 Thomas Gleixner <tglx@linutronix.de>

treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 177

Based on 1 normalized pattern(s):

licensed under the gpl 2

extracted by the scancode license scanner the SPDX license identifier

GPL-2.0-only

has been chosen to replace the boilerplate/reference in 135 file(s).

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Reviewed-by: Allison Randal <allison@lohutok.net>
Reviewed-by: Richard Fontana <rfontana@redhat.com>
Reviewed-by: Alexios Zavras <alexios.zavras@intel.com>
Reviewed-by: Steve Winslow <swinslow@gmail.com>
Cc: linux-spdx@vger.kernel.org
Link: https://lkml.kernel.org/r/20190528170026.071193225@linutronix.de
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>


# 6a15fef2 23-Jul-2017 Jonathan Cameron <jic23@kernel.org>

iio:pressure: drop assign iio_info.driver_module and iio_trigger_ops.owner

The equivalent of both of these are now done via macro magic when
the relevant register calls are made. The actual structure
elements will shortly go away.

Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Reviewed-by: Lars-Peter Clausen <lars@metafoo.de>


# 1813c713 13-Jun-2017 Manivannan Sadhasivam <mani@kernel.org>

iio: pressure: ms5637: Add OF match table

Add of_match_table for Measurement-Specialties MS5637, MS5805, MS5837 and MS8607 pressure & temperature sensor

Signed-off-by: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>


# 47146eb8 06-Jun-2016 Markezana, William <William.Markezana@te.com>

iio: ms5637 Add Measurement Specialties explicit MS5805 and MS5837 support

Signed-off-by: William Markezana <william.markezana@meas-spec.com>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>


# cdd469ad 16-May-2016 Javier Martinez Canillas <javier@osg.samsung.com>

iio: Export I2C module alias information

The I2C drivers have an i2c_device_id array but that information isn't
exported to the modules using the MODULE_DEVICE_TABLE() macro. So the
modules autoloading won't work if the I2C device is registered using
OF or legacy board files due missing alias information in the modules.

The issue was found using Kieran Bingham's coccinelle semantic patch:
https://lkml.org/lkml/2016/5/10/520

Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>


# f8d9d3b4 26-Feb-2016 Matt Ranostay <mranostay@gmail.com>

iio: convert to common i2c_check_functionality() return value

Previously most drivers that used a i2c_check_functionality() check
condition required various error codes on failure. This patchset
converts to a standard of -EOPNOTSUPP

Signed-off-by: Matt Ranostay <mranostay@gmail.com>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>


# 1b75ce65 01-Oct-2015 Ludovic Tancerel <ludovic.tancerel@maplehightech.com>

Add ms8607 meas-spec driver support

Support for MS8607 temperature, pressure & humidity sensor.
This part is using functions from MS5637 for temperature and pressure
and HTU21 for humidity

Signed-off-by: Ludovic Tancerel <ludovic.tancerel@maplehightech.com>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>


# 64a70c65 01-Oct-2015 Ludovic Tancerel <ludovic.tancerel@maplehightech.com>

Add ms5637 meas-spec driver support

Support for MS5637 temperature & pressure sensor

Signed-off-by: Ludovic Tancerel <ludovic.tancerel@maplehightech.com>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>