regulator: mt6360: Add support for MT6360 regulator
v4 cover regulator: mt6360: Add support for MT6360 regulator
This patch series add MT6360 regulator support contains driver and binding document
Gene Chen (2)
regulator: mt6360: Add support for MT6360 regulator
dt-bindings: regulator: mt6360: Add DT binding
Documentation/devicetree/bindings/regulator/mt6360-regulator.yaml | 113 ++ drivers/regulator/Kconfig | 9 drivers/regulator/Makefile | 1 drivers/regulator/mt6360-regulator.c | 459 ++++++++++ include/dt-bindings/regulator/mediatek,mt6360-regulator.h | 16 5 files changed, 598 insertions(+)
changelogs between v1 & v2
- regulator: merge regmap to mfd driver for r/w with crc
changelogs between v2 & v3
- Move regmap define to MFD parent driver
- Add bindings document
changelogs between v3 & v4
- replace of_node binding table by platform_id_table
- set regulator_desc.regulators_node find dt
_______________________________________________
Linux-mediatek mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/linux-mediatek
PATCH v4 1/2 regulator: mt6360: Add support for MT6360 regulator
From: Gene Chen <[email protected]>
Add MT6360 regulator driver that contains two BUCKs and six LDOs
--- drivers/regulator/Kconfig | 9 + drivers/regulator/Makefile | 1 + drivers/regulator/mt6360-regulator.c | 459 +++++++++++++++++++++ .../regulator/mediatek,mt6360-regulator.h | 16 + 4 files changed, 485 insertions(+) create mode 100644 drivers/regulator/mt6360-regulator.c create mode 100644 include/dt-bindings/regulator/mediatek,mt6360-regulator.h
drivers/regulator/Kconfig +9 -0
@@ -711,6 +711,15 @@ config REGULATOR_MT6358 This driver supports the control of different power rails of device through regulator interface. +config REGULATOR_MT6360 + tristate "MT6360 SubPMIC Regulator" + depends on MFD_MT6360 + help + Say Y here to enable MT6360 regulator support. + This is support MT6360 PMIC/LDO part include + 2-channel buck with Thermal Shutdown and Overload Protection + 6-channel High PSRR and Low Dropout LDO. + config REGULATOR_MT6380 tristate "MediaTek MT6380 PMIC" depends on MTK_PMIC_WRAP
drivers/regulator/Makefile +1 -0
@@ -88,6 +88,7 @@ obj-$(CONFIG_REGULATOR_MPQ7920) += mpq7920.o obj-$(CONFIG_REGULATOR_MT6311) += mt6311-regulator.o obj-$(CONFIG_REGULATOR_MT6323) += mt6323-regulator.o obj-$(CONFIG_REGULATOR_MT6358) += mt6358-regulator.o +obj-$(CONFIG_REGULATOR_MT6360) += mt6360-regulator.o obj-$(CONFIG_REGULATOR_MT6380) += mt6380-regulator.o obj-$(CONFIG_REGULATOR_MT6397) += mt6397-regulator.o obj-$(CONFIG_REGULATOR_QCOM_LABIBB) += qcom-labibb-regulator.o
drivers/regulator/mt6360-regulator.c new file +459 -0
459 lines not on this page · raw message
include/dt-bindings/regulator/mediatek,mt6360-regulator.h new file +16 -0
@@ -0,0 +1,16 @@ +/* SPDX-License-Identifier: GPL-2.0 */ + +#ifndef __DT_BINDINGS_MEDIATEK_MT6360_REGULATOR_H__ +#define __DT_BINDINGS_MEDIATEK_MT6360_REGULATOR_H__ + +/* +* BUCK/LDO mode constants which may be used in devicetree properties +* (eg. regulator-allowed-modes). +* See the manufacturer's datasheet for more information on these modes. +*/ + +#define MT6360_OPMODE_LP 2 +#define MT6360_OPMODE_ULP 3 +#define MT6360_OPMODE_NORMAL 0 + +#endif
Signature · 1 line
2.7.4
PATCH v4 2/2 dt-bindings: regulator: mt6360: Add DT binding documentation
In reply to Gene ChenFrom: Gene Chen <[email protected]>
Add a devicetree binding documentation for the mt6360 regulator driver.
--- .../bindings/regulator/mt6360-regulator.yaml | 113 +++++++++++++++++++++ 1 file changed, 113 insertions(+) create mode 100644 Documentation/devicetree/bindings/regulator/mt6360-regulator.yaml
Documentation/devicetree/bindings/regulator/mt6360-regulator.yaml new file +113 -0
@@ -0,0 +1,113 @@ +# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/regulator/mt6360-regulator.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: MT6360 Regulator from MediaTek Integrated + +maintainers: + - Gene Chen <[email protected]> + +description: | + list of regulators provided by this controller, must be named + after their hardware counterparts buck1/2 or ldo1/2/3/5/6/7 + +properties: + compatible: + const: mediatek,mt6360-regulator + + LDO_VIN1-supply: + description: Input supply phandle(s) for LDO1/2/3 + LDO_VIN2-supply: + description: Input supply phandle(s) for LDO5 + LDO_VIN3-supply: + description: Input supply phandle(s) for LDO6/7 + +patternProperties: + "^buck[12]$": + $ref: "regulator.yaml#" + + "^ldo[123567]$": + $ref: "regulator.yaml#" + +required: + - compatible + +additionalProperties: false + +examples: + - | + #include <dt-bindings/interrupt-controller/irq.h> + #include <dt-bindings/regulator/mediatek,mt6360-regulator.h> + regulator { + compatible = "mediatek,mt6360-regulator"; + LDO_VIN3-supply = <&BUCK2>; + buck1 { + regulator-compatible = "BUCK1"; + regulator-name = "mt6360,buck1"; + regulator-min-microvolt = <300000>; + regulator-max-microvolt = <1300000>; + regulator-allowed-modes = <MT6360_OPMODE_NORMAL + MT6360_OPMODE_LP + MT6360_OPMODE_ULP>; + }; + BUCK2: buck2 { + regulator-compatible = "BUCK2"; + regulator-name = "mt6360,buck2"; + regulator-min-microvolt = <300000>; + regulator-max-microvolt = <1300000>; + regulator-allowed-modes = <MT6360_OPMODE_NORMAL + MT6360_OPMODE_LP + MT6360_OPMODE_ULP>; + }; + ldo6 { + regulator-compatible = "LDO6"; + regulator-name = "mt6360,ldo6"; + regulator-min-microvolt = <500000>; + regulator-max-microvolt = <2100000>; + regulator-allowed-modes = <MT6360_OPMODE_NORMAL + MT6360_OPMODE_LP>; + }; + ldo7 { + regulator-compatible = "LDO7"; + regulator-name = "mt6360,ldo7"; + regulator-min-microvolt = <500000>; + regulator-max-microvolt = <2100000>; + regulator-allowed-modes = <MT6360_OPMODE_NORMAL + MT6360_OPMODE_LP>; + }; + ldo1 { + regulator-compatible = "LDO1"; + regulator-name = "mt6360,ldo1"; + regulator-min-microvolt = <1200000>; + regulator-max-microvolt = <3600000>; + regulator-allowed-modes = <MT6360_OPMODE_NORMAL + MT6360_OPMODE_LP>; + }; + ldo2 { + regulator-compatible = "LDO2"; + regulator-name = "mt6360,ldo2"; + regulator-min-microvolt = <1200000>; + regulator-max-microvolt = <3600000>; + regulator-allowed-modes = <MT6360_OPMODE_NORMAL + MT6360_OPMODE_LP>; + }; + ldo3 { + regulator-compatible = "LDO3"; + regulator-name = "mt6360,ldo3"; + regulator-min-microvolt = <1200000>; + regulator-max-microvolt = <3600000>; + regulator-allowed-modes = <MT6360_OPMODE_NORMAL + MT6360_OPMODE_LP>; + }; + ldo5 { + regulator-compatible = "LDO5"; + regulator-name = "mt6360,ldo5"; + regulator-min-microvolt = <2700000>; + regulator-max-microvolt = <3600000>; + regulator-allowed-modes = <MT6360_OPMODE_NORMAL + MT6360_OPMODE_LP>; + }; + }; +...
Signature · 7 lines
2.7.4 _______________________________________________ Linux-mediatek mailing list [email protected] http://lists.infradead.org/mailman/listinfo/linux-mediatek
Mark Brown
maintainerQuoted 6 lines · Gene Chen
This patch series add MT6360 regulator support contains driver and binding document
Gene Chen (2)
regulator: mt6360: Add support for MT6360 regulator
dt-bindings: regulator: mt6360: Add DT binding
Quoted 8 lines
Documentation/devicetree/bindings/regulator/mt6360-regulator.yaml | 113 ++ drivers/regulator/Kconfig | 9 drivers/regulator/Makefile | 1 drivers/regulator/mt6360-regulator.c | 459 ++++++++++ include/dt-bindings/regulator/mediatek,mt6360-regulator.h | 16 5 files changed, 598 insertions(+)[...]
Applied to
https://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator.git for-next
Thanks!
[1/2] regulator: mt6360: Add support for MT6360 regulator
commit: d321571d5e4c2d5511b75e6cf1a910e0a0c2a2e9
[2/2] dt-bindings: regulator: mt6360: Add DT binding documentation
commit: 9b1d3422e16ffcd4dad7729459717b216490540dAll being well this means that it will be integrated into the linux-next tree (usually sometime in the next 24 hours) and sent to Linus during the next merge window (or sooner if it is a bug fix), however if problems are discovered then the patch may be dropped or reverted.
You may get further e-mails resulting from automated or manual testing and review of the tree, please engage with people reporting problems and send followup patches addressing any issues that are reported if needed.
If any updates are required or you are submitting further changes they should be sent as incremental updates against current git, existing patches will not be replaced.
Please add any relevant lists and maintainers to the CCs when replying to this mail.
Thanks,
Mark