arm64: dts: allwinner: h6: orangepi: Add device nodes for LEDs
authorChen-Yu Tsai <wens@csie.org>
Tue, 20 Nov 2018 06:53:11 +0000 (14:53 +0800)
committerMaxime Ripard <maxime.ripard@bootlin.com>
Tue, 20 Nov 2018 07:57:22 +0000 (08:57 +0100)
The Orange Pi Lite 2 and Orange Pi One Plus both have two LEDs, one red
and one green. These are driven directly by GPIO lines in an active high
arrangement. The red LED is labeled "power", so it is set to be on by
default.

Note that the default drive current for the GPIO lines makes the LEDs
very bright.

Signed-off-by: Chen-Yu Tsai <wens@csie.org>
Signed-off-by: Maxime Ripard <maxime.ripard@bootlin.com>
arch/arm64/boot/dts/allwinner/sun50i-h6-orangepi.dtsi

index f16b7ffbe797a468fb459dabced0556721d3de7a..b2526dac2fcfab3c7473b6745a68ecff2b0ee22f 100644 (file)
                stdout-path = "serial0:115200n8";
        };
 
+       leds {
+               compatible = "gpio-leds";
+
+               power {
+                       label = "orangepi:red:power";
+                       gpios = <&r_pio 0 4 GPIO_ACTIVE_HIGH>; /* PL4 */
+                       default-state = "on";
+               };
+
+               status {
+                       label = "orangepi:green:status";
+                       gpios = <&r_pio 0 7 GPIO_ACTIVE_HIGH>; /* PL7 */
+               };
+       };
+
        reg_vcc5v: vcc5v {
                /* board wide 5V supply directly from the DC jack */
                compatible = "regulator-fixed";