diff options
Diffstat (limited to 'include/asm-s390')
-rw-r--r-- | include/asm-s390/compat.h | 5 | ||||
-rw-r--r-- | include/asm-s390/page.h | 3 |
2 files changed, 6 insertions, 2 deletions
diff --git a/include/asm-s390/compat.h b/include/asm-s390/compat.h index a007715f4aea..356a0b183539 100644 --- a/include/asm-s390/compat.h +++ b/include/asm-s390/compat.h | |||
@@ -128,6 +128,11 @@ static inline void __user *compat_ptr(compat_uptr_t uptr) | |||
128 | return (void __user *)(unsigned long)(uptr & 0x7fffffffUL); | 128 | return (void __user *)(unsigned long)(uptr & 0x7fffffffUL); |
129 | } | 129 | } |
130 | 130 | ||
131 | static inline compat_uptr_t ptr_to_compat(void __user *uptr) | ||
132 | { | ||
133 | return (u32)(unsigned long)uptr; | ||
134 | } | ||
135 | |||
131 | static inline void __user *compat_alloc_user_space(long len) | 136 | static inline void __user *compat_alloc_user_space(long len) |
132 | { | 137 | { |
133 | unsigned long stack; | 138 | unsigned long stack; |
diff --git a/include/asm-s390/page.h b/include/asm-s390/page.h index 2430c561e021..3b1138ac7e79 100644 --- a/include/asm-s390/page.h +++ b/include/asm-s390/page.h | |||
@@ -181,8 +181,6 @@ page_get_storage_key(unsigned long addr) | |||
181 | #define PAGE_OFFSET 0x0UL | 181 | #define PAGE_OFFSET 0x0UL |
182 | #define __pa(x) (unsigned long)(x) | 182 | #define __pa(x) (unsigned long)(x) |
183 | #define __va(x) (void *)(unsigned long)(x) | 183 | #define __va(x) (void *)(unsigned long)(x) |
184 | #define pfn_to_page(pfn) (mem_map + (pfn)) | ||
185 | #define page_to_pfn(page) ((unsigned long)((page) - mem_map)) | ||
186 | #define virt_to_page(kaddr) pfn_to_page(__pa(kaddr) >> PAGE_SHIFT) | 184 | #define virt_to_page(kaddr) pfn_to_page(__pa(kaddr) >> PAGE_SHIFT) |
187 | 185 | ||
188 | #define pfn_valid(pfn) ((pfn) < max_mapnr) | 186 | #define pfn_valid(pfn) ((pfn) < max_mapnr) |
@@ -193,6 +191,7 @@ page_get_storage_key(unsigned long addr) | |||
193 | 191 | ||
194 | #endif /* __KERNEL__ */ | 192 | #endif /* __KERNEL__ */ |
195 | 193 | ||
194 | #include <asm-generic/memory_model.h> | ||
196 | #include <asm-generic/page.h> | 195 | #include <asm-generic/page.h> |
197 | 196 | ||
198 | #endif /* _S390_PAGE_H */ | 197 | #endif /* _S390_PAGE_H */ |