xref: /freebsd/sys/contrib/device-tree/Bindings/mfd/mt6397.txt (revision 84943d6f38e936ac3b7a3947ca26eeb27a39f938)
1c66ec88fSEmmanuel VadotMediaTek MT6397/MT6323 Multifunction Device Driver
2c66ec88fSEmmanuel Vadot
3c66ec88fSEmmanuel VadotMT6397/MT6323 is a multifunction device with the following sub modules:
4c66ec88fSEmmanuel Vadot- Regulator
5c66ec88fSEmmanuel Vadot- RTC
6c66ec88fSEmmanuel Vadot- Audio codec
7c66ec88fSEmmanuel Vadot- GPIO
8c66ec88fSEmmanuel Vadot- Clock
9c66ec88fSEmmanuel Vadot- LED
10c66ec88fSEmmanuel Vadot- Keys
11c66ec88fSEmmanuel Vadot- Power controller
12c66ec88fSEmmanuel Vadot
13c66ec88fSEmmanuel VadotIt is interfaced to host controller using SPI interface by a proprietary hardware
14c66ec88fSEmmanuel Vadotcalled PMIC wrapper or pwrap. MT6397/MT6323 MFD is a child device of pwrap.
15c66ec88fSEmmanuel VadotSee the following for pwarp node definitions:
16cb7aa33aSEmmanuel Vadot../soc/mediatek/mediatek,pwrap.yaml
17c66ec88fSEmmanuel Vadot
18c66ec88fSEmmanuel VadotThis document describes the binding for MFD device and its sub module.
19c66ec88fSEmmanuel Vadot
20c66ec88fSEmmanuel VadotRequired properties:
21c66ec88fSEmmanuel Vadotcompatible:
22c66ec88fSEmmanuel Vadot	"mediatek,mt6323" for PMIC MT6323
23b97ee269SEmmanuel Vadot	"mediatek,mt6331" for PMIC MT6331 and MT6332
248bab661aSEmmanuel Vadot	"mediatek,mt6357" for PMIC MT6357
25*84943d6fSEmmanuel Vadot	"mediatek,mt6358" for PMIC MT6358
265956d97fSEmmanuel Vadot	"mediatek,mt6359" for PMIC MT6359
27*84943d6fSEmmanuel Vadot	"mediatek,mt6366", "mediatek,mt6358" for PMIC MT6366
28c66ec88fSEmmanuel Vadot	"mediatek,mt6397" for PMIC MT6397
29c66ec88fSEmmanuel Vadot
30c66ec88fSEmmanuel VadotOptional subnodes:
31c66ec88fSEmmanuel Vadot
32c66ec88fSEmmanuel Vadot- rtc
33c66ec88fSEmmanuel Vadot	Required properties: Should be one of follows
34c66ec88fSEmmanuel Vadot		- compatible: "mediatek,mt6323-rtc"
35b97ee269SEmmanuel Vadot		- compatible: "mediatek,mt6331-rtc"
36c66ec88fSEmmanuel Vadot		- compatible: "mediatek,mt6358-rtc"
37c66ec88fSEmmanuel Vadot		- compatible: "mediatek,mt6397-rtc"
38c66ec88fSEmmanuel Vadot	For details, see ../rtc/rtc-mt6397.txt
39c66ec88fSEmmanuel Vadot- regulators
40c66ec88fSEmmanuel Vadot	Required properties:
41c66ec88fSEmmanuel Vadot		- compatible: "mediatek,mt6323-regulator"
42c66ec88fSEmmanuel Vadot	see ../regulator/mt6323-regulator.txt
43c66ec88fSEmmanuel Vadot		- compatible: "mediatek,mt6358-regulator"
44*84943d6fSEmmanuel Vadot		- compatible: "mediatek,mt6366-regulator", "mediatek-mt6358-regulator"
45c66ec88fSEmmanuel Vadot	see ../regulator/mt6358-regulator.txt
46c66ec88fSEmmanuel Vadot		- compatible: "mediatek,mt6397-regulator"
47c66ec88fSEmmanuel Vadot	see ../regulator/mt6397-regulator.txt
48c66ec88fSEmmanuel Vadot- codec
49c66ec88fSEmmanuel Vadot	Required properties:
50c66ec88fSEmmanuel Vadot		- compatible: "mediatek,mt6397-codec" or "mediatek,mt6358-sound"
51c66ec88fSEmmanuel Vadot- clk
52c66ec88fSEmmanuel Vadot	Required properties:
53c66ec88fSEmmanuel Vadot		- compatible: "mediatek,mt6397-clk"
54c66ec88fSEmmanuel Vadot- led
55c66ec88fSEmmanuel Vadot	Required properties:
56c66ec88fSEmmanuel Vadot		- compatible: "mediatek,mt6323-led"
57c66ec88fSEmmanuel Vadot	see ../leds/leds-mt6323.txt
58c66ec88fSEmmanuel Vadot
59c66ec88fSEmmanuel Vadot- keys
60b97ee269SEmmanuel Vadot	Required properties: Should be one of the following
61b97ee269SEmmanuel Vadot		- compatible: "mediatek,mt6323-keys"
62b97ee269SEmmanuel Vadot		- compatible: "mediatek,mt6331-keys"
63b97ee269SEmmanuel Vadot		- compatible: "mediatek,mt6397-keys"
64c66ec88fSEmmanuel Vadot	see ../input/mtk-pmic-keys.txt
65c66ec88fSEmmanuel Vadot
66c66ec88fSEmmanuel Vadot- power-controller
67c66ec88fSEmmanuel Vadot	Required properties:
68c66ec88fSEmmanuel Vadot		- compatible: "mediatek,mt6323-pwrc"
69c66ec88fSEmmanuel Vadot	For details, see ../power/reset/mt6323-poweroff.txt
70c66ec88fSEmmanuel Vadot
71c66ec88fSEmmanuel Vadot- pin-controller
72c66ec88fSEmmanuel Vadot	Required properties:
73c66ec88fSEmmanuel Vadot		- compatible: "mediatek,mt6397-pinctrl"
74c66ec88fSEmmanuel Vadot	For details, see ../pinctrl/pinctrl-mt65xx.txt
75c66ec88fSEmmanuel Vadot
76c66ec88fSEmmanuel VadotExample:
77c66ec88fSEmmanuel Vadot	pwrap: pwrap@1000f000 {
78c66ec88fSEmmanuel Vadot		compatible = "mediatek,mt8135-pwrap";
79c66ec88fSEmmanuel Vadot
80c66ec88fSEmmanuel Vadot		...
81c66ec88fSEmmanuel Vadot
82c66ec88fSEmmanuel Vadot		pmic {
83c66ec88fSEmmanuel Vadot			compatible = "mediatek,mt6397";
84c66ec88fSEmmanuel Vadot
85c66ec88fSEmmanuel Vadot			codec: mt6397codec {
86c66ec88fSEmmanuel Vadot				compatible = "mediatek,mt6397-codec";
87c66ec88fSEmmanuel Vadot			};
88c66ec88fSEmmanuel Vadot
89c66ec88fSEmmanuel Vadot			regulators {
90c66ec88fSEmmanuel Vadot				compatible = "mediatek,mt6397-regulator";
91c66ec88fSEmmanuel Vadot
92c66ec88fSEmmanuel Vadot				mt6397_vpca15_reg: buck_vpca15 {
93c66ec88fSEmmanuel Vadot					regulator-compatible = "buck_vpca15";
94c66ec88fSEmmanuel Vadot					regulator-name = "vpca15";
95c66ec88fSEmmanuel Vadot					regulator-min-microvolt = <850000>;
96c66ec88fSEmmanuel Vadot					regulator-max-microvolt = <1400000>;
97c66ec88fSEmmanuel Vadot					regulator-ramp-delay = <12500>;
98c66ec88fSEmmanuel Vadot					regulator-always-on;
99c66ec88fSEmmanuel Vadot				};
100c66ec88fSEmmanuel Vadot
101c66ec88fSEmmanuel Vadot				mt6397_vgp4_reg: ldo_vgp4 {
102c66ec88fSEmmanuel Vadot					regulator-compatible = "ldo_vgp4";
103c66ec88fSEmmanuel Vadot					regulator-name = "vgp4";
104c66ec88fSEmmanuel Vadot					regulator-min-microvolt = <1200000>;
105c66ec88fSEmmanuel Vadot					regulator-max-microvolt = <3300000>;
106c66ec88fSEmmanuel Vadot					regulator-enable-ramp-delay = <218>;
107c66ec88fSEmmanuel Vadot				};
108c66ec88fSEmmanuel Vadot			};
109c66ec88fSEmmanuel Vadot		};
110c66ec88fSEmmanuel Vadot	};
111