1# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) 2%YAML 1.2 3--- 4$id: http://devicetree.org/schemas/net/sophgo,cv1800b-dwmac.yaml# 5$schema: http://devicetree.org/meta-schemas/core.yaml# 6 7title: Sophgo CV1800B DWMAC glue layer 8 9maintainers: 10 - Inochi Amaoto <inochiama@gmail.com> 11 12select: 13 properties: 14 compatible: 15 contains: 16 enum: 17 - sophgo,cv1800b-dwmac 18 required: 19 - compatible 20 21properties: 22 compatible: 23 items: 24 - const: sophgo,cv1800b-dwmac 25 - const: snps,dwmac-3.70a 26 27 reg: 28 maxItems: 1 29 30 clocks: 31 items: 32 - description: GMAC main clock 33 - description: PTP clock 34 35 clock-names: 36 items: 37 - const: stmmaceth 38 - const: ptp_ref 39 40 interrupts: 41 maxItems: 1 42 43 interrupt-names: 44 maxItems: 1 45 46 resets: 47 maxItems: 1 48 49 reset-names: 50 const: stmmaceth 51 52required: 53 - compatible 54 - reg 55 - clocks 56 - clock-names 57 - interrupts 58 - interrupt-names 59 - resets 60 - reset-names 61 62allOf: 63 - $ref: snps,dwmac.yaml# 64 65unevaluatedProperties: false 66 67examples: 68 - | 69 #include <dt-bindings/interrupt-controller/irq.h> 70 71 ethernet@4070000 { 72 compatible = "sophgo,cv1800b-dwmac", "snps,dwmac-3.70a"; 73 reg = <0x04070000 0x10000>; 74 clocks = <&clk 35>, <&clk 36>; 75 clock-names = "stmmaceth", "ptp_ref"; 76 interrupts = <31 IRQ_TYPE_LEVEL_HIGH>; 77 interrupt-names = "macirq"; 78 phy-handle = <&internal_ephy>; 79 phy-mode = "internal"; 80 resets = <&rst 12>; 81 reset-names = "stmmaceth"; 82 rx-fifo-depth = <8192>; 83 tx-fifo-depth = <8192>; 84 snps,multicast-filter-bins = <0>; 85 snps,perfect-filter-entries = <1>; 86 snps,aal; 87 snps,txpbl = <8>; 88 snps,rxpbl = <8>; 89 snps,mtl-rx-config = <&gmac0_mtl_rx_setup>; 90 snps,mtl-tx-config = <&gmac0_mtl_tx_setup>; 91 snps,axi-config = <&gmac0_stmmac_axi_setup>; 92 93 mdio { 94 compatible = "snps,dwmac-mdio"; 95 #address-cells = <1>; 96 #size-cells = <0>; 97 }; 98 99 gmac0_mtl_rx_setup: rx-queues-config { 100 snps,rx-queues-to-use = <1>; 101 queue0 {}; 102 }; 103 104 gmac0_mtl_tx_setup: tx-queues-config { 105 snps,tx-queues-to-use = <1>; 106 queue0 {}; 107 }; 108 109 gmac0_stmmac_axi_setup: stmmac-axi-config { 110 snps,blen = <16 8 4 0 0 0 0>; 111 snps,rd_osr_lmt = <2>; 112 snps,wr_osr_lmt = <1>; 113 }; 114 }; 115