From patchwork Mon Aug 16 20:06:46 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Juha.Kuikka@elektrobit.com X-Patchwork-Id: 119783 Received: from comal.ext.ti.com (comal.ext.ti.com [198.47.26.152]) by demeter.kernel.org (8.14.4/8.14.3) with ESMTP id o7GKAw4t020493 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Mon, 16 Aug 2010 20:11:34 GMT Received: from dlep36.itg.ti.com ([157.170.170.91]) by comal.ext.ti.com (8.13.7/8.13.7) with ESMTP id o7GK7kqY013082 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Mon, 16 Aug 2010 15:07:46 -0500 Received: from linux.omap.com (localhost [127.0.0.1]) by dlep36.itg.ti.com (8.13.8/8.13.8) with ESMTP id o7GK7kX3012844; Mon, 16 Aug 2010 15:07:46 -0500 (CDT) Received: from linux.omap.com (localhost [127.0.0.1]) by linux.omap.com (Postfix) with ESMTP id 6B2B280686; Mon, 16 Aug 2010 15:07:32 -0500 (CDT) X-Original-To: davinci-linux-open-source@linux.davincidsp.com Delivered-To: davinci-linux-open-source@linux.davincidsp.com Received: from dflp52.itg.ti.com (dflp52.itg.ti.com [128.247.22.96]) by linux.omap.com (Postfix) with ESMTP id 62F5680643 for ; Mon, 16 Aug 2010 15:06:49 -0500 (CDT) Received: from neches.ext.ti.com (localhost [127.0.0.1]) by dflp52.itg.ti.com (8.13.7/8.13.7) with ESMTP id o7GK6n8B009685 for ; Mon, 16 Aug 2010 15:06:49 -0500 (CDT) Received: from psmtp.com (na3sys009amx202.postini.com [74.125.149.42]) by neches.ext.ti.com (8.13.7/8.13.7) with SMTP id o7GK6lIZ000539 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Mon, 16 Aug 2010 15:06:48 -0500 Received: from source ([207.170.229.71]) (using TLSv1) by na3sys009amx202.postini.com ([74.125.148.10]) with SMTP; Mon, 16 Aug 2010 20:06:48 GMT Received: from usrdes03.ebgroup.elektrobit.com (usrdes03.ebgroup.elektrobit.com [172.18.145.10]) by smtpgw1us.elektrobit.com (8.13.8/8.13.8) with ESMTP id o7GK6ldS013900 for ; Mon, 16 Aug 2010 13:06:47 -0700 MIME-Version: 1.0 X-MimeOLE: Produced By Microsoft Exchange V6.5 Content-class: urn:content-classes:message Subject: [PATCH 4/4] DA8xx: Add MMCSD1 resources, platform device and convenience registration function Date: Mon, 16 Aug 2010 13:06:46 -0700 Message-ID: X-MS-Has-Attach: X-MS-TNEF-Correlator: Thread-Topic: [PATCH 4/4] DA8xx: Add MMCSD1 resources, platform device and convenience registration function Thread-Index: Acs9fo3sAu9fYyJLSIm7Al6oyQTcAQ== From: To: X-Greylist: Sender succeeded STARTTLS authentication, not delayed by milter-greylist-4.2.3 (demeter.kernel.org [140.211.167.41]); Mon, 16 Aug 2010 20:11:34 +0000 (UTC) X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.2.3 (smtpgw1us.elektrobit.com [10.127.1.11]); Mon, 16 Aug 2010 13:06:47 -0700 (PDT) X-Virus-Scanned: at elektrobit.com Content-Disposition: inline X-Scanned-By: MIMEDefang 2.67 on 10.127.1.11 X-pstn-levels: (S:87.40084/99.90000 CV:99.9000 FC:95.5390 LC:95.5390 R:95.9108 P:95.9108 M:97.0282 C:98.6951 ) X-pstn-settings: 2 (0.5000:0.5000) s cv gt3 gt2 gt1 r p m c X-pstn-addresses: from [db-null] X-BeenThere: davinci-linux-open-source@linux.davincidsp.com X-Mailman-Version: 2.1.12 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: davinci-linux-open-source-bounces@linux.davincidsp.com Errors-To: davinci-linux-open-source-bounces@linux.davincidsp.com diff --git a/arch/arm/mach-davinci/devices-da8xx.c b/arch/arm/mach-davinci/devices-da8xx.c old mode 100644 new mode 100755 index 52bc7b1..9e1a8be --- a/arch/arm/mach-davinci/devices-da8xx.c +++ b/arch/arm/mach-davinci/devices-da8xx.c @@ -566,6 +566,42 @@ int __init da8xx_register_mmcsd0(struct davinci_mmc_config *config) return platform_device_register(&da8xx_mmcsd0_device); } +static struct resource da8xx_mmcsd1_resources[] = { + { /* registers */ + .start = DA8XX_MMCSD1_BASE, + .end = DA8XX_MMCSD1_BASE + SZ_4K - 1, + .flags = IORESOURCE_MEM, + }, + { /* interrupt */ + .start = IRQ_DA850_MMCSDINT0_1, + .end = IRQ_DA850_MMCSDINT0_1, + .flags = IORESOURCE_IRQ, + }, + { /* DMA RX */ + .start = EDMA_CTLR_CHAN(1, 28), + .end = EDMA_CTLR_CHAN(1, 28), + .flags = IORESOURCE_DMA, + }, + { /* DMA TX */ + .start = EDMA_CTLR_CHAN(1, 29), + .end = EDMA_CTLR_CHAN(1, 29), + .flags = IORESOURCE_DMA, + }, +}; + +static struct platform_device da8xx_mmcsd1_device = { + .name = "davinci_mmc", + .id = 1, + .num_resources = ARRAY_SIZE(da8xx_mmcsd1_resources), + .resource = da8xx_mmcsd1_resources, +}; + +int __init da8xx_register_mmcsd1(struct davinci_mmc_config *config) +{ + da8xx_mmcsd1_device.dev.platform_data = config; + return platform_device_register(&da8xx_mmcsd1_device); +} + static struct resource da8xx_rtc_resources[] = { {