xref: /freebsd/sys/contrib/device-tree/Bindings/net/dsa/microchip,ksz.yaml (revision 2eb4d8dc723da3cf7d735a3226ae49da4c8c5dbc)
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:
145def4c47SEmmanuel Vadot  - $ref: dsa.yaml#
155def4c47SEmmanuel Vadot
165def4c47SEmmanuel Vadotproperties:
175def4c47SEmmanuel Vadot  # See Documentation/devicetree/bindings/net/dsa/dsa.yaml for a list of additional
185def4c47SEmmanuel Vadot  # required and optional properties.
195def4c47SEmmanuel Vadot  compatible:
205def4c47SEmmanuel Vadot    enum:
215def4c47SEmmanuel Vadot      - microchip,ksz8765
225def4c47SEmmanuel Vadot      - microchip,ksz8794
235def4c47SEmmanuel Vadot      - microchip,ksz8795
24*2eb4d8dcSEmmanuel Vadot      - microchip,ksz8863
25*2eb4d8dcSEmmanuel Vadot      - microchip,ksz8873
265def4c47SEmmanuel Vadot      - microchip,ksz9477
275def4c47SEmmanuel Vadot      - microchip,ksz9897
285def4c47SEmmanuel Vadot      - microchip,ksz9896
295def4c47SEmmanuel Vadot      - microchip,ksz9567
305def4c47SEmmanuel Vadot      - microchip,ksz8565
315def4c47SEmmanuel Vadot      - microchip,ksz9893
325def4c47SEmmanuel Vadot      - microchip,ksz9563
335def4c47SEmmanuel Vadot      - microchip,ksz8563
345def4c47SEmmanuel Vadot
355def4c47SEmmanuel Vadot  reset-gpios:
365def4c47SEmmanuel Vadot    description:
375def4c47SEmmanuel Vadot      Should be a gpio specifier for a reset line.
385def4c47SEmmanuel Vadot    maxItems: 1
395def4c47SEmmanuel Vadot
405def4c47SEmmanuel Vadot  microchip,synclko-125:
415def4c47SEmmanuel Vadot    $ref: /schemas/types.yaml#/definitions/flag
425def4c47SEmmanuel Vadot    description:
435def4c47SEmmanuel Vadot      Set if the output SYNCLKO frequency should be set to 125MHz instead of 25MHz.
445def4c47SEmmanuel Vadot
455def4c47SEmmanuel Vadotrequired:
465def4c47SEmmanuel Vadot  - compatible
475def4c47SEmmanuel Vadot  - reg
485def4c47SEmmanuel Vadot
495def4c47SEmmanuel VadotunevaluatedProperties: false
505def4c47SEmmanuel Vadot
515def4c47SEmmanuel Vadotexamples:
525def4c47SEmmanuel Vadot  - |
535def4c47SEmmanuel Vadot    #include <dt-bindings/gpio/gpio.h>
545def4c47SEmmanuel Vadot
555def4c47SEmmanuel Vadot    // Ethernet switch connected via SPI to the host, CPU port wired to eth0:
565def4c47SEmmanuel Vadot    eth0 {
575def4c47SEmmanuel Vadot        fixed-link {
585def4c47SEmmanuel Vadot            speed = <1000>;
595def4c47SEmmanuel Vadot            full-duplex;
605def4c47SEmmanuel Vadot        };
615def4c47SEmmanuel Vadot    };
625def4c47SEmmanuel Vadot
635def4c47SEmmanuel Vadot    spi0 {
645def4c47SEmmanuel Vadot        #address-cells = <1>;
655def4c47SEmmanuel Vadot        #size-cells = <0>;
665def4c47SEmmanuel Vadot
675def4c47SEmmanuel Vadot        pinctrl-0 = <&pinctrl_spi_ksz>;
685def4c47SEmmanuel Vadot        cs-gpios = <&pioC 25 0>;
695def4c47SEmmanuel Vadot        id = <1>;
705def4c47SEmmanuel Vadot
715def4c47SEmmanuel Vadot        ksz9477: switch@0 {
725def4c47SEmmanuel Vadot            compatible = "microchip,ksz9477";
735def4c47SEmmanuel Vadot            reg = <0>;
745def4c47SEmmanuel Vadot            reset-gpios = <&gpio5 0 GPIO_ACTIVE_LOW>;
755def4c47SEmmanuel Vadot
765def4c47SEmmanuel Vadot            spi-max-frequency = <44000000>;
775def4c47SEmmanuel Vadot
785def4c47SEmmanuel Vadot            ethernet-ports {
795def4c47SEmmanuel Vadot                #address-cells = <1>;
805def4c47SEmmanuel Vadot                #size-cells = <0>;
815def4c47SEmmanuel Vadot                port@0 {
825def4c47SEmmanuel Vadot                    reg = <0>;
835def4c47SEmmanuel Vadot                    label = "lan1";
845def4c47SEmmanuel Vadot                };
855def4c47SEmmanuel Vadot                port@1 {
865def4c47SEmmanuel Vadot                    reg = <1>;
875def4c47SEmmanuel Vadot                    label = "lan2";
885def4c47SEmmanuel Vadot                };
895def4c47SEmmanuel Vadot                port@2 {
905def4c47SEmmanuel Vadot                    reg = <2>;
915def4c47SEmmanuel Vadot                    label = "lan3";
925def4c47SEmmanuel Vadot                };
935def4c47SEmmanuel Vadot                port@3 {
945def4c47SEmmanuel Vadot                    reg = <3>;
955def4c47SEmmanuel Vadot                    label = "lan4";
965def4c47SEmmanuel Vadot                };
975def4c47SEmmanuel Vadot                port@4 {
985def4c47SEmmanuel Vadot                    reg = <4>;
995def4c47SEmmanuel Vadot                    label = "lan5";
1005def4c47SEmmanuel Vadot                };
1015def4c47SEmmanuel Vadot                port@5 {
1025def4c47SEmmanuel Vadot                    reg = <5>;
1035def4c47SEmmanuel Vadot                    label = "cpu";
1045def4c47SEmmanuel Vadot                    ethernet = <&eth0>;
1055def4c47SEmmanuel Vadot                    fixed-link {
1065def4c47SEmmanuel Vadot                        speed = <1000>;
1075def4c47SEmmanuel Vadot                        full-duplex;
1085def4c47SEmmanuel Vadot                    };
1095def4c47SEmmanuel Vadot                };
1105def4c47SEmmanuel Vadot            };
1115def4c47SEmmanuel Vadot        };
1125def4c47SEmmanuel Vadot
1135def4c47SEmmanuel Vadot        ksz8565: switch@1 {
1145def4c47SEmmanuel Vadot            compatible = "microchip,ksz8565";
1155def4c47SEmmanuel Vadot            reg = <1>;
1165def4c47SEmmanuel Vadot
1175def4c47SEmmanuel Vadot            spi-max-frequency = <44000000>;
1185def4c47SEmmanuel Vadot
1195def4c47SEmmanuel Vadot            ethernet-ports {
1205def4c47SEmmanuel Vadot                #address-cells = <1>;
1215def4c47SEmmanuel Vadot                #size-cells = <0>;
1225def4c47SEmmanuel Vadot                port@0 {
1235def4c47SEmmanuel Vadot                    reg = <0>;
1245def4c47SEmmanuel Vadot                    label = "lan1";
1255def4c47SEmmanuel Vadot                };
1265def4c47SEmmanuel Vadot                port@1 {
1275def4c47SEmmanuel Vadot                    reg = <1>;
1285def4c47SEmmanuel Vadot                    label = "lan2";
1295def4c47SEmmanuel Vadot                };
1305def4c47SEmmanuel Vadot                port@2 {
1315def4c47SEmmanuel Vadot                    reg = <2>;
1325def4c47SEmmanuel Vadot                    label = "lan3";
1335def4c47SEmmanuel Vadot                };
1345def4c47SEmmanuel Vadot                port@3 {
1355def4c47SEmmanuel Vadot                    reg = <3>;
1365def4c47SEmmanuel Vadot                    label = "lan4";
1375def4c47SEmmanuel Vadot                };
1385def4c47SEmmanuel Vadot                port@6 {
1395def4c47SEmmanuel Vadot                    reg = <6>;
1405def4c47SEmmanuel Vadot                    label = "cpu";
1415def4c47SEmmanuel Vadot                    ethernet = <&eth0>;
1425def4c47SEmmanuel Vadot                    fixed-link {
1435def4c47SEmmanuel Vadot                        speed = <1000>;
1445def4c47SEmmanuel Vadot                        full-duplex;
1455def4c47SEmmanuel Vadot                    };
1465def4c47SEmmanuel Vadot                };
1475def4c47SEmmanuel Vadot            };
1485def4c47SEmmanuel Vadot        };
1495def4c47SEmmanuel Vadot    };
1505def4c47SEmmanuel Vadot...
151