diff options
Diffstat (limited to 'arch/sh/include/asm/cacheflush.h')
-rw-r--r-- | arch/sh/include/asm/cacheflush.h | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/arch/sh/include/asm/cacheflush.h b/arch/sh/include/asm/cacheflush.h index 4c85d55847cc..5dffbd126e46 100644 --- a/arch/sh/include/asm/cacheflush.h +++ b/arch/sh/include/asm/cacheflush.h | |||
@@ -1,6 +1,8 @@ | |||
1 | #ifndef __ASM_SH_CACHEFLUSH_H | 1 | #ifndef __ASM_SH_CACHEFLUSH_H |
2 | #define __ASM_SH_CACHEFLUSH_H | 2 | #define __ASM_SH_CACHEFLUSH_H |
3 | 3 | ||
4 | #include <linux/mm.h> | ||
5 | |||
4 | #ifdef __KERNEL__ | 6 | #ifdef __KERNEL__ |
5 | 7 | ||
6 | #ifdef CONFIG_CACHE_OFF | 8 | #ifdef CONFIG_CACHE_OFF |
@@ -43,6 +45,18 @@ extern void __flush_purge_region(void *start, int size); | |||
43 | extern void __flush_invalidate_region(void *start, int size); | 45 | extern void __flush_invalidate_region(void *start, int size); |
44 | #endif | 46 | #endif |
45 | 47 | ||
48 | #ifdef CONFIG_MMU | ||
49 | #define ARCH_HAS_FLUSH_ANON_PAGE | ||
50 | extern void __flush_anon_page(struct page *page, unsigned long); | ||
51 | |||
52 | static inline void flush_anon_page(struct vm_area_struct *vma, | ||
53 | struct page *page, unsigned long vmaddr) | ||
54 | { | ||
55 | if (boot_cpu_data.dcache.n_aliases && PageAnon(page)) | ||
56 | __flush_anon_page(page, vmaddr); | ||
57 | } | ||
58 | #endif | ||
59 | |||
46 | #define ARCH_HAS_FLUSH_KERNEL_DCACHE_PAGE | 60 | #define ARCH_HAS_FLUSH_KERNEL_DCACHE_PAGE |
47 | static inline void flush_kernel_dcache_page(struct page *page) | 61 | static inline void flush_kernel_dcache_page(struct page *page) |
48 | { | 62 | { |