]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
ARM: EXYNOS: force MAC ip to 32bit DMA
authorGirish K S <ks.giri@samsung.com>
Fri, 5 Apr 2013 06:25:18 +0000 (15:25 +0900)
committerKukjin Kim <kgene.kim@samsung.com>
Mon, 20 May 2013 16:28:58 +0000 (01:28 +0900)
The synopsys gigabit ethernet ip is compatible with only 32 bit
buffers. so restrict the driver to use only 32 bit dma mapping.

Signed-off-by: Girish K S <ks.giri@samsung.com>
Signed-off-by: Siva Reddy <siva.kallam@samsung.com>
Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
arch/arm/mach-exynos/mach-exynos5-dt.c

index e47c2a5d60f94be5a05919be439c65738e60d07b..9596861969e42c07baadef22fe6d97f7adf08008 100644 (file)
@@ -25,6 +25,7 @@
 #include "common.h"
 
 static u64 dma_mask64 = DMA_BIT_MASK(64);
+static u64 dma_mask32 = DMA_BIT_MASK(32);
 
 static void __init exynos5_dt_map_io(void)
 {
@@ -41,6 +42,10 @@ static int exynos5440_platform_notifier(struct notifier_block *nb,
 
        dev->dma_mask = &dma_mask64;
        dev->coherent_dma_mask = DMA_BIT_MASK(64);
+
+       if (of_device_is_compatible(dev->of_node, "snps,dwmac-3.70a"))
+               dev->dma_mask = &dma_mask32;
+
        return NOTIFY_OK;
 }