Commit 1dcc3ed4 authored by Greg Kroah-Hartman's avatar Greg Kroah-Hartman
Browse files

Merge tag 'iio-for-5.1a' of...

Merge tag 'iio-for-5.1a' of git://git.kernel.org/pub/scm/linux/kernel/git/jic23/iio into staging-next

Jonathan writes:

First set of new device support, features and cleanup for IIO in the 5.1 cycle

A number of interesting new devices supported plus a good set of staging
cleanup including one graduation and one drop.

New device support
* ad56886
  - Add support for AD5674R/AD5679R with some minor driver changes to support
    more channels.
* ad7768
  - New driver and dt bindings for this 24 bit ADC.
* max44009
  - New driver and dt bindings for this ambient light sensor.
* mpu6050
  - Support the ICM 20602 IMU. Minor tweaks due to slightly different
    register map.
* NPCM adc
  - New driver and dt bindings for this BMC ADC.
* Sensiron SGP30
  - Modifiers for ethanol and H2.
  - New driver and dt bindings.
  - Follow patch added self cleaning support.
* Sensiron SPS30
  - New channel type for mass concentration.
  - New driver and bindings.
  - Minor tidy up patch followed (drop fmt specifier as unused)
* st_pressure
  - lps22hh support. ID plus information structures and dt bindings.
* ti-ads124s08
  - Add binding doc and driver.

Staging graduations
* ad7606 driver and bindings.

Staging drops
* ad7152 CDC driver dropped.  This part is near EoL and no one is known
  to be using it.  If anyone surfaces obviously we can bring the driver
  back.  If not, good to drop it to avoid wasting anyone's time cleaning
  it up.

New features
* bme680
  - DT support and bindings doc.
* isl29018
  - Add regulator for VCC.
* mag3110
  - Add regulators for supplies.
* meson-saradc
  - Support the temperature sensors of more SoCs.
* mma8452
  - Add regulators for power suplies and binding docs to reflect them.
* st-accel
  - Support the undocumented but it seems fairly common _ONT ACPI method
    to specify orientation of the sensor.

Cleanup, minor fixes and fixes for staging driver that have been broken a
long time
* ad5933
  - Drop platform data alternative to specifying the reference voltage
    using a regulator.
  - Use the clock framework to contorl the reference clock.
  - Add a DT binding doc to cover the defacto binding.
* ad7280a
  - Split up some big functions to improve readability.
* ad7606
  - Allow for timeout if interrupt never occurs.
  - Use devm functions to simplify probe and remove.
  - Use the find_closest macro to avoid need for precise values from
    userspace.
  - Add missing vendor prefixes for various DT properties. Note the
    driver is in staging still and there are no known devicetrees.
  - Add explict OF device ID table.
  - Simplify the Kconfig choices
  - Change to a threaded IRQ.
  - SPDX and simple stype fixes.
* ad7816
  - Drop unnecessary variable init.
* ad9523
  - Check a return value that was ignored.
* ad9833
  - Drop platform data.  It was just setting most values to the hardware
    defaults.
  - Use the clock framework to provide the input clock.
* adt7316 (lots of staging cleanup)
  - Fix some wrong register / bit definitions
  - Invert the logic of the check for an ldac pin so it actually makes sense.
  - Read the right register to get internal vref settings
  - Allow adt751x chips to use the internal vref for all DAC channels rather
    than a subset.
  - Remove dac vref bypass control from parts that don't have one.
  - Make the store DAC update mode function consistent with the show one.
  - Fix some spellings and other minor tidy up.
  - Avoid passing irq numbers around by putting all the irq logic in
    one place.
  - Fix an issue with the resolution of DAC control.
  - Fix support of the high resolution DAC mode (for temp proportional output)
    where supported.
  - Fix DAC read and write calculations.
* st_lsm6dsx
  - Drop an unused variable (set but not read)
* xilinx-xadc
  - Check an unhandled return value.

* tag 'iio-for-5.1a' of git://git.kernel.org/pub/scm/linux/kernel/git/jic23/iio: (67 commits)
  iio: chemical: sps30: remove printk format specifier
  staging: iio: frequency: ad9833: Load clock using clock framework
  staging: iio: frequency: ad9833: Get frequency value statically
  dt-bindings: iio: light: Add max44009
  iio: light: add driver for MAX44009
  dt-bindings: iio: adc: Add docs for AD7768-1
  iio: adc: Add AD7768-1 ADC basic support
  staging: iio: cdc: ad7152: remove driver completely
  iio: imu: mpu6050: Add support for the ICM 20602 IMU
  dt-bindings: iio: imu: add icm20602 bindings to mpu6050
  dt-bindings: iio: pressure: add LPS22HH bindings
  iio: st_accel: use ACPI orientation data
  iio: adc: add NPCM ADC driver
  dt-binding: iio: add NPCM ADC documentation
  iio: chemical: sps30: allow changing self cleaning period
  dt-bindings: iio: chemical: Add bindings for bme680
  iio: chemical: bme680: Add device-tree support
  iio:st_pressure:initial lps22hh sensor support
  iio: accell: mma8452: add vdd/vddio regulator operation support
  dt-bindings: iio: accel: mma8452: add power supplies property
  ...
parents 1c516c54 3fa30bf7
Loading
Loading
Loading
Loading
+20 −1
Original line number Diff line number Diff line
@@ -1554,6 +1554,10 @@ What: /sys/bus/iio/devices/iio:deviceX/in_concentration_raw
What:		/sys/bus/iio/devices/iio:deviceX/in_concentrationX_raw
What:		/sys/bus/iio/devices/iio:deviceX/in_concentration_co2_raw
What:		/sys/bus/iio/devices/iio:deviceX/in_concentrationX_co2_raw
What:		/sys/bus/iio/devices/iio:deviceX/in_concentration_ethanol_raw
What:		/sys/bus/iio/devices/iio:deviceX/in_concentrationX_ethanol_raw
What:		/sys/bus/iio/devices/iio:deviceX/in_concentration_h2_raw
What:		/sys/bus/iio/devices/iio:deviceX/in_concentrationX_h2_raw
What:		/sys/bus/iio/devices/iio:deviceX/in_concentration_voc_raw
What:		/sys/bus/iio/devices/iio:deviceX/in_concentrationX_voc_raw
KernelVersion:	4.3
@@ -1685,3 +1689,18 @@ Contact: linux-iio@vger.kernel.org
Description:
		Raw (unscaled) phase difference reading from channel Y
		that can be processed to radians.

What:		/sys/bus/iio/devices/iio:deviceX/in_massconcentration_pm1_input
What:		/sys/bus/iio/devices/iio:deviceX/in_massconcentrationY_pm1_input
What:		/sys/bus/iio/devices/iio:deviceX/in_massconcentration_pm2p5_input
What:		/sys/bus/iio/devices/iio:deviceX/in_massconcentrationY_pm2p5_input
What:		/sys/bus/iio/devices/iio:deviceX/in_massconcentration_pm4_input
What:		/sys/bus/iio/devices/iio:deviceX/in_massconcentrationY_pm4_input
What:		/sys/bus/iio/devices/iio:deviceX/in_massconcentration_pm10_input
What:		/sys/bus/iio/devices/iio:deviceX/in_massconcentrationY_pm10_input
KernelVersion:	4.22
Contact:	linux-iio@vger.kernel.org
Description:
		Mass concentration reading of particulate matter in ug / m3.
		pmX consists of particles with aerodynamic diameter less or
		equal to X micrometers.
+28 −0
Original line number Diff line number Diff line
What:		/sys/bus/iio/devices/iio:deviceX/start_cleaning
Date:		December 2018
KernelVersion:	4.22
Contact:	linux-iio@vger.kernel.org
Description:
		Writing 1 starts sensor self cleaning. Internal fan accelerates
		to its maximum speed and keeps spinning for about 10 seconds in
		order to blow out accumulated dust.

What:		/sys/bus/iio/devices/iio:deviceX/cleaning_period
Date:		January 2019
KernelVersion:	5.1
Contact:	linux-iio@vger.kernel.org
Description:
		Sensor is capable of triggering self cleaning periodically.
		Period can be changed by writing a new value here. Upon reading
		the current one is returned. Units are seconds.

		Writing 0 disables periodical self cleaning entirely.

What:		/sys/bus/iio/devices/iio:deviceX/cleaning_period_available
Date:		January 2019
KernelVersion:	5.1
Contact:	linux-iio@vger.kernel.org
Description:
		The range of available values in seconds represented as the
		minimum value, the step and the maximum value, all enclosed in
		square brackets.
+4 −0
Original line number Diff line number Diff line
@@ -20,6 +20,10 @@ Optional properties:
  - interrupt-names: should contain "INT1" and/or "INT2", the accelerometer's
		     interrupt line in use.

  - vdd-supply: phandle to the regulator that provides vdd power to the accelerometer.

  - vddio-supply: phandle to the regulator that provides vddio power to the accelerometer.

Example:

	mma8453fc@1d {
+65 −0
Original line number Diff line number Diff line
Analog Devices AD7606 Simultaneous Sampling ADC

Required properties for the AD7606:

- compatible: Must be one of
	* "adi,ad7605-4"
	* "adi,ad7606-8"
	* "adi,ad7606-6"
	* "adi,ad7606-4"
- reg: SPI chip select number for the device
- spi-max-frequency: Max SPI frequency to use
	see: Documentation/devicetree/bindings/spi/spi-bus.txt
- spi-cpha: See Documentation/devicetree/bindings/spi/spi-bus.txt
- avcc-supply: phandle to the Avcc power supply
- interrupts: IRQ line for the ADC
	see: Documentation/devicetree/bindings/interrupt-controller/interrupts.txt
- adi,conversion-start-gpios: must be the device tree identifier of the CONVST pin.
		  This logic input is used to initiate conversions on the analog
		  input channels. As the line is active high, it should be marked
		  GPIO_ACTIVE_HIGH.

Optional properties:

- reset-gpios: must be the device tree identifier of the RESET pin. If specified,
	       it will be asserted during driver probe. As the line is active high,
	       it should be marked GPIO_ACTIVE_HIGH.
- standby-gpios: must be the device tree identifier of the STBY pin. This pin is used
		to place the AD7606 into one of two power-down modes, Standby mode or
		Shutdown mode. As the line is active low, it should be marked
		GPIO_ACTIVE_LOW.
- adi,first-data-gpios: must be the device tree identifier of the FRSTDATA pin.
		    The FRSTDATA output indicates when the first channel, V1, is
		    being read back on either the parallel, byte or serial interface.
		    As the line is active high, it should be marked GPIO_ACTIVE_HIGH.
- adi,range-gpios: must be the device tree identifier of the RANGE pin. The polarity on
	      this pin determines the input range of the analog input channels. If
	      this pin is tied to a logic high, the analog input range is ±10V for
	      all channels. If this pin is tied to a logic low, the analog input range
	      is ±5V for all channels. As the line is active high, it should be marked
	      GPIO_ACTIVE_HIGH.
- adi,oversampling-ratio-gpios: must be the device tree identifier of the over-sampling
				mode pins. As the line is active high, it should be marked
				GPIO_ACTIVE_HIGH.

Example:

	adc@0 {
		compatible = "adi,ad7606-8";
		reg = <0>;
		spi-max-frequency = <1000000>;
		spi-cpol;

		avcc-supply = <&adc_vref>;

		interrupts = <25 IRQ_TYPE_EDGE_FALLING>;
		interrupt-parent = <&gpio>;

		adi,conversion-start-gpios = <&gpio 17 GPIO_ACTIVE_HIGH>;
		reset-gpios = <&gpio 27 GPIO_ACTIVE_HIGH>;
		adi,first-data-gpios = <&gpio 22 GPIO_ACTIVE_HIGH>;
		adi,oversampling-ratio-gpios = <&gpio 18 GPIO_ACTIVE_HIGH
						&gpio 23 GPIO_ACTIVE_HIGH
						&gpio 26 GPIO_ACTIVE_HIGH>;
		standby-gpios = <&gpio 24 GPIO_ACTIVE_LOW>;
	};
+41 −0
Original line number Diff line number Diff line
Analog Devices AD7768-1 ADC device driver

Required properties for the AD7768-1:

- compatible: Must be "adi,ad7768-1"
- reg: SPI chip select number for the device
- spi-max-frequency: Max SPI frequency to use
	see: Documentation/devicetree/bindings/spi/spi-bus.txt
- clocks: phandle to the master clock (mclk)
	see: Documentation/devicetree/bindings/clock/clock-bindings.txt
- clock-names: Must be "mclk".
- interrupts: IRQ line for the ADC
	see: Documentation/devicetree/bindings/interrupt-controller/interrupts.txt
- vref-supply: vref supply can be used as reference for conversion
- adi,sync-in-gpios: must be the device tree identifier of the SYNC-IN pin. Enables
	synchronization of multiple devices that require simultaneous sampling.
	A pulse is always required if the configuration is changed in any way, for example
	if the filter decimation rate changes. As the line is active low, it should
	be marked GPIO_ACTIVE_LOW.

Optional properties:

 - reset-gpios : GPIO spec for the RESET pin. If specified, it will be asserted during
	driver probe. As the line is active low, it should be marked GPIO_ACTIVE_LOW.

Example:

	adc@0 {
		compatible = "adi,ad7768-1";
		reg = <0>;
		spi-max-frequency = <2000000>;
		spi-cpol;
		spi-cpha;
		vref-supply = <&adc_vref>;
		interrupts = <25 IRQ_TYPE_EDGE_RISING>;
		interrupt-parent = <&gpio>;
		adi,sync-in-gpios = <&gpio 22 GPIO_ACTIVE_LOW>;
		reset-gpios = <&gpio 27 GPIO_ACTIVE_LOW>;
		clocks = <&ad7768_mclk>;
		clock-names = "mclk";
	};
Loading