Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

ARM: dts: rza2mevb: Add input switch

Add support for input switch SW3 on the Renesas RZ/A2M EVB
development board.

Note that this uses the IRQ interrupt, as the RZ/A2 GPIO controller
does not include interrupt support

Signed-off-by: Chris Brandt <chris.brandt@renesas.com>
Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be>
Signed-off-by: Simon Horman <horms+renesas@verge.net.au>

authored by

Chris Brandt and committed by
Simon Horman
4592e492 e23391f3

+20
+20
arch/arm/boot/dts/r7s9210-rza2mevb.dts
··· 9 9 /dts-v1/; 10 10 #include "r7s9210.dtsi" 11 11 #include <dt-bindings/gpio/gpio.h> 12 + #include <dt-bindings/input/input.h> 12 13 #include <dt-bindings/pinctrl/r7s9210-pinctrl.h> 13 14 14 15 / { ··· 25 24 chosen { 26 25 bootargs = "ignore_loglevel"; 27 26 stdout-path = "serial0:115200n8"; 27 + }; 28 + 29 + keyboard { 30 + compatible = "gpio-keys"; 31 + 32 + pinctrl-names = "default"; 33 + pinctrl-0 = <&keyboard_pins>; 34 + 35 + key-3 { 36 + interrupt-parent = <&irqc>; 37 + interrupts = <0 IRQ_TYPE_EDGE_BOTH>; 38 + linux,code = <KEY_3>; 39 + label = "SW3"; 40 + wakeup-source; 41 + }; 28 42 }; 29 43 30 44 lbsc { ··· 135 119 <RZA2_PINMUX(PORT3, 3, 1)>, /* ET1_MDC */ 136 120 <RZA2_PINMUX(PORT3, 4, 1)>, /* ET1_MDIO */ 137 121 <RZA2_PINMUX(PORTL, 1, 5)>; /* IRQ5 */ 122 + }; 123 + 124 + keyboard_pins: keyboard { 125 + pinmux = <RZA2_PINMUX(PORTJ, 1, 6)>; /* IRQ0 */ 138 126 }; 139 127 140 128 /* Serial Console */