[PATCH/RFC] arm64: dts: renesas: r8a77995-draak: gpio-leds prototype

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: Magnus Damm <damm+renesas@xxxxxxxxxxxxx>

This patch adds support for a couple of LEDs on the r8a77995 Draak board.

It also ignores the issue that push switches are also used on the same GPIOs.

The approach is the same as in the earlier posted patch for other boards:
[PATCH/RFC] arm64: dts: renesas: salvator-common: gpio-leds prototype

The limitations of DT bindings and kernel software support remain the same.

As Geert pointed out we need to extend the software to allow sharing of
GPIOs somehow. On this board and several others the GPIOs used for LEDs
are also used for push switches. Both DT bindings and drivers need to
be extended, most likely together with the GPIO subsystem. And to make it
more fun it is probably possible to get interrupts from these GPIOs as well.

In the patch the LED order and the GPIO number assignments look quite random
but match the schematics.

Signed-off-by: Magnus Damm <damm+renesas@xxxxxxxxxxxxx>
---

 arch/arm64/boot/dts/renesas/r8a77995-draak.dts |   14 ++++++++++++++
 1 file changed, 14 insertions(+)

--- 0001/arch/arm64/boot/dts/renesas/r8a77995-draak.dts
+++ work/arch/arm64/boot/dts/renesas/r8a77995-draak.dts	2020-06-22 21:00:20.000000000 +0900
@@ -91,6 +91,20 @@
 		};
 	};
 
+	leds {
+		compatible = "gpio-leds";
+
+		led13 {
+			gpios = <&gpio4 7 GPIO_ACTIVE_HIGH>;
+		};
+		led12 {
+			gpios = <&gpio1 30 GPIO_ACTIVE_HIGH>;
+		};
+		led14 {
+			gpios = <&gpio4 25 GPIO_ACTIVE_HIGH>;
+		};
+	};
+
 	memory@48000000 {
 		device_type = "memory";
 		/* first 128MB is reserved for secure area. */



[Index of Archives]     [Linux Samsung SOC]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]

  Powered by Linux