Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

dt-bindings: net: Add Loongson-1 Ethernet Controller

Add devicetree binding document for Loongson-1 Ethernet controller.
And modify MAINTAINERS to add a new F: entry for
Loongson1 dt-binding documents.

Signed-off-by: Keguang Zhang <keguang.zhang@gmail.com>
Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Reviewed-by: Serge Semin <fancer.lancer@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

authored by

Keguang Zhang and committed by
David S. Miller
2af21077 7e10088b

+228
+114
Documentation/devicetree/bindings/net/loongson,ls1b-gmac.yaml
··· 1 + # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) 2 + %YAML 1.2 3 + --- 4 + $id: http://devicetree.org/schemas/net/loongson,ls1b-gmac.yaml# 5 + $schema: http://devicetree.org/meta-schemas/core.yaml# 6 + 7 + title: Loongson-1B Gigabit Ethernet MAC Controller 8 + 9 + maintainers: 10 + - Keguang Zhang <keguang.zhang@gmail.com> 11 + 12 + description: | 13 + Loongson-1B Gigabit Ethernet MAC Controller is based on 14 + Synopsys DesignWare MAC (version 3.50a). 15 + 16 + Main features 17 + - Dual 10/100/1000Mbps GMAC controllers 18 + - Full-duplex operation (IEEE 802.3x flow control automatic transmission) 19 + - Half-duplex operation (CSMA/CD Protocol and back-pressure support) 20 + - RX Checksum Offload 21 + - TX Checksum insertion 22 + - MII interface 23 + - RGMII interface 24 + 25 + select: 26 + properties: 27 + compatible: 28 + contains: 29 + enum: 30 + - loongson,ls1b-gmac 31 + required: 32 + - compatible 33 + 34 + properties: 35 + compatible: 36 + items: 37 + - enum: 38 + - loongson,ls1b-gmac 39 + - const: snps,dwmac-3.50a 40 + 41 + reg: 42 + maxItems: 1 43 + 44 + clocks: 45 + maxItems: 1 46 + 47 + clock-names: 48 + items: 49 + - const: stmmaceth 50 + 51 + interrupts: 52 + maxItems: 1 53 + 54 + interrupt-names: 55 + items: 56 + - const: macirq 57 + 58 + loongson,ls1-syscon: 59 + $ref: /schemas/types.yaml#/definitions/phandle 60 + description: 61 + Phandle to the syscon containing some extra configurations 62 + including PHY interface mode. 63 + 64 + phy-mode: 65 + enum: 66 + - mii 67 + - rgmii-id 68 + 69 + required: 70 + - compatible 71 + - reg 72 + - clocks 73 + - clock-names 74 + - interrupts 75 + - interrupt-names 76 + - loongson,ls1-syscon 77 + 78 + allOf: 79 + - $ref: snps,dwmac.yaml# 80 + 81 + unevaluatedProperties: false 82 + 83 + examples: 84 + - | 85 + #include <dt-bindings/clock/loongson,ls1x-clk.h> 86 + #include <dt-bindings/interrupt-controller/irq.h> 87 + 88 + gmac0: ethernet@1fe10000 { 89 + compatible = "loongson,ls1b-gmac", "snps,dwmac-3.50a"; 90 + reg = <0x1fe10000 0x10000>; 91 + 92 + clocks = <&clkc LS1X_CLKID_AHB>; 93 + clock-names = "stmmaceth"; 94 + 95 + interrupt-parent = <&intc1>; 96 + interrupts = <2 IRQ_TYPE_LEVEL_HIGH>; 97 + interrupt-names = "macirq"; 98 + 99 + loongson,ls1-syscon = <&syscon>; 100 + 101 + phy-handle = <&phy0>; 102 + phy-mode = "mii"; 103 + snps,pbl = <1>; 104 + 105 + mdio { 106 + #address-cells = <1>; 107 + #size-cells = <0>; 108 + compatible = "snps,dwmac-mdio"; 109 + 110 + phy0: ethernet-phy@0 { 111 + reg = <0x0>; 112 + }; 113 + }; 114 + };
+113
Documentation/devicetree/bindings/net/loongson,ls1c-emac.yaml
··· 1 + # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) 2 + %YAML 1.2 3 + --- 4 + $id: http://devicetree.org/schemas/net/loongson,ls1c-emac.yaml# 5 + $schema: http://devicetree.org/meta-schemas/core.yaml# 6 + 7 + title: Loongson-1C Ethernet MAC Controller 8 + 9 + maintainers: 10 + - Keguang Zhang <keguang.zhang@gmail.com> 11 + 12 + description: | 13 + Loongson-1C Ethernet MAC Controller is based on 14 + Synopsys DesignWare MAC (version 3.50a). 15 + 16 + Main features 17 + - 10/100Mbps 18 + - Full-duplex operation (IEEE 802.3x flow control automatic transmission) 19 + - Half-duplex operation (CSMA/CD Protocol and back-pressure support) 20 + - IEEE 802.1Q VLAN tag detection for reception frames 21 + - MII interface 22 + - RMII interface 23 + 24 + select: 25 + properties: 26 + compatible: 27 + contains: 28 + enum: 29 + - loongson,ls1c-emac 30 + required: 31 + - compatible 32 + 33 + properties: 34 + compatible: 35 + items: 36 + - enum: 37 + - loongson,ls1c-emac 38 + - const: snps,dwmac-3.50a 39 + 40 + reg: 41 + maxItems: 1 42 + 43 + clocks: 44 + maxItems: 1 45 + 46 + clock-names: 47 + items: 48 + - const: stmmaceth 49 + 50 + interrupts: 51 + maxItems: 1 52 + 53 + interrupt-names: 54 + items: 55 + - const: macirq 56 + 57 + loongson,ls1-syscon: 58 + $ref: /schemas/types.yaml#/definitions/phandle 59 + description: 60 + Phandle to the syscon containing some extra configurations 61 + including PHY interface mode. 62 + 63 + phy-mode: 64 + enum: 65 + - mii 66 + - rmii 67 + 68 + required: 69 + - compatible 70 + - reg 71 + - clocks 72 + - clock-names 73 + - interrupts 74 + - interrupt-names 75 + - loongson,ls1-syscon 76 + 77 + allOf: 78 + - $ref: snps,dwmac.yaml# 79 + 80 + unevaluatedProperties: false 81 + 82 + examples: 83 + - | 84 + #include <dt-bindings/clock/loongson,ls1x-clk.h> 85 + #include <dt-bindings/interrupt-controller/irq.h> 86 + 87 + emac: ethernet@1fe10000 { 88 + compatible = "loongson,ls1c-emac", "snps,dwmac-3.50a"; 89 + reg = <0x1fe10000 0x10000>; 90 + 91 + clocks = <&clkc LS1X_CLKID_AHB>; 92 + clock-names = "stmmaceth"; 93 + 94 + interrupt-parent = <&intc1>; 95 + interrupts = <2 IRQ_TYPE_LEVEL_HIGH>; 96 + interrupt-names = "macirq"; 97 + 98 + loongson,ls1-syscon = <&syscon>; 99 + 100 + phy-handle = <&phy0>; 101 + phy-mode = "mii"; 102 + snps,pbl = <1>; 103 + 104 + mdio { 105 + #address-cells = <1>; 106 + #size-cells = <0>; 107 + compatible = "snps,dwmac-mdio"; 108 + 109 + phy0: ethernet-phy@13 { 110 + reg = <0x13>; 111 + }; 112 + }; 113 + };
+1
MAINTAINERS
··· 14344 14344 M: Keguang Zhang <keguang.zhang@gmail.com> 14345 14345 L: linux-mips@vger.kernel.org 14346 14346 S: Maintained 14347 + F: Documentation/devicetree/bindings/*/loongson,ls1*.yaml 14347 14348 F: arch/mips/include/asm/mach-loongson32/ 14348 14349 F: arch/mips/loongson32/ 14349 14350 F: drivers/*/*loongson1*