168 lines · yaml
1# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)2%YAML 1.23---4$id: http://devicetree.org/schemas/net/dsa/brcm,sf2.yaml#5$schema: http://devicetree.org/meta-schemas/core.yaml#6 7title: Broadcom Starfighter 2 integrated switch8 9maintainers:10 - Florian Fainelli <f.fainelli@gmail.com>11 12properties:13 compatible:14 items:15 - enum:16 - brcm,bcm4908-switch17 - brcm,bcm7278-switch-v4.018 - brcm,bcm7278-switch-v4.819 - brcm,bcm7445-switch-v4.020 21 reg:22 minItems: 623 maxItems: 624 25 reg-names:26 items:27 - const: core28 - const: reg29 - const: intrl2_030 - const: intrl2_131 - const: fcb32 - const: acb33 34 interrupts:35 minItems: 236 maxItems: 237 38 interrupt-names:39 items:40 - const: switch_041 - const: switch_142 43 resets:44 maxItems: 145 46 reset-names:47 const: switch48 49 clocks:50 minItems: 151 items:52 - description: switch's main clock53 - description: dividing of the switch core clock54 55 clock-names:56 minItems: 157 items:58 - const: sw_switch59 - const: sw_switch_mdiv60 61 brcm,num-gphy:62 $ref: /schemas/types.yaml#/definitions/uint3263 description: maximum number of integrated gigabit PHYs in the switch64 65 brcm,num-rgmii-ports:66 $ref: /schemas/types.yaml#/definitions/uint3267 description: maximum number of RGMII interfaces supported by the switch68 69 brcm,fcb-pause-override:70 description: if present indicates that the switch supports Failover Control71 Block pause override capability72 type: boolean73 74 brcm,acb-packets-inflight:75 description: if present indicates that the switch Admission Control Block76 supports reporting the number of packets in-flight in a switch queue77 type: boolean78 79 ports:80 type: object81 additionalProperties: true82 83 patternProperties:84 '^port@[0-9a-f]$':85 $ref: dsa-port.yaml#86 unevaluatedProperties: false87 88 properties:89 brcm,use-bcm-hdr:90 description: if present, indicates that the switch port has Broadcom91 tags enabled (per-packet metadata)92 type: boolean93 94required:95 - reg96 - interrupts97 98allOf:99 - $ref: dsa.yaml#100 - if:101 properties:102 compatible:103 contains:104 enum:105 - brcm,bcm7278-switch-v4.0106 - brcm,bcm7278-switch-v4.8107 then:108 properties:109 clocks:110 minItems: 1111 maxItems: 1112 clock-names:113 minItems: 1114 maxItems: 1115 required:116 - clocks117 - clock-names118 - if:119 properties:120 compatible:121 contains:122 const: brcm,bcm7445-switch-v4.0123 then:124 properties:125 clocks:126 minItems: 2127 maxItems: 2128 clock-names:129 minItems: 2130 maxItems: 2131 required:132 - clocks133 - clock-names134 135additionalProperties: false136 137examples:138 - |139 switch@f0b00000 {140 compatible = "brcm,bcm7445-switch-v4.0";141 reg = <0xf0b00000 0x40000>,142 <0xf0b40000 0x110>,143 <0xf0b40340 0x30>,144 <0xf0b40380 0x30>,145 <0xf0b40400 0x34>,146 <0xf0b40600 0x208>;147 reg-names = "core", "reg", "intrl2_0", "intrl2_1",148 "fcb", "acb";149 interrupts = <0 0x18 0>,150 <0 0x19 0>;151 clocks = <&sw_switch>, <&sw_switch_mdiv>;152 clock-names = "sw_switch", "sw_switch_mdiv";153 brcm,num-gphy = <1>;154 brcm,num-rgmii-ports = <2>;155 brcm,fcb-pause-override;156 brcm,acb-packets-inflight;157 158 ports {159 #address-cells = <1>;160 #size-cells = <0>;161 162 port@0 {163 label = "gphy";164 reg = <0>;165 };166 };167 };168