new file mode 100644
@@ -31,6 +31,7 @@ properties:
- mediatek,mt6358-keys
- mediatek,mt6359-keys
- mediatek,mt6397-keys
+ - mediatek,mt6363-keys
power-off-time-sec: true
new file mode 100644
@@ -0,0 +1,50 @@
+# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) %YAML 1.2
+---
+$id: http://devicetree.org/schemas/mfd/mediatek,mt6685.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: MediaTek MT6685 Clock IC
+
+maintainers:
+ - Lu Tang <lu.tang@mediatek.com>
+
+description: |
+ MT6685 is a clock IC.
+ Please see the sub-modules below for supported features.
+
+ MT6685 is a multifunction device with the following sub modules:
+ - RTC
+ - Clock
+
+properties:
+ compatible:
+ const: mediatek,mt6685
+
+ interrupts:
+ maxItems: 1
+
+ interrupt-controller: true
+
+ "#interrupt-cells":
+ const: 2
+
+required:
+ - compatible
+
+additionalProperties: false
+
+examples:
+ - |
+ #include <dt-bindings/spmi/spmi.h>
+ #include <dt-bindings/interrupt-controller/irq.h>
+ #include <dt-bindings/interrupt-controller/arm-gic.h>
+
+ spmi {
+ mfd@9 {
+ compatible = "mediatek,mt6685";
+ reg = <0x9 SPMI_USID>;
+ #address-cells = <1>;
+ #size-cells = <0>;
+ };
+ };
new file mode 100644
@@ -0,0 +1,173 @@
+# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) %YAML 1.2
+---
+$id: http://devicetree.org/schemas/mfd/mediatek,spmi-pmic.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: MediaTek SPMI PMICs multi-function device
+
+maintainers:
+ - Lu Tang <lu.tang@mediatek.com>
+
+description: |
+ Some Mediatek PMICs are interfaced to the chip via the SPMI (System
+Power
+ Management Interface) bus.
+
+ The Mediatek SPMI series includes the MT6363, MT6373, MT6316 and
+ other PMICs.Please see the sub-modules below for supported features.
+
+ MT6363/MT6373 is a multifunction device with the following sub modules:
+ - Regulators
+ - ADC
+ - GPIO
+ - Keys
+ MT6316 is a multifunction device with the following sub modules:
+ - Regulators
+
+properties:
+ compatible:
+ oneOf:
+ - enum:
+ - mediatek,mt6363
+ - mediatek,mt6373
+ - mediatek,mt6316
+
+ interrupts:
+ maxItems: 1
+
+ interrupt-controller: true
+
+ "#interrupt-cells":
+ const: 2
+
+ regulators:
+ type: object
+ description:
+ List of child nodes that specify the regulators.
+ additionalProperties: true
+
+ properties:
+ compatible:
+ oneOf:
+ - enum:
+ - mediatek,mt6363-regulator
+ - mediatek,mt6373-regulator
+ - mediatek,mt6316-regulator
+
+ required:
+ - compatible
+
+ adc:
+ type: object
+ $ref: /schemas/iio/adc/mediatek,spmi-pmic-auxadc.yaml#
+ unevaluatedProperties: false
+
+ keys:
+ type: object
+ $ref: /schemas/input/mediatek,pmic-keys.yaml
+ unevaluatedProperties: false
+ description:
+ Power and Home keys.
+
+ pinctrl:
+ type: object
+ $ref: /schemas/pinctrl/mediatek,mt65xx-pinctrl.yaml
+ unevaluatedProperties: false
+ description:
+ Pin controller
+
+required:
+ - compatible
+ - regulators
+
+additionalProperties: false
+
+examples:
+ - |
+ #include <dt-bindings/spmi/spmi.h>
+ #include <dt-bindings/interrupt-controller/irq.h>
+ #include <dt-bindings/interrupt-controller/arm-gic.h>
+
+ spmi {
+ main_pmic: pmic@4 {
+ compatible = "mediatek,mt6363";
+ reg = <0x4 SPMI_USID>;
+ interrupts = <0x4 IRQ_TYPE_NONE>;
+ #address-cells = <0>;
+ interrupt-controller;
+ #interrupt-cells = <2>;
+
+ mt6363keys: keys {
+ compatible = "mediatek,mt6363-keys";
+ mediatek,long-press-mode = <1>;
+ power-off-time-sec = <0>;
+
+ power {
+ linux,keycodes = <116>;
+ wakeup-source;
+ };
+
+ home {
+ linux,keycodes = <115>;
+ };
+ };
+
+ mt6363_pio: pinctrl {
+ compatible = "mediatek,mt6363-pinctrl";
+ gpio-controller;
+ #gpio-cells = <2>;
+ };
+
+ mt6363regulator: regulators {
+ compatible = "mediatek,mt6363-regulator";
+
+ mt6363_vs2: vs2 {
+ regulator-name = "mt6363_vs2";
+ regulator-allowed-modes = <0 1 2>;
+ regulator-always-on;
+ regulator-allow-set-load;
+ };
+
+ mt6363_vbuck1: vbuck1 {
+ regulator-name = "mt6363_vbuck1";
+ regulator-allowed-modes = <0 1 2>;
+ };
+
+ mt6363_vbuck2: vbuck2 {
+ regulator-name = "mt6363_vbuck2";
+ regulator-allowed-modes = <0 1 2>;
+ };
+
+ mt6363_vbuck3: vbuck3 {
+ regulator-name = "mt6363_vbuck3";
+ regulator-allowed-modes = <0 1 2>;
+ };
+
+ mt6363_vbuck4: vbuck4 {
+ regulator-name = "mt6363_vbuck4";
+ regulator-allowed-modes = <0 1 2>;
+ };
+
+ mt6363_vbuck5: vbuck5 {
+ regulator-name = "mt6363_vbuck5";
+ regulator-allowed-modes = <0 1 2>;
+ };
+
+ mt6363_vbuck6: vbuck6 {
+ regulator-name = "mt6363_vbuck6";
+ regulator-allowed-modes = <0 1 2>;
+ };
+
+ mt6363_vbuck7: vbuck7 {
+ regulator-name = "mt6363_vbuck7";
+ regulator-allowed-modes = <0 1 2>;
+ };
+
+ // ...
+
+ mt6363_isink_load: isink-load {
+ regulator-name = "mt6363_isink_load";
+ };
+ };
+ };
+ };
Update email -----邮件原件----- 发件人: Lu.Tang <Lu.Tang@mediatek.com> 发送时间: 2025年3月14日 15:33 收件人: Jonathan Cameron <jic23@kernel.org>; Lars-Peter Clausen <lars@metafoo.de>; Rob Herring <robh@kernel.org>; Krzysztof Kozlowski <krzk+dt@kernel.org>; Conor Dooley <conor+dt@kernel.org>; Dmitry Torokhov <dmitry.torokhov@gmail.com>; Lee Jones <lee@kernel.org>; Matthias Brugger <matthias.bgg@gmail.com>; AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>; Sean Wang <sean.wang@kernel.org>; Linus Walleij <linus.walleij@linaro.org>; Liam Girdwood <lgirdwood@gmail.com>; Mark Brown <broonie@kernel.org>; Stephen Boyd <sboyd@kernel.org>; Chen Zhong (钟辰) <Chen.Zhong@mediatek.com>; Sen Chu <shen.chu@mediatek.com> 抄送: linux-iio@vger.kernel.org; devicetree@vger.kernel.org; linux-kernel@vger.kernel.org; linux-input@vger.kernel.org; linux-arm-kernel@lists.infradead.org; linux-mediatek@lists.infradead.org; linux-gpio@vger.kernel.org; Project_Global_Chrome_Upstream_Group <Project_Global_Chrome_Upstream_Group@mediatek.com>; Lu Tang (汤璐) <Lu.Tang@mediatek.com> 主题: [PATCH 5/5] dt-bindings: pmic: mediatek: Add pmic documents Add new pmic mfd and adc documents for mt8196 Signed-off-by: Lu.Tang <Lu.Tang@mediatek.com> --- .../iio/adc/mediatek,spmi-pmic-auxadc.yaml | 31 ++++ .../bindings/input/mediatek,pmic-keys.yaml | 1 + .../bindings/mfd/mediatek,mt6685.yaml | 50 +++++ .../bindings/mfd/mediatek,spmi-pmic.yaml | 173 ++++++++++++++++++ .../pinctrl/mediatek,mt65xx-pinctrl.yaml | 1 + 5 files changed, 256 insertions(+) create mode 100644 Documentation/devicetree/bindings/iio/adc/mediatek,spmi-pmic-auxadc.yaml create mode 100644 Documentation/devicetree/bindings/mfd/mediatek,mt6685.yaml create mode 100644 Documentation/devicetree/bindings/mfd/mediatek,spmi-pmic.yaml +++ b/Documentation/devicetree/bindings/iio/adc/mediatek,spmi-pmic-auxad +++ c.yaml @@ -0,0 +1,31 @@ +# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause) %YAML 1.2 +--- +$id: +http://devicetree.org/schemas/iio/adc/mediatek,spmi-pmic-auxadc.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: MediaTek SPMI PMIC AUXADC + +maintainers: + - Lu Tang <lu.tang@mediatek.com> + +description: + The Auxiliary Analog/Digital Converter (AUXADC) is an ADC found + in some MediaTek PMICs, performing various PMIC related measurements + such as battery and PMIC internal voltage regulators temperatures, + other than voltages for various PMIC internal components. + +properties: + compatible: + enum: + - mediatek,mt6363-auxadc + - mediatek,mt6373-auxadc + + "#io-channel-cells": + const: 1 + +required: + - compatible + - "#io-channel-cells" + +additionalProperties: false +++ b/Documentation/devicetree/bindings/pinctrl/mediatek,mt65xx-pinctrl. +++ yaml @@ -17,6 +17,7 @@ properties: enum: - mediatek,mt2701-pinctrl - mediatek,mt2712-pinctrl + - mediatek,mt6363-pinctrl - mediatek,mt6397-pinctrl - mediatek,mt7623-pinctrl - mediatek,mt8127-pinctrl -- 2.46.0