Commit cee4a593 authored by Jonathan Cameron's avatar Jonathan Cameron
Browse files

dt-bindings: iio: adc: ti,adc161s626 yaml conversion.



Simple conversion for this ADC driver.  Note that I haven't put
limits on the spi-max-sampling-frequency because the adc161s626
doesn't state one clearly defined value.

Added the #io-channel-cells property to allow for consumers.

Signed-off-by: default avatarJonathan Cameron <Jonathan.Cameron@huawei.com>
Reviewed-by: default avatarRob Herring <robh@kernel.org>
Acked-by: default avatarMatt Ranostay <matt.ranostay@konsulko.com>
Cc: Matt Ranostay <matt.ranostay@konsulko.com>
Link: https://lore.kernel.org/r/20200809111753.156236-6-jic23@kernel.org
parent b713259c
Loading
Loading
Loading
Loading
+51 −0
Original line number Diff line number Diff line
# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
%YAML 1.2
---
$id: http://devicetree.org/schemas/iio/adc/ti,adc161s626.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#

title: Texas Instruments ADC141S626 and ADC161S626 ADCs

maintainers:
  - Matt Ranostay <matt.ranostay@konsulko.com>

description: |
  Single channel 14/16bit differential ADCs

properties:
  compatible:
    enum:
      - ti,adc141s626
      - ti,adc161s626

  reg:
    maxItems: 1

  spi-max-frequency: true

  vdda-supply: true

  "#io-channel-cells":
    const: 1

required:
  - compatible
  - reg

additionalProperties: false

examples:
  - |
    spi {
        #address-cells = <1>;
        #size-cells = <0>;

        adc@0 {
            compatible = "ti,adc161s626";
            vdda-supply = <&vdda_fixed>;
            reg = <0>;
            spi-max-frequency = <4300000>;
            #io-channel-cells = <1>;
        };
    };
...
+0 −18
Original line number Diff line number Diff line
* Texas Instruments ADC141S626 and ADC161S626 chips

Required properties:
 - compatible: Should be "ti,adc141s626" or "ti,adc161s626"
 - reg: spi chip select number for the device
 - vdda-supply: supply voltage to VDDA pin

Recommended properties:
 - spi-max-frequency: Definition as per
		Documentation/devicetree/bindings/spi/spi-bus.txt

Example:
adc@0 {
	compatible = "ti,adc161s626";
	vdda-supply = <&vdda_fixed>;
	reg = <0>;
	spi-max-frequency = <4300000>;
};