17f5bccc8SColin Foster# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) 27f5bccc8SColin Foster%YAML 1.2 37f5bccc8SColin Foster--- 47f5bccc8SColin Foster$id: http://devicetree.org/schemas/net/ethernet-switch.yaml# 57f5bccc8SColin Foster$schema: http://devicetree.org/meta-schemas/core.yaml# 67f5bccc8SColin Foster 77f5bccc8SColin Fostertitle: Generic Ethernet Switch 87f5bccc8SColin Foster 97f5bccc8SColin Fostermaintainers: 107f5bccc8SColin Foster - Andrew Lunn <andrew@lunn.ch> 117f5bccc8SColin Foster - Florian Fainelli <f.fainelli@gmail.com> 127f5bccc8SColin Foster - Vladimir Oltean <olteanv@gmail.com> 137f5bccc8SColin Foster 147f5bccc8SColin Fosterdescription: 157f5bccc8SColin Foster Ethernet switches are multi-port Ethernet controllers. Each port has 167f5bccc8SColin Foster its own number and is represented as its own Ethernet controller. 177f5bccc8SColin Foster The minimum required functionality is to pass packets to software. 187f5bccc8SColin Foster They may or may not be able to forward packets automonously between 197f5bccc8SColin Foster ports. 207f5bccc8SColin Foster 217f5bccc8SColin Fosterselect: false 227f5bccc8SColin Foster 23*f45c1974SLinus WalleijallOf: 24*f45c1974SLinus Walleij # This condition is here to satisfy the case where certain device 25*f45c1974SLinus Walleij # nodes have to preserve non-standard names because of 26*f45c1974SLinus Walleij # backward-compatibility with boot loaders inspecting certain 27*f45c1974SLinus Walleij # node names. 28*f45c1974SLinus Walleij - if: 29*f45c1974SLinus Walleij properties: 30*f45c1974SLinus Walleij compatible: 31*f45c1974SLinus Walleij contains: 32*f45c1974SLinus Walleij enum: 33*f45c1974SLinus Walleij - marvell,turris-mox-mv88e6085 34*f45c1974SLinus Walleij - marvell,turris-mox-mv88e6190 35*f45c1974SLinus Walleij then: 36*f45c1974SLinus Walleij properties: 37*f45c1974SLinus Walleij $nodename: 38*f45c1974SLinus Walleij pattern: "switch[0-3]@[0-3]+$" 39*f45c1974SLinus Walleij else: 407f5bccc8SColin Foster properties: 417f5bccc8SColin Foster $nodename: 427f5bccc8SColin Foster pattern: "^(ethernet-)?switch(@.*)?$" 437f5bccc8SColin Foster 447f5bccc8SColin FosterpatternProperties: 457f5bccc8SColin Foster "^(ethernet-)?ports$": 467f5bccc8SColin Foster type: object 477f5bccc8SColin Foster unevaluatedProperties: false 487f5bccc8SColin Foster 497f5bccc8SColin Foster properties: 507f5bccc8SColin Foster '#address-cells': 517f5bccc8SColin Foster const: 1 527f5bccc8SColin Foster '#size-cells': 537f5bccc8SColin Foster const: 0 547f5bccc8SColin Foster 557f5bccc8SColin Foster patternProperties: 5651ff5150SRob Herring "^(ethernet-)?port@[0-9a-f]+$": 577f5bccc8SColin Foster type: object 587f5bccc8SColin Foster description: Ethernet switch ports 597f5bccc8SColin Foster 60c8f1f2e9SRob Herring required: 61c8f1f2e9SRob Herring - "#address-cells" 62c8f1f2e9SRob Herring - "#size-cells" 63c8f1f2e9SRob Herring 647f5bccc8SColin FosteroneOf: 657f5bccc8SColin Foster - required: 667f5bccc8SColin Foster - ports 677f5bccc8SColin Foster - required: 687f5bccc8SColin Foster - ethernet-ports 697f5bccc8SColin Foster 707f5bccc8SColin FosteradditionalProperties: true 717f5bccc8SColin Foster 727f5bccc8SColin Foster$defs: 73b9823df7SRob Herring ethernet-ports: 747f5bccc8SColin Foster description: An ethernet switch without any extra port properties 7584ce730fSRob Herring $ref: '#' 767f5bccc8SColin Foster 777f5bccc8SColin Foster patternProperties: 78f0fdec92SRob Herring "^(ethernet-)?ports$": 79f0fdec92SRob Herring patternProperties: 8051ff5150SRob Herring "^(ethernet-)?port@[0-9a-f]+$": 817f5bccc8SColin Foster description: Ethernet switch ports 8268e3e3beSColin Foster $ref: ethernet-switch-port.yaml# 837f5bccc8SColin Foster unevaluatedProperties: false 847f5bccc8SColin Foster 857f5bccc8SColin Foster... 86