diff options
Diffstat (limited to 'arch/arm/mach-omap2/hsmmc.c')
-rw-r--r-- | arch/arm/mach-omap2/hsmmc.c | 16 |
1 files changed, 10 insertions, 6 deletions
diff --git a/arch/arm/mach-omap2/hsmmc.c b/arch/arm/mach-omap2/hsmmc.c index 87bdb7bfd1bf..eb92b8107d2c 100644 --- a/arch/arm/mach-omap2/hsmmc.c +++ b/arch/arm/mach-omap2/hsmmc.c | |||
@@ -263,7 +263,7 @@ void __init omap2_hsmmc_init(struct omap2_hsmmc_info *controllers) | |||
263 | "mmc%islot%i", c->mmc, 1); | 263 | "mmc%islot%i", c->mmc, 1); |
264 | mmc->slots[0].name = hc->name; | 264 | mmc->slots[0].name = hc->name; |
265 | mmc->nr_slots = 1; | 265 | mmc->nr_slots = 1; |
266 | mmc->slots[0].wires = c->wires; | 266 | mmc->slots[0].caps = c->caps; |
267 | mmc->slots[0].internal_clock = !c->ext_clock; | 267 | mmc->slots[0].internal_clock = !c->ext_clock; |
268 | mmc->dma_mask = 0xffffffff; | 268 | mmc->dma_mask = 0xffffffff; |
269 | 269 | ||
@@ -321,16 +321,20 @@ void __init omap2_hsmmc_init(struct omap2_hsmmc_info *controllers) | |||
321 | } | 321 | } |
322 | 322 | ||
323 | /* Omap3630 HSMMC1 supports only 4-bit */ | 323 | /* Omap3630 HSMMC1 supports only 4-bit */ |
324 | if (cpu_is_omap3630() && c->wires > 4) { | 324 | if (cpu_is_omap3630() && |
325 | c->wires = 4; | 325 | (c->caps & MMC_CAP_8_BIT_DATA)) { |
326 | mmc->slots[0].wires = c->wires; | 326 | c->caps &= ~MMC_CAP_8_BIT_DATA; |
327 | c->caps |= MMC_CAP_4_BIT_DATA; | ||
328 | mmc->slots[0].caps = c->caps; | ||
327 | } | 329 | } |
328 | break; | 330 | break; |
329 | case 2: | 331 | case 2: |
330 | if (c->ext_clock) | 332 | if (c->ext_clock) |
331 | c->transceiver = 1; | 333 | c->transceiver = 1; |
332 | if (c->transceiver && c->wires > 4) | 334 | if (c->transceiver && (c->caps & MMC_CAP_8_BIT_DATA)) { |
333 | c->wires = 4; | 335 | c->caps &= ~MMC_CAP_8_BIT_DATA; |
336 | c->caps |= MMC_CAP_4_BIT_DATA; | ||
337 | } | ||
334 | /* FALLTHROUGH */ | 338 | /* FALLTHROUGH */ |
335 | case 3: | 339 | case 3: |
336 | if (mmc->slots[0].features & HSMMC_HAS_PBIAS) { | 340 | if (mmc->slots[0].features & HSMMC_HAS_PBIAS) { |