]> git.dujemihanovic.xyz Git - linux.git/commitdiff
dt-bindings: backlight: add Kinetic KTD2801 binding
authorDuje Mihanović <duje.mihanovic@skole.hr>
Thu, 5 Oct 2023 18:49:08 +0000 (20:49 +0200)
committerDuje Mihanović <duje.mihanovic@skole.hr>
Wed, 27 Dec 2023 12:32:24 +0000 (13:32 +0100)
Add the dt binding for the Kinetic KTD2801 backlight driver.

Signed-off-by: Duje Mihanović <duje.mihanovic@skole.hr>
Documentation/devicetree/bindings/leds/backlight/kinetic,ktd2801.yaml [new file with mode: 0644]

diff --git a/Documentation/devicetree/bindings/leds/backlight/kinetic,ktd2801.yaml b/Documentation/devicetree/bindings/leds/backlight/kinetic,ktd2801.yaml
new file mode 100644 (file)
index 0000000..970d54b
--- /dev/null
@@ -0,0 +1,46 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/leds/backlight/kinetic,ktd2801.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Kinetic Technologies KTD2801 one-wire backlight
+
+maintainers:
+  - Duje Mihanović <duje.mihanovic@skole.hr>
+
+description: |
+  The Kinetic Technologies KTD2801 is a LED backlight driver controlled
+  by a single GPIO line. The driver can be controlled with a PWM signal
+  or by pulsing the GPIO line to set the backlight level. This is called
+  "ExpressWire".
+
+allOf:
+  - $ref: common.yaml#
+
+properties:
+  compatible:
+    const: kinetic,ktd2801
+
+  enable-gpios:
+    maxItems: 1
+
+  default-brightness: true
+  max-brightness: true
+
+required:
+  - compatible
+  - enable-gpios
+
+additionalProperties: false
+
+examples:
+  - |
+    #include <dt-bindings/gpio/gpio.h>
+
+    backlight {
+        compatible = "kinetic,ktd2801";
+        enable-gpios = <&gpio 97 GPIO_ACTIVE_LOW>;
+        max-brightness = <210>;
+        default-brightness = <100>;
+    };