summaryrefslogtreecommitdiff
path: root/Documentation/devicetree/bindings/net/brcm,bcm7445-switch-v4.0.txt
blob: 48a7f916c5e4e21e9c1b154b7cc7697ad0e5b608 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
* Broadcom Starfighter 2 integrated swich

Required properties:

- compatible: should be one of
	"brcm,bcm7445-switch-v4.0"
	"brcm,bcm7278-switch-v4.0"
	"brcm,bcm7278-switch-v4.8"
- reg: addresses and length of the register sets for the device, must be 6
  pairs of register addresses and lengths
- interrupts: interrupts for the devices, must be two interrupts
- #address-cells: must be 1, see dsa/dsa.txt
- #size-cells: must be 0, see dsa/dsa.txt

Deprecated binding required properties:

- dsa,mii-bus: phandle to the MDIO bus controller, see dsa/dsa.txt
- dsa,ethernet: phandle to the CPU network interface controller, see dsa/dsa.txt
- #address-cells: must be 2, see dsa/dsa.txt

Subnodes:

The integrated switch subnode should be specified according to the binding
described in dsa/dsa.txt.

Optional properties:

- reg-names: litteral names for the device base register addresses, when present
  must be: "core", "reg", "intrl2_0", "intrl2_1", "fcb", "acb"

- interrupt-names: litternal names for the device interrupt lines, when present
  must be: "switch_0" and "switch_1"

- brcm,num-gphy: specify the maximum number of integrated gigabit PHYs in the
  switch

- brcm,num-rgmii-ports: specify the maximum number of RGMII interfaces supported
  by the switch

- brcm,fcb-pause-override: boolean property, if present indicates that the switch
  supports Failover Control Block pause override capability

- brcm,acb-packets-inflight: boolean property, if present indicates that the switch
  Admission Control Block supports reporting the number of packets in-flight in a
  switch queue

- resets: a single phandle and reset identifier pair. See
  Documentation/devicetree/binding/reset/reset.txt for details.

- reset-names: If the "reset" property is specified, this property should have
  the value "switch" to denote the switch reset line.

Port subnodes:

Optional properties:

- brcm,use-bcm-hdr: boolean property, if present, indicates that the switch
  port has Broadcom tags enabled (per-packet metadata)

Example:

switch_top@f0b00000 {
	compatible = "simple-bus";
	#size-cells = <1>;
	#address-cells = <1>;
	ranges = <0 0xf0b00000 0x40804>;

	ethernet_switch@0 {
		compatible = "brcm,bcm7445-switch-v4.0";
		#size-cells = <0>;
		#address-cells = <1>;
		reg = <0x0 0x40000
			0x40000 0x110
			0x40340 0x30
			0x40380 0x30
			0x40400 0x34
			0x40600 0x208>;
		reg-names = "core", "reg", intrl2_0", "intrl2_1",
			    "fcb, "acb";
		interrupts = <0 0x18 0
				0 0x19 0>;
		brcm,num-gphy = <1>;
		brcm,num-rgmii-ports = <2>;
		brcm,fcb-pause-override;
		brcm,acb-packets-inflight;

		ports {
			#address-cells = <1>;
			#size-cells = <0>;

			port@0 {
				label = "gphy";
				reg = <0>;
			};
		};
	};
};

Example using the old DSA DeviceTree binding:

switch_top@f0b00000 {
	compatible = "simple-bus";
	#size-cells = <1>;
	#address-cells = <1>;
	ranges = <0 0xf0b00000 0x40804>;

	ethernet_switch@0 {
		compatible = "brcm,bcm7445-switch-v4.0";
		#size-cells = <0>;
		#address-cells = <2>;
		reg = <0x0 0x40000
			0x40000 0x110
			0x40340 0x30
			0x40380 0x30
			0x40400 0x34
			0x40600 0x208>;
		interrupts = <0 0x18 0
				0 0x19 0>;
		brcm,num-gphy = <1>;
		brcm,num-rgmii-ports = <2>;
		brcm,fcb-pause-override;
		brcm,acb-packets-inflight;

		...
		switch@0 {
			reg = <0 0>;
			#size-cells = <0>;
			#address-cells <1>;

			port@0 {
				label = "gphy";
				reg = <0>;
				brcm,use-bcm-hdr;
			};
			...
		};
	};
};