162306a36Sopenharmony_ciMediaTek MT6397/MT6323 Multifunction Device Driver
262306a36Sopenharmony_ci
362306a36Sopenharmony_ciMT6397/MT6323 is a multifunction device with the following sub modules:
462306a36Sopenharmony_ci- Regulator
562306a36Sopenharmony_ci- RTC
662306a36Sopenharmony_ci- Audio codec
762306a36Sopenharmony_ci- GPIO
862306a36Sopenharmony_ci- Clock
962306a36Sopenharmony_ci- LED
1062306a36Sopenharmony_ci- Keys
1162306a36Sopenharmony_ci- Power controller
1262306a36Sopenharmony_ci
1362306a36Sopenharmony_ciIt is interfaced to host controller using SPI interface by a proprietary hardware
1462306a36Sopenharmony_cicalled PMIC wrapper or pwrap. MT6397/MT6323 MFD is a child device of pwrap.
1562306a36Sopenharmony_ciSee the following for pwarp node definitions:
1662306a36Sopenharmony_ci../soc/mediatek/mediatek,pwrap.yaml
1762306a36Sopenharmony_ci
1862306a36Sopenharmony_ciThis document describes the binding for MFD device and its sub module.
1962306a36Sopenharmony_ci
2062306a36Sopenharmony_ciRequired properties:
2162306a36Sopenharmony_cicompatible:
2262306a36Sopenharmony_ci	"mediatek,mt6323" for PMIC MT6323
2362306a36Sopenharmony_ci	"mediatek,mt6331" for PMIC MT6331 and MT6332
2462306a36Sopenharmony_ci	"mediatek,mt6357" for PMIC MT6357
2562306a36Sopenharmony_ci	"mediatek,mt6358" for PMIC MT6358
2662306a36Sopenharmony_ci	"mediatek,mt6359" for PMIC MT6359
2762306a36Sopenharmony_ci	"mediatek,mt6366", "mediatek,mt6358" for PMIC MT6366
2862306a36Sopenharmony_ci	"mediatek,mt6397" for PMIC MT6397
2962306a36Sopenharmony_ci
3062306a36Sopenharmony_ciOptional subnodes:
3162306a36Sopenharmony_ci
3262306a36Sopenharmony_ci- rtc
3362306a36Sopenharmony_ci	Required properties: Should be one of follows
3462306a36Sopenharmony_ci		- compatible: "mediatek,mt6323-rtc"
3562306a36Sopenharmony_ci		- compatible: "mediatek,mt6331-rtc"
3662306a36Sopenharmony_ci		- compatible: "mediatek,mt6358-rtc"
3762306a36Sopenharmony_ci		- compatible: "mediatek,mt6397-rtc"
3862306a36Sopenharmony_ci	For details, see ../rtc/rtc-mt6397.txt
3962306a36Sopenharmony_ci- regulators
4062306a36Sopenharmony_ci	Required properties:
4162306a36Sopenharmony_ci		- compatible: "mediatek,mt6323-regulator"
4262306a36Sopenharmony_ci	see ../regulator/mt6323-regulator.txt
4362306a36Sopenharmony_ci		- compatible: "mediatek,mt6358-regulator"
4462306a36Sopenharmony_ci		- compatible: "mediatek,mt6366-regulator", "mediatek-mt6358-regulator"
4562306a36Sopenharmony_ci	see ../regulator/mt6358-regulator.txt
4662306a36Sopenharmony_ci		- compatible: "mediatek,mt6397-regulator"
4762306a36Sopenharmony_ci	see ../regulator/mt6397-regulator.txt
4862306a36Sopenharmony_ci- codec
4962306a36Sopenharmony_ci	Required properties:
5062306a36Sopenharmony_ci		- compatible: "mediatek,mt6397-codec" or "mediatek,mt6358-sound"
5162306a36Sopenharmony_ci- clk
5262306a36Sopenharmony_ci	Required properties:
5362306a36Sopenharmony_ci		- compatible: "mediatek,mt6397-clk"
5462306a36Sopenharmony_ci- led
5562306a36Sopenharmony_ci	Required properties:
5662306a36Sopenharmony_ci		- compatible: "mediatek,mt6323-led"
5762306a36Sopenharmony_ci	see ../leds/leds-mt6323.txt
5862306a36Sopenharmony_ci
5962306a36Sopenharmony_ci- keys
6062306a36Sopenharmony_ci	Required properties: Should be one of the following
6162306a36Sopenharmony_ci		- compatible: "mediatek,mt6323-keys"
6262306a36Sopenharmony_ci		- compatible: "mediatek,mt6331-keys"
6362306a36Sopenharmony_ci		- compatible: "mediatek,mt6397-keys"
6462306a36Sopenharmony_ci	see ../input/mtk-pmic-keys.txt
6562306a36Sopenharmony_ci
6662306a36Sopenharmony_ci- power-controller
6762306a36Sopenharmony_ci	Required properties:
6862306a36Sopenharmony_ci		- compatible: "mediatek,mt6323-pwrc"
6962306a36Sopenharmony_ci	For details, see ../power/reset/mt6323-poweroff.txt
7062306a36Sopenharmony_ci
7162306a36Sopenharmony_ci- pin-controller
7262306a36Sopenharmony_ci	Required properties:
7362306a36Sopenharmony_ci		- compatible: "mediatek,mt6397-pinctrl"
7462306a36Sopenharmony_ci	For details, see ../pinctrl/pinctrl-mt65xx.txt
7562306a36Sopenharmony_ci
7662306a36Sopenharmony_ciExample:
7762306a36Sopenharmony_ci	pwrap: pwrap@1000f000 {
7862306a36Sopenharmony_ci		compatible = "mediatek,mt8135-pwrap";
7962306a36Sopenharmony_ci
8062306a36Sopenharmony_ci		...
8162306a36Sopenharmony_ci
8262306a36Sopenharmony_ci		pmic {
8362306a36Sopenharmony_ci			compatible = "mediatek,mt6397";
8462306a36Sopenharmony_ci
8562306a36Sopenharmony_ci			codec: mt6397codec {
8662306a36Sopenharmony_ci				compatible = "mediatek,mt6397-codec";
8762306a36Sopenharmony_ci			};
8862306a36Sopenharmony_ci
8962306a36Sopenharmony_ci			regulators {
9062306a36Sopenharmony_ci				compatible = "mediatek,mt6397-regulator";
9162306a36Sopenharmony_ci
9262306a36Sopenharmony_ci				mt6397_vpca15_reg: buck_vpca15 {
9362306a36Sopenharmony_ci					regulator-compatible = "buck_vpca15";
9462306a36Sopenharmony_ci					regulator-name = "vpca15";
9562306a36Sopenharmony_ci					regulator-min-microvolt = <850000>;
9662306a36Sopenharmony_ci					regulator-max-microvolt = <1400000>;
9762306a36Sopenharmony_ci					regulator-ramp-delay = <12500>;
9862306a36Sopenharmony_ci					regulator-always-on;
9962306a36Sopenharmony_ci				};
10062306a36Sopenharmony_ci
10162306a36Sopenharmony_ci				mt6397_vgp4_reg: ldo_vgp4 {
10262306a36Sopenharmony_ci					regulator-compatible = "ldo_vgp4";
10362306a36Sopenharmony_ci					regulator-name = "vgp4";
10462306a36Sopenharmony_ci					regulator-min-microvolt = <1200000>;
10562306a36Sopenharmony_ci					regulator-max-microvolt = <3300000>;
10662306a36Sopenharmony_ci					regulator-enable-ramp-delay = <218>;
10762306a36Sopenharmony_ci				};
10862306a36Sopenharmony_ci			};
10962306a36Sopenharmony_ci		};
11062306a36Sopenharmony_ci	};
111