blob: 8398a3a5e106e80d813d04cffda6c11283d7b0d0 [file] [log] [blame]
Laxman Dewangane5812452016-06-17 16:21:06 +05301Binding for Maxim MAX77686/MAX77802/MAX77620 32k clock generator block
Tomasz Figab06c6982013-12-12 17:07:20 +01002
Laxman Dewangane5812452016-06-17 16:21:06 +05303This is a part of device tree bindings of MAX77686/MAX77802/MAX77620
4multi-function device. More information can be found in MFD DT binding
5doc as follows:
6 bindings/mfd/max77686.txt for MAX77686 and
7 bindings/mfd/max77802.txt for MAX77802 and
8 bindings/mfd/max77620.txt for MAX77620.
Tomasz Figab06c6982013-12-12 17:07:20 +01009
10The MAX77686 contains three 32.768khz clock outputs that can be controlled
Laxman Dewangane5812452016-06-17 16:21:06 +053011(gated/ungated) over I2C. Clocks are defined as preprocessor macros in
12dt-bindings/clock/maxim,max77686.h.
13
Tomasz Figab06c6982013-12-12 17:07:20 +010014
Laxman Dewangan24f668d2016-06-17 16:21:05 +053015The MAX77802 contains two 32.768khz clock outputs that can be controlled
Laxman Dewangane5812452016-06-17 16:21:06 +053016(gated/ungated) over I2C. Clocks are defined as preprocessor macros in
17dt-bindings/clock/maxim,max77802.h.
18
19The MAX77686 contains one 32.768khz clock outputs that can be controlled
20(gated/ungated) over I2C. Clocks are defined as preprocessor macros in
21dt-bindings/clock/maxim,max77620.h.
Laxman Dewangan24f668d2016-06-17 16:21:05 +053022
Tomasz Figab06c6982013-12-12 17:07:20 +010023Following properties should be presend in main device node of the MFD chip.
24
25Required properties:
Javier Martinez Canillasfcd08642014-08-18 10:33:02 +020026
27- #clock-cells: from common clock binding; shall be set to 1.
28
29Optional properties:
30- clock-output-names: From common clock binding.
31
32Each clock is assigned an identifier and client nodes can use this identifier
33to specify the clock which they consume. Following indices are allowed:
Laxman Dewangane5812452016-06-17 16:21:06 +053034 - 0: 32khz_ap clock (max77686, max77802), 32khz_out0 (max77620)
Laxman Dewangan24f668d2016-06-17 16:21:05 +053035 - 1: 32khz_cp clock (max77686, max77802),
36 - 2: 32khz_pmic clock (max77686).
Tomasz Figab06c6982013-12-12 17:07:20 +010037
Laxman Dewangane5812452016-06-17 16:21:06 +053038Clocks are defined as preprocessor macros in above dt-binding header for
39respective chips.
Javier Martinez Canillasfcd08642014-08-18 10:33:02 +020040
Laxman Dewangan24f668d2016-06-17 16:21:05 +053041Example:
Tomasz Figab06c6982013-12-12 17:07:20 +010042
Laxman Dewangan24f668d2016-06-17 16:21:05 +0530431. With MAX77686:
Tomasz Figab06c6982013-12-12 17:07:20 +010044
Laxman Dewangan24f668d2016-06-17 16:21:05 +053045#include <dt-bindings/clock/maxim,max77686.h>
46/* ... */
Tomasz Figab06c6982013-12-12 17:07:20 +010047
Laxman Dewangan24f668d2016-06-17 16:21:05 +053048 Node of the MFD chip
49 max77686: max77686@09 {
50 compatible = "maxim,max77686";
51 interrupt-parent = <&wakeup_eint>;
52 interrupts = <26 0>;
53 reg = <0x09>;
54 #clock-cells = <1>;
Tomasz Figab06c6982013-12-12 17:07:20 +010055
Laxman Dewangan24f668d2016-06-17 16:21:05 +053056 /* ... */
57 };
58
59 Clock consumer node
60
61 foo@0 {
62 compatible = "bar,foo";
63 /* ... */
64 clock-names = "my-clock";
65 clocks = <&max77686 MAX77686_CLK_PMIC>;
66 };
67
682. With MAX77802:
69
70#include <dt-bindings/clock/maxim,max77802.h>
71/* ... */
72
73 Node of the MFD chip
74 max77802: max77802@09 {
75 compatible = "maxim,max77802";
76 interrupt-parent = <&wakeup_eint>;
77 interrupts = <26 0>;
78 reg = <0x09>;
79 #clock-cells = <1>;
80
81 /* ... */
82 };
83
84 Clock consumer node
85
86 foo@0 {
87 compatible = "bar,foo";
88 /* ... */
89 clock-names = "my-clock";
90 clocks = <&max77802 MAX77802_CLK_32K_AP>;
91 };
Laxman Dewangane5812452016-06-17 16:21:06 +053092
93
943. With MAX77620:
95
96#include <dt-bindings/clock/maxim,max77620.h>
97/* ... */
98
99 Node of the MFD chip
100 max77620: max77620@3c {
101 compatible = "maxim,max77620";
102 reg = <0x3c>;
103 #clock-cells = <1>;
104 /* ... */
105 };
106
107 Clock consumer node
108
109 foo@0 {
110 compatible = "bar,foo";
111 /* ... */
112 clock-names = "my-clock";
113 clocks = <&max77620 MAX77620_CLK_32K_OUT0>;
114 };