From patchwork Fri Sep 9 12:45:13 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Corentin Labbe X-Patchwork-Id: 9323291 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 20E4160752 for ; Fri, 9 Sep 2016 12:50:13 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 1416D29E79 for ; Fri, 9 Sep 2016 12:50:13 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 0922F29E7F; Fri, 9 Sep 2016 12:50:13 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-4.1 required=2.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_MED, T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.9]) (using TLSv1.2 with cipher AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 8ECB429E79 for ; Fri, 9 Sep 2016 12:50:12 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.85_2 #1 (Red Hat Linux)) id 1biLEi-0006SU-8V; Fri, 09 Sep 2016 12:48:52 +0000 Received: from mail-wm0-x244.google.com ([2a00:1450:400c:c09::244]) by bombadil.infradead.org with esmtps (Exim 4.85_2 #1 (Red Hat Linux)) id 1biLD8-0005oQ-RU for linux-arm-kernel@lists.infradead.org; Fri, 09 Sep 2016 12:47:17 +0000 Received: by mail-wm0-x244.google.com with SMTP id a6so2622736wmc.2 for ; Fri, 09 Sep 2016 05:46:54 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=A/jw1etKlpU+EylxOGVKSmi4ftMwNiNtkeRSAc5k/ic=; b=rAoXIyh4het+QjUvM1ATa7UZnB0+SbLAWlc0QjFlG4QH33eAFtKAZ5pY0Z/najxwjM hzfOIE5K+AWzCN+qny0OimT71QdaiNnB3CoOOZrjvUM9dRjXEm4msXzgr5t6W3YWzpvd Um7vozC3bxKqAHxOjUqW7i9anIoD9nbDcIHP21ZktdKHxsDFGWjTfJq5dh3ExTAcWwSg AunAAWj2iOfT/S6OQfzD/9pbtv5grDRZp73O++7M/SR5wBqwCHWjX+Ogz+PmGcy7x8d9 1VBmA244BxsIekubw19oS+VHu+JO9aaSpQJOyq6BTEE8vp3eHBbOfxUquT/WtSQR1EOw Yl7A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=A/jw1etKlpU+EylxOGVKSmi4ftMwNiNtkeRSAc5k/ic=; b=jAG9TlaIdQUUqgPr2ZgipuISAgmqfN49VHGv0jKrXf8JmHT0WndnlH3fBpbBowGvSn AYRRVoCeBv7sKbNJoH74XhN3iQAYV+Mvd32oLk/YqxJFLMxanlFwtia6HObRh7tYWz2e 0fglXrWAlOrJcg5O7DRDyR2sGwXn603cvflSu2GpX4MAYFgVE/eYaJaMUzM0EjQRFtlC mR2oKKBw+4zhjlg891h3G4UJCWeKlGL1QU7TQqskkCwHMJ7o9DXJwE8Cnfi4D23SWf0p c7beIEAudG89Vhv6ipqhMOxdeCkiSNLPey4Ex4f2yWUKAiqo00xjT9PCSorlNEectpMn zDAQ== X-Gm-Message-State: AE9vXwNHbSBCiZVDHqScRg/4wvZSVdYpkrS0oSnOdn+cyKamAPxiBux6YSUs89qt29TqYw== X-Received: by 10.194.176.2 with SMTP id ce2mr3142171wjc.189.1473425212958; Fri, 09 Sep 2016 05:46:52 -0700 (PDT) Received: from Red.local (LFbn-1-7035-57.w90-116.abo.wanadoo.fr. [90.116.208.57]) by smtp.googlemail.com with ESMTPSA id b188sm3192572wmg.24.2016.09.09.05.46.51 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Fri, 09 Sep 2016 05:46:52 -0700 (PDT) From: Corentin Labbe To: robh+dt@kernel.org, mark.rutland@arm.com, maxime.ripard@free-electrons.com, wens@csie.org, linux@armlinux.org.uk, davem@davemloft.net Subject: [PATCH v3 5/9] ARM: dts: sun8i-h3: add sun8i-emac ethernet driver Date: Fri, 9 Sep 2016 14:45:13 +0200 Message-Id: <1473425117-18645-6-git-send-email-clabbe.montjoie@gmail.com> X-Mailer: git-send-email 2.7.3 In-Reply-To: <1473425117-18645-1-git-send-email-clabbe.montjoie@gmail.com> References: <1473425117-18645-1-git-send-email-clabbe.montjoie@gmail.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20160909_054715_264584_FC0379D8 X-CRM114-Status: GOOD ( 10.13 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: netdev@vger.kernel.org, Corentin Labbe , linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP The sun8i-emac is an ethernet MAC hardware that support 10/100/1000 speed. This patch enable the sun8i-emac on the Allwinner H3 SoC Device-tree. The SoC H3 have an internal PHY, so optionals syscon and ephy are set. Signed-off-by: Corentin Labbe --- arch/arm/boot/dts/sun8i-h3.dtsi | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/arch/arm/boot/dts/sun8i-h3.dtsi b/arch/arm/boot/dts/sun8i-h3.dtsi index a39da6f..a3ac476 100644 --- a/arch/arm/boot/dts/sun8i-h3.dtsi +++ b/arch/arm/boot/dts/sun8i-h3.dtsi @@ -50,6 +50,10 @@ / { interrupt-parent = <&gic>; + aliases { + ethernet0 = &emac; + }; + cpus { #address-cells = <1>; #size-cells = <0>; @@ -446,6 +450,21 @@ status = "disabled"; }; + emac: ethernet@1c30000 { + compatible = "allwinner,sun8i-h3-emac"; + syscon = <&syscon>; + reg = <0x01c30000 0x104>; + reg-names = "emac"; + interrupts = ; + resets = <&ccu RST_BUS_EMAC>, <&ccu RST_BUS_EPHY>; + reset-names = "ahb", "ephy"; + clocks = <&ccu CLK_BUS_EMAC>, <&ccu CLK_BUS_EPHY>; + clock-names = "ahb", "ephy"; + #address-cells = <1>; + #size-cells = <0>; + status = "disabled"; + }; + gic: interrupt-controller@01c81000 { compatible = "arm,cortex-a7-gic", "arm,cortex-a15-gic"; reg = <0x01c81000 0x1000>,