From patchwork Fri Oct 30 06:22:03 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Magnus Damm X-Patchwork-Id: 56571 Received: from vger.kernel.org (vger.kernel.org [209.132.176.167]) by demeter.kernel.org (8.14.2/8.14.2) with ESMTP id n9U6R5Gf017546 for ; Fri, 30 Oct 2009 06:27:05 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755065AbZJ3G05 (ORCPT ); Fri, 30 Oct 2009 02:26:57 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1755928AbZJ3G05 (ORCPT ); Fri, 30 Oct 2009 02:26:57 -0400 Received: from mail-yw0-f202.google.com ([209.85.211.202]:50049 "EHLO mail-yw0-f202.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755065AbZJ3G05 (ORCPT ); Fri, 30 Oct 2009 02:26:57 -0400 Received: by ywh40 with SMTP id 40so2428517ywh.33 for ; Thu, 29 Oct 2009 23:27:02 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:from:to:cc:date:message-id :subject; bh=0e7jyCSfPNrPgxK4ltlUPQEkR/uZqxOYc9hZ1LyGQkk=; b=Chg8zeIDJzmdBI/CbksPo8PTHJxijCg8MjcgEYwDeToJC9ZeHfZn4ADtgGLoHu6Zne eXBmMcTZ/6zgOY5oyTZir3pYITWsBXIYr8j5NTf8KElljna8izp+p+xLY8xR3lpQliIF E7YJiUuplGcZhrbz6I+KjiYW8oMWPKA+7u0AM= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=from:to:cc:date:message-id:subject; b=oTkYlbnLiyaJkuZuxcluwiLt05+tmwHbPv8zj+p8rJ5IyiYl7t+If1XNxCWyRYVpSF Z52hyiUmqntmMbT151sjLm23KayU1cdm/6BCcabpJEKYoS5jeGgCfLd/oscZuuOAhQuw zbiDKnyxNvLY+AtpjODK+Q8cR4fkPv0sqjWxc= Received: by 10.91.183.4 with SMTP id k4mr3326807agp.41.1256884021891; Thu, 29 Oct 2009 23:27:01 -0700 (PDT) Received: from rxone.opensource.se (49.14.32.202.bf.2iij.net [202.32.14.49]) by mx.google.com with ESMTPS id 36sm1239180yxh.67.2009.10.29.23.27.00 (version=TLSv1/SSLv3 cipher=RC4-MD5); Thu, 29 Oct 2009 23:27:01 -0700 (PDT) From: Magnus Damm To: linux-sh@vger.kernel.org Cc: Magnus Damm , lethal@linux-sh.org Date: Fri, 30 Oct 2009 15:22:03 +0900 Message-Id: <20091030062203.24074.90609.sendpatchset@rxone.opensource.se> Subject: [PATCH] sh: Add SDHI1 support to the AP325RXA board Sender: linux-sh-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-sh@vger.kernel.org --- 0003/arch/sh/boards/mach-ap325rxa/setup.c +++ work/arch/sh/boards/mach-ap325rxa/setup.c 2009-10-30 14:48:58.000000000 +0900 @@ -423,6 +423,7 @@ static struct resource sdhi0_cn3_resourc static struct platform_device sdhi0_cn3_device = { .name = "sh_mobile_sdhi", + .id = 0, /* "sdhi0" clock */ .num_resources = ARRAY_SIZE(sdhi0_cn3_resources), .resource = sdhi0_cn3_resources, .archdata = { @@ -430,6 +431,29 @@ static struct platform_device sdhi0_cn3_ }, }; +static struct resource sdhi1_cn7_resources[] = { + [0] = { + .name = "SDHI1", + .start = 0x04cf0000, + .end = 0x04cf01ff, + .flags = IORESOURCE_MEM, + }, + [1] = { + .start = 24, + .flags = IORESOURCE_IRQ, + }, +}; + +static struct platform_device sdhi1_cn7_device = { + .name = "sh_mobile_sdhi", + .id = 1, /* "sdhi1" clock */ + .num_resources = ARRAY_SIZE(sdhi1_cn7_resources), + .resource = sdhi1_cn7_resources, + .archdata = { + .hwblk_id = HWBLK_SDHI1, + }, +}; + static struct i2c_board_info __initdata ap325rxa_i2c_devices[] = { { I2C_BOARD_INFO("pcf8563", 0x51), @@ -478,6 +502,7 @@ static struct platform_device *ap325rxa_ &ceu_device, &nand_flash_device, &sdhi0_cn3_device, + &sdhi1_cn7_device, &ap325rxa_camera[0], &ap325rxa_camera[1], }; @@ -588,7 +613,7 @@ static int __init ap325rxa_devices_setup platform_resource_setup_memory(&ceu_device, "ceu", 4 << 20); - /* SDHI0 */ + /* SDHI0 - CN3 - SD CARD */ gpio_request(GPIO_FN_SDHI0CD_PTD, NULL); gpio_request(GPIO_FN_SDHI0WP_PTD, NULL); gpio_request(GPIO_FN_SDHI0D3_PTD, NULL); @@ -598,6 +623,15 @@ static int __init ap325rxa_devices_setup gpio_request(GPIO_FN_SDHI0CMD_PTD, NULL); gpio_request(GPIO_FN_SDHI0CLK_PTD, NULL); + /* SDHI1 - CN7 - MICRO SD CARD */ + gpio_request(GPIO_FN_SDHI1CD, NULL); + gpio_request(GPIO_FN_SDHI1D3, NULL); + gpio_request(GPIO_FN_SDHI1D2, NULL); + gpio_request(GPIO_FN_SDHI1D1, NULL); + gpio_request(GPIO_FN_SDHI1D0, NULL); + gpio_request(GPIO_FN_SDHI1CMD, NULL); + gpio_request(GPIO_FN_SDHI1CLK, NULL); + i2c_register_board_info(0, ap325rxa_i2c_devices, ARRAY_SIZE(ap325rxa_i2c_devices));