diff mbox series

[RFC,v2,1/3] iio: adc: ltc2496: provide device tree binding document

Message ID 20191114105159.14195-2-u.kleine-koenig@pengutronix.de (mailing list archive)
State New, archived
Headers show
Series iio: adc: add support for ltc2496 | expand

Commit Message

Uwe Kleine-König Nov. 14, 2019, 10:51 a.m. UTC
The ADC only requires the standard stuff for spi devices and a reference
voltage.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
---
Hello,

I didn't say anything about stuff like spi-max-frequency, spi-cpha etc
and even reg because I wonder if there is something I can write into the
document to just reference the generic spi device binding. So I marked
as RFC.

Best regards
Uwe
 .../bindings/iio/adc/lltc,ltc2496.yaml        | 30 +++++++++++++++++++
 1 file changed, 30 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/iio/adc/lltc,ltc2496.yaml
diff mbox series

Patch

diff --git a/Documentation/devicetree/bindings/iio/adc/lltc,ltc2496.yaml b/Documentation/devicetree/bindings/iio/adc/lltc,ltc2496.yaml
new file mode 100644
index 000000000000..e8acab5f04ec
--- /dev/null
+++ b/Documentation/devicetree/bindings/iio/adc/lltc,ltc2496.yaml
@@ -0,0 +1,30 @@ 
+# SPDX-License-Identifier: GPL-2.0
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/adc/lltc,ltc2496.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Linear Technology / Analog Devices LTC2496 ADC
+
+properties:
+  compatible:
+    enum:
+      - lltc,ltc2496
+
+  vref-supply:
+    description: phandle to an external regulator providing the reference voltage
+    allOf:
+      - $ref: /schemas/types.yaml#/definitions/phandle
+
+required:
+  - compatible
+  - vref-supply
+
+examples:
+  - |
+	adc@0 {
+		compatible = "lltc,ltc2496";
+		reg = <0>;
+		vref-supply = <&ltc249x_reg>;
+		spi-max-frequency = <2000000>;
+	};