From patchwork Thu Jun 6 15:48:23 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Guennadi Liakhovetski X-Patchwork-Id: 2681741 Return-Path: X-Original-To: patchwork-linux-sh@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork2.kernel.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by patchwork2.kernel.org (Postfix) with ESMTP id AB158DF23A for ; Thu, 6 Jun 2013 15:48:33 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752819Ab3FFPsd (ORCPT ); Thu, 6 Jun 2013 11:48:33 -0400 Received: from moutng.kundenserver.de ([212.227.126.171]:54700 "EHLO moutng.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752843Ab3FFPsa (ORCPT ); Thu, 6 Jun 2013 11:48:30 -0400 Received: from axis700.grange (dslb-088-077-167-013.pools.arcor-ip.net [88.77.167.13]) by mrelayeu.kundenserver.de (node=mrbap1) with ESMTP (Nemesis) id 0MFR0G-1UYUxB2idY-00EZUI; Thu, 06 Jun 2013 17:48:25 +0200 Received: from 6a.grange (6a.grange [192.168.1.11]) by axis700.grange (Postfix) with ESMTPS id CEBB040BB8; Thu, 6 Jun 2013 17:48:24 +0200 (CEST) Received: from lyakh by 6a.grange with local (Exim 4.72) (envelope-from ) id 1UkcQK-0006BU-Nc; Thu, 06 Jun 2013 17:48:24 +0200 From: Guennadi Liakhovetski To: linux-sh@vger.kernel.org Cc: Magnus Damm , Simon Horman , Guennadi Liakhovetski Subject: [PATCH v2 5/6] ARM: shmobile: r8a7740: add DT nodes for three DMAC instance Date: Thu, 6 Jun 2013 17:48:23 +0200 Message-Id: <1370533704-23734-6-git-send-email-g.liakhovetski@gmx.de> X-Mailer: git-send-email 1.7.2.5 In-Reply-To: <1370533704-23734-1-git-send-email-g.liakhovetski@gmx.de> References: <1370533704-23734-1-git-send-email-g.liakhovetski@gmx.de> X-Provags-ID: V02:K0:CAr7X9AmzHFAINf+j/AgpC9lVEjJyuanLFnQ7csX3cb 9dYDRYEOLF7uNDaJ3+36AjJT3c5mDQ100gk3n3PtCUJpp/M6hc TKu/7NGdTqcZCIP4PkwcCBEXBEiKplVsJfW9oowdBGdt/k+OX4 bNf0QcABgFpk9bnXqtVyxUX39w3wNPqnMKQUoWPXGNDoe8z6E0 kuYwcW1QRm3MyTnJsrEuDWZ1N/oGLRtEOHgtU2gJLcSFQoAgoW NaXq0+m2xKsjn45VjZMy0CmACD4Ku6St/+Ky908mIwZ72MipNE q1tFXp2PbAUKrHnPgpfdc7xQSVtrPBID/6WeJSjtrZCqHo5qBP KjtvPrnuZI5hrn4Wn0zqmoPnJF8pOsb2r/9zuSQmCu1DmxHCDF 8UWbXLxlBIoUA== Sender: linux-sh-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-sh@vger.kernel.org This patch adds Device Tree support for the three DMA controller instances on r8a7740 in a DMA multiplexer node. Signed-off-by: Guennadi Liakhovetski --- arch/arm/boot/dts/r8a7740.dtsi | 67 ++++++++++++++++++++++++++++++++ arch/arm/mach-shmobile/setup-r8a7740.c | 6 +++ 2 files changed, 73 insertions(+), 0 deletions(-) diff --git a/arch/arm/boot/dts/r8a7740.dtsi b/arch/arm/boot/dts/r8a7740.dtsi index e9a90d8..848eb02 100644 --- a/arch/arm/boot/dts/r8a7740.dtsi +++ b/arch/arm/boot/dts/r8a7740.dtsi @@ -112,6 +112,73 @@ 0 149 0x4>; }; + dmac: dma-mux0 { + compatible = "simple-bus", "dma-mux"; + #address-cells = <1>; + #size-cells = <1>; + ranges; + + dma0: shdma@fe008020 { + compatible = "renesas,shdma"; + reg = <0xfe008020 0x270>, + <0xfe009000 0xc>; + interrupt-parent = <&gic>; + interrupts = <0 34 4 + 0 28 4 + 0 29 4 + 0 30 4 + 0 31 4 + 0 32 4 + 0 33 4>; + interrupt-names = "error", + "ch0", "ch1", "ch2", "ch3", + "ch4", "ch5"; + #dma-cells = <1>; + dma-channels = <6>; + dma-requests = <256>; + }; + + dma1: shdma@fe018020 { + compatible = "renesas,shdma"; + reg = <0xfe018020 0x270>, + <0xfe019000 0xc>; + interrupt-parent = <&gic>; + interrupts = <0 41 4 + 0 35 4 + 0 36 4 + 0 37 4 + 0 38 4 + 0 39 4 + 0 40 4>; + interrupt-names = "error", + "ch0", "ch1", "ch2", "ch3", + "ch4", "ch5"; + #dma-cells = <1>; + dma-channels = <6>; + dma-requests = <256>; + }; + + dma2: shdma@fe028020 { + compatible = "renesas,shdma"; + reg = <0xfe028020 0x270>, + <0xfe029000 0xc>; + interrupt-parent = <&gic>; + interrupts = <0 48 4 + 0 42 4 + 0 43 4 + 0 44 4 + 0 45 4 + 0 46 4 + 0 47 4>; + interrupt-names = "error", + "ch0", "ch1", "ch2", "ch3", + "ch4", "ch5"; + #dma-cells = <1>; + dma-channels = <6>; + dma-requests = <256>; + }; + }; + i2c0: i2c@fff20000 { #address-cells = <1>; #size-cells = <0>; diff --git a/arch/arm/mach-shmobile/setup-r8a7740.c b/arch/arm/mach-shmobile/setup-r8a7740.c index 6b3ed42..dbe12db 100644 --- a/arch/arm/mach-shmobile/setup-r8a7740.c +++ b/arch/arm/mach-shmobile/setup-r8a7740.c @@ -997,6 +997,12 @@ void __init r8a7740_add_early_devices(void) #ifdef CONFIG_USE_OF static const struct of_dev_auxdata r8a7740_auxdata_lookup[] __initconst = { + OF_DEV_AUXDATA("renesas,shdma", 0xfe008020, "sh-dma-engine.0", + &dma_platform_data), + OF_DEV_AUXDATA("renesas,shdma", 0xfe018020, "sh-dma-engine.1", + &dma_platform_data), + OF_DEV_AUXDATA("renesas,shdma", 0xfe028020, "sh-dma-engine.2", + &dma_platform_data), { } };