]> asedeno.scripts.mit.edu Git - linux.git/commitdiff
ARM: dts: imx7-colibri: add GPIO wakeup key
authorStefan Agner <stefan.agner@toradex.com>
Tue, 27 Aug 2019 13:18:18 +0000 (13:18 +0000)
committerShawn Guo <shawnguo@kernel.org>
Wed, 2 Oct 2019 01:09:49 +0000 (09:09 +0800)
Add wakeup GPIO key which is able to wake the system from sleep
modes (e.g. Suspend-to-Memory).

Signed-off-by: Stefan Agner <stefan.agner@toradex.com>
Signed-off-by: Philippe Schenker <philippe.schenker@toradex.com>
Acked-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
arch/arm/boot/dts/imx7-colibri-eval-v3.dtsi
arch/arm/boot/dts/imx7-colibri.dtsi

index 3f2746169181e568f51e623788fdc8b706eadbf7..45c4e721115abc663546dae3ee42cfb40a3f939d 100644 (file)
@@ -52,6 +52,20 @@ clk16m: clk16m {
                clock-frequency = <16000000>;
        };
 
+       gpio-keys {
+               compatible = "gpio-keys";
+               pinctrl-names = "default";
+               pinctrl-0 = <&pinctrl_gpiokeys>;
+
+               power {
+                       label = "Wake-Up";
+                       gpios = <&gpio1 1 GPIO_ACTIVE_HIGH>;
+                       linux,code = <KEY_WAKEUP>;
+                       debounce-interval = <10>;
+                       wakeup-source;
+               };
+       };
+
        panel: panel {
                compatible = "edt,et057090dhu";
                backlight = <&bl>;
index 917eb0b58b132045b775d209ed52753c698d9034..8df8a2a4f2edb491653b5332b9b88c5229d05bcd 100644 (file)
@@ -737,12 +737,17 @@ &iomuxc_lpsr {
 
        pinctrl_gpio_lpsr: gpio1-grp {
                fsl,pins = <
-                       MX7D_PAD_LPSR_GPIO1_IO01__GPIO1_IO1     0x59
                        MX7D_PAD_LPSR_GPIO1_IO02__GPIO1_IO2     0x59
                        MX7D_PAD_LPSR_GPIO1_IO03__GPIO1_IO3     0x59
                >;
        };
 
+       pinctrl_gpiokeys: gpiokeysgrp {
+               fsl,pins = <
+                       MX7D_PAD_LPSR_GPIO1_IO01__GPIO1_IO1     0x19
+               >;
+       };
+
        pinctrl_i2c1: i2c1-grp {
                fsl,pins = <
                        MX7D_PAD_LPSR_GPIO1_IO05__I2C1_SDA      0x4000007f