xref: /linux/Documentation/devicetree/bindings/net/dsa/hirschmann,hellcreek.yaml (revision 9a87ffc99ec8eb8d35eed7c4f816d75f5cc9662e)
1d5d29d52SKurt Kanzenbach# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
2d5d29d52SKurt Kanzenbach%YAML 1.2
3d5d29d52SKurt Kanzenbach---
4d5d29d52SKurt Kanzenbach$id: http://devicetree.org/schemas/net/dsa/hirschmann,hellcreek.yaml#
5d5d29d52SKurt Kanzenbach$schema: http://devicetree.org/meta-schemas/core.yaml#
6d5d29d52SKurt Kanzenbach
7a612130cSKrzysztof Kozlowskititle: Hirschmann Hellcreek TSN Switch
8d5d29d52SKurt Kanzenbach
9d5d29d52SKurt KanzenbachallOf:
10*3cec368aSColin Foster  - $ref: dsa.yaml#/$defs/ethernet-ports
11d5d29d52SKurt Kanzenbach
12d5d29d52SKurt Kanzenbachmaintainers:
13d5d29d52SKurt Kanzenbach  - Andrew Lunn <andrew@lunn.ch>
14d5d29d52SKurt Kanzenbach  - Florian Fainelli <f.fainelli@gmail.com>
1593e637a3SKurt Kanzenbach  - Vladimir Oltean <olteanv@gmail.com>
16d5d29d52SKurt Kanzenbach  - Kurt Kanzenbach <kurt@linutronix.de>
17d5d29d52SKurt Kanzenbach
18d5d29d52SKurt Kanzenbachdescription:
19d5d29d52SKurt Kanzenbach  The Hellcreek TSN Switch IP is a 802.1Q Ethernet compliant switch. It supports
20d5d29d52SKurt Kanzenbach  the Precision Time Protocol, Hardware Timestamping as well the Time Aware
21d5d29d52SKurt Kanzenbach  Shaper.
22d5d29d52SKurt Kanzenbach
23d5d29d52SKurt Kanzenbachproperties:
24d5d29d52SKurt Kanzenbach  compatible:
25d5d29d52SKurt Kanzenbach    items:
26d5d29d52SKurt Kanzenbach      - const: hirschmann,hellcreek-de1soc-r1
27d5d29d52SKurt Kanzenbach
28d5d29d52SKurt Kanzenbach  reg:
29d5d29d52SKurt Kanzenbach    description:
30d5d29d52SKurt Kanzenbach      The physical base address and size of TSN and PTP memory base
31d5d29d52SKurt Kanzenbach    minItems: 2
32d5d29d52SKurt Kanzenbach    maxItems: 2
33d5d29d52SKurt Kanzenbach
34d5d29d52SKurt Kanzenbach  reg-names:
35d5d29d52SKurt Kanzenbach    items:
36d5d29d52SKurt Kanzenbach      - const: tsn
37d5d29d52SKurt Kanzenbach      - const: ptp
38d5d29d52SKurt Kanzenbach
39d5d29d52SKurt Kanzenbach  leds:
40d5d29d52SKurt Kanzenbach    type: object
41d5d29d52SKurt Kanzenbach    properties:
42d5d29d52SKurt Kanzenbach      '#address-cells':
43d5d29d52SKurt Kanzenbach        const: 1
44d5d29d52SKurt Kanzenbach      '#size-cells':
45d5d29d52SKurt Kanzenbach        const: 0
46d5d29d52SKurt Kanzenbach
47d5d29d52SKurt Kanzenbach    patternProperties:
48d5d29d52SKurt Kanzenbach      "^led@[01]$":
49d5d29d52SKurt Kanzenbach        type: object
50d5d29d52SKurt Kanzenbach        description: Hellcreek leds
51a683dc5cSKrzysztof Kozlowski        $ref: /schemas/leds/common.yaml#
52d5d29d52SKurt Kanzenbach
53d5d29d52SKurt Kanzenbach        properties:
54d5d29d52SKurt Kanzenbach          reg:
55d5d29d52SKurt Kanzenbach            items:
56d5d29d52SKurt Kanzenbach              - enum: [0, 1]
57d5d29d52SKurt Kanzenbach            description: Led number
58d5d29d52SKurt Kanzenbach
59d5d29d52SKurt Kanzenbach          label: true
60d5d29d52SKurt Kanzenbach
61d5d29d52SKurt Kanzenbach          default-state: true
62d5d29d52SKurt Kanzenbach
63d5d29d52SKurt Kanzenbach        required:
64d5d29d52SKurt Kanzenbach          - reg
65d5d29d52SKurt Kanzenbach
66d5d29d52SKurt Kanzenbach        additionalProperties: false
67d5d29d52SKurt Kanzenbach
68d5d29d52SKurt Kanzenbach    additionalProperties: false
69d5d29d52SKurt Kanzenbach
70d5d29d52SKurt Kanzenbachrequired:
71d5d29d52SKurt Kanzenbach  - compatible
72d5d29d52SKurt Kanzenbach  - reg
73d5d29d52SKurt Kanzenbach  - reg-names
74d5d29d52SKurt Kanzenbach  - ethernet-ports
75d5d29d52SKurt Kanzenbach  - leds
76d5d29d52SKurt Kanzenbach
77d5d29d52SKurt KanzenbachunevaluatedProperties: false
78d5d29d52SKurt Kanzenbach
79d5d29d52SKurt Kanzenbachexamples:
80d5d29d52SKurt Kanzenbach  - |
81d5d29d52SKurt Kanzenbach        switch0: switch@ff240000 {
82d5d29d52SKurt Kanzenbach            compatible = "hirschmann,hellcreek-de1soc-r1";
83d5d29d52SKurt Kanzenbach            reg = <0xff240000 0x1000>,
84d5d29d52SKurt Kanzenbach                  <0xff250000 0x1000>;
85d5d29d52SKurt Kanzenbach            reg-names = "tsn", "ptp";
86d5d29d52SKurt Kanzenbach            dsa,member = <0 0>;
87d5d29d52SKurt Kanzenbach
88d5d29d52SKurt Kanzenbach            ethernet-ports {
89d5d29d52SKurt Kanzenbach                #address-cells = <1>;
90d5d29d52SKurt Kanzenbach                #size-cells = <0>;
91d5d29d52SKurt Kanzenbach
92d5d29d52SKurt Kanzenbach                port@0 {
93d5d29d52SKurt Kanzenbach                    reg = <0>;
94d5d29d52SKurt Kanzenbach                    ethernet = <&gmac0>;
95b975b734SVladimir Oltean                    phy-mode = "mii";
96b975b734SVladimir Oltean
97b975b734SVladimir Oltean                    fixed-link {
98b975b734SVladimir Oltean                        speed = <100>;
99b975b734SVladimir Oltean                        full-duplex;
100b975b734SVladimir Oltean                    };
101d5d29d52SKurt Kanzenbach                };
102d5d29d52SKurt Kanzenbach
103d5d29d52SKurt Kanzenbach                port@2 {
104d5d29d52SKurt Kanzenbach                    reg = <2>;
105d5d29d52SKurt Kanzenbach                    label = "lan0";
106d5d29d52SKurt Kanzenbach                    phy-handle = <&phy1>;
107d5d29d52SKurt Kanzenbach                };
108d5d29d52SKurt Kanzenbach
109d5d29d52SKurt Kanzenbach                port@3 {
110d5d29d52SKurt Kanzenbach                    reg = <3>;
111d5d29d52SKurt Kanzenbach                    label = "lan1";
112d5d29d52SKurt Kanzenbach                    phy-handle = <&phy2>;
113d5d29d52SKurt Kanzenbach                };
114d5d29d52SKurt Kanzenbach            };
115d5d29d52SKurt Kanzenbach
116d5d29d52SKurt Kanzenbach            leds {
117d5d29d52SKurt Kanzenbach                #address-cells = <1>;
118d5d29d52SKurt Kanzenbach                #size-cells = <0>;
119d5d29d52SKurt Kanzenbach
120d5d29d52SKurt Kanzenbach                led@0 {
121d5d29d52SKurt Kanzenbach                    reg = <0>;
122d5d29d52SKurt Kanzenbach                    label = "sync_good";
123d5d29d52SKurt Kanzenbach                    default-state = "on";
124d5d29d52SKurt Kanzenbach                };
125d5d29d52SKurt Kanzenbach
126d5d29d52SKurt Kanzenbach                led@1 {
127d5d29d52SKurt Kanzenbach                    reg = <1>;
128d5d29d52SKurt Kanzenbach                    label = "is_gm";
129d5d29d52SKurt Kanzenbach                    default-state = "off";
130d5d29d52SKurt Kanzenbach                };
131d5d29d52SKurt Kanzenbach            };
132d5d29d52SKurt Kanzenbach        };
133