aboutsummaryrefslogtreecommitdiffstats
path: root/arch
diff options
context:
space:
mode:
authorGrazvydas Ignotas <notasas@gmail.com>2010-08-10 21:01:52 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2010-08-11 11:59:04 -0400
commited199f7e7346ba508f803180ecc6830e92558a1e (patch)
tree5ae8161fff1b173b932a0f69a995650518c9f9f9 /arch
parent4816858cce279b5e8d1eab0b4832d89d8f2ca58c (diff)
omap: pandora: pass wl1251 information to SDIO core
Pandora has TI WL1251 attached on MMC3, which is non-standard SDIO chip. Make use MMC_QUIRK_NONSTD_SDIO to tell SDIO core about it. Signed-off-by: Grazvydas Ignotas <notasas@gmail.com> Cc: Adrian Hunter <adrian.hunter@nokia.com> Cc: Tony Lindgren <tony@atomide.com> Cc: Bob Copeland <me@bobcopeland.com> Cc: Kalle Valo <kvalo@adurom.com> Cc: Madhusudhan Chikkature <madhu.cr@ti.com> Cc: Kishore Kadiyala <kishore.kadiyala@ti.com> Cc: Russell King <linux@arm.linux.org.uk> Cc: <linux-mmc@vger.kernel.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'arch')
-rw-r--r--arch/arm/mach-omap2/board-omap3pandora.c16
-rw-r--r--arch/arm/mach-omap2/hsmmc.c1
-rw-r--r--arch/arm/mach-omap2/hsmmc.h4
3 files changed, 21 insertions, 0 deletions
diff --git a/arch/arm/mach-omap2/board-omap3pandora.c b/arch/arm/mach-omap2/board-omap3pandora.c
index 55836fa3506..dd3af2be13b 100644
--- a/arch/arm/mach-omap2/board-omap3pandora.c
+++ b/arch/arm/mach-omap2/board-omap3pandora.c
@@ -32,6 +32,7 @@
32#include <linux/input.h> 32#include <linux/input.h>
33#include <linux/input/matrix_keypad.h> 33#include <linux/input/matrix_keypad.h>
34#include <linux/gpio_keys.h> 34#include <linux/gpio_keys.h>
35#include <linux/mmc/card.h>
35 36
36#include <asm/mach-types.h> 37#include <asm/mach-types.h>
37#include <asm/mach/arch.h> 38#include <asm/mach/arch.h>
@@ -258,6 +259,20 @@ static struct platform_device pandora_dss_device = {
258 }, 259 },
259}; 260};
260 261
262static void pandora_wl1251_init_card(struct mmc_card *card)
263{
264 /*
265 * We have TI wl1251 attached to MMC3. Pass this information to
266 * SDIO core because it can't be probed by normal methods.
267 */
268 card->quirks |= MMC_QUIRK_NONSTD_SDIO;
269 card->cccr.wide_bus = 1;
270 card->cis.vendor = 0x104c;
271 card->cis.device = 0x9066;
272 card->cis.blksize = 512;
273 card->cis.max_dtr = 20000000;
274}
275
261static struct omap2_hsmmc_info omap3pandora_mmc[] = { 276static struct omap2_hsmmc_info omap3pandora_mmc[] = {
262 { 277 {
263 .mmc = 1, 278 .mmc = 1,
@@ -279,6 +294,7 @@ static struct omap2_hsmmc_info omap3pandora_mmc[] = {
279 .wires = 4, 294 .wires = 4,
280 .gpio_cd = -EINVAL, 295 .gpio_cd = -EINVAL,
281 .gpio_wp = -EINVAL, 296 .gpio_wp = -EINVAL,
297 .init_card = pandora_wl1251_init_card,
282 }, 298 },
283 {} /* Terminator */ 299 {} /* Terminator */
284}; 300};
diff --git a/arch/arm/mach-omap2/hsmmc.c b/arch/arm/mach-omap2/hsmmc.c
index 1ef54b03610..c8f647b6205 100644
--- a/arch/arm/mach-omap2/hsmmc.c
+++ b/arch/arm/mach-omap2/hsmmc.c
@@ -268,6 +268,7 @@ void __init omap2_hsmmc_init(struct omap2_hsmmc_info *controllers)
268 mmc->slots[0].gpio_wp = c->gpio_wp; 268 mmc->slots[0].gpio_wp = c->gpio_wp;
269 269
270 mmc->slots[0].remux = c->remux; 270 mmc->slots[0].remux = c->remux;
271 mmc->slots[0].init_card = c->init_card;
271 272
272 if (c->cover_only) 273 if (c->cover_only)
273 mmc->slots[0].cover = 1; 274 mmc->slots[0].cover = 1;
diff --git a/arch/arm/mach-omap2/hsmmc.h b/arch/arm/mach-omap2/hsmmc.h
index 36f0ba8d89e..1fe6f018717 100644
--- a/arch/arm/mach-omap2/hsmmc.h
+++ b/arch/arm/mach-omap2/hsmmc.h
@@ -6,6 +6,8 @@
6 * published by the Free Software Foundation. 6 * published by the Free Software Foundation.
7 */ 7 */
8 8
9struct mmc_card;
10
9struct omap2_hsmmc_info { 11struct omap2_hsmmc_info {
10 u8 mmc; /* controller 1/2/3 */ 12 u8 mmc; /* controller 1/2/3 */
11 u8 wires; /* 1/4/8 wires */ 13 u8 wires; /* 1/4/8 wires */
@@ -23,6 +25,8 @@ struct omap2_hsmmc_info {
23 int ocr_mask; /* temporary HACK */ 25 int ocr_mask; /* temporary HACK */
24 /* Remux (pad configuation) when powering on/off */ 26 /* Remux (pad configuation) when powering on/off */
25 void (*remux)(struct device *dev, int slot, int power_on); 27 void (*remux)(struct device *dev, int slot, int power_on);
28 /* init some special card */
29 void (*init_card)(struct mmc_card *card);
26}; 30};
27 31
28#if defined(CONFIG_MMC_OMAP_HS) || defined(CONFIG_MMC_OMAP_HS_MODULE) 32#if defined(CONFIG_MMC_OMAP_HS) || defined(CONFIG_MMC_OMAP_HS_MODULE)