diff options
author | James Bottomley <James.Bottomley@suse.de> | 2010-01-25 12:42:22 -0500 |
---|---|---|
committer | James Bottomley <James.Bottomley@HansenPartnership.com> | 2010-02-05 13:32:34 -0500 |
commit | 252a9afff76097667429b583e8b5b170b47665a4 (patch) | |
tree | 2e61eaf9c662b0c8f0762fc4a90d206915d0244d /arch/arm/include/asm/cacheflush.h | |
parent | ef7cc35b0ee03431731186320b18e5da585341ff (diff) |
arm: add mm API for DMA to vmalloc/vmap areas
ARM cannot prevent cache movein, so this patch implements both the
flush and invalidate pieces of the API.
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Diffstat (limited to 'arch/arm/include/asm/cacheflush.h')
-rw-r--r-- | arch/arm/include/asm/cacheflush.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/arch/arm/include/asm/cacheflush.h b/arch/arm/include/asm/cacheflush.h index 730aefcfbee3..4ae503cb1b8a 100644 --- a/arch/arm/include/asm/cacheflush.h +++ b/arch/arm/include/asm/cacheflush.h | |||
@@ -432,6 +432,16 @@ static inline void __flush_icache_all(void) | |||
432 | : "r" (0)); | 432 | : "r" (0)); |
433 | #endif | 433 | #endif |
434 | } | 434 | } |
435 | static inline void flush_kernel_vmap_range(void *addr, int size) | ||
436 | { | ||
437 | if ((cache_is_vivt() || cache_is_vipt_aliasing())) | ||
438 | __cpuc_flush_dcache_area(addr, (size_t)size); | ||
439 | } | ||
440 | static inline void invalidate_kernel_vmap_range(void *addr, int size) | ||
441 | { | ||
442 | if ((cache_is_vivt() || cache_is_vipt_aliasing())) | ||
443 | __cpuc_flush_dcache_area(addr, (size_t)size); | ||
444 | } | ||
435 | 445 | ||
436 | #define ARCH_HAS_FLUSH_ANON_PAGE | 446 | #define ARCH_HAS_FLUSH_ANON_PAGE |
437 | static inline void flush_anon_page(struct vm_area_struct *vma, | 447 | static inline void flush_anon_page(struct vm_area_struct *vma, |