diff options
Diffstat (limited to 'arch/arm/mm/dma-mapping.c')
-rw-r--r-- | arch/arm/mm/dma-mapping.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/arch/arm/mm/dma-mapping.c b/arch/arm/mm/dma-mapping.c index c704eed63c5d..e4dd0646e859 100644 --- a/arch/arm/mm/dma-mapping.c +++ b/arch/arm/mm/dma-mapping.c | |||
@@ -229,6 +229,8 @@ __dma_alloc_remap(struct page *page, size_t size, gfp_t gfp, pgprot_t prot) | |||
229 | } | 229 | } |
230 | } while (size -= PAGE_SIZE); | 230 | } while (size -= PAGE_SIZE); |
231 | 231 | ||
232 | dsb(); | ||
233 | |||
232 | return (void *)c->vm_start; | 234 | return (void *)c->vm_start; |
233 | } | 235 | } |
234 | return NULL; | 236 | return NULL; |
@@ -521,6 +523,12 @@ void ___dma_page_dev_to_cpu(struct page *page, unsigned long off, | |||
521 | outer_inv_range(paddr, paddr + size); | 523 | outer_inv_range(paddr, paddr + size); |
522 | 524 | ||
523 | dma_cache_maint_page(page, off, size, dir, dmac_unmap_area); | 525 | dma_cache_maint_page(page, off, size, dir, dmac_unmap_area); |
526 | |||
527 | /* | ||
528 | * Mark the D-cache clean for this page to avoid extra flushing. | ||
529 | */ | ||
530 | if (dir != DMA_TO_DEVICE && off == 0 && size >= PAGE_SIZE) | ||
531 | set_bit(PG_dcache_clean, &page->flags); | ||
524 | } | 532 | } |
525 | EXPORT_SYMBOL(___dma_page_dev_to_cpu); | 533 | EXPORT_SYMBOL(___dma_page_dev_to_cpu); |
526 | 534 | ||