summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorShreeya Patel <shreeya.patel@collabora.com>2022-07-25 13:40:49 +0300
committerJonathan Cameron <Jonathan.Cameron@huawei.com>2022-08-16 00:29:57 +0300
commitaf0a61e940f8cea62c3c9a18ff5b3830b16e2087 (patch)
tree270d189aa81fb8c6f0014bd32194c175aadd7b70
parentbd1d558c9c65cf56623a3a237a2998697586c409 (diff)
downloadlinux-af0a61e940f8cea62c3c9a18ff5b3830b16e2087.tar.xz
dt-bindings: Document ltrf216a light sensor bindings
Add devicetree bindings for ltrf216a ambient light sensor. Reviewed-by: Rob Herring <robh@kernel.org> Signed-off-by: Shreeya Patel <shreeya.patel@collabora.com> Link: https://lore.kernel.org/r/20220725104050.491396-2-shreeya.patel@collabora.com Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-rw-r--r--Documentation/devicetree/bindings/iio/light/liteon,ltrf216a.yaml49
1 files changed, 49 insertions, 0 deletions
diff --git a/Documentation/devicetree/bindings/iio/light/liteon,ltrf216a.yaml b/Documentation/devicetree/bindings/iio/light/liteon,ltrf216a.yaml
new file mode 100644
index 000000000000..7de1b0e721ca
--- /dev/null
+++ b/Documentation/devicetree/bindings/iio/light/liteon,ltrf216a.yaml
@@ -0,0 +1,49 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/iio/light/liteon,ltrf216a.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: LTRF216A Ambient Light Sensor
+
+maintainers:
+ - Shreeya Patel <shreeya.patel@collabora.com>
+
+description:
+ Ambient light sensing with an i2c interface.
+
+properties:
+ compatible:
+ const: liteon,ltrf216a
+
+ reg:
+ maxItems: 1
+
+ interrupts:
+ maxItems: 1
+
+ vdd-supply:
+ description: Regulator that provides power to the sensor.
+
+required:
+ - compatible
+ - reg
+
+additionalProperties: false
+
+examples:
+ - |
+ #include <dt-bindings/interrupt-controller/irq.h>
+
+ i2c {
+ #address-cells = <1>;
+ #size-cells = <0>;
+
+ light-sensor@53 {
+ compatible = "liteon,ltrf216a";
+ reg = <0x53>;
+ vdd-supply = <&vdd_regulator>;
+ interrupt-parent = <&gpio0>;
+ interrupts = <5 IRQ_TYPE_LEVEL_LOW>;
+ };
+ };