From patchwork Sun Nov 18 10:44:57 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andrew Lunn X-Patchwork-Id: 1760561 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork1.kernel.org Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) by patchwork1.kernel.org (Postfix) with ESMTP id CDCFA3FCDE for ; Sun, 18 Nov 2012 10:47:46 +0000 (UTC) Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.76 #1 (Red Hat Linux)) id 1Ta2O8-0003EK-9r; Sun, 18 Nov 2012 10:46:08 +0000 Received: from londo.lunn.ch ([80.238.139.98]) by merlin.infradead.org with esmtp (Exim 4.76 #1 (Red Hat Linux)) id 1Ta2Nt-0003Bf-4j for linux-arm-kernel@lists.infradead.org; Sun, 18 Nov 2012 10:46:00 +0000 Received: from lunn by londo.lunn.ch with local (Exim 3.36 #1 (Debian)) id 1Ta2N4-0005tj-00; Sun, 18 Nov 2012 11:45:02 +0100 From: Andrew Lunn To: Jason Cooper Subject: [PATCH v2 2/2] ARM: Kirkwood: Convert XOR instantiation to DT. Date: Sun, 18 Nov 2012 11:44:57 +0100 Message-Id: <1353235498-22638-2-git-send-email-andrew@lunn.ch> X-Mailer: git-send-email 1.7.10.4 In-Reply-To: <1353235498-22638-1-git-send-email-andrew@lunn.ch> References: <1353235498-22638-1-git-send-email-andrew@lunn.ch> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20121118_054559_863196_59B4B6AE X-CRM114-Status: GOOD ( 11.27 ) X-Spam-Score: -2.6 (--) X-Spam-Report: SpamAssassin version 3.3.2 on merlin.infradead.org summary: Content analysis details: (-2.6 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 SPF_HELO_PASS SPF: HELO matches SPF record -0.0 SPF_PASS SPF: sender matches SPF record -0.7 RP_MATCHES_RCVD Envelope sender domain matches handover relay domain -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] Cc: Thomas Petazzoni , Lior Amsalem , Andrew Lunn , vinod.koul@intel.com, djbw@fb.com, linux ARM X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: linux-arm-kernel-bounces@lists.infradead.org Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org Use DT to describe the two XOR DMA engines on Kirkwood. Remove the C code initialization. Signed-off-by: Andrew Lunn --- These patches depend on the refactoring/DT patches from Thomas and NOT the clock patches from me. With the clock patches, a slight different patch is needed, specifying a clocks property in DT and no auxdata. arch/arm/boot/dts/kirkwood.dtsi | 38 +++++++++++++++++++++++++++++++++++++ arch/arm/mach-kirkwood/board-dt.c | 6 ++---- 2 files changed, 40 insertions(+), 4 deletions(-) diff --git a/arch/arm/boot/dts/kirkwood.dtsi b/arch/arm/boot/dts/kirkwood.dtsi index 4e5b815..e0ba79d 100644 --- a/arch/arm/boot/dts/kirkwood.dtsi +++ b/arch/arm/boot/dts/kirkwood.dtsi @@ -77,6 +77,44 @@ status = "okay"; }; + xor@60800 { + compatible = "marvell,orion-xor"; + reg = <0x60800 0x100 + 0x60A00 0x100>; + status = "okay"; + + xor00 { + interrupts = <5>; + dmacap,memcpy; + dmacap,xor; + }; + xor01 { + interrupts = <6>; + dmacap,memcpy; + dmacap,xor; + dmacap,memset; + }; + }; + + xor@60900 { + compatible = "marvell,orion-xor"; + reg = <0x60900 0x100 + 0xd0B00 0x100>; + status = "okay"; + + xor00 { + interrupts = <7>; + dmacap,memcpy; + dmacap,xor; + }; + xor01 { + interrupts = <8>; + dmacap,memcpy; + dmacap,xor; + dmacap,memset; + }; + }; + sata@80000 { compatible = "marvell,orion-sata"; reg = <0x80000 0x5000>; diff --git a/arch/arm/mach-kirkwood/board-dt.c b/arch/arm/mach-kirkwood/board-dt.c index d94872f..e62f10de 100644 --- a/arch/arm/mach-kirkwood/board-dt.c +++ b/arch/arm/mach-kirkwood/board-dt.c @@ -34,6 +34,8 @@ struct of_dev_auxdata kirkwood_auxdata_lookup[] __initdata = { OF_DEV_AUXDATA("marvell,orion-sata", 0xf1080000, "sata_mv.0", NULL), OF_DEV_AUXDATA("marvell,orion-nand", 0xf4000000, "orion_nand", NULL), OF_DEV_AUXDATA("marvell,orion-crypto", 0xf1030000, "mv_crypto", NULL), + OF_DEV_AUXDATA("marvell,orion-xor", 0xf1060800, "mv_xor.0", NULL), + OF_DEV_AUXDATA("marvell,orion-xor", 0xf1060900, "mv_xor.1", NULL), {}, }; @@ -56,10 +58,6 @@ static void __init kirkwood_dt_init(void) /* Setup root of clk tree */ kirkwood_clk_init(); - /* internal devices that every board has */ - kirkwood_xor0_init(); - kirkwood_xor1_init(); - #ifdef CONFIG_KEXEC kexec_reinit = kirkwood_enable_pcie; #endif