summaryrefslogtreecommitdiff
path: root/arch/arm/mach-bcm2708
diff options
context:
space:
mode:
authorgellert <gellert@raspberrypi.org>2014-08-15 16:35:06 +0100
committerpopcornmix <popcornmix@gmail.com>2015-05-18 14:10:22 +0100
commit968262f06b012abdfa9e81aa999e6cb233e84854 (patch)
tree59b5c5af30c00d739d9867e833e40b3eefddf650 /arch/arm/mach-bcm2708
parent4924e14ef24f0fb459cd28cc814f8091ff21521a (diff)
downloadlinux-968262f06b012abdfa9e81aa999e6cb233e84854.tar.gz
MMC: added alternative MMC driver
mmc: Disable CMD23 transfers on all cards Pending wire-level investigation of these types of transfers and associated errors on bcm2835-mmc, disable for now. Fallback of CMD18/CMD25 transfers will be used automatically by the MMC layer. Reported/Tested-by: Gellert Weisz <gellert@raspberrypi.org> mmc: bcm2835-mmc: enable DT support for all architectures Both ARCH_BCM2835 and ARCH_BCM270x are built with OF now. Enable Device Tree support for all architectures. Signed-off-by: Noralf Trønnes <noralf@tronnes.org> mmc: bcm2835-mmc: fix probe error handling Probe error handling is broken in several places. Simplify error handling by using device managed functions. Replace pr_{err,info} with dev_{err,info}. Signed-off-by: Noralf Trønnes <noralf@tronnes.org>
Diffstat (limited to 'arch/arm/mach-bcm2708')
-rw-r--r--arch/arm/mach-bcm2708/bcm2708.c31
1 files changed, 31 insertions, 0 deletions
diff --git a/arch/arm/mach-bcm2708/bcm2708.c b/arch/arm/mach-bcm2708/bcm2708.c
index 5d8657b78ac1..d1308edaea87 100644
--- a/arch/arm/mach-bcm2708/bcm2708.c
+++ b/arch/arm/mach-bcm2708/bcm2708.c
@@ -399,6 +399,34 @@ static struct platform_device bcm2708_systemtimer_device = {
},
};
+#ifdef CONFIG_MMC_BCM2835 /* Arasan emmc SD (new) */
+static struct resource bcm2835_emmc_resources[] = {
+ [0] = {
+ .start = EMMC_BASE,
+ .end = EMMC_BASE + SZ_256 - 1, /* we only need this area */
+ /* the memory map actually makes SZ_4K available */
+ .flags = IORESOURCE_MEM,
+ },
+ [1] = {
+ .start = IRQ_ARASANSDIO,
+ .end = IRQ_ARASANSDIO,
+ .flags = IORESOURCE_IRQ,
+ },
+};
+
+static u64 bcm2835_emmc_dmamask = 0xffffffffUL;
+
+struct platform_device bcm2835_emmc_device = {
+ .name = "mmc-bcm2835",
+ .id = 0,
+ .num_resources = ARRAY_SIZE(bcm2835_emmc_resources),
+ .resource = bcm2835_emmc_resources,
+ .dev = {
+ .dma_mask = &bcm2835_emmc_dmamask,
+ .coherent_dma_mask = 0xffffffffUL},
+};
+#endif /* CONFIG_MMC_BCM2835 */
+
static struct resource bcm2708_powerman_resources[] = {
[0] = {
.start = PM_BASE,
@@ -524,6 +552,9 @@ void __init bcm2708_init(void)
bcm_register_device(&bcm2708_uart1_device);
bcm_register_device(&bcm2708_powerman_device);
+#ifdef CONFIG_MMC_BCM2835
+ bcm_register_device(&bcm2835_emmc_device);
+#endif
bcm2708_init_led();
for (i = 0; i < ARRAY_SIZE(amba_devs); i++) {