diff mbox

ARM: dts: wheat: add support for tactile switches

Message ID 10465663.8teCsXZU7y@wasted.cogentembedded.com (mailing list archive)
State New, archived
Headers show

Commit Message

Sergei Shtylyov Sept. 5, 2016, 9:33 p.m. UTC
Add  support for the  tactile switches  SW2/3 (on the debug board) as a
virtual keyboard like it  was done with the Blanche board).

Signed-off-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com>

---
This patch is against the 'renesas-devel-20160905-v4.8-rc5' of Simon Horman's
'renesas.git' repo plus the Wheat DU patch...

 arch/arm/boot/dts/r8a7792-wheat.dts |   20 ++++++++++++++++++++
 1 file changed, 20 insertions(+)

Comments

Geert Uytterhoeven Sept. 6, 2016, 7:11 a.m. UTC | #1
On Mon, Sep 5, 2016 at 11:33 PM, Sergei Shtylyov
<sergei.shtylyov@cogentembedded.com> wrote:
> Add  support for the  tactile switches  SW2/3 (on the debug board) as a
> virtual keyboard like it  was done with the Blanche board).
>
> Signed-off-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com>

Acked-by: Geert Uytterhoeven <geert+renesas@glider.be>

DT syntax looks OK to me, I have no board schematics or documentation.

Gr{oetje,eeting}s,

                        Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds
Simon Horman Sept. 6, 2016, 10:15 a.m. UTC | #2
On Tue, Sep 06, 2016 at 09:11:41AM +0200, Geert Uytterhoeven wrote:
> On Mon, Sep 5, 2016 at 11:33 PM, Sergei Shtylyov
> <sergei.shtylyov@cogentembedded.com> wrote:
> > Add  support for the  tactile switches  SW2/3 (on the debug board) as a
> > virtual keyboard like it  was done with the Blanche board).
> >
> > Signed-off-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com>
> 
> Acked-by: Geert Uytterhoeven <geert+renesas@glider.be>
> 
> DT syntax looks OK to me, I have no board schematics or documentation.

Thanks, I have queued this up.
diff mbox

Patch

Index: renesas/arch/arm/boot/dts/r8a7792-wheat.dts
===================================================================
--- renesas.orig/arch/arm/boot/dts/r8a7792-wheat.dts
+++ renesas/arch/arm/boot/dts/r8a7792-wheat.dts
@@ -12,6 +12,7 @@ 
 /dts-v1/;
 #include "r8a7792.dtsi"
 #include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
 
 / {
 	model = "Wheat";
@@ -56,6 +57,25 @@ 
 		pinctrl-names = "default";
 	};
 
+	keyboard {
+		compatible = "gpio-keys";
+
+		key-a {
+			linux,code = <KEY_A>;
+			label = "SW2";
+			wakeup-source;
+			debounce-interval = <20>;
+			gpios = <&gpio3 20 GPIO_ACTIVE_LOW>;
+		};
+		key-b {
+			linux,code = <KEY_B>;
+			label = "SW3";
+			wakeup-source;
+			debounce-interval = <20>;
+			gpios = <&gpio11 2 GPIO_ACTIVE_LOW>;
+		};
+	};
+
 	vcc_sdhi0: regulator-vcc-sdhi0 {
 		compatible = "regulator-fixed";