xref: /OK3568_Linux_fs/kernel/Documentation/devicetree/bindings/input/mtk-pmic-keys.txt (revision 4882a59341e53eb6f0b4789bf948001014eff981)
1*4882a593SmuzhiyunMediaTek MT6397/MT6323 PMIC Keys Device Driver
2*4882a593Smuzhiyun
3*4882a593SmuzhiyunThere are two key functions provided by MT6397/MT6323 PMIC, pwrkey
4*4882a593Smuzhiyunand homekey. The key functions are defined as the subnode of the function
5*4882a593Smuzhiyunnode provided by MT6397/MT6323 PMIC that is being defined as one kind
6*4882a593Smuzhiyunof Muti-Function Device (MFD)
7*4882a593Smuzhiyun
8*4882a593SmuzhiyunFor MT6397/MT6323 MFD bindings see:
9*4882a593SmuzhiyunDocumentation/devicetree/bindings/mfd/mt6397.txt
10*4882a593Smuzhiyun
11*4882a593SmuzhiyunRequired properties:
12*4882a593Smuzhiyun- compatible: "mediatek,mt6397-keys" or "mediatek,mt6323-keys"
13*4882a593Smuzhiyun- linux,keycodes: See Documentation/devicetree/bindings/input/input.yaml
14*4882a593Smuzhiyun
15*4882a593SmuzhiyunOptional Properties:
16*4882a593Smuzhiyun- wakeup-source: See Documentation/devicetree/bindings/power/wakeup-source.txt
17*4882a593Smuzhiyun- mediatek,long-press-mode: Long press key shutdown setting, 1 for
18*4882a593Smuzhiyun	pwrkey only, 2 for pwrkey/homekey together, others for disabled.
19*4882a593Smuzhiyun- power-off-time-sec: See Documentation/devicetree/bindings/input/input.yaml
20*4882a593Smuzhiyun
21*4882a593SmuzhiyunExample:
22*4882a593Smuzhiyun
23*4882a593Smuzhiyun	pmic: mt6397 {
24*4882a593Smuzhiyun		compatible = "mediatek,mt6397";
25*4882a593Smuzhiyun
26*4882a593Smuzhiyun		...
27*4882a593Smuzhiyun
28*4882a593Smuzhiyun		mt6397keys: mt6397keys {
29*4882a593Smuzhiyun			compatible = "mediatek,mt6397-keys";
30*4882a593Smuzhiyun			mediatek,long-press-mode = <1>;
31*4882a593Smuzhiyun			power-off-time-sec = <0>;
32*4882a593Smuzhiyun
33*4882a593Smuzhiyun			power {
34*4882a593Smuzhiyun				linux,keycodes = <116>;
35*4882a593Smuzhiyun				wakeup-source;
36*4882a593Smuzhiyun			};
37*4882a593Smuzhiyun
38*4882a593Smuzhiyun			home {
39*4882a593Smuzhiyun				linux,keycodes = <114>;
40*4882a593Smuzhiyun			};
41*4882a593Smuzhiyun		};
42*4882a593Smuzhiyun
43*4882a593Smuzhiyun	};
44