devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Kathiravan Thirumoorthy <quic_kathirav@quicinc.com>
To: Andy Gross <agross@kernel.org>,
	Bjorn Andersson <andersson@kernel.org>,
	Konrad Dybcio <konrad.dybcio@linaro.org>,
	Rob Herring <robh+dt@kernel.org>,
	Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org>,
	Conor Dooley <conor+dt@kernel.org>
Cc: <linux-arm-msm@vger.kernel.org>, <devicetree@vger.kernel.org>,
	<linux-kernel@vger.kernel.org>,
	Anusha Rao <quic_anusha@quicinc.com>,
	Kathiravan Thirumoorthy <quic_kathirav@quicinc.com>
Subject: [PATCH v3 2/2] arm64: dts: qcom: ipq9574: Enable WPS buttons
Date: Wed, 27 Sep 2023 12:13:19 +0530	[thread overview]
Message-ID: <20230927-common-rdp-v3-2-3d07b3ff6d42@quicinc.com> (raw)
In-Reply-To: <20230927-common-rdp-v3-0-3d07b3ff6d42@quicinc.com>

From: Anusha Rao <quic_anusha@quicinc.com>

Add support for wps buttons on GPIO 37.

Reviewed-by: Konrad Dybcio <konrad.dybcio@linaro.org>
Signed-off-by: Anusha Rao <quic_anusha@quicinc.com>
Signed-off-by: Kathiravan Thirumoorthy <quic_kathirav@quicinc.com>
---
 Changes in V3:
	- None
 Changes in V2:
	- Removed linux,input-type from button-wps.
	- Picked up Reviewed-by tag.
---
 arch/arm64/boot/dts/qcom/ipq9574-rdp-common.dtsi | 22 ++++++++++++++++++++++
 1 file changed, 22 insertions(+)

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_fixed_0p925: s0925 {
 		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 @@ spi_0_pins: spi-0-state {
 		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 {

-- 
2.34.1


  parent reply	other threads:[~2023-09-27  6:43 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-09-27  6:43 [PATCH v3 0/2] Add common RDP dtsi file for IPQ9574 Kathiravan Thirumoorthy
2023-09-27  6:43 ` [PATCH v3 1/2] arm64: dts: qcom: ipq9574: Add common RDP dtsi file Kathiravan Thirumoorthy
2023-09-27  6:43 ` Kathiravan Thirumoorthy [this message]
2023-10-11 10:32 ` [PATCH v3 0/2] Add common RDP dtsi file for IPQ9574 Kathiravan Thirumoorthy
2023-10-16 18:25 ` Bjorn Andersson

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20230927-common-rdp-v3-2-3d07b3ff6d42@quicinc.com \
    --to=quic_kathirav@quicinc.com \
    --cc=agross@kernel.org \
    --cc=andersson@kernel.org \
    --cc=conor+dt@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=konrad.dybcio@linaro.org \
    --cc=krzysztof.kozlowski+dt@linaro.org \
    --cc=linux-arm-msm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=quic_anusha@quicinc.com \
    --cc=robh+dt@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).