diff options
author | Jonathan Cameron <Jonathan.Cameron@huawei.com> | 2020-10-31 19:48:31 +0100 |
---|---|---|
committer | Jonathan Cameron <Jonathan.Cameron@huawei.com> | 2020-11-22 18:55:06 +0100 |
commit | a7d6eb9dbb835f9c2bf6c75881bf163772a0ba9f (patch) | |
tree | 69d5538759ea6606a4f65689f2061ec1bb9d5632 /Documentation | |
parent | dt-bindings:iio:light:st,vl6180: txt to yaml format conversion. (diff) | |
download | linux-a7d6eb9dbb835f9c2bf6c75881bf163772a0ba9f.tar.xz linux-a7d6eb9dbb835f9c2bf6c75881bf163772a0ba9f.zip |
dt-bindings:iio:magnetometer:fsl,mag3110: txt to yaml conversion
Dropped a few bits of help text in here that didn't seem to add anything
that wasn't fairly obvious. Otherwise simple format conversion
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Reviewed-by: Rob Herring <robh@kernel.org>
Cc: Anson Huang <Anson.Huang@nxp.com>
Link: https://lore.kernel.org/r/20201031184854.745828-24-jic23@kernel.org
Diffstat (limited to 'Documentation')
-rw-r--r-- | Documentation/devicetree/bindings/iio/magnetometer/fsl,mag3110.yaml | 48 | ||||
-rw-r--r-- | Documentation/devicetree/bindings/iio/magnetometer/mag3110.txt | 27 |
2 files changed, 48 insertions, 27 deletions
diff --git a/Documentation/devicetree/bindings/iio/magnetometer/fsl,mag3110.yaml b/Documentation/devicetree/bindings/iio/magnetometer/fsl,mag3110.yaml new file mode 100644 index 000000000000..6b54d32323fc --- /dev/null +++ b/Documentation/devicetree/bindings/iio/magnetometer/fsl,mag3110.yaml @@ -0,0 +1,48 @@ +# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/iio/magnetometer/fsl,mag3110.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Freescale MAG3110 magnetometer sensor + +maintainers: + - Anson Huang <Anson.Huang@nxp.com> + +properties: + compatible: + const: fsl,mag3110 + + reg: + maxItems: 1 + + interrupts: + maxItems: 1 + + vdd-supply: true + + vddio-supply: true + +additionalProperties: false + +required: + - compatible + - reg + +examples: + - | + #include <dt-bindings/interrupt-controller/irq.h> + i2c { + #address-cells = <1>; + #size-cells = <0>; + + magnetometer@e { + compatible = "fsl,mag3110"; + reg = <0x0e>; + pinctrl-names = "default"; + pinctrl-0 = <&pinctrl_i2c3_mag3110_int>; + interrupt-parent = <&gpio3>; + interrupts = <16 IRQ_TYPE_EDGE_RISING>; + }; + }; +... diff --git a/Documentation/devicetree/bindings/iio/magnetometer/mag3110.txt b/Documentation/devicetree/bindings/iio/magnetometer/mag3110.txt deleted file mode 100644 index bdd40bcaaa1f..000000000000 --- a/Documentation/devicetree/bindings/iio/magnetometer/mag3110.txt +++ /dev/null @@ -1,27 +0,0 @@ -* FREESCALE MAG3110 magnetometer sensor - -Required properties: - - - compatible : should be "fsl,mag3110" - - reg : the I2C address of the magnetometer - -Optional properties: - - - interrupts: the sole interrupt generated by the device - - Refer to interrupt-controller/interrupts.txt for generic interrupt client - node bindings. - - - vdd-supply: phandle to the regulator that provides power to the sensor. - - vddio-supply: phandle to the regulator that provides power to the sensor's IO. - -Example: - -magnetometer@e { - compatible = "fsl,mag3110"; - reg = <0x0e>; - pinctrl-names = "default"; - pinctrl-0 = <&pinctrl_i2c3_mag3110_int>; - interrupt-parent = <&gpio3>; - interrupts = <16 IRQ_TYPE_EDGE_RISING>; -}; |