]> git.karo-electronics.de Git - karo-tx-linux.git/blobdiff - arch/arm/mm/dma-mapping.c
Merge branch 'devel-stable' into for-next
[karo-tx-linux.git] / arch / arm / mm / dma-mapping.c
index 50be842e89fd06ca43c9dd71a296509ad065bb1b..66e30534fd25de1f64e7b5da73444878a7e26309 100644 (file)
@@ -120,9 +120,8 @@ static void __dma_free_buffer(struct page *page, size_t size)
 
 #ifdef CONFIG_MMU
 
-
 #define CONSISTENT_OFFSET(x)   (((unsigned long)(x) - consistent_base) >> PAGE_SHIFT)
-#define CONSISTENT_PTE_INDEX(x) (((unsigned long)(x) - consistent_base) >> PGDIR_SHIFT)
+#define CONSISTENT_PTE_INDEX(x) (((unsigned long)(x) - consistent_base) >> PMD_SHIFT)
 
 /*
  * These are the page tables (2MB each) covering uncached, DMA consistent allocations
@@ -206,7 +205,7 @@ static int __init consistent_init(void)
                }
 
                consistent_pte[i++] = pte;
-               base += (1 << PGDIR_SHIFT);
+               base += PMD_SIZE;
        } while (base < CONSISTENT_END);
 
        return ret;