From patchwork Mon Nov 17 23:28:07 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnaud Ebalard X-Patchwork-Id: 5324491 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 26D9D9F2ED for ; Mon, 17 Nov 2014 23:31:33 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 322D9200F0 for ; Mon, 17 Nov 2014 23:31:32 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.9]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 36A99200ED for ; Mon, 17 Nov 2014 23:31:31 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1XqVj3-00056T-N6; Mon, 17 Nov 2014 23:28:53 +0000 Received: from 36.223.133.77.rev.sfr.net ([77.133.223.36] helo=smtp.natisbad.org) by bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1XqVhn-0003fS-Mt for linux-arm-kernel@lists.infradead.org; Mon, 17 Nov 2014 23:27:36 +0000 Received: by smtp.natisbad.org (Postfix, from userid 109) id 05D771700D55; Tue, 18 Nov 2014 00:26:52 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=natisbad.org; s=mail; t=1416266813; bh=dDeebe2YSF7xClT+d9Rgr9EV+HxlaA4jFBMMC6TkQ6c=; h=From:To:Cc:Subject:In-Reply-To:References:Date:From; b=yCoOiygRcUHz2rzdjMIHysfWkXfu9f24yhCdha0T2+3BVKrYVabLRXIxe8HzV4KvA eZo0euxb1tH2Nax6yjYCojVABrxW99KPRMCS8rjZgY6kiKzXdQZGSipghgBA0AzHDL 6iqIw5QtKF1Q0t92MN7gITRi3XGOxgddFYesRdw4= X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Spam-Level: X-Spam-Status: No, score=-2.5 required=5.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_LOW, T_DKIM_INVALID, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 Received: from small (localhost [IPv6:::1]) by smtp.natisbad.org (Postfix) with ESMTP id D1AA2170053E; Tue, 18 Nov 2014 00:24:45 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=natisbad.org; s=mail; t=1416266686; bh=dDeebe2YSF7xClT+d9Rgr9EV+HxlaA4jFBMMC6TkQ6c=; h=From:To:Cc:Subject:In-Reply-To:References:Date:From; b=nUyhDPo4b6tx5UMRnC8qGmXaIFjSe2xXwcfSvDyv9H7WgUMA5liZ+h7wCqm4LB91i BJoSOKTRwdAo2Gcyz/441Si/xQdjrmAxBSPPLcgVp44sJhjFnGTBJlVeIDq5iXC3hi uDT2Nr28wEb0W+bvIMuAllABbvPZCTLeE/kntIE0= X-Hashcash: 1:20:141117:jason@lakedaemon.net::XI/56ziAy48TVe0K:000000000000000000000000000000000000000003fFf X-Hashcash: 1:20:141117:andrew@lunn.ch::97YdjiSg02r+M9Sr:0002b2c X-Hashcash: 1:20:141117:gregory.clement@free-electrons.com::XgGKyHzuB7AZFT22:0000000000000000000000000006XFZ X-Hashcash: 1:20:141117:sebastian.hesselbarth@gmail.com::QSX3S4irZOGIHSUB:0000000000000000000000000000001EgS X-Hashcash: 1:20:141117:klightspeed@killerwolves.net::gUZzwIJmqkNQKQ36:00000000000000000000000000000000000WL X-Hashcash: 1:20:141117:linux@arm.linux.org.uk::McQXLFk3ov+o7LZ3:0000000000000000000000000000000000000004JvE X-Hashcash: 1:20:141117:linux-arm-kernel@lists.infradead.org::8mZLS/5HQlTAbetu:00000000000000000000000007jsg X-Hashcash: 1:20:141117:rob.herring@calxeda.com::euFAeGtkvRAEfEFd:0000000000000000000000000000000000000031dM X-Hashcash: 1:20:141117:pawel.moll@arm.com::UTs8a9aQElKmJSGt:00000000000000000000000000000000000000000009Mhq X-Hashcash: 1:20:141117:mark.rutland@arm.com::eUKeCNx44VlI1cgC:000000000000000000000000000000000000000001mNh X-Hashcash: 1:20:141117:swarren@wwwdotorg.org::BlyjCOeR/TJ/UkkO:00000000000000000000000000000000000000000zza X-Hashcash: 1:20:141117:ijc+devicetree@hellion.org.uk::Cpiht05cqom5cc78:000000000000000000000000000000001kkC X-Hashcash: 1:20:141117:devicetree@vger.kernel.org::5HMSFc3TRUlX4Wgr:0000000000000000000000000000000000032C6 From: Arnaud Ebalard To: Jason Cooper , Andrew Lunn , Gregory Clement , Sebastian Hesselbarth , Ben Peddell Subject: [PATCHv3 09/12] arm: mvebu: define and use ge0/1 rgmii pinctrl settings for armada XP In-Reply-To: References: Message-Id: <9cb4b81e1d0f160af4c7db8ec35870ba6dcaa985.1416266432.git.arno@natisbad.org> Date: Tue, 18 Nov 2014 00:28:07 +0100 User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux) MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20141117_152736_078784_1ADBE904 X-CRM114-Status: GOOD ( 10.95 ) X-Spam-Score: 0.3 (/) Cc: Mark Rutland , devicetree@vger.kernel.org, Russell King , Pawel Moll , Stephen Warren , Ian Campbell , Rob Herring , linux-arm-kernel@lists.infradead.org X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , 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 Armada XP AXWiFiAP has local definitions for ge0/1 rgmii pinctrl settings which can be be used by other boards. This patch moves those definitions to armada-xp.dtsi file and then reference those pinctrl entries in all current .dts files using ge0/1 interface in rgmii-id mode for their PHY. Signed-off-by: Arnaud Ebalard --- arch/arm/boot/dts/armada-xp-axpwifiap.dts | 18 ++---------------- arch/arm/boot/dts/armada-xp-db.dts | 4 ++++ arch/arm/boot/dts/armada-xp-lenovo-ix4-300d.dts | 4 ++++ arch/arm/boot/dts/armada-xp-netgear-rn2120.dts | 4 ++++ arch/arm/boot/dts/armada-xp.dtsi | 14 ++++++++++++++ 5 files changed, 28 insertions(+), 16 deletions(-) diff --git a/arch/arm/boot/dts/armada-xp-axpwifiap.dts b/arch/arm/boot/dts/armada-xp-axpwifiap.dts index a55a97a70505..7a6e50632a1f 100644 --- a/arch/arm/boot/dts/armada-xp-axpwifiap.dts +++ b/arch/arm/boot/dts/armada-xp-axpwifiap.dts @@ -64,20 +64,6 @@ pinctrl-0 = <&pmx_phy_int>; pinctrl-names = "default"; - pmx_ge0: pmx-ge0 { - marvell,pins = "mpp0", "mpp1", "mpp2", "mpp3", - "mpp4", "mpp5", "mpp6", "mpp7", - "mpp8", "mpp9", "mpp10", "mpp11"; - marvell,function = "ge0"; - }; - - pmx_ge1: pmx-ge1 { - marvell,pins = "mpp12", "mpp13", "mpp14", "mpp15", - "mpp16", "mpp17", "mpp18", "mpp19", - "mpp20", "mpp21", "mpp22", "mpp23"; - marvell,function = "ge1"; - }; - pmx_keys: pmx-keys { marvell,pins = "mpp33"; marvell,function = "gpio"; @@ -118,14 +104,14 @@ }; ethernet@70000 { - pinctrl-0 = <&pmx_ge0>; + pinctrl-0 = <&ge0_rgmii_pins>; pinctrl-names = "default"; status = "okay"; phy = <&phy0>; phy-mode = "rgmii-id"; }; ethernet@74000 { - pinctrl-0 = <&pmx_ge1>; + pinctrl-0 = <&ge1_rgmii_pins>; pinctrl-names = "default"; status = "okay"; phy = <&phy1>; diff --git a/arch/arm/boot/dts/armada-xp-db.dts b/arch/arm/boot/dts/armada-xp-db.dts index 42ddb2864365..bc28691161f4 100644 --- a/arch/arm/boot/dts/armada-xp-db.dts +++ b/arch/arm/boot/dts/armada-xp-db.dts @@ -142,11 +142,15 @@ }; ethernet@70000 { + pinctrl-0 = <&ge0_rgmii_pins>; + pinctrl-names = "default"; status = "okay"; phy = <&phy0>; phy-mode = "rgmii-id"; }; ethernet@74000 { + pinctrl-0 = <&ge1_rgmii_pins>; + pinctrl-names = "default"; status = "okay"; phy = <&phy1>; phy-mode = "rgmii-id"; diff --git a/arch/arm/boot/dts/armada-xp-lenovo-ix4-300d.dts b/arch/arm/boot/dts/armada-xp-lenovo-ix4-300d.dts index cccf54784c4c..8560047ce426 100644 --- a/arch/arm/boot/dts/armada-xp-lenovo-ix4-300d.dts +++ b/arch/arm/boot/dts/armada-xp-lenovo-ix4-300d.dts @@ -97,12 +97,16 @@ }; ethernet@70000 { + pinctrl-0 = <&ge0_rgmii_pins>; + pinctrl-names = "default"; status = "okay"; phy = <&phy0>; phy-mode = "rgmii-id"; }; ethernet@74000 { + pinctrl-0 = <&ge1_rgmii_pins>; + pinctrl-names = "default"; status = "okay"; phy = <&phy1>; phy-mode = "rgmii-id"; diff --git a/arch/arm/boot/dts/armada-xp-netgear-rn2120.dts b/arch/arm/boot/dts/armada-xp-netgear-rn2120.dts index 7d8f32873e82..d61caf829b8b 100644 --- a/arch/arm/boot/dts/armada-xp-netgear-rn2120.dts +++ b/arch/arm/boot/dts/armada-xp-netgear-rn2120.dts @@ -152,12 +152,16 @@ }; ethernet@70000 { + pinctrl-0 = <&ge0_rgmii_pins>; + pinctrl-names = "default"; status = "okay"; phy = <&phy0>; phy-mode = "rgmii-id"; }; ethernet@74000 { + pinctrl-0 = <&ge1_rgmii_pins>; + pinctrl-names = "default"; status = "okay"; phy = <&phy1>; phy-mode = "rgmii-id"; diff --git a/arch/arm/boot/dts/armada-xp.dtsi b/arch/arm/boot/dts/armada-xp.dtsi index c7449f652fb5..4f685f7ec273 100644 --- a/arch/arm/boot/dts/armada-xp.dtsi +++ b/arch/arm/boot/dts/armada-xp.dtsi @@ -58,6 +58,20 @@ marvell,pins = "mpp44", "mpp45"; marvell,function = "uart3"; }; + + ge0_rgmii_pins: ge0-rgmii-pins { + marvell,pins = "mpp0", "mpp1", "mpp2", "mpp3", + "mpp4", "mpp5", "mpp6", "mpp7", + "mpp8", "mpp9", "mpp10", "mpp11"; + marvell,function = "ge0"; + }; + + ge1_rgmii_pins: ge1-rgmii-pins { + marvell,pins = "mpp12", "mpp13", "mpp14", "mpp15", + "mpp16", "mpp17", "mpp18", "mpp19", + "mpp20", "mpp21", "mpp22", "mpp23"; + marvell,function = "ge1"; + }; }; i2c0: i2c@11000 {