xref: /freebsd/sys/contrib/device-tree/Bindings/net/dsa/dsa.yaml (revision cb7aa33ac6cd46a5434798e50363136e64f3ae98)
1c66ec88fSEmmanuel Vadot# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
2c66ec88fSEmmanuel Vadot%YAML 1.2
3c66ec88fSEmmanuel Vadot---
4c66ec88fSEmmanuel Vadot$id: http://devicetree.org/schemas/net/dsa/dsa.yaml#
5c66ec88fSEmmanuel Vadot$schema: http://devicetree.org/meta-schemas/core.yaml#
6c66ec88fSEmmanuel Vadot
78bab661aSEmmanuel Vadottitle: Ethernet Switch
8c66ec88fSEmmanuel Vadot
9c66ec88fSEmmanuel Vadotmaintainers:
10c66ec88fSEmmanuel Vadot  - Andrew Lunn <andrew@lunn.ch>
11c66ec88fSEmmanuel Vadot  - Florian Fainelli <f.fainelli@gmail.com>
12*cb7aa33aSEmmanuel Vadot  - Vladimir Oltean <olteanv@gmail.com>
13c66ec88fSEmmanuel Vadot
14c66ec88fSEmmanuel Vadotdescription:
15c66ec88fSEmmanuel Vadot  This binding represents Ethernet Switches which have a dedicated CPU
16c66ec88fSEmmanuel Vadot  port. That port is usually connected to an Ethernet Controller of the
17c66ec88fSEmmanuel Vadot  SoC. Such setups are typical for embedded devices.
18c66ec88fSEmmanuel Vadot
19c66ec88fSEmmanuel Vadotselect: false
20c66ec88fSEmmanuel Vadot
21*cb7aa33aSEmmanuel Vadot$ref: /schemas/net/ethernet-switch.yaml#
22c66ec88fSEmmanuel Vadot
23*cb7aa33aSEmmanuel Vadotproperties:
24c66ec88fSEmmanuel Vadot  dsa,member:
25c66ec88fSEmmanuel Vadot    minItems: 2
26c66ec88fSEmmanuel Vadot    maxItems: 2
27c66ec88fSEmmanuel Vadot    description:
28c66ec88fSEmmanuel Vadot      A two element list indicates which DSA cluster, and position within the
29c66ec88fSEmmanuel Vadot      cluster a switch takes. <0 0> is cluster 0, switch 0. <0 1> is cluster 0,
30c66ec88fSEmmanuel Vadot      switch 1. <1 0> is cluster 1, switch 0. A switch not part of any cluster
31c66ec88fSEmmanuel Vadot      (single device hanging off a CPU port) must not specify this property
32c66ec88fSEmmanuel Vadot    $ref: /schemas/types.yaml#/definitions/uint32-array
33c66ec88fSEmmanuel Vadot
34*cb7aa33aSEmmanuel VadotadditionalProperties: true
35*cb7aa33aSEmmanuel Vadot
36*cb7aa33aSEmmanuel Vadot$defs:
37*cb7aa33aSEmmanuel Vadot  ethernet-ports:
38*cb7aa33aSEmmanuel Vadot    description: A DSA switch without any extra port properties
39*cb7aa33aSEmmanuel Vadot    $ref: '#/'
40*cb7aa33aSEmmanuel Vadot
41c66ec88fSEmmanuel Vadot    patternProperties:
42c66ec88fSEmmanuel Vadot      "^(ethernet-)?ports$":
43c66ec88fSEmmanuel Vadot        type: object
44*cb7aa33aSEmmanuel Vadot        additionalProperties: false
45*cb7aa33aSEmmanuel Vadot
46c66ec88fSEmmanuel Vadot        properties:
47c66ec88fSEmmanuel Vadot          '#address-cells':
48c66ec88fSEmmanuel Vadot            const: 1
49c66ec88fSEmmanuel Vadot          '#size-cells':
50c66ec88fSEmmanuel Vadot            const: 0
51c66ec88fSEmmanuel Vadot
52c66ec88fSEmmanuel Vadot        patternProperties:
53c66ec88fSEmmanuel Vadot          "^(ethernet-)?port@[0-9]+$":
54c66ec88fSEmmanuel Vadot            description: Ethernet switch ports
55e67e8565SEmmanuel Vadot            $ref: dsa-port.yaml#
56e67e8565SEmmanuel Vadot            unevaluatedProperties: false
57c66ec88fSEmmanuel Vadot
58c66ec88fSEmmanuel Vadot...
59