blob: fcafce635ff01944b50294c24e2ffe8f43fe34ae [file] [log] [blame]
b.liue9582032025-04-17 19:18:16 +08001# SPDX-License-Identifier: GPL-2.0
2%YAML 1.2
3---
4$id: http://devicetree.org/schemas/net/ethernet-controller.yaml#
5$schema: http://devicetree.org/meta-schemas/core.yaml#
6
7title: Ethernet Controller Generic Binding
8
9maintainers:
10 - David S. Miller <davem@davemloft.net>
11
12properties:
13 $nodename:
14 pattern: "^ethernet(@.*)?$"
15
16 local-mac-address:
17 allOf:
18 - $ref: /schemas/types.yaml#definitions/uint8-array
19 - items:
20 - minItems: 6
21 maxItems: 6
22 description:
23 Specifies the MAC address that was assigned to the network device.
24
25 mac-address:
26 allOf:
27 - $ref: /schemas/types.yaml#definitions/uint8-array
28 - items:
29 - minItems: 6
30 maxItems: 6
31 description:
32 Specifies the MAC address that was last used by the boot
33 program; should be used in cases where the MAC address assigned
34 to the device by the boot program is different from the
35 local-mac-address property.
36
37 max-frame-size:
38 $ref: /schemas/types.yaml#definitions/uint32
39 description:
40 Maximum transfer unit (IEEE defined MTU), rather than the
41 maximum frame size (there\'s contradiction in the Devicetree
42 Specification).
43
44 max-speed:
45 $ref: /schemas/types.yaml#definitions/uint32
46 description:
47 Specifies maximum speed in Mbit/s supported by the device.
48
49 nvmem-cells:
50 maxItems: 1
51 description:
52 Reference to an nvmem node for the MAC address
53
54 nvmem-cell-names:
55 const: mac-address
56
57 phy-connection-type:
58 description:
59 Operation mode of the PHY interface
60 enum:
61 # There is not a standard bus between the MAC and the PHY,
62 # something proprietary is being used to embed the PHY in the
63 # MAC.
64 - internal
65 - mii
66 - gmii
67 - sgmii
68 - qsgmii
69 - tbi
70 - rev-mii
71 - rmii
72
73 # RX and TX delays are added by the MAC when required
74 - rgmii
75
76 # RGMII with internal RX and TX delays provided by the PHY,
77 # the MAC should not add the RX or TX delays in this case
78 - rgmii-id
79
80 # RGMII with internal RX delay provided by the PHY, the MAC
81 # should not add an RX delay in this case
82 - rgmii-rxid
83
84 # RGMII with internal TX delay provided by the PHY, the MAC
85 # should not add an TX delay in this case
86 - rgmii-txid
87 - rtbi
88 - smii
89 - xgmii
90 - trgmii
91 - 1000base-x
92 - 2500base-x
93 - rxaui
94 - xaui
95
96 # 10GBASE-KR, XFI, SFI
97 - 10gbase-kr
98 - usxgmii
99
100 phy-mode:
101 $ref: "#/properties/phy-connection-type"
102
103 phy-handle:
104 $ref: /schemas/types.yaml#definitions/phandle
105 description:
106 Specifies a reference to a node representing a PHY device.
107
108 phy:
109 $ref: "#/properties/phy-handle"
110 deprecated: true
111
112 phy-device:
113 $ref: "#/properties/phy-handle"
114 deprecated: true
115
116 rx-fifo-depth:
117 $ref: /schemas/types.yaml#definitions/uint32
118 description:
119 The size of the controller\'s receive fifo in bytes. This is used
120 for components that can have configurable receive fifo sizes,
121 and is useful for determining certain configuration settings
122 such as flow control thresholds.
123
124 tx-fifo-depth:
125 $ref: /schemas/types.yaml#definitions/uint32
126 description:
127 The size of the controller\'s transmit fifo in bytes. This
128 is used for components that can have configurable fifo sizes.
129
130 managed:
131 allOf:
132 - $ref: /schemas/types.yaml#definitions/string
133 - default: auto
134 enum:
135 - auto
136 - in-band-status
137 description:
138 Specifies the PHY management type. If auto is set and fixed-link
139 is not specified, it uses MDIO for management.
140
141 fixed-link:
142 allOf:
143 - if:
144 type: array
145 then:
146 deprecated: true
147 minItems: 1
148 maxItems: 1
149 items:
150 items:
151 - minimum: 0
152 maximum: 31
153 description:
154 Emulated PHY ID, choose any but unique to the all
155 specified fixed-links
156
157 - enum: [0, 1]
158 description:
159 Duplex configuration. 0 for half duplex or 1 for
160 full duplex
161
162 - enum: [10, 100, 1000]
163 description:
164 Link speed in Mbits/sec.
165
166 - enum: [0, 1]
167 description:
168 Pause configuration. 0 for no pause, 1 for pause
169
170 - enum: [0, 1]
171 description:
172 Asymmetric pause configuration. 0 for no asymmetric
173 pause, 1 for asymmetric pause
174
175
176 - if:
177 type: object
178 then:
179 properties:
180 speed:
181 allOf:
182 - $ref: /schemas/types.yaml#definitions/uint32
183 - enum: [10, 100, 1000]
184 description:
185 Link speed.
186
187 full-duplex:
188 $ref: /schemas/types.yaml#definitions/flag
189 description:
190 Indicates that full-duplex is used. When absent, half
191 duplex is assumed.
192
193 pause:
194 $ref: /schemas/types.yaml#definitions/flag
195 description:
196 Indicates that pause should be enabled.
197
198 asym-pause:
199 $ref: /schemas/types.yaml#definitions/flag
200 description:
201 Indicates that asym_pause should be enabled.
202
203 link-gpios:
204 maxItems: 1
205 description:
206 GPIO to determine if the link is up
207
208 required:
209 - speed
210
211...