xref: /OK3568_Linux_fs/kernel/Documentation/devicetree/bindings/net/mscc-ocelot.txt (revision 4882a59341e53eb6f0b4789bf948001014eff981)
1*4882a593SmuzhiyunMicrosemi Ocelot network Switch
2*4882a593Smuzhiyun===============================
3*4882a593Smuzhiyun
4*4882a593SmuzhiyunThe Microsemi Ocelot network switch can be found on Microsemi SoCs (VSC7513,
5*4882a593SmuzhiyunVSC7514)
6*4882a593Smuzhiyun
7*4882a593SmuzhiyunRequired properties:
8*4882a593Smuzhiyun- compatible: Should be "mscc,vsc7514-switch"
9*4882a593Smuzhiyun- reg: Must contain an (offset, length) pair of the register set for each
10*4882a593Smuzhiyun  entry in reg-names.
11*4882a593Smuzhiyun- reg-names: Must include the following entries:
12*4882a593Smuzhiyun  - "sys"
13*4882a593Smuzhiyun  - "rew"
14*4882a593Smuzhiyun  - "qs"
15*4882a593Smuzhiyun  - "ptp" (optional due to backward compatibility)
16*4882a593Smuzhiyun  - "qsys"
17*4882a593Smuzhiyun  - "ana"
18*4882a593Smuzhiyun  - "portX" with X from 0 to the number of last port index available on that
19*4882a593Smuzhiyun    switch
20*4882a593Smuzhiyun- interrupts: Should contain the switch interrupts for frame extraction,
21*4882a593Smuzhiyun  frame injection and PTP ready.
22*4882a593Smuzhiyun- interrupt-names: should contain the interrupt names: "xtr", "inj". Can contain
23*4882a593Smuzhiyun  "ptp_rdy" which is optional due to backward compatibility.
24*4882a593Smuzhiyun- ethernet-ports: A container for child nodes representing switch ports.
25*4882a593Smuzhiyun
26*4882a593SmuzhiyunThe ethernet-ports container has the following properties
27*4882a593Smuzhiyun
28*4882a593SmuzhiyunRequired properties:
29*4882a593Smuzhiyun
30*4882a593Smuzhiyun- #address-cells: Must be 1
31*4882a593Smuzhiyun- #size-cells: Must be 0
32*4882a593Smuzhiyun
33*4882a593SmuzhiyunEach port node must have the following mandatory properties:
34*4882a593Smuzhiyun- reg: Describes the port address in the switch
35*4882a593Smuzhiyun
36*4882a593SmuzhiyunPort nodes may also contain the following optional standardised
37*4882a593Smuzhiyunproperties, described in binding documents:
38*4882a593Smuzhiyun
39*4882a593Smuzhiyun- phy-handle: Phandle to a PHY on an MDIO bus. See
40*4882a593Smuzhiyun  Documentation/devicetree/bindings/net/ethernet.txt for details.
41*4882a593Smuzhiyun
42*4882a593SmuzhiyunExample:
43*4882a593Smuzhiyun
44*4882a593Smuzhiyun	switch@1010000 {
45*4882a593Smuzhiyun		compatible = "mscc,vsc7514-switch";
46*4882a593Smuzhiyun		reg = <0x1010000 0x10000>,
47*4882a593Smuzhiyun		      <0x1030000 0x10000>,
48*4882a593Smuzhiyun		      <0x1080000 0x100>,
49*4882a593Smuzhiyun		      <0x10e0000 0x10000>,
50*4882a593Smuzhiyun		      <0x11e0000 0x100>,
51*4882a593Smuzhiyun		      <0x11f0000 0x100>,
52*4882a593Smuzhiyun		      <0x1200000 0x100>,
53*4882a593Smuzhiyun		      <0x1210000 0x100>,
54*4882a593Smuzhiyun		      <0x1220000 0x100>,
55*4882a593Smuzhiyun		      <0x1230000 0x100>,
56*4882a593Smuzhiyun		      <0x1240000 0x100>,
57*4882a593Smuzhiyun		      <0x1250000 0x100>,
58*4882a593Smuzhiyun		      <0x1260000 0x100>,
59*4882a593Smuzhiyun		      <0x1270000 0x100>,
60*4882a593Smuzhiyun		      <0x1280000 0x100>,
61*4882a593Smuzhiyun		      <0x1800000 0x80000>,
62*4882a593Smuzhiyun		      <0x1880000 0x10000>;
63*4882a593Smuzhiyun		reg-names = "sys", "rew", "qs", "ptp", "port0", "port1",
64*4882a593Smuzhiyun			    "port2", "port3", "port4", "port5", "port6",
65*4882a593Smuzhiyun			    "port7", "port8", "port9", "port10", "qsys",
66*4882a593Smuzhiyun			    "ana";
67*4882a593Smuzhiyun		interrupts = <18 21 22>;
68*4882a593Smuzhiyun		interrupt-names = "ptp_rdy", "xtr", "inj";
69*4882a593Smuzhiyun
70*4882a593Smuzhiyun		ethernet-ports {
71*4882a593Smuzhiyun			#address-cells = <1>;
72*4882a593Smuzhiyun			#size-cells = <0>;
73*4882a593Smuzhiyun
74*4882a593Smuzhiyun			port0: port@0 {
75*4882a593Smuzhiyun				reg = <0>;
76*4882a593Smuzhiyun				phy-handle = <&phy0>;
77*4882a593Smuzhiyun			};
78*4882a593Smuzhiyun			port1: port@1 {
79*4882a593Smuzhiyun				reg = <1>;
80*4882a593Smuzhiyun				phy-handle = <&phy1>;
81*4882a593Smuzhiyun			};
82*4882a593Smuzhiyun		};
83*4882a593Smuzhiyun	};
84