- 03 Sep, 2020 35 commits
-
-
Krzysztof Kozlowski authored
Common pattern of handling deferred probe can be simplified with dev_err_probe(). Less code and also it prints the error value. Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org> Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com> Link: https://lore.kernel.org/r/20200829064726.26268-2-krzk@kernel.orgSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Krzysztof Kozlowski authored
Common pattern of handling deferred probe can be simplified with dev_err_probe(). Less code and also it prints the error value. Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org> Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com> Link: https://lore.kernel.org/r/20200829064726.26268-1-krzk@kernel.orgSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Matt Ranostay authored
Add support for atlas,hum-ezo / humidity sensor which with scaling provides respective data in millipercent Signed-off-by: Matt Ranostay <matt.ranostay@konsulko.com> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Matt Ranostay authored
Cc: devicetree@vger.kernel.org Signed-off-by: Matt Ranostay <matt.ranostay@konsulko.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Tian Tao authored
Use kobj_to_dev() instead of container_of() Signed-off-by: Tian Tao <tiantao6@hisilicon.com> Acked-by: Alexandru Ardelean <alexandru.ardelean@analog.com> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Rikard Falkeborn authored
These are never modified and can be made const to allow the compiler to put it in read-only memory. Before: text data bss dec hex filename 6642 12608 64 19314 4b72 drivers/iio/dac/ad5686.o After: text data bss dec hex filename 16946 2304 64 19314 4b72 drivers/iio/dac/ad5686.o Signed-off-by: Rikard Falkeborn <rikard.falkeborn@gmail.com> Acked-by: Alexandru Ardelean <alexandru.ardelean@analog.com> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Chris Ruehl authored
Conversion of the ltc2632 to yaml format and name the file to 'lltc,ltc2632.yaml'. Signed-off-by: Chris Ruehl <chris.ruehl@gtsys.com.hk> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Christian Eggers authored
The driver for the as73211 light sensor provides the following not yet documented sysfs entries: - in_intensity_(x|y|z)_raw - in_intensity_(x|y|z)_scale - in_intensity_sampling_frequency(_available) - in_intensity_hardwaregain(_available) - in_intensity_integration_time Signed-off-by: Christian Eggers <ceggers@arri.de> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Jonathan Cameron authored
Whilst fairly unlikely anyone will ever use this driver with anything other than DT, we are trying to move IIO over to the generic interfaces where easy to do so. In this case this involved moving to generic check on presence of fwnode, generic device_get_match_data() and dropping the of_match_ptr protection. Also relevant header changes to have property.h and mod_devicetable.h only. Also drop the casting away of a const in favour of retaining the const throughout. Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com> Cc: Quentin Schulz <quentin.schulz@bootlin.com> Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com>
-
Ahmad Fatoum authored
This fixes some typos found while browsing the documentation. Cc: trivial@kernel.org Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Matt Ranostay authored
Update email to author's current employer Signed-off-by: Matt Ranostay <matt.ranostay@konsulko.com> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Jonathan Cameron authored
We have no known users of these in the wild. it seems very unlikely these are real IDs having the form ADCXXXX as that ID is owned by Achnor Datacomm not TI. Suggested-by: Andy Shevchenko <andy.shevchenko@gmail.com> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com> Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com>
-
Jonathan Cameron authored
I'm trying to clean this (now) anti-pattern out of IIO to avoid cut and paste into new drivers. Also add an include of mod_devicetable.h as the driver directly uses struct of_device_id which is defined in there. Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com> Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com> Cc: Jan Kiszka <jan.kiszka@siemens.com>
-
Jonathan Cameron authored
There is no real advantage in having these protections and for parts that do not have an explicit ACPI ID, it prevents the use of PRP0001. I'm trying to clear this out of IIO in general to avoid copying in new drivers. Include mod_devicetable.h as we are using of_device_id in here so including that header is best practice. Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com> Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com> Cc: Angelo Compagnucci <angelo.compagnucci@gmail.com>
-
Jonathan Cameron authored
This driver cannot be instantiated from ACPI due to it's use of syscon_regmap_lookup_by_phandle() but in the interests of clearing this anti pattern out of IIO, let us switch to an explicit check in Kconfig and remove the protections on the of_match_table The switch of header is because we only use of_device_id in here and that is defined in mod_devicetable.h not of.h. Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com> Cc: Raveendra Padasalagi <raveendra.padasalagi@broadcom.com> Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com>
-
Vincent Whitchurch authored
The driver currently only allows channel 0 to be powered down but the multi-channel variants of the hardware allow each channel to be powered down separately and with separate power down modes. Add support for this. Signed-off-by: Vincent Whitchurch <vincent.whitchurch@axis.com> Acked-by: Sean Nyekjaer <sean@geanix.com> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Eugene Zaikonnikov authored
Add device tree bindings for HDC2010/HDC2080 family of humidity and temperature sensors. Signed-off-by: Eugene Zaikonnikov <ez@norphonic.com> Reviewed-by: Rob Herring <robh@kernel.org> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Eugene Zaikonnikov authored
Add driver support for HDC2010/2080 series devices and sysfs documentation for their heater element. HDC2010 is an integrated high-accuracy humidity and temperature sensor with very low power consumption. The device includes a resistive heating element. The temperature range is -40C to 125C with 0.2C accuracy. Humidity measurement is 0 to 100% with 2% RH accuracy. Signed-off-by: Eugene Zaikonnikov <ez@norphonic.com> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Stephen Boyd authored
We shouldn't need to set default irq trigger flags here as the firmware should have properly indicated the trigger type, i.e. level low, in the DT or ACPI tables. Signed-off-by: Stephen Boyd <swboyd@chromium.org> Signed-off-by: Daniel Campello <campello@chromium.org> Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Stephen Boyd authored
Enable the main power supply (vdd) and digital IO power supply (svdd) during probe so that the i2c communication and device works properly on boards that aggressively power gate these supplies. Signed-off-by: Stephen Boyd <swboyd@chromium.org> Reviewed-by: Douglas Anderson <dianders@chromium.org> Signed-off-by: Daniel Campello <campello@chromium.org> Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Stephen Boyd authored
This struct member isn't used. Drop it. Fixes: 72ad02b1 ("iio: Add SEMTECH SX9310/9311 sensor driver") Signed-off-by: Stephen Boyd <swboyd@chromium.org> Reviewed-by: Douglas Anderson <dianders@chromium.org> Reviewed-by: Daniel Campello <campello@chromium.org> Signed-off-by: Daniel Campello <campello@chromium.org> Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Daniel Campello authored
Miscellaneous format fixes throughout the whole file. Signed-off-by: Daniel Campello <campello@chromium.org> Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com> Reviewed-by: Stephen Boyd <swboyd@chromium.org> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Daniel Campello authored
Improves readability by storing &client->dev in a local variable. Signed-off-by: Daniel Campello <campello@chromium.org> Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com> Reviewed-by: Stephen Boyd <swboyd@chromium.org> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Daniel Campello authored
Checks for non-zero return values to signal error conditions. Signed-off-by: Daniel Campello <campello@chromium.org> Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com> Reviewed-by: Stephen Boyd <swboyd@chromium.org> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Daniel Campello authored
Fixes wrong copyright year. Signed-off-by: Daniel Campello <campello@chromium.org> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Daniel Campello authored
Simplify compensation stage by using regmap_read_poll_timeout(). Signed-off-by: Daniel Campello <campello@chromium.org> Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com> Reviewed-by: Stephen Boyd <swboyd@chromium.org> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Daniel Campello authored
Uses for_each_set_bit() macro to loop over channel bitmaps. Signed-off-by: Daniel Campello <campello@chromium.org> Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com> Reviewed-by: Stephen Boyd <swboyd@chromium.org> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Daniel Campello authored
Makes use __aligned(8) to ensure that the timestamp is correctly aligned when we call io_push_to_buffers_with_timestamp(). Also makes use of sizeof() for regmap_bulk_read instead of static value. Signed-off-by: Daniel Campello <campello@chromium.org> Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Daniel Campello authored
Uses .probe_new in place of .probe. Also uses device_get_match_data() for whoami matching. Signed-off-by: Daniel Campello <campello@chromium.org> Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com> Reviewed-by: Stephen Boyd <swboyd@chromium.org> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Daniel Campello authored
Avoids unused warnings due to acpi/of table macros. Reported-by: kbuild test robot <lkp@intel.com> Signed-off-by: Daniel Campello <campello@chromium.org> Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com> Reviewed-by: Stephen Boyd <swboyd@chromium.org> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Daniel Campello authored
Fixes enable/disable irq handling at various points. The driver needs to only enable/disable irqs if there is an actual irq handler installed. Signed-off-by: Daniel Campello <campello@chromium.org> Reviewed-by: Stephen Boyd <swboyd@chromium.org> Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Daniel Campello authored
Follows spec sheet for macro declarations. Signed-off-by: Daniel Campello <campello@chromium.org> Reviewed-by: Stephen Boyd <swboyd@chromium.org> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Daniel Campello authored
Adds device tree bindings for sx9310 sensor. Signed-off-by: Daniel Campello <campello@chromium.org> Cc: Hartmut Knaack <knaack.h@gmx.de> Cc: Lars-Peter Clausen <lars@metafoo.de> Cc: Peter Meerwald-Stadler <pmeerw@pmeerw.net> Cc: Rob Herring <robh+dt@kernel.org> Reviewed-by: Douglas Anderson <dianders@chromium.org> [swboyd@chromium.org: Add both regulators and make them optional] Signed-off-by: Stephen Boyd <swboyd@chromium.org> Reviewed-by: Rob Herring <robh@kernel.org> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Jonathan Cameron authored
Simple device with a simple conversion. Special handling needed for the max1118 which is the only supported part that has an external reference voltage. Cc: Akinobu Mita <akinobu.mita@gmail.com> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com> Reviewed-by: Rob Herring <robh@kernel.org>
-
Christian Eggers authored
Support for AMS AS73211 JENCOLOR(R) Digital XYZ Sensor. This driver has no built-in trigger. In order for making triggered measurements, an external (software) trigger driver like iio-trig-hrtimer or iio-trig-sysfs is required. The sensor supports single and continuous measurement modes. The latter is not used by design as this would require tight timing synchronization between hardware and driver without much benefit. Datasheet: https://ams.com/documents/20143/36005/AS73211_DS000556_3-01.pdfSigned-off-by: Christian Eggers <ceggers@arri.de> Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
- 22 Aug, 2020 5 commits
-
-
Christian Eggers authored
Add DT bindings for AMS AS73211 XYZ True Color Sensor. Signed-off-by: Christian Eggers <ceggers@arri.de> Reviewed-by: Rob Herring <robh@kernel.org> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Calvin Glisson authored
Remove excess blank line after variable declarations. Improves code consistency and readability. Change suggested by checkpatch.pl: CHECK: Please don't use multiple blank lines Signed-off-by: Calvin Glisson <taragaram@gmail.com> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Randy Dunlap authored
Drop the repeated word "and" in a comment. Signed-off-by: Randy Dunlap <rdunlap@infradead.org> Cc: Lars-Peter Clausen <lars@metafoo.de> Cc: Jonathan Cameron <jic23@kernel.org> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Jonathan Cameron authored
Straight forward conversion of this binding for this current sense amplifier and ADC. Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com> Reviewed-by: Jacopo Mondi <jacopo@jmondi.org> Reviewed-by: Rob Herring <robh@kernel.org>
-
Jonathan Cameron authored
Straight forward conversion for this SPI ADC. Added limits on spi-max-frequency from datasheet (0.1 to 4.8MHz) Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com> Reviewed-by: Jacopo Mondi <jacopo@jmondi.org> Reviewed-by: Rob Herring <robh@kernel.org>
-