Add Richtek RTQ2208 SubPMIC support
Subsystems (2)
v3 cover Add Richtek RTQ2208 SubPMIC support
From: alinayu <[email protected]>
This patch series adds support for RTQ2208 SubPMIC regulators. The RTQ2208 is a multi-phase, programmable power management IC that integrate with dual multi-configurable, synchronous buck converters and two ldos. The bucks features wide output voltage range from 0.4V to 2.05V and the capability to configure the corresponding power stages.
Thank you,
Alina yu
---
Change in v3:
- In Patch 1/2:
- Fix some typos
- Modify the descriptions for "richtek,mtp-sel"
- Modify the node name to lowercase and remove underscore
- Remove '|' from description
- Remove "regulator-compatible" from property
- Remove "regulator-state-mem" from pattern
- Modify node name to generic one
---
alinayu (2):
regulator: dt-bindings: rtq2208: Add Richtek RTQ2208 SubPMIC
regulator: rtq2208: Add Richtek RTQ2208 SubPMIC driver
.../regulator/richtek,rtq2208-regulator.yaml | 206 ++++++++ drivers/regulator/Kconfig | 11 + drivers/regulator/Makefile | 1 + drivers/regulator/rtq2208-regulator.c | 538 +++++++++++++++++++++ 4 files changed, 756 insertions(+) create mode 100644 Documentation/devicetree/bindings/regulator/richtek,rtq2208-regulator.yaml create mode 100644 drivers/regulator/rtq2208-regulator.c
Signature · 1 line
2.7.4
PATCH v3 1/2 regulator: dt-bindings: rtq2208: Add Richtek RTQ2208 SubPMIC
From: alinayu <[email protected]>
Add bindings for Richtek RTQ2208 IC controlled SubPMIC
---
v3
- Fix some typos
- Modify the descriptions for "richtek,mtp-sel"
- Modify the node name to lowercase and remove underscore
- Remove '|' from description
- Remove "regulator-compatible" from property
- Remove "regulator-state-mem" from pattern
- Modify node name to generic one
--- .../regulator/richtek,rtq2208-regulator.yaml | 206 +++++++++++++++++++++ 1 file changed, 206 insertions(+) create mode 100644 Documentation/devicetree/bindings/regulator/richtek,rtq2208-regulator.yaml
Documentation/devicetree/bindings/regulator/richtek,rtq2208-regulator.yaml new file +206 -0
@@ -0,0 +1,206 @@ +# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/regulator/richtek,rtq2208-regulator.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Richtek RTQ2208 SubPMIC Regulator + +maintainers: + - Alina Yu <[email protected]> + +description: | + RTQ2208 is a highly integrated power converter that offers functional safety dual + multi-configurable synchronous buck converters and two LDOs. + + Bucks support "regulator-allowed-modes" and "regulator-mode". The former defines the permitted + switching operation in normal mode; the latter defines the operation in suspend to RAM mode. + + No matter the RTQ2208 is configured to normal or suspend to RAM mode, there are two switching + operation modes for all buck rails, automatic power saving mode (Auto mode) and forced continuous + conduction mode (FCCM). + + The definition of modes is in the datasheet which is available in below link + and their meaning is:: + 0 - Auto mode for power saving, which reducing the switching frequency at light load condition + to maintain high frequency. + 1 - FCCM to meet the strict voltage regulation accuracy, which keeping constant switching frequency. + + Datasheet will be available soon at + https://www.richtek.com/assets/Products + +properties: + compatible: + enum: + - richtek,rtq2208 + + reg: + maxItems: 1 + + interrupts: + maxItems: 1 + + richtek,mtp-sel: + type: boolean + description: + vout register selection besed on this boolean value. + false - Using DVS0 register setting to adjust vout + true - Using DVS1 register setting to adjust vout + + regulators: + type: object + + patternProperties: + "^buck-[a-h]$": + type: object + $ref: regulator.yaml# + unevaluatedProperties: false + description: + description for buck-[a-h] regulator. + + properties: + regulator-allowed-modes: + description: + two buck modes in different switching accuracy. + items: + enum: [0, 1] + + regulator-mode: + enum: [0, 1] + description: + describe buck initial operating mode in suspend state. + + "^ldo[1-2]$": + type: object + $ref: regulator.yaml# + description: + regulator description for ldo[1-2]. + + properties: + regulator-compatible: + pattern: "^LDO[1-2]$" + + richtek,fixed-uV: + $ref: "/schemas/types.yaml#/definitions/uint32" + enum: [ 900000, 1200000, 1800000, 3300000 ] + description: + the fixed voltage in micro volt which is decided at the factory. + +required: + - compatible + - reg + - regulators + +unevaluatedProperties: false + +examples: + - | + #include <dt-bindings/interrupt-controller/irq.h> + i2c { + #address-cells = <1>; + #size-cells = <0>; + + pmic@10 { + compatible = "richtek,rtq2208"; + reg = <0x10>; + interrupts-extended = <&gpio26 0 IRQ_TYPE_LEVEL_LOW>; + richtek,mtp-sel; + + regulators { + buck-a { + regulator-min-microvolt = <400000>; + regulator-max-microvolt = <2050000>; + regulator-allowed-modes = <0 1>; + regulator-always-on; + regulator-state-mem { + regulator-on-in-suspend; + regulator-mode = <1>; + }; + }; + buck-b { + regulator-min-microvolt = <400000>; + regulator-max-microvolt = <2050000>; + regulator-allowed-modes = <0 1>; + regulator-always-on; + regulator-state-mem { + regulator-on-in-suspend; + regulator-mode = <1>; + }; + }; + buck-c { + regulator-min-microvolt = <400000>; + regulator-max-microvolt = <2050000>; + regulator-allowed-modes = <0 1>; + regulator-always-on; + regulator-state-mem { + regulator-on-in-suspend; + regulator-mode = <1>; + }; + }; + buck-d { + regulator-min-microvolt = <400000>; + regulator-max-microvolt = <2050000>; + regulator-allowed-modes = <0 1>; + regulator-always-on; + regulator-state-mem { + regulator-on-in-suspend; + regulator-mode = <1>; + }; + }; + buck-e { + regulator-min-microvolt = <400000>; + regulator-max-microvolt = <2050000>; + regulator-allowed-modes = <0 1>; + regulator-always-on; + regulator-state-mem { + regulator-on-in-suspend; + regulator-mode = <1>; + }; + }; + buck-f { + regulator-min-microvolt = <400000>; + regulator-max-microvolt = <2050000>; + regulator-allowed-modes = <0 1>; + regulator-always-on; + regulator-state-mem { + regulator-on-in-suspend; + regulator-mode = <1>; + }; + }; + buck-g { + regulator-min-microvolt = <400000>; + regulator-max-microvolt = <2050000>; + regulator-allowed-modes = <0 1>; + regulator-always-on; + regulator-state-mem { + regulator-on-in-suspend; + regulator-mode = <1>; + }; + }; + buck-h { + regulator-min-microvolt = <400000>; + regulator-max-microvolt = <2050000>; + regulator-allowed-modes = <0 1>; + regulator-always-on; + regulator-state-mem { + regulator-on-in-suspend; + regulator-mode = <1>; + }; + }; + ldo1 { + richtek,fixed-uV = <1200000>; + regulator-always-on; + regulator-state-mem { + regulator-on-in-suspend; + }; + }; + ldo2 { + regulator-always-on; + richtek,fixed-uV = <3300000>; + regulator-state-mem { + regulator-on-in-suspend; + }; + }; + }; + }; + };
Signature · 1 line
2.7.4
Re: [PATCH v3 1/2] regulator: dt-bindings: rtq2208: Add Richtek RTQ2208 SubPMIC
Documentation/devicetree/bindings/regulator/richtek,rtq2208-regulator.yaml
Quoted 24 lines · On 19/07/2023 06:25, [email protected] wrote:
From: alinayu <[email protected]>
Add bindings for Richtek RTQ2208 IC controlled SubPMIC
Signed-off-by Alina Yu <[email protected]>---
v3
- Fix some typos
- Modify the descriptions for "richtek,mtp-sel"
- Modify the node name to lowercase and remove underscore
- Remove '|' from description
- Remove "regulator-compatible" from property
- Remove "regulator-state-mem" from pattern
- Modify node name to generic one--- .../regulator/richtek,rtq2208-regulator.yaml | 206 +++++++++++++++++++++ 1 file changed, 206 insertions(+) create mode 100644 Documentation/devicetree/bindings/regulator/richtek,rtq2208-regulator.yamlDocumentation/devicetree/bindings/regulator/richtek,rtq2208-regulator.yaml new file +0
-0
No improvements here.
This is a friendly reminder during the review process.
It seems my previous comments were not fully addressed. Maybe my feedback got lost between the quotes, maybe you just forgot to apply it. Please go back to the previous discussion and either implement all requested changes or keep discussing them.
Thank you.
Best regards,
Krzysztof
Re: [PATCH v3 1/2] regulator: dt-bindings: rtq2208: Add Richtek RTQ2208 SubPMIC
Hi,
Krzysztof,
Quoted 35 lines · Krzysztof Kozlowski
Documentation/devicetree/bindings/regulator/richtek,rtq2208-regulator.yaml
Quoted 24 lines · On 19/07/2023 06:25, [email protected] wrote:
From: alinayu <[email protected]>
Add bindings for Richtek RTQ2208 IC controlled SubPMIC
Signed-off-by Alina Yu <[email protected]>---
v3
- Fix some typos
- Modify the descriptions for "richtek,mtp-sel"
- Modify the node name to lowercase and remove underscore
- Remove '|' from description
- Remove "regulator-compatible" from property
- Remove "regulator-state-mem" from pattern
- Modify node name to generic one--- .../regulator/richtek,rtq2208-regulator.yaml | 206 +++++++++++++++++++++ 1 file changed, 206 insertions(+) create mode 100644 Documentation/devicetree/bindings/regulator/richtek,rtq2208-regulator.yamlDocumentation/devicetree/bindings/regulator/richtek,rtq2208-regulator.yaml new file +0
-0No improvements here.
This is a friendly reminder during the review process.
It seems my previous comments were not fully addressed. Maybe my feedback got lost between the quotes, maybe you just forgot to apply it. Please go back to the previous discussion and either implement all requested changes or keep discussing them.
Quoted 5 lines
Thank you.
Best regards,
Krzysztof
Sorry, I missed this one "Filename like compatible".
If I modify the filename to "richtek,rtq2208.yaml", is it unlike a compatible ?
Best regards,
Alina
Re: [PATCH v3 1/2] regulator: dt-bindings: rtq2208: Add Richtek RTQ2208 SubPMIC
Quoted 41 lines · Alina Yu
Hi,
Krzysztof,Quoted 37 lines · Krzysztof Kozlowski
Documentation/devicetree/bindings/regulator/richtek,rtq2208-regulator.yaml
Quoted 24 lines · On 19/07/2023 06:25, [email protected] wrote:
From: alinayu <[email protected]>
Add bindings for Richtek RTQ2208 IC controlled SubPMIC
Signed-off-by Alina Yu <[email protected]>---
v3
- Fix some typos
- Modify the descriptions for "richtek,mtp-sel"
- Modify the node name to lowercase and remove underscore
- Remove '|' from description
- Remove "regulator-compatible" from property
- Remove "regulator-state-mem" from pattern
- Modify node name to generic one--- .../regulator/richtek,rtq2208-regulator.yaml | 206 +++++++++++++++++++++ 1 file changed, 206 insertions(+) create mode 100644 Documentation/devicetree/bindings/regulator/richtek,rtq2208-regulator.yamlDocumentation/devicetree/bindings/regulator/richtek,rtq2208-regulator.yaml new file +0
-0No improvements here.
This is a friendly reminder during the review process.
It seems my previous comments were not fully addressed. Maybe my feedback got lost between the quotes, maybe you just forgot to apply it. Please go back to the previous discussion and either implement all requested changes or keep discussing them.
Thank you.
Quoted 7 lines
Quoted 3 lines
Best regards,
KrzysztofSorry, I missed this one "Filename like compatible".
If I modify the filename to "richtek,rtq2208.yaml", is it unlike a compatible ?
Yes.
Best regards,
Krzysztof
PATCH v3 2/2 regulator: rtq2208: Add Richtek RTQ2208 SubPMIC driver
In reply to [email protected]From: alinayu <[email protected]>
Add support for the RTQ2208 SubPMIC
This ic integrates with configurable, synchrnous buck converters and two ldos.
--- drivers/regulator/Kconfig | 11 + drivers/regulator/Makefile | 1 + drivers/regulator/rtq2208-regulator.c | 538 ++++++++++++++++++++++++++++++++++ 3 files changed, 550 insertions(+) create mode 100644 drivers/regulator/rtq2208-regulator.c
drivers/regulator/Kconfig +11 -0
@@ -1213,6 +1213,17 @@ config REGULATOR_RTQ6752 synchronous boost converters for PAVDD, and one synchronous NAVDD buck-boost. This device is suitable for automotive TFT-LCD panel. +config REGULATOR_RTQ2208 + tristate "Richtek RTQ2208 SubPMIC Regulator" + depends on I2C + select REGMAP_I2C + help + This driver adds support for RTQ2208 SubPMIC regulators. + The RTQ2208 is a multi-phase, programmable power management IC that + integrate with dual multi-configurable, synchronous buck converters + and two ldos. It features wide output voltage range from 0.4V to 2.05V + and the capability to configure the corresponding power stages. + config REGULATOR_S2MPA01 tristate "Samsung S2MPA01 voltage regulator" depends on MFD_SEC_CORE || COMPILE_TEST
drivers/regulator/Makefile +1 -0
@@ -143,6 +143,7 @@ obj-$(CONFIG_REGULATOR_RT6245) += rt6245-regulator.o obj-$(CONFIG_REGULATOR_RTMV20) += rtmv20-regulator.o obj-$(CONFIG_REGULATOR_RTQ2134) += rtq2134-regulator.o obj-$(CONFIG_REGULATOR_RTQ6752) += rtq6752-regulator.o +obj-$(CONFIG_REGULATOR_RTQ2208) += rtq2208-regulator.o obj-$(CONFIG_REGULATOR_S2MPA01) += s2mpa01.o obj-$(CONFIG_REGULATOR_S2MPS11) += s2mps11.o obj-$(CONFIG_REGULATOR_S5M8767) += s5m8767.o
drivers/regulator/rtq2208-regulator.c new file +538 -0
538 lines not on this page · raw message
Signature · 1 line
2.7.4