xref: /freebsd/sys/contrib/device-tree/Bindings/i2c/marvell,mv64xxx-i2c.yaml (revision 5def4c47d4bd90b209b9b4a4ba9faec15846d8fd)
1c66ec88fSEmmanuel Vadot# SPDX-License-Identifier: GPL-2.0
2c66ec88fSEmmanuel Vadot%YAML 1.2
3c66ec88fSEmmanuel Vadot---
4c66ec88fSEmmanuel Vadot$id: http://devicetree.org/schemas/i2c/marvell,mv64xxx-i2c.yaml#
5c66ec88fSEmmanuel Vadot$schema: http://devicetree.org/meta-schemas/core.yaml#
6c66ec88fSEmmanuel Vadot
7c66ec88fSEmmanuel Vadottitle: Marvell MV64XXX I2C Controller Device Tree Bindings
8c66ec88fSEmmanuel Vadot
9c66ec88fSEmmanuel Vadotmaintainers:
10c66ec88fSEmmanuel Vadot  - Gregory CLEMENT <gregory.clement@bootlin.com>
11c66ec88fSEmmanuel Vadot
12c66ec88fSEmmanuel Vadotproperties:
13c66ec88fSEmmanuel Vadot  compatible:
14c66ec88fSEmmanuel Vadot    oneOf:
15c66ec88fSEmmanuel Vadot      - const: allwinner,sun4i-a10-i2c
16c66ec88fSEmmanuel Vadot      - items:
17c66ec88fSEmmanuel Vadot          - const: allwinner,sun7i-a20-i2c
18c66ec88fSEmmanuel Vadot          - const: allwinner,sun4i-a10-i2c
19c66ec88fSEmmanuel Vadot      - const: allwinner,sun6i-a31-i2c
20c66ec88fSEmmanuel Vadot      - items:
21*5def4c47SEmmanuel Vadot          - enum:
22*5def4c47SEmmanuel Vadot              - allwinner,sun8i-a23-i2c
23*5def4c47SEmmanuel Vadot              - allwinner,sun8i-a83t-i2c
24*5def4c47SEmmanuel Vadot              - allwinner,sun50i-a64-i2c
25*5def4c47SEmmanuel Vadot              - allwinner,sun50i-a100-i2c
26*5def4c47SEmmanuel Vadot              - allwinner,sun50i-h6-i2c
27*5def4c47SEmmanuel Vadot              - allwinner,sun50i-h616-i2c
28c66ec88fSEmmanuel Vadot          - const: allwinner,sun6i-a31-i2c
29c66ec88fSEmmanuel Vadot      - const: marvell,mv64xxx-i2c
30c66ec88fSEmmanuel Vadot      - const: marvell,mv78230-i2c
31c66ec88fSEmmanuel Vadot      - const: marvell,mv78230-a0-i2c
32c66ec88fSEmmanuel Vadot
33c66ec88fSEmmanuel Vadot    description:
34c66ec88fSEmmanuel Vadot      Only use "marvell,mv78230-a0-i2c" for a very rare, initial
35c66ec88fSEmmanuel Vadot      version of the SoC which had broken offload support. Linux
36c66ec88fSEmmanuel Vadot      auto-detects this and sets it appropriately.
37c66ec88fSEmmanuel Vadot
38c66ec88fSEmmanuel Vadot  reg:
39c66ec88fSEmmanuel Vadot    maxItems: 1
40c66ec88fSEmmanuel Vadot
41c66ec88fSEmmanuel Vadot  interrupts:
42c66ec88fSEmmanuel Vadot    maxItems: 1
43c66ec88fSEmmanuel Vadot
44c66ec88fSEmmanuel Vadot  clocks:
45c66ec88fSEmmanuel Vadot    minItems: 1
46c66ec88fSEmmanuel Vadot    maxItems: 2
47c66ec88fSEmmanuel Vadot    items:
48c66ec88fSEmmanuel Vadot      - description: Reference clock for the I2C bus
49c66ec88fSEmmanuel Vadot      - description: Bus clock (Only for Armada 7K/8K)
50c66ec88fSEmmanuel Vadot
51c66ec88fSEmmanuel Vadot  clock-names:
52c66ec88fSEmmanuel Vadot    minItems: 1
53c66ec88fSEmmanuel Vadot    maxItems: 2
54c66ec88fSEmmanuel Vadot    items:
55c66ec88fSEmmanuel Vadot      - const: core
56c66ec88fSEmmanuel Vadot      - const: reg
57c66ec88fSEmmanuel Vadot    description:
58c66ec88fSEmmanuel Vadot      Mandatory if two clocks are used (only for Armada 7k and 8k).
59c66ec88fSEmmanuel Vadot
60c66ec88fSEmmanuel Vadot  resets:
61c66ec88fSEmmanuel Vadot    maxItems: 1
62c66ec88fSEmmanuel Vadot
63c66ec88fSEmmanuel Vadotrequired:
64c66ec88fSEmmanuel Vadot  - compatible
65c66ec88fSEmmanuel Vadot  - reg
66c66ec88fSEmmanuel Vadot  - interrupts
67c66ec88fSEmmanuel Vadot
68c66ec88fSEmmanuel VadotallOf:
69c66ec88fSEmmanuel Vadot  - $ref: /schemas/i2c/i2c-controller.yaml#
70c66ec88fSEmmanuel Vadot  - if:
71c66ec88fSEmmanuel Vadot      properties:
72c66ec88fSEmmanuel Vadot        compatible:
73c66ec88fSEmmanuel Vadot          contains:
74c66ec88fSEmmanuel Vadot            enum:
75c66ec88fSEmmanuel Vadot              - allwinner,sun4i-a10-i2c
76c66ec88fSEmmanuel Vadot              - allwinner,sun6i-a31-i2c
77c66ec88fSEmmanuel Vadot
78c66ec88fSEmmanuel Vadot    then:
79c66ec88fSEmmanuel Vadot      required:
80c66ec88fSEmmanuel Vadot        - clocks
81c66ec88fSEmmanuel Vadot
82c66ec88fSEmmanuel Vadot  - if:
83c66ec88fSEmmanuel Vadot      properties:
84c66ec88fSEmmanuel Vadot        compatible:
85c66ec88fSEmmanuel Vadot          contains:
86c66ec88fSEmmanuel Vadot            const: allwinner,sun6i-a31-i2c
87c66ec88fSEmmanuel Vadot
88c66ec88fSEmmanuel Vadot    then:
89c66ec88fSEmmanuel Vadot      required:
90c66ec88fSEmmanuel Vadot        - resets
91c66ec88fSEmmanuel Vadot
92c66ec88fSEmmanuel VadotunevaluatedProperties: false
93c66ec88fSEmmanuel Vadot
94c66ec88fSEmmanuel Vadotexamples:
95c66ec88fSEmmanuel Vadot  - |
96c66ec88fSEmmanuel Vadot    i2c@11000 {
97c66ec88fSEmmanuel Vadot        compatible = "marvell,mv64xxx-i2c";
98c66ec88fSEmmanuel Vadot        reg = <0x11000 0x20>;
99c66ec88fSEmmanuel Vadot        interrupts = <29>;
100c66ec88fSEmmanuel Vadot        clock-frequency = <100000>;
101c66ec88fSEmmanuel Vadot    };
102c66ec88fSEmmanuel Vadot
103c66ec88fSEmmanuel Vadot  - |
104c66ec88fSEmmanuel Vadot    i2c@11000 {
105c66ec88fSEmmanuel Vadot        compatible = "marvell,mv78230-i2c";
106c66ec88fSEmmanuel Vadot        reg = <0x11000 0x100>;
107c66ec88fSEmmanuel Vadot        interrupts = <29>;
108c66ec88fSEmmanuel Vadot        clock-frequency = <100000>;
109c66ec88fSEmmanuel Vadot    };
110c66ec88fSEmmanuel Vadot
111c66ec88fSEmmanuel Vadot  - |
112c66ec88fSEmmanuel Vadot    i2c@701000 {
113c66ec88fSEmmanuel Vadot        compatible = "marvell,mv78230-i2c";
114c66ec88fSEmmanuel Vadot        reg = <0x701000 0x20>;
115c66ec88fSEmmanuel Vadot        interrupts = <29>;
116c66ec88fSEmmanuel Vadot        clock-frequency = <100000>;
117c66ec88fSEmmanuel Vadot        clock-names = "core", "reg";
118c66ec88fSEmmanuel Vadot        clocks = <&core_clock>, <&reg_clock>;
119c66ec88fSEmmanuel Vadot    };
120c66ec88fSEmmanuel Vadot
121c66ec88fSEmmanuel Vadot...
122