diff mbox series

arm64: dts: exynos: add gpio-key node for exynosautov9-sadk

Message ID 20231027040338.63088-1-jaewon02.kim@samsung.com
State New
Headers show
Series arm64: dts: exynos: add gpio-key node for exynosautov9-sadk | expand

Commit Message

Jaewon Kim Oct. 27, 2023, 4:03 a.m. UTC
ExynosAutov9 SADK board has 3 keys to test external GPIO interrupt.
To support this, add 3 gpio-key(Wakeup, Volume Down, Volume Up) node.

Signed-off-by: Jaewon Kim <jaewon02.kim@samsung.com>
---
 .../boot/dts/exynos/exynosautov9-sadk.dts     | 51 +++++++++++++++++++
 1 file changed, 51 insertions(+)

Comments

Krzysztof Kozlowski Oct. 27, 2023, 7:04 a.m. UTC | #1
On 27/10/2023 06:03, Jaewon Kim wrote:
> ExynosAutov9 SADK board has 3 keys to test external GPIO interrupt.
> To support this, add 3 gpio-key(Wakeup, Volume Down, Volume Up) node.
> 
> Signed-off-by: Jaewon Kim <jaewon02.kim@samsung.com>
> ---

Thank you for the patch.
It is too late in the cycle for me to pick it up. I will take it after
the merge window.


Best regards,
Krzysztof
Krzysztof Kozlowski Nov. 14, 2023, 3:26 p.m. UTC | #2
On Fri, 27 Oct 2023 13:03:37 +0900, Jaewon Kim wrote:
> ExynosAutov9 SADK board has 3 keys to test external GPIO interrupt.
> To support this, add 3 gpio-key(Wakeup, Volume Down, Volume Up) node.
> 
> 

Applied, thanks!

[1/1] arm64: dts: exynos: add gpio-key node for exynosautov9-sadk
      https://git.kernel.org/krzk/linux/c/6479f40a10f773d712f645c3d7bc2ffd5904aa6c

Best regards,
diff mbox series

Patch

diff --git a/arch/arm64/boot/dts/exynos/exynosautov9-sadk.dts b/arch/arm64/boot/dts/exynos/exynosautov9-sadk.dts
index bc1815f6ada2..de2c1de51a76 100644
--- a/arch/arm64/boot/dts/exynos/exynosautov9-sadk.dts
+++ b/arch/arm64/boot/dts/exynos/exynosautov9-sadk.dts
@@ -9,6 +9,7 @@ 
 /dts-v1/;
 #include "exynosautov9.dtsi"
 #include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
 
 / {
 	model = "Samsung ExynosAuto v9 SADK board";
@@ -32,6 +33,31 @@  memory@80000000 {
 		      <0xa 0x00000000 0x2 0x00000000>;
 	};
 
+	gpio-keys {
+		compatible = "gpio-keys";
+		pinctrl-names = "default";
+		pinctrl-0 = <&key_wakeup &key_volup &key_voldown>;
+
+		key-wakeup {
+			label = "Wakeup";
+			linux,code = <KEY_WAKEUP>;
+			gpios = <&gpa0 0 GPIO_ACTIVE_LOW>;
+			wakeup-source;
+		};
+
+		key-volume-down {
+			label = "Volume Down";
+			linux,code = <KEY_VOLUMEDOWN>;
+			gpios = <&gpg2 0 GPIO_ACTIVE_LOW>;
+		};
+
+		key-volume-up {
+			label = "Volume Up";
+			linux,code = <KEY_VOLUMEUP>;
+			gpios = <&gpg1 5 GPIO_ACTIVE_LOW>;
+		};
+	};
+
 	ufs_0_fixed_vcc_reg: regulator-0 {
 		compatible = "regulator-fixed";
 		regulator-name = "ufs-vcc";
@@ -49,6 +75,31 @@  ufs_1_fixed_vcc_reg: regulator-1 {
 	};
 };
 
+&pinctrl_alive {
+	key_wakeup: key-wakeup-pins {
+		samsung,pins = "gpa0-0";
+		samsung,pin-function = <EXYNOS_PIN_FUNC_EINT>;
+		samsung,pin-pud = <EXYNOS_PIN_PULL_NONE>;
+		samsung,pin-drv = <EXYNOS5420_PIN_DRV_LV1>;
+	};
+};
+
+&pinctrl_peric1 {
+	key_voldown: key-voldown-pins {
+		samsung,pins = "gpg2-0";
+		samsung,pin-function = <EXYNOS_PIN_FUNC_EINT>;
+		samsung,pin-pud = <EXYNOS_PIN_PULL_NONE>;
+		samsung,pin-drv = <EXYNOS5420_PIN_DRV_LV1>;
+	};
+
+	key_volup: key-volup-pins {
+		samsung,pins = "gpg1-5";
+		samsung,pin-function = <EXYNOS_PIN_FUNC_EINT>;
+		samsung,pin-pud = <EXYNOS_PIN_PULL_NONE>;
+		samsung,pin-drv = <EXYNOS5420_PIN_DRV_LV1>;
+	};
+};
+
 &pwm {
 	pinctrl-names = "default";
 	pinctrl-0 = <&pwm_tout3>;