page.h (59f0cb0fddc14ffc6676ae62e911f8115ebc8ccf) | page.h (063b0a4207e43acbeff3d4b09f43e750e0212b48) |
---|---|
1/* 2 * arch/arm/include/asm/page.h 3 * 4 * Copyright (C) 1995-2003 Russell King 5 * 6 * This program is free software; you can redistribute it and/or modify 7 * it under the terms of the GNU General Public License version 2 as 8 * published by the Free Software Foundation. --- 94 unchanged lines hidden (view full) --- 103#ifdef CONFIG_CPU_COPY_V6 104# define MULTI_USER 1 105#endif 106 107#if !defined(_USER) && !defined(MULTI_USER) 108#error Unknown user operations model 109#endif 110 | 1/* 2 * arch/arm/include/asm/page.h 3 * 4 * Copyright (C) 1995-2003 Russell King 5 * 6 * This program is free software; you can redistribute it and/or modify 7 * it under the terms of the GNU General Public License version 2 as 8 * published by the Free Software Foundation. --- 94 unchanged lines hidden (view full) --- 103#ifdef CONFIG_CPU_COPY_V6 104# define MULTI_USER 1 105#endif 106 107#if !defined(_USER) && !defined(MULTI_USER) 108#error Unknown user operations model 109#endif 110 |
111struct page; 112 |
|
111struct cpu_user_fns { 112 void (*cpu_clear_user_page)(void *p, unsigned long user); | 113struct cpu_user_fns { 114 void (*cpu_clear_user_page)(void *p, unsigned long user); |
113 void (*cpu_copy_user_page)(void *to, const void *from, 114 unsigned long user); | 115 void (*cpu_copy_user_highpage)(struct page *to, struct page *from, 116 unsigned long vaddr); |
115}; 116 117#ifdef MULTI_USER 118extern struct cpu_user_fns cpu_user; 119 | 117}; 118 119#ifdef MULTI_USER 120extern struct cpu_user_fns cpu_user; 121 |
120#define __cpu_clear_user_page cpu_user.cpu_clear_user_page 121#define __cpu_copy_user_page cpu_user.cpu_copy_user_page | 122#define __cpu_clear_user_page cpu_user.cpu_clear_user_page 123#define __cpu_copy_user_highpage cpu_user.cpu_copy_user_highpage |
122 123#else 124 | 124 125#else 126 |
125#define __cpu_clear_user_page __glue(_USER,_clear_user_page) 126#define __cpu_copy_user_page __glue(_USER,_copy_user_page) | 127#define __cpu_clear_user_page __glue(_USER,_clear_user_page) 128#define __cpu_copy_user_highpage __glue(_USER,_copy_user_highpage) |
127 128extern void __cpu_clear_user_page(void *p, unsigned long user); | 129 130extern void __cpu_clear_user_page(void *p, unsigned long user); |
129extern void __cpu_copy_user_page(void *to, const void *from, 130 unsigned long user); | 131extern void __cpu_copy_user_highpage(struct page *to, struct page *from, 132 unsigned long vaddr); |
131#endif 132 133#define clear_user_page(addr,vaddr,pg) __cpu_clear_user_page(addr, vaddr) | 133#endif 134 135#define clear_user_page(addr,vaddr,pg) __cpu_clear_user_page(addr, vaddr) |
134#define copy_user_page(to,from,vaddr,pg) __cpu_copy_user_page(to, from, vaddr) | |
135 | 136 |
136#define clear_page(page) memset((void *)(page), 0, PAGE_SIZE) | 137#define __HAVE_ARCH_COPY_USER_HIGHPAGE 138#define copy_user_highpage(to,from,vaddr,vma) \ 139 __cpu_copy_user_highpage(to, from, vaddr) 140 141#define clear_page(page) memzero((void *)(page), PAGE_SIZE) |
137extern void copy_page(void *to, const void *from); 138 139#undef STRICT_MM_TYPECHECKS 140 141#ifdef STRICT_MM_TYPECHECKS 142/* 143 * These are used to make use of C type-checking.. 144 */ --- 56 unchanged lines hidden --- | 142extern void copy_page(void *to, const void *from); 143 144#undef STRICT_MM_TYPECHECKS 145 146#ifdef STRICT_MM_TYPECHECKS 147/* 148 * These are used to make use of C type-checking.. 149 */ --- 56 unchanged lines hidden --- |