Merge branch 'x86-alternatives-for-linus' of git://git.kernel.org/pub/scm/linux/kerne...
[sfrench/cifs-2.6.git] / Documentation / devicetree / bindings / net / dsa / mt7530.txt
1 Mediatek MT7530 Ethernet switch
2 ================================
3
4 Required properties:
5
6 - compatible: may be compatible = "mediatek,mt7530"
7         or compatible = "mediatek,mt7621"
8 - #address-cells: Must be 1.
9 - #size-cells: Must be 0.
10 - mediatek,mcm: Boolean; if defined, indicates that either MT7530 is the part
11         on multi-chip module belong to MT7623A has or the remotely standalone
12         chip as the function MT7623N reference board provided for.
13
14 If compatible mediatek,mt7530 is set then the following properties are required
15
16 - core-supply: Phandle to the regulator node necessary for the core power.
17 - io-supply: Phandle to the regulator node necessary for the I/O power.
18         See Documentation/devicetree/bindings/regulator/mt6323-regulator.txt
19         for details for the regulator setup on these boards.
20
21 If the property mediatek,mcm isn't defined, following property is required
22
23 - reset-gpios: Should be a gpio specifier for a reset line.
24
25 Else, following properties are required
26
27 - resets : Phandle pointing to the system reset controller with
28         line index for the ethsys.
29 - reset-names : Should be set to "mcm".
30
31 Required properties for the child nodes within ports container:
32
33 - reg: Port address described must be 6 for CPU port and from 0 to 5 for
34         user ports.
35 - phy-mode: String, must be either "trgmii" or "rgmii" for port labeled
36          "cpu".
37
38 See Documentation/devicetree/bindings/net/dsa/dsa.txt for a list of additional
39 required, optional properties and how the integrated switch subnodes must
40 be specified.
41
42 Example:
43
44         &mdio0 {
45                 switch@0 {
46                         compatible = "mediatek,mt7530";
47                         #address-cells = <1>;
48                         #size-cells = <0>;
49                         reg = <0>;
50
51                         core-supply = <&mt6323_vpa_reg>;
52                         io-supply = <&mt6323_vemc3v3_reg>;
53                         reset-gpios = <&pio 33 0>;
54
55                         ports {
56                                 #address-cells = <1>;
57                                 #size-cells = <0>;
58                                 reg = <0>;
59                                 port@0 {
60                                         reg = <0>;
61                                         label = "lan0";
62                                 };
63
64                                 port@1 {
65                                         reg = <1>;
66                                         label = "lan1";
67                                 };
68
69                                 port@2 {
70                                         reg = <2>;
71                                         label = "lan2";
72                                 };
73
74                                 port@3 {
75                                         reg = <3>;
76                                         label = "lan3";
77                                 };
78
79                                 port@4 {
80                                         reg = <4>;
81                                         label = "wan";
82                                 };
83
84                                 port@6 {
85                                         reg = <6>;
86                                         label = "cpu";
87                                         ethernet = <&gmac0>;
88                                         phy-mode = "trgmii";
89                                         fixed-link {
90                                                 speed = <1000>;
91                                                 full-duplex;
92                                         };
93                                 };
94                         };
95                 };
96         };