diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/asm-sparc64/cacheflush.h | 22 |
1 files changed, 14 insertions, 8 deletions
diff --git a/include/asm-sparc64/cacheflush.h b/include/asm-sparc64/cacheflush.h index 86f02937ff1b..51b26e81d828 100644 --- a/include/asm-sparc64/cacheflush.h +++ b/include/asm-sparc64/cacheflush.h | |||
@@ -49,16 +49,22 @@ extern void flush_dcache_page(struct page *page); | |||
49 | #define flush_icache_page(vma, pg) do { } while(0) | 49 | #define flush_icache_page(vma, pg) do { } while(0) |
50 | #define flush_icache_user_range(vma,pg,adr,len) do { } while (0) | 50 | #define flush_icache_user_range(vma,pg,adr,len) do { } while (0) |
51 | 51 | ||
52 | #define copy_to_user_page(vma, page, vaddr, dst, src, len) \ | 52 | extern void flush_ptrace_access(struct vm_area_struct *, struct page *, |
53 | do { \ | 53 | unsigned long uaddr, void *kaddr, |
54 | flush_cache_page(vma, vaddr, page_to_pfn(page));\ | 54 | unsigned long len, int write); |
55 | memcpy(dst, src, len); \ | 55 | |
56 | #define copy_to_user_page(vma, page, vaddr, dst, src, len) \ | ||
57 | do { \ | ||
58 | flush_cache_page(vma, vaddr, page_to_pfn(page)); \ | ||
59 | memcpy(dst, src, len); \ | ||
60 | flush_ptrace_access(vma, page, vaddr, src, len, 0); \ | ||
56 | } while (0) | 61 | } while (0) |
57 | 62 | ||
58 | #define copy_from_user_page(vma, page, vaddr, dst, src, len) \ | 63 | #define copy_from_user_page(vma, page, vaddr, dst, src, len) \ |
59 | do { \ | 64 | do { \ |
60 | flush_cache_page(vma, vaddr, page_to_pfn(page));\ | 65 | flush_cache_page(vma, vaddr, page_to_pfn(page)); \ |
61 | memcpy(dst, src, len); \ | 66 | memcpy(dst, src, len); \ |
67 | flush_ptrace_access(vma, page, vaddr, dst, len, 1); \ | ||
62 | } while (0) | 68 | } while (0) |
63 | 69 | ||
64 | #define flush_dcache_mmap_lock(mapping) do { } while (0) | 70 | #define flush_dcache_mmap_lock(mapping) do { } while (0) |