devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Lin, Meng-Bo" <linmengbo0689@protonmail.com>
To: devicetree@vger.kernel.org
Cc: Andy Gross <agross@kernel.org>,
	Bjorn Andersson <bjorn.andersson@linaro.org>,
	Konrad Dybcio <konrad.dybcio@somainline.org>,
	Rob Herring <robh+dt@kernel.org>,
	Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org>,
	linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org,
	Stephan Gerhold <stephan@gerhold.net>,
	Nikita Travkin <nikita@trvn.ru>,
	~postmarketos/upstreaming@lists.sr.ht
Subject: [RESEND PATCH 4/4] arm64: dts: qcom: msm8916-samsung-e2015: Add touchkey
Date: Fri, 15 Jul 2022 10:25:03 +0000	[thread overview]
Message-ID: <20220715102413.4119-1-linmengbo0689@protonmail.com> (raw)
In-Reply-To: <20220715102055.3844-1-linmengbo0689@protonmail.com>

On the Samsung Galaxy E5 and E7 the touch key is supplied by a single
fixed regulator (enabled via GPIO 97) that supplies both MCU and LED.
Add it to the device tree.

Signed-off-by: Lin, Meng-Bo <linmengbo0689@protonmail.com>
---
 .../qcom/msm8916-samsung-e2015-common.dtsi    | 26 +++++++++++++++++++
 .../dts/qcom/msm8916-samsung-grandmax.dts     |  4 +++
 2 files changed, 30 insertions(+)

diff --git a/arch/arm64/boot/dts/qcom/msm8916-samsung-e2015-common.dtsi b/arch/arm64/boot/dts/qcom/msm8916-samsung-e2015-common.dtsi
index 373154ee2643..9f3aca17130d 100644
--- a/arch/arm64/boot/dts/qcom/msm8916-samsung-e2015-common.dtsi
+++ b/arch/arm64/boot/dts/qcom/msm8916-samsung-e2015-common.dtsi
@@ -19,6 +19,19 @@ muic: extcon@14 {
 		};
 	};

+	reg_touch_key: regulator-touch-key {
+		compatible = "regulator-fixed";
+		regulator-name = "touch_key";
+		regulator-min-microvolt = <3300000>;
+		regulator-max-microvolt = <3300000>;
+
+		gpio = <&msmgpio 97 GPIO_ACTIVE_HIGH>;
+		enable-active-high;
+
+		pinctrl-names = "default";
+		pinctrl-0 = <&tkey_en_default>;
+	};
+
 	vibrator: vibrator {
 		compatible = "gpio-vibrator";
 		enable-gpios = <&msmgpio 76 GPIO_ACTIVE_HIGH>;
@@ -28,6 +41,11 @@ vibrator: vibrator {
 	};
 };

+&touchkey {
+	vcc-supply = <&reg_touch_key>;
+	vdd-supply = <&reg_touch_key>;
+};
+
 &msmgpio {
 	motor_en_default: motor-en-default {
 		pins = "gpio76";
@@ -36,4 +54,12 @@ motor_en_default: motor-en-default {
 		drive-strength = <2>;
 		bias-disable;
 	};
+
+	tkey_en_default: tkey-en-default {
+		pins = "gpio97";
+		function = "gpio";
+
+		drive-strength = <2>;
+		bias-disable;
+	};
 };
diff --git a/arch/arm64/boot/dts/qcom/msm8916-samsung-grandmax.dts b/arch/arm64/boot/dts/qcom/msm8916-samsung-grandmax.dts
index 41aada4bfb80..f68dd3d69a33 100644
--- a/arch/arm64/boot/dts/qcom/msm8916-samsung-grandmax.dts
+++ b/arch/arm64/boot/dts/qcom/msm8916-samsung-grandmax.dts
@@ -27,6 +27,10 @@ / {
 	/delete-node/ i2c-tkey;
 };

+&reg_touch_key {
+	status = "disabled";
+};
+
 &vibrator {
 	enable-gpios = <&msmgpio 72 GPIO_ACTIVE_HIGH>;
 };
--
2.30.2



  parent reply	other threads:[~2022-07-15 10:25 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-07-15 10:21 [RESEND PATCH 1/4] dt-bindings: qcom: Document bindings for new msm8916-samsung-e2015 devices Lin, Meng-Bo
2022-07-15 10:24 ` [RESEND PATCH 2/4] arm64: dts: qcom: msm8916-samsung-e2015: Add initial common dtsi Lin, Meng-Bo
2022-07-15 10:24 ` [RESEND PATCH 3/4] ARM: dts: qcom-msm8916-samsung-e2015: Include dts from arm64 Lin, Meng-Bo
2022-07-15 10:25 ` Lin, Meng-Bo [this message]
2022-07-17 11:01 ` [RESEND PATCH 1/4] dt-bindings: qcom: Document bindings for new msm8916-samsung-e2015 devices Lin, Meng-Bo
2022-07-18 13:09 ` Krzysztof Kozlowski
2022-07-18 13:09 ` Krzysztof Kozlowski
2022-07-19 13:01 ` [PATCH v3 0/4] Add Samsung Galaxy E5/E7/Grand Max device trees Lin, Meng-Bo
2022-08-29 23:45   ` (subset) " Bjorn Andersson
2022-07-19 13:01 ` [PATCH v3 1/4] dt-bindings: qcom: Document bindings for new msm8916-samsung-e2015 devices Lin, Meng-Bo
2022-07-19 19:09   ` Krzysztof Kozlowski
2022-07-19 13:01 ` [PATCH v3 2/4] arm64: dts: qcom: msm8916-samsung-e2015: Add initial common dtsi Lin, Meng-Bo
2022-07-19 13:01 ` [PATCH v3 3/4] ARM: dts: qcom-msm8916-samsung-e2015: Include dts from arm64 Lin, Meng-Bo
2022-07-19 13:01 ` [PATCH v3 4/4] arm64: dts: qcom: msm8916-samsung-e2015: Add touchkey Lin, Meng-Bo

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=20220715102413.4119-1-linmengbo0689@protonmail.com \
    --to=linmengbo0689@protonmail.com \
    --cc=agross@kernel.org \
    --cc=bjorn.andersson@linaro.org \
    --cc=devicetree@vger.kernel.org \
    --cc=konrad.dybcio@somainline.org \
    --cc=krzysztof.kozlowski+dt@linaro.org \
    --cc=linux-arm-msm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=nikita@trvn.ru \
    --cc=robh+dt@kernel.org \
    --cc=stephan@gerhold.net \
    --cc=~postmarketos/upstreaming@lists.sr.ht \
    /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).