GNU Linux-libre 4.14.266-gnu1
[releases.git] / Documentation / devicetree / bindings / i2c / i2c-mtk.txt
1 * MediaTek's I2C controller
2
3 The MediaTek's I2C controller is used to interface with I2C devices.
4
5 Required properties:
6   - compatible: value should be either of the following.
7       "mediatek,mt2701-i2c", "mediatek,mt6577-i2c": for MediaTek MT2701
8       "mediatek,mt6577-i2c": for MediaTek MT6577
9       "mediatek,mt6589-i2c": for MediaTek MT6589
10       "mediatek,mt7622-i2c": for MediaTek MT7622
11       "mediatek,mt7623-i2c", "mediatek,mt6577-i2c": for MediaTek MT7623
12       "mediatek,mt8173-i2c": for MediaTek MT8173
13   - reg: physical base address of the controller and dma base, length of memory
14     mapped region.
15   - interrupts: interrupt number to the cpu.
16   - clock-div: the fixed value for frequency divider of clock source in i2c
17     module. Each IC may be different.
18   - clocks: clock name from clock manager
19   - clock-names: Must include "main" and "dma", if enable have-pmic need include
20     "pmic" extra.
21
22 Optional properties:
23   - clock-frequency: Frequency in Hz of the bus when transfer, the default value
24     is 100000.
25   - mediatek,have-pmic: platform can control i2c form special pmic side.
26     Only mt6589 and mt8135 support this feature.
27   - mediatek,use-push-pull: IO config use push-pull mode.
28
29 Example:
30
31         i2c0: i2c@1100d000 {
32                         compatible = "mediatek,mt6577-i2c";
33                         reg = <0x1100d000 0x70>,
34                               <0x11000300 0x80>;
35                         interrupts = <GIC_SPI 44 IRQ_TYPE_LEVEL_LOW>;
36                         clock-frequency = <400000>;
37                         mediatek,have-pmic;
38                         clock-div = <16>;
39                         clocks = <&i2c0_ck>, <&ap_dma_ck>;
40                         clock-names = "main", "dma";
41         };
42