15def4c47SEmmanuel Vadot# SPDX-License-Identifier: GPL-2.0-only 25def4c47SEmmanuel Vadot%YAML 1.2 35def4c47SEmmanuel Vadot--- 45def4c47SEmmanuel Vadot$id: http://devicetree.org/schemas/net/dsa/microchip,ksz.yaml# 55def4c47SEmmanuel Vadot$schema: http://devicetree.org/meta-schemas/core.yaml# 65def4c47SEmmanuel Vadot 75def4c47SEmmanuel Vadottitle: Microchip KSZ Series Ethernet switches 85def4c47SEmmanuel Vadot 95def4c47SEmmanuel Vadotmaintainers: 105def4c47SEmmanuel Vadot - Marek Vasut <marex@denx.de> 115def4c47SEmmanuel Vadot - Woojung Huh <Woojung.Huh@microchip.com> 125def4c47SEmmanuel Vadot 135def4c47SEmmanuel VadotallOf: 14cb7aa33aSEmmanuel Vadot - $ref: dsa.yaml#/$defs/ethernet-ports 15d5b0e70fSEmmanuel Vadot - $ref: /schemas/spi/spi-peripheral-props.yaml# 165def4c47SEmmanuel Vadot 175def4c47SEmmanuel Vadotproperties: 185def4c47SEmmanuel Vadot # See Documentation/devicetree/bindings/net/dsa/dsa.yaml for a list of additional 195def4c47SEmmanuel Vadot # required and optional properties. 205def4c47SEmmanuel Vadot compatible: 215def4c47SEmmanuel Vadot enum: 225def4c47SEmmanuel Vadot - microchip,ksz8765 235def4c47SEmmanuel Vadot - microchip,ksz8794 245def4c47SEmmanuel Vadot - microchip,ksz8795 252eb4d8dcSEmmanuel Vadot - microchip,ksz8863 262eb4d8dcSEmmanuel Vadot - microchip,ksz8873 275def4c47SEmmanuel Vadot - microchip,ksz9477 285def4c47SEmmanuel Vadot - microchip,ksz9897 295def4c47SEmmanuel Vadot - microchip,ksz9896 305def4c47SEmmanuel Vadot - microchip,ksz9567 315def4c47SEmmanuel Vadot - microchip,ksz8565 325def4c47SEmmanuel Vadot - microchip,ksz9893 335def4c47SEmmanuel Vadot - microchip,ksz9563 345def4c47SEmmanuel Vadot - microchip,ksz8563 355def4c47SEmmanuel Vadot 365def4c47SEmmanuel Vadot reset-gpios: 375def4c47SEmmanuel Vadot description: 385def4c47SEmmanuel Vadot Should be a gpio specifier for a reset line. 395def4c47SEmmanuel Vadot maxItems: 1 405def4c47SEmmanuel Vadot 415def4c47SEmmanuel Vadot microchip,synclko-125: 425def4c47SEmmanuel Vadot $ref: /schemas/types.yaml#/definitions/flag 435def4c47SEmmanuel Vadot description: 445def4c47SEmmanuel Vadot Set if the output SYNCLKO frequency should be set to 125MHz instead of 25MHz. 455def4c47SEmmanuel Vadot 46c9ccf3a3SEmmanuel Vadot microchip,synclko-disable: 47c9ccf3a3SEmmanuel Vadot $ref: /schemas/types.yaml#/definitions/flag 48c9ccf3a3SEmmanuel Vadot description: 49c9ccf3a3SEmmanuel Vadot Set if the output SYNCLKO clock should be disabled. Do not mix with 50c9ccf3a3SEmmanuel Vadot microchip,synclko-125. 51c9ccf3a3SEmmanuel Vadot 52*aa1a8ff2SEmmanuel Vadot interrupts: 53*aa1a8ff2SEmmanuel Vadot maxItems: 1 54*aa1a8ff2SEmmanuel Vadot 555def4c47SEmmanuel Vadotrequired: 565def4c47SEmmanuel Vadot - compatible 575def4c47SEmmanuel Vadot - reg 585def4c47SEmmanuel Vadot 595def4c47SEmmanuel VadotunevaluatedProperties: false 605def4c47SEmmanuel Vadot 615def4c47SEmmanuel Vadotexamples: 625def4c47SEmmanuel Vadot - | 635def4c47SEmmanuel Vadot #include <dt-bindings/gpio/gpio.h> 645def4c47SEmmanuel Vadot 655def4c47SEmmanuel Vadot // Ethernet switch connected via SPI to the host, CPU port wired to eth0: 665def4c47SEmmanuel Vadot eth0 { 675def4c47SEmmanuel Vadot fixed-link { 685def4c47SEmmanuel Vadot speed = <1000>; 695def4c47SEmmanuel Vadot full-duplex; 705def4c47SEmmanuel Vadot }; 715def4c47SEmmanuel Vadot }; 725def4c47SEmmanuel Vadot 73fac71e4eSEmmanuel Vadot spi { 745def4c47SEmmanuel Vadot #address-cells = <1>; 755def4c47SEmmanuel Vadot #size-cells = <0>; 765def4c47SEmmanuel Vadot 775def4c47SEmmanuel Vadot pinctrl-0 = <&pinctrl_spi_ksz>; 785def4c47SEmmanuel Vadot cs-gpios = <&pioC 25 0>; 795def4c47SEmmanuel Vadot id = <1>; 805def4c47SEmmanuel Vadot 815def4c47SEmmanuel Vadot ksz9477: switch@0 { 825def4c47SEmmanuel Vadot compatible = "microchip,ksz9477"; 835def4c47SEmmanuel Vadot reg = <0>; 845def4c47SEmmanuel Vadot reset-gpios = <&gpio5 0 GPIO_ACTIVE_LOW>; 855def4c47SEmmanuel Vadot 865def4c47SEmmanuel Vadot spi-max-frequency = <44000000>; 875def4c47SEmmanuel Vadot 885def4c47SEmmanuel Vadot ethernet-ports { 895def4c47SEmmanuel Vadot #address-cells = <1>; 905def4c47SEmmanuel Vadot #size-cells = <0>; 915def4c47SEmmanuel Vadot port@0 { 925def4c47SEmmanuel Vadot reg = <0>; 935def4c47SEmmanuel Vadot label = "lan1"; 945def4c47SEmmanuel Vadot }; 955def4c47SEmmanuel Vadot port@1 { 965def4c47SEmmanuel Vadot reg = <1>; 975def4c47SEmmanuel Vadot label = "lan2"; 985def4c47SEmmanuel Vadot }; 995def4c47SEmmanuel Vadot port@2 { 1005def4c47SEmmanuel Vadot reg = <2>; 1015def4c47SEmmanuel Vadot label = "lan3"; 1025def4c47SEmmanuel Vadot }; 1035def4c47SEmmanuel Vadot port@3 { 1045def4c47SEmmanuel Vadot reg = <3>; 1055def4c47SEmmanuel Vadot label = "lan4"; 1065def4c47SEmmanuel Vadot }; 1075def4c47SEmmanuel Vadot port@4 { 1085def4c47SEmmanuel Vadot reg = <4>; 1095def4c47SEmmanuel Vadot label = "lan5"; 1105def4c47SEmmanuel Vadot }; 1115def4c47SEmmanuel Vadot port@5 { 1125def4c47SEmmanuel Vadot reg = <5>; 1135def4c47SEmmanuel Vadot ethernet = <ð0>; 1147ef62cebSEmmanuel Vadot phy-mode = "rgmii"; 1157ef62cebSEmmanuel Vadot 1165def4c47SEmmanuel Vadot fixed-link { 1175def4c47SEmmanuel Vadot speed = <1000>; 1185def4c47SEmmanuel Vadot full-duplex; 1195def4c47SEmmanuel Vadot }; 1205def4c47SEmmanuel Vadot }; 1215def4c47SEmmanuel Vadot }; 1225def4c47SEmmanuel Vadot }; 1235def4c47SEmmanuel Vadot 1245def4c47SEmmanuel Vadot ksz8565: switch@1 { 1255def4c47SEmmanuel Vadot compatible = "microchip,ksz8565"; 1265def4c47SEmmanuel Vadot reg = <1>; 1275def4c47SEmmanuel Vadot 1285def4c47SEmmanuel Vadot spi-max-frequency = <44000000>; 1295def4c47SEmmanuel Vadot 1305def4c47SEmmanuel Vadot ethernet-ports { 1315def4c47SEmmanuel Vadot #address-cells = <1>; 1325def4c47SEmmanuel Vadot #size-cells = <0>; 1335def4c47SEmmanuel Vadot port@0 { 1345def4c47SEmmanuel Vadot reg = <0>; 1355def4c47SEmmanuel Vadot label = "lan1"; 1365def4c47SEmmanuel Vadot }; 1375def4c47SEmmanuel Vadot port@1 { 1385def4c47SEmmanuel Vadot reg = <1>; 1395def4c47SEmmanuel Vadot label = "lan2"; 1405def4c47SEmmanuel Vadot }; 1415def4c47SEmmanuel Vadot port@2 { 1425def4c47SEmmanuel Vadot reg = <2>; 1435def4c47SEmmanuel Vadot label = "lan3"; 1445def4c47SEmmanuel Vadot }; 1455def4c47SEmmanuel Vadot port@3 { 1465def4c47SEmmanuel Vadot reg = <3>; 1475def4c47SEmmanuel Vadot label = "lan4"; 1485def4c47SEmmanuel Vadot }; 1495def4c47SEmmanuel Vadot port@6 { 1505def4c47SEmmanuel Vadot reg = <6>; 1515def4c47SEmmanuel Vadot ethernet = <ð0>; 1527ef62cebSEmmanuel Vadot phy-mode = "rgmii"; 1537ef62cebSEmmanuel Vadot 1545def4c47SEmmanuel Vadot fixed-link { 1555def4c47SEmmanuel Vadot speed = <1000>; 1565def4c47SEmmanuel Vadot full-duplex; 1575def4c47SEmmanuel Vadot }; 1585def4c47SEmmanuel Vadot }; 1595def4c47SEmmanuel Vadot }; 1605def4c47SEmmanuel Vadot }; 1615def4c47SEmmanuel Vadot }; 1625def4c47SEmmanuel Vadot... 163