From: Neil Armstrong <neil.armstrong@linaro.org>
To: Bjorn Andersson <andersson@kernel.org>,
Satya Priya <quic_c_skakit@quicinc.com>,
Lee Jones <lee@kernel.org>,
Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org>,
Rob Herring <robh+dt@kernel.org>,
Konrad Dybcio <konrad.dybcio@somainline.org>,
Dmitry Torokhov <dmitry.torokhov@gmail.com>,
Alexandre Belloni <alexandre.belloni@bootlin.com>,
Andy Gross <agross@kernel.org>,
Alessandro Zummo <a.zummo@towertech.it>
Cc: Bjorn Andersson <andersson@kernel.org>,
linux-input@vger.kernel.org, linux-arm-msm@vger.kernel.org,
Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>,
devicetree@vger.kernel.org,
Neil Armstrong <neil.armstrong@linaro.org>,
Rob Herring <robh@kernel.org>,
linux-rtc@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: [PATCH v4 06/11] dt-bindings: input: qcom,pm8921-pwrkey: convert to dt-schema
Date: Fri, 21 Oct 2022 11:06:42 +0200 [thread overview]
Message-ID: <20220928-mdm9615-dt-schema-fixes-v4-6-dac2dfaac703@linaro.org> (raw)
In-Reply-To: <20220928-mdm9615-dt-schema-fixes-v4-0-dac2dfaac703@linaro.org>
Convert input/qcom,pm8xxx-pwrkey.txt to YAML, and take in account that
the PM8921 pwrkey compatible is used as fallback for the PM8018 pwrkey.
Reviewed-by: Rob Herring <robh@kernel.org>
Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org>
---
.../bindings/input/qcom,pm8921-pwrkey.yaml | 75 ++++++++++++++++++++++
.../bindings/input/qcom,pm8xxx-pwrkey.txt | 46 -------------
2 files changed, 75 insertions(+), 46 deletions(-)
diff --git a/Documentation/devicetree/bindings/input/qcom,pm8921-pwrkey.yaml b/Documentation/devicetree/bindings/input/qcom,pm8921-pwrkey.yaml
new file mode 100644
index 000000000000..12c74c083258
--- /dev/null
+++ b/Documentation/devicetree/bindings/input/qcom,pm8921-pwrkey.yaml
@@ -0,0 +1,75 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/input/qcom,pm8921-pwrkey.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Qualcomm PM8921 PMIC Power Key
+
+maintainers:
+ - Bjorn Andersson <andersson@kernel.org>
+
+allOf:
+ - $ref: input.yaml#
+
+properties:
+ compatible:
+ oneOf:
+ - enum:
+ - qcom,pm8921-pwrkey
+ - qcom,pm8058-pwrkey
+ - items:
+ - enum:
+ - qcom,pm8018-pwrkey
+ - const: qcom,pm8921-pwrkey
+
+ reg:
+ maxItems: 1
+
+ interrupts:
+ items:
+ - description: key release
+ - description: key press
+
+ debounce:
+ description:
+ Time in microseconds that key must be pressed or
+ released for state change interrupt to trigger.
+ $ref: /schemas/types.yaml#/definitions/uint32
+
+ pull-up:
+ description:
+ Presence of this property indicates that the KPDPWR_N
+ pin should be configured for pull up.
+ $ref: /schemas/types.yaml#/definitions/flag
+
+required:
+ - compatible
+ - reg
+ - interrupts
+
+unevaluatedProperties: false
+
+examples:
+ - |
+ #include <dt-bindings/interrupt-controller/irq.h>
+ ssbi {
+ #address-cells = <1>;
+ #size-cells = <0>;
+
+ pmic@0 {
+ reg = <0x0>;
+ #address-cells = <1>;
+ #size-cells = <0>;
+
+ pwrkey@1c {
+ compatible = "qcom,pm8921-pwrkey";
+ reg = <0x1c>;
+ interrupt-parent = <&pmicint>;
+ interrupts = <50 IRQ_TYPE_EDGE_RISING>, <51 IRQ_TYPE_EDGE_RISING>;
+ debounce = <15625>;
+ pull-up;
+ };
+ };
+ };
+...
diff --git a/Documentation/devicetree/bindings/input/qcom,pm8xxx-pwrkey.txt b/Documentation/devicetree/bindings/input/qcom,pm8xxx-pwrkey.txt
deleted file mode 100644
index 588536cc96ed..000000000000
--- a/Documentation/devicetree/bindings/input/qcom,pm8xxx-pwrkey.txt
+++ /dev/null
@@ -1,46 +0,0 @@
-Qualcomm PM8xxx PMIC Power Key
-
-PROPERTIES
-
-- compatible:
- Usage: required
- Value type: <string>
- Definition: must be one of:
- "qcom,pm8058-pwrkey"
- "qcom,pm8921-pwrkey"
-
-- reg:
- Usage: required
- Value type: <prop-encoded-array>
- Definition: address of power key control register
-
-- interrupts:
- Usage: required
- Value type: <prop-encoded-array>
- Definition: the first interrupt specifies the key release interrupt
- and the second interrupt specifies the key press interrupt.
- The format of the specifier is defined by the binding
- document describing the node's interrupt parent.
-
-- debounce:
- Usage: optional
- Value type: <u32>
- Definition: time in microseconds that key must be pressed or release
- for state change interrupt to trigger.
-
-- pull-up:
- Usage: optional
- Value type: <empty>
- Definition: presence of this property indicates that the KPDPWR_N pin
- should be configured for pull up.
-
-EXAMPLE
-
- pwrkey@1c {
- compatible = "qcom,pm8921-pwrkey";
- reg = <0x1c>;
- interrupt-parent = <&pmicintc>;
- interrupts = <50 1>, <51 1>;
- debounce = <15625>;
- pull-up;
- };
--
b4 0.10.1
next prev parent reply other threads:[~2022-10-21 9:09 UTC|newest]
Thread overview: 28+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-10-21 9:06 [PATCH v4 00/11] arm: qcom: mdm9615: first round of bindings and DT fixes Neil Armstrong
2022-10-21 9:06 ` [PATCH v4 01/11] dt-bindings: arm: qcom: move swir,mangoh-green-wp8548 board documentation to qcom.yaml Neil Armstrong
2022-10-21 9:06 ` [PATCH v4 02/11] arm: dts: qcom: mdm9615*: add SPDX-License-Identifier Neil Armstrong
2022-10-21 13:42 ` Krzysztof Kozlowski
2022-10-21 13:43 ` Krzysztof Kozlowski
2022-10-21 9:06 ` [PATCH v4 03/11] arm: dts: qcom: mdm9615: add missing reg in cpu@0 node Neil Armstrong
2022-10-21 9:14 ` Konrad Dybcio
2022-10-21 9:06 ` [PATCH v4 04/11] arm: dts: qcom: mdm9615: remove invalid spi-max-frequency gsbi3_spi node Neil Armstrong
2022-10-21 9:14 ` Konrad Dybcio
2022-10-21 9:06 ` [PATCH v4 05/11] dt-bindings: mfd: qcom-pm8xxx: document qcom,pm8921 as fallback of qcom,pm8018 Neil Armstrong
2022-10-31 15:31 ` Lee Jones
2022-10-21 9:06 ` Neil Armstrong [this message]
2022-10-27 7:55 ` [PATCH v4 06/11] dt-bindings: input: qcom,pm8921-pwrkey: convert to dt-schema Dmitry Torokhov
2022-10-27 12:39 ` Neil Armstrong
2022-10-27 12:43 ` Krzysztof Kozlowski
2022-10-28 0:53 ` Dmitry Torokhov
2022-10-21 9:06 ` [PATCH v4 07/11] dt-bindings: rtc: qcom-pm8xxx: document qcom,pm8921-rtc as fallback of qcom,pm8018-rtc Neil Armstrong
2022-10-21 9:06 ` [PATCH v4 08/11] mfd: qcom-pm8xxx: drop unused PM8018 compatible Neil Armstrong
2022-10-31 15:32 ` Lee Jones
2022-10-31 15:35 ` Neil Armstrong
2022-11-02 14:10 ` Krzysztof Kozlowski
2022-11-02 14:40 ` Lee Jones
2022-10-21 9:06 ` [PATCH v4 09/11] rtc: pm8xxx: drop unused pm8018 compatible Neil Armstrong
2022-10-21 9:16 ` Konrad Dybcio
2022-10-21 9:06 ` [PATCH v4 10/11] arm: dts: qcom: mdm9615: remove invalid interrupt-names from pl18x mmc nodes Neil Armstrong
2022-10-21 9:06 ` [PATCH v4 11/11] arm: dts: qcom: mdm9615: remove useless amba subnode Neil Armstrong
2022-10-21 9:16 ` Konrad Dybcio
2022-11-07 3:12 ` (subset) [PATCH v4 00/11] arm: qcom: mdm9615: first round of bindings and DT fixes 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=20220928-mdm9615-dt-schema-fixes-v4-6-dac2dfaac703@linaro.org \
--to=neil.armstrong@linaro.org \
--cc=a.zummo@towertech.it \
--cc=agross@kernel.org \
--cc=alexandre.belloni@bootlin.com \
--cc=andersson@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=dmitry.torokhov@gmail.com \
--cc=konrad.dybcio@somainline.org \
--cc=krzysztof.kozlowski+dt@linaro.org \
--cc=krzysztof.kozlowski@linaro.org \
--cc=lee@kernel.org \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-input@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-rtc@vger.kernel.org \
--cc=quic_c_skakit@quicinc.com \
--cc=robh+dt@kernel.org \
--cc=robh@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).