diff options
author | Paul Mundt <lethal@linux-sh.org> | 2009-07-27 08:30:17 -0400 |
---|---|---|
committer | Paul Mundt <lethal@linux-sh.org> | 2009-07-27 08:30:17 -0400 |
commit | 0dfae7d5a21901b28ec0452d71be64adf5ea323e (patch) | |
tree | 1ff16641313a76505ec89058d953c92d355af275 /arch/sh/include/asm/cacheflush.h | |
parent | 221c007b028ebf663ebee4fc90483909547d92a7 (diff) |
sh: Use the now generic SH-4 clear/copy page ops for all MMU platforms.
Now that the SH-4 page clear/copy ops are generic, they can be used for
all platforms with CONFIG_MMU=y. SH-5 remains the odd one out, but it too
will gradually be converted over to using this interface.
SH-3 platforms which do not contain aliases will see no impact from this
change, while aliasing SH-3 platforms will get the same interface as
SH-4.
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
Diffstat (limited to 'arch/sh/include/asm/cacheflush.h')
-rw-r--r-- | arch/sh/include/asm/cacheflush.h | 15 |
1 files changed, 0 insertions, 15 deletions
diff --git a/arch/sh/include/asm/cacheflush.h b/arch/sh/include/asm/cacheflush.h index 4e360114269d..4c85d55847cc 100644 --- a/arch/sh/include/asm/cacheflush.h +++ b/arch/sh/include/asm/cacheflush.h | |||
@@ -49,7 +49,6 @@ static inline void flush_kernel_dcache_page(struct page *page) | |||
49 | flush_dcache_page(page); | 49 | flush_dcache_page(page); |
50 | } | 50 | } |
51 | 51 | ||
52 | #if (defined(CONFIG_CPU_SH4) || defined(CONFIG_SH7705_CACHE_32KB)) && !defined(CONFIG_CACHE_OFF) | ||
53 | extern void copy_to_user_page(struct vm_area_struct *vma, | 52 | extern void copy_to_user_page(struct vm_area_struct *vma, |
54 | struct page *page, unsigned long vaddr, void *dst, const void *src, | 53 | struct page *page, unsigned long vaddr, void *dst, const void *src, |
55 | unsigned long len); | 54 | unsigned long len); |
@@ -57,20 +56,6 @@ extern void copy_to_user_page(struct vm_area_struct *vma, | |||
57 | extern void copy_from_user_page(struct vm_area_struct *vma, | 56 | extern void copy_from_user_page(struct vm_area_struct *vma, |
58 | struct page *page, unsigned long vaddr, void *dst, const void *src, | 57 | struct page *page, unsigned long vaddr, void *dst, const void *src, |
59 | unsigned long len); | 58 | unsigned long len); |
60 | #else | ||
61 | #define copy_to_user_page(vma, page, vaddr, dst, src, len) \ | ||
62 | do { \ | ||
63 | flush_cache_page(vma, vaddr, page_to_pfn(page));\ | ||
64 | memcpy(dst, src, len); \ | ||
65 | flush_icache_user_range(vma, page, vaddr, len); \ | ||
66 | } while (0) | ||
67 | |||
68 | #define copy_from_user_page(vma, page, vaddr, dst, src, len) \ | ||
69 | do { \ | ||
70 | flush_cache_page(vma, vaddr, page_to_pfn(page));\ | ||
71 | memcpy(dst, src, len); \ | ||
72 | } while (0) | ||
73 | #endif | ||
74 | 59 | ||
75 | #define flush_cache_vmap(start, end) flush_cache_all() | 60 | #define flush_cache_vmap(start, end) flush_cache_all() |
76 | #define flush_cache_vunmap(start, end) flush_cache_all() | 61 | #define flush_cache_vunmap(start, end) flush_cache_all() |