From patchwork Sat Jun 29 15:01:37 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Lorenzo Bianconi X-Patchwork-Id: 13716953 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id BB6F5C27C4F for ; Sat, 29 Jun 2024 15:02:27 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:Content-Transfer-Encoding: MIME-Version:References:In-Reply-To:Message-ID:Date:Subject:Cc:To:From: Reply-To:Content-Type:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=j29NmUhDn5wTlk6MuzAR0g7L6dn9qTE59EzjJKUHxHE=; b=glBEc7sjXY+S28eUmUOM8u9luA 5BGtSzFTZrHT1QVdXBXC5ZC4GC57So0PRplRD1bwzypQ4Sba9gaB8KdVv0vvB872L9aDtQ1+ms/i5 3dyDkzFqvQR7bxYFbByE9pNEIznVt8OG0i4Ixr/eiWTVFkwzhTSYE71WxUOgkYgY1bxN5QxWEtP3m CQP/Zw3s/nzxl6YDrBQ+KVCwpgnrfvHPfUrMod13aFe5F4v+D4fnJcrgkCRrMGs3ANSgvosBb3wfD ifdphdem7AKv10tV/xAf3XYz62CpQzCzYphevrslYt/IzYJUDWxep1F9zCQHJdO2/XXyARHzDZ4kA CJImsoJw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1sNZah-0000000GYeU-1w3J; Sat, 29 Jun 2024 15:02:15 +0000 Received: from dfw.source.kernel.org ([2604:1380:4641:c500::1]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1sNZaL-0000000GYWY-2dL1 for linux-arm-kernel@lists.infradead.org; Sat, 29 Jun 2024 15:01:55 +0000 Received: from smtp.kernel.org (transwarp.subspace.kernel.org [100.75.92.58]) by dfw.source.kernel.org (Postfix) with ESMTP id BBE6A60B7D; Sat, 29 Jun 2024 15:01:52 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id E138DC2BBFC; Sat, 29 Jun 2024 15:01:51 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1719673312; bh=SwqgEM9gABZ/kq/FR5x5DuJvZdyd1njTF45cNQIedSY=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=tWBHTw0c7dZ9+dozVsloCp9Q/jkFQZCNHZxv68CseubmL5aaVDTZ2nNduVSlHaBLM g1ibunQt1erSebtNdhsNhPd9wYneeTfxyOfZ5gEkznx2oUD7gV++l8TrBa6GTMfD1B 2pHqmvfJMUd8tIMS7i29bjGMlVOmkP3+Itsx1Fk7pfKo3dkdPGenlzgv0S9gbOQDZk iF1L5tDpPohCstIR+SGl6+quhqXJD5fPjzalCrpC7S9qw39dB4y2ZPzL4u3ykWufwo hg2jCy28hWEKWojj2JXyB0wjGPbtllQcV39KsdUeFwfNvD4qMHd+P1K73HGeMJKDs9 nBLTc8/aZ0cTg== From: Lorenzo Bianconi To: netdev@vger.kernel.org Cc: nbd@nbd.name, lorenzo.bianconi83@gmail.com, davem@davemloft.net, edumazet@google.com, kuba@kernel.org, pabeni@redhat.com, conor@kernel.org, linux-arm-kernel@lists.infradead.org, robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, conor+dt@kernel.org, devicetree@vger.kernel.org, catalin.marinas@arm.com, will@kernel.org, upstream@airoha.com, angelogioacchino.delregno@collabora.com, benjamin.larsson@genexis.eu, rkannoth@marvell.com, sgoutham@marvell.com, andrew@lunn.ch, arnd@arndb.de, horms@kernel.org Subject: [PATCH v4 1/2] dt-bindings: net: airoha: Add EN7581 ethernet controller Date: Sat, 29 Jun 2024 17:01:37 +0200 Message-ID: <20d103799a20d9d61a1c378eb27e61748859e978.1719672695.git.lorenzo@kernel.org> X-Mailer: git-send-email 2.45.2 In-Reply-To: References: MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240629_080153_849267_D31A2128 X-CRM114-Status: GOOD ( 11.90 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Introduce device-tree binding documentation for Airoha EN7581 ethernet mac controller. Signed-off-by: Lorenzo Bianconi --- .../bindings/net/airoha,en7581-eth.yaml | 171 ++++++++++++++++++ 1 file changed, 171 insertions(+) create mode 100644 Documentation/devicetree/bindings/net/airoha,en7581-eth.yaml diff --git a/Documentation/devicetree/bindings/net/airoha,en7581-eth.yaml b/Documentation/devicetree/bindings/net/airoha,en7581-eth.yaml new file mode 100644 index 000000000000..e2c0da02ccf2 --- /dev/null +++ b/Documentation/devicetree/bindings/net/airoha,en7581-eth.yaml @@ -0,0 +1,171 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/net/airoha,en7581-eth.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Airoha EN7581 Frame Engine Ethernet controller + +allOf: + - $ref: ethernet-controller.yaml# + +maintainers: + - Lorenzo Bianconi + +description: + The frame engine ethernet controller can be found on Airoha SoCs. + These SoCs have dual GMAC ports. + +properties: + compatible: + enum: + - airoha,en7581-eth + + reg: + items: + - description: Frame engine base address + - description: QDMA0 base address + - description: QDMA1 base address + + reg-names: + items: + - const: fe + - const: qdma0 + - const: qdma1 + + interrupts: + items: + - description: QDMA lan irq0 + - description: QDMA lan irq1 + - description: QDMA lan irq2 + - description: QDMA lan irq3 + - description: QDMA wan irq0 + - description: QDMA wan irq1 + - description: QDMA wan irq2 + - description: QDMA wan irq3 + - description: FE error irq + - description: PDMA irq + + resets: + maxItems: 8 + + reset-names: + items: + - const: fe + - const: pdma + - const: qdma + - const: xsi-mac + - const: hsi0-mac + - const: hsi1-mac + - const: hsi-mac + - const: xfp-mac + + "#address-cells": + const: 1 + + "#size-cells": + const: 0 + +patternProperties: + "^mac@[1-4]$": + type: object + unevaluatedProperties: false + allOf: + - $ref: ethernet-controller.yaml# + description: + Ethernet MAC node + properties: + compatible: + const: airoha,eth-mac + + reg: + maxItems: 1 + + required: + - reg + - compatible + +required: + - compatible + - reg + - interrupts + - resets + - reset-names + +unevaluatedProperties: false + +examples: + - | + #include + #include + #include + + soc { + #address-cells = <2>; + #size-cells = <2>; + + eth0: ethernet@1fb50000 { + compatible = "airoha,en7581-eth"; + reg = <0 0x1fb50000 0 0x2600>, + <0 0x1fb54000 0 0x2000>, + <0 0x1fb56000 0 0x2000>; + reg-names = "fe", "qdma0", "qdma1"; + + resets = <&scuclk 44>, + <&scuclk 30>, + <&scuclk 31>, + <&scuclk 6>, + <&scuclk 15>, + <&scuclk 16>, + <&scuclk 17>, + <&scuclk 26>; + reset-names = "fe", "pdma", "qdma", "xsi-mac", + "hsi0-mac", "hsi1-mac", "hsi-mac", + "xfp-mac"; + + interrupts = , + , + , + , + , + , + , + , + , + ; + + #address-cells = <1>; + #size-cells = <0>; + + mac1: mac@1 { + compatible = "airoha,eth-mac"; + reg = <1>; + phy-mode = "2500base-x"; + phy-handle = <&phy0>; + }; + + mac2: mac@2 { + compatible = "airoha,eth-mac"; + reg = <2>; + phy-mode = "2500base-x"; + phy-handle = <&phy1>; + }; + }; + + mdio: mdio-bus { + #address-cells = <1>; + #size-cells = <0>; + + phy0: ethernet-phy@0 { + compatible = "ethernet-phy-id67c9.de0a"; + reg = <0>; + phy-mode = "2500base-x"; + }; + + phy1: ethernet-phy@1 { + compatible = "ethernet-phy-id67c9.de0a"; + reg = <1>; + phy-mode = "2500base-x"; + }; + }; + };