From patchwork Mon Nov 7 10:43:56 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Neil Armstrong X-Patchwork-Id: 9414693 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 AEA9960512 for ; Mon, 7 Nov 2016 10:44:58 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 9F64028B9F for ; Mon, 7 Nov 2016 10:44:58 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 93DE928BCF; Mon, 7 Nov 2016 10:44:58 +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_SIGNED, 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 356B628B9F for ; Mon, 7 Nov 2016 10:44:58 +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 1c3hQ3-0003BN-Nr; Mon, 07 Nov 2016 10:44:51 +0000 Received: from merlin.infradead.org ([2001:4978:20e::2]) by bombadil.infradead.org with esmtps (Exim 4.85_2 #1 (Red Hat Linux)) id 1c3hPh-00036M-IX for linux-amlogic@bombadil.infradead.org; Mon, 07 Nov 2016 10:44:29 +0000 Received: from mail-wm0-x22f.google.com ([2a00:1450:400c:c09::22f]) by merlin.infradead.org with esmtps (Exim 4.85_2 #1 (Red Hat Linux)) id 1c3hPf-0002gF-9C for linux-amlogic@lists.infradead.org; Mon, 07 Nov 2016 10:44:28 +0000 Received: by mail-wm0-x22f.google.com with SMTP id t79so168461561wmt.0 for ; Mon, 07 Nov 2016 02:44:05 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=h5DJisHhT8k0ihW4WqUsCSqCe3c1KCzhHClep+Zgb0A=; b=GTkO2CqZZ1iS5t+IjENpQwjykZ8Z8ozj5ySBaS9CB1HqPRCwqBeyxfE20+OW73OSqu CYgUAQwk2tuqEFzwLBYxAF+8CME8kQfsiteZW90S8OskoiLUHcUah1pGeXBMQUkx2xYa JHYaoGuhzpH4lZIJ/so8fLkOpbAAaqN9MvDkxTD5CoP5KS3p+OEVk4YQiHt/H/ukgHR1 RqK4alKGBFclTjybU82mmgxyYo0KR1O561wpLudVLear1hHv7cjclvmYxbQII2zgFKzK qtIttLpNupyTA+A++u8Y8BnUIH+vY+9N1/JMiSQveTmeadi6lDflGuio/ZapPuRh9s2V fE7A== 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=h5DJisHhT8k0ihW4WqUsCSqCe3c1KCzhHClep+Zgb0A=; b=SG73FODvOJBW5LaJVgUSBZLL1qEAv5xQlhPuKQ12uwVTAQYl03DNkpz0P1c2yGy40K /jc9NfK9KXXisybIhWABO5/NDMFKG0LGv1i8whZxTQea4uZsu2PYYk9LwEloVDSyNJgm yeVAMSTOzRym2edbhDuc92Noy9GbXukcPFRZeYp0Wom+Iwk2q6o/Uv6sK5sJ2+kl4vY5 OhhOU6DbUzQu//UsFAHfd8OTUd3o4n1Ve5V9I0xMklsVQ11a6rZ36nI3ADTacuHnGeOo 3XXalKp2Jqkye8ukgZ6UP+EkXKSyc2r3uv5H9H08ZsqkdokmEAzfyBvvAVK/PTdymO81 3FKQ== X-Gm-Message-State: ABUngveO+bwErMzx2B0DQNO1BpRA9WQnmLj3RvV70GQVAnmLWI96vw0XTvdSANYqmhOVTQKl X-Received: by 10.194.116.225 with SMTP id jz1mr4888466wjb.224.1478515443886; Mon, 07 Nov 2016 02:44:03 -0800 (PST) Received: from build.net (build.baylibre.com. [37.187.146.144]) by smtp.gmail.com with ESMTPSA id c133sm2058225wme.12.2016.11.07.02.44.03 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 07 Nov 2016 02:44:03 -0800 (PST) From: Neil Armstrong To: khilman@baylibre.com, carlo@caione.org Subject: [PATCH 2/3] ARM64: dts: meson-gxl-p23x: Enable ethernet Date: Mon, 7 Nov 2016 11:43:56 +0100 Message-Id: <20161107104357.24428-3-narmstrong@baylibre.com> X-Mailer: git-send-email 2.9.3 In-Reply-To: <20161107104357.24428-1-narmstrong@baylibre.com> References: <20161107104357.24428-1-narmstrong@baylibre.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20161107_054427_472734_F1273E22 X-CRM114-Status: UNSURE ( 8.49 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-amlogic@lists.infradead.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: linux-amlogic@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Neil Armstrong MIME-Version: 1.0 Sender: "linux-amlogic" Errors-To: linux-amlogic-bounces+patchwork-linux-amlogic=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP Enable Ethernet on the p23x board, pinctrl attribute is only added for the p230 board since the p231 only uses the Internal PHY. Signed-off-by: Neil Armstrong --- .../boot/dts/amlogic/meson-gxl-s905d-p230.dts | 25 ++++++++++++++++++++++ .../boot/dts/amlogic/meson-gxl-s905d-p231.dts | 6 ++++++ .../boot/dts/amlogic/meson-gxl-s905d-p23x.dtsi | 4 ++++ 3 files changed, 35 insertions(+) diff --git a/arch/arm64/boot/dts/amlogic/meson-gxl-s905d-p230.dts b/arch/arm64/boot/dts/amlogic/meson-gxl-s905d-p230.dts index 3dfaa37..4d082a7 100644 --- a/arch/arm64/boot/dts/amlogic/meson-gxl-s905d-p230.dts +++ b/arch/arm64/boot/dts/amlogic/meson-gxl-s905d-p230.dts @@ -49,3 +49,28 @@ compatible = "amlogic,p230", "amlogic,s905d", "amlogic,meson-gxl"; model = "Amlogic Meson GXL (S905D) P230 Development Board"; }; + +/* P230 has exclusive choice between internal or external PHY */ +ðmac { + pinctrl-0 = <ð_pins>; + pinctrl-names = "default"; + + /* Select external PHY by default */ + phy-handle = <&external_phy>; + + /* External PHY reset is shared with internal PHY Led signals */ + snps,reset-gpio = <&gpio GPIOZ_14 0>; + snps,reset-delays-us = <0 10000 1000000>; + snps,reset-active-low; + + /* External PHY is in RGMII */ + phy-mode = "rgmii"; +}; + +&external_mdio { + external_phy: ethernet-phy@0 { + compatible = "ethernet-phy-id001c.c916", "ethernet-phy-ieee802.3-c22"; + reg = <0>; + max-speed = <1000>; + }; +}; diff --git a/arch/arm64/boot/dts/amlogic/meson-gxl-s905d-p231.dts b/arch/arm64/boot/dts/amlogic/meson-gxl-s905d-p231.dts index ade8d29..1cc8d49 100644 --- a/arch/arm64/boot/dts/amlogic/meson-gxl-s905d-p231.dts +++ b/arch/arm64/boot/dts/amlogic/meson-gxl-s905d-p231.dts @@ -49,3 +49,9 @@ compatible = "amlogic,p231", "amlogic,s905d", "amlogic,meson-gxl"; model = "Amlogic Meson GXL (S905D) P231 Development Board"; }; + +/* P231 has only internal PHY port */ +ðmac { + phy-mode = "rmii"; + phy-handle = <&internal_phy>; +}; diff --git a/arch/arm64/boot/dts/amlogic/meson-gxl-s905d-p23x.dtsi b/arch/arm64/boot/dts/amlogic/meson-gxl-s905d-p23x.dtsi index bbe46a2..622ffbe 100644 --- a/arch/arm64/boot/dts/amlogic/meson-gxl-s905d-p23x.dtsi +++ b/arch/arm64/boot/dts/amlogic/meson-gxl-s905d-p23x.dtsi @@ -182,3 +182,7 @@ clocks = <&clkc CLKID_FCLK_DIV4>; clock-names = "clkin0"; }; + +ðmac { + status = "okay"; +};