summaryrefslogtreecommitdiff
path: root/Documentation/devicetree/bindings/leds
diff options
context:
space:
mode:
authorChristian Mauderer <oss@c-mauderer.de>2019-05-13 22:33:06 +0300
committerJacek Anaszewski <jacek.anaszewski@gmail.com>2019-05-24 23:18:37 +0300
commite7c787cb2697ee4c101109bf21b4fc397cea150b (patch)
treeaa4a986fc7660d115dcd92ffe99f94dd569e83b7 /Documentation/devicetree/bindings/leds
parenta188339ca5a396acc588e5851ed7e19f66b0ebd9 (diff)
downloadlinux-e7c787cb2697ee4c101109bf21b4fc397cea150b.tar.xz
dt-bindings: leds: Add binding for spi-byte LED.
This patch adds the binding documentation for a simple SPI based LED controller which use only one byte for setting the brightness. Signed-off-by: Christian Mauderer <oss@c-mauderer.de> Reviewed-by: Rob Herring <robh@kernel.org> Signed-off-by: Jacek Anaszewski <jacek.anaszewski@gmail.com>
Diffstat (limited to 'Documentation/devicetree/bindings/leds')
-rw-r--r--Documentation/devicetree/bindings/leds/leds-spi-byte.txt44
1 files changed, 44 insertions, 0 deletions
diff --git a/Documentation/devicetree/bindings/leds/leds-spi-byte.txt b/Documentation/devicetree/bindings/leds/leds-spi-byte.txt
new file mode 100644
index 000000000000..28b6b2d9091e
--- /dev/null
+++ b/Documentation/devicetree/bindings/leds/leds-spi-byte.txt
@@ -0,0 +1,44 @@
+* Single Byte SPI LED Device Driver.
+
+The driver can be used for controllers with a very simple SPI protocol:
+- one LED is controlled by a single byte on MOSI
+- the value of the byte gives the brightness between two values (lowest to
+ highest)
+- no return value is necessary (no MISO signal)
+
+The value for lowest and highest brightness is dependent on the device and
+therefore on the compatible string.
+
+Depending on the compatible string some special functions (like hardware
+accelerated blinking) might can be supported too.
+
+The driver currently only supports one LED. The properties of the LED are
+configured in a sub-node in the device node.
+
+Required properties:
+- compatible: should be one of
+ * "ubnt,acb-spi-led" microcontroller (SONiX 8F26E611LA) based device
+ used for example in Ubiquiti airCube ISP
+
+Property rules described in Documentation/devicetree/bindings/spi/spi-bus.txt
+apply.
+
+LED sub-node properties:
+- label:
+ see Documentation/devicetree/bindings/leds/common.txt
+- default-state:
+ see Documentation/devicetree/bindings/leds/common.txt
+ Only "on" and "off" are supported.
+
+Example:
+
+led-controller@0 {
+ compatible = "ubnt,acb-spi-led";
+ reg = <0>;
+ spi-max-frequency = <100000>;
+
+ led {
+ label = "white:status";
+ default-state = "on";
+ };
+};