diff mbox series

[V2,2/2] arm64: dts: qcom: ipq9574: Enable WPS buttons

Message ID 20230713105909.14209-3-quic_anusha@quicinc.com
State Accepted
Commit 0e2f2c506f01abcec412ccf91ed39ddfafbda60a
Headers show
Series Add common RDP dtsi file for ipq9574 | expand

Commit Message

Anusha Canchi July 13, 2023, 10:59 a.m. UTC
Add support for wps buttons on GPIO 37.

Signed-off-by: Anusha Rao <quic_anusha@quicinc.com>
Reviewed-by: Konrad Dybcio <konrad.dybcio@linaro.org>
---
 Changes in V2:
	- Removed linux,input-type from button-wps.
	- Picked up Reviewed-by tag.

 .../boot/dts/qcom/ipq9574-rdp-common.dtsi     | 22 +++++++++++++++++++
 1 file changed, 22 insertions(+)
diff mbox series

Patch

diff --git a/arch/arm64/boot/dts/qcom/ipq9574-rdp-common.dtsi b/arch/arm64/boot/dts/qcom/ipq9574-rdp-common.dtsi
index 40a7aefd0540..49c9b6478357 100644
--- a/arch/arm64/boot/dts/qcom/ipq9574-rdp-common.dtsi
+++ b/arch/arm64/boot/dts/qcom/ipq9574-rdp-common.dtsi
@@ -8,6 +8,8 @@ 
 
 /dts-v1/;
 
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
 #include "ipq9574.dtsi"
 
 / {
@@ -36,6 +38,19 @@ 
 		regulator-always-on;
 		regulator-name = "fixed_0p925";
 	};
+
+	gpio-keys {
+		compatible = "gpio-keys";
+		pinctrl-0 = <&gpio_keys_default>;
+		pinctrl-names = "default";
+
+		button-wps {
+			label = "wps";
+			linux,code = <KEY_WPS_BUTTON>;
+			gpios = <&tlmm 37 GPIO_ACTIVE_LOW>;
+			debounce-interval = <60>;
+		};
+	};
 };
 
 &blsp1_spi0 {
@@ -95,6 +110,13 @@ 
 		drive-strength = <8>;
 		bias-disable;
 	};
+
+	gpio_keys_default: gpio-keys-default-state {
+		pins = "gpio37";
+		function = "gpio";
+		drive-strength = <8>;
+		bias-pull-up;
+	};
 };
 
 &usb_0_dwc3 {