diff options
Diffstat (limited to 'arch/parisc/include/asm')
-rw-r--r-- | arch/parisc/include/asm/cacheflush.h | 12 | ||||
-rw-r--r-- | arch/parisc/include/asm/compat.h | 3 | ||||
-rw-r--r-- | arch/parisc/include/asm/param.h | 23 | ||||
-rw-r--r-- | arch/parisc/include/asm/pci.h | 14 | ||||
-rw-r--r-- | arch/parisc/include/asm/pgtable.h | 2 | ||||
-rw-r--r-- | arch/parisc/include/asm/ptrace.h | 5 | ||||
-rw-r--r-- | arch/parisc/include/asm/system.h | 2 | ||||
-rw-r--r-- | arch/parisc/include/asm/uaccess.h | 27 | ||||
-rw-r--r-- | arch/parisc/include/asm/unistd.h | 4 |
9 files changed, 45 insertions, 47 deletions
diff --git a/arch/parisc/include/asm/cacheflush.h b/arch/parisc/include/asm/cacheflush.h index 7a73b615c23d..477277739da5 100644 --- a/arch/parisc/include/asm/cacheflush.h +++ b/arch/parisc/include/asm/cacheflush.h | |||
@@ -38,6 +38,18 @@ void flush_cache_mm(struct mm_struct *mm); | |||
38 | 38 | ||
39 | #define flush_kernel_dcache_range(start,size) \ | 39 | #define flush_kernel_dcache_range(start,size) \ |
40 | flush_kernel_dcache_range_asm((start), (start)+(size)); | 40 | flush_kernel_dcache_range_asm((start), (start)+(size)); |
41 | /* vmap range flushes and invalidates. Architecturally, we don't need | ||
42 | * the invalidate, because the CPU should refuse to speculate once an | ||
43 | * area has been flushed, so invalidate is left empty */ | ||
44 | static inline void flush_kernel_vmap_range(void *vaddr, int size) | ||
45 | { | ||
46 | unsigned long start = (unsigned long)vaddr; | ||
47 | |||
48 | flush_kernel_dcache_range_asm(start, start + size); | ||
49 | } | ||
50 | static inline void invalidate_kernel_vmap_range(void *vaddr, int size) | ||
51 | { | ||
52 | } | ||
41 | 53 | ||
42 | #define flush_cache_vmap(start, end) flush_cache_all() | 54 | #define flush_cache_vmap(start, end) flush_cache_all() |
43 | #define flush_cache_vunmap(start, end) flush_cache_all() | 55 | #define flush_cache_vunmap(start, end) flush_cache_all() |
diff --git a/arch/parisc/include/asm/compat.h b/arch/parisc/include/asm/compat.h index 7f32611a7a5e..02b77baa5da6 100644 --- a/arch/parisc/include/asm/compat.h +++ b/arch/parisc/include/asm/compat.h | |||
@@ -7,7 +7,8 @@ | |||
7 | #include <linux/sched.h> | 7 | #include <linux/sched.h> |
8 | #include <linux/thread_info.h> | 8 | #include <linux/thread_info.h> |
9 | 9 | ||
10 | #define COMPAT_USER_HZ 100 | 10 | #define COMPAT_USER_HZ 100 |
11 | #define COMPAT_UTS_MACHINE "parisc\0\0" | ||
11 | 12 | ||
12 | typedef u32 compat_size_t; | 13 | typedef u32 compat_size_t; |
13 | typedef s32 compat_ssize_t; | 14 | typedef s32 compat_ssize_t; |
diff --git a/arch/parisc/include/asm/param.h b/arch/parisc/include/asm/param.h index 32e03d877858..965d45427975 100644 --- a/arch/parisc/include/asm/param.h +++ b/arch/parisc/include/asm/param.h | |||
@@ -1,22 +1 @@ | |||
1 | #ifndef _ASMPARISC_PARAM_H | #include <asm-generic/param.h> | |
2 | #define _ASMPARISC_PARAM_H | ||
3 | |||
4 | #ifdef __KERNEL__ | ||
5 | #define HZ CONFIG_HZ | ||
6 | #define USER_HZ 100 /* some user API use "ticks" */ | ||
7 | #define CLOCKS_PER_SEC (USER_HZ) /* like times() */ | ||
8 | #endif | ||
9 | |||
10 | #ifndef HZ | ||
11 | #define HZ 100 | ||
12 | #endif | ||
13 | |||
14 | #define EXEC_PAGESIZE 4096 | ||
15 | |||
16 | #ifndef NOGROUP | ||
17 | #define NOGROUP (-1) | ||
18 | #endif | ||
19 | |||
20 | #define MAXHOSTNAMELEN 64 /* max length of hostname */ | ||
21 | |||
22 | #endif | ||
diff --git a/arch/parisc/include/asm/pci.h b/arch/parisc/include/asm/pci.h index 64c7aa590ae5..2242a5c636c2 100644 --- a/arch/parisc/include/asm/pci.h +++ b/arch/parisc/include/asm/pci.h | |||
@@ -183,20 +183,6 @@ struct pci_bios_ops { | |||
183 | void (*fixup_bus)(struct pci_bus *bus); | 183 | void (*fixup_bus)(struct pci_bus *bus); |
184 | }; | 184 | }; |
185 | 185 | ||
186 | /* pci_unmap_{single,page} is not a nop, thus... */ | ||
187 | #define DECLARE_PCI_UNMAP_ADDR(ADDR_NAME) \ | ||
188 | dma_addr_t ADDR_NAME; | ||
189 | #define DECLARE_PCI_UNMAP_LEN(LEN_NAME) \ | ||
190 | __u32 LEN_NAME; | ||
191 | #define pci_unmap_addr(PTR, ADDR_NAME) \ | ||
192 | ((PTR)->ADDR_NAME) | ||
193 | #define pci_unmap_addr_set(PTR, ADDR_NAME, VAL) \ | ||
194 | (((PTR)->ADDR_NAME) = (VAL)) | ||
195 | #define pci_unmap_len(PTR, LEN_NAME) \ | ||
196 | ((PTR)->LEN_NAME) | ||
197 | #define pci_unmap_len_set(PTR, LEN_NAME, VAL) \ | ||
198 | (((PTR)->LEN_NAME) = (VAL)) | ||
199 | |||
200 | /* | 186 | /* |
201 | ** Stuff declared in arch/parisc/kernel/pci.c | 187 | ** Stuff declared in arch/parisc/kernel/pci.c |
202 | */ | 188 | */ |
diff --git a/arch/parisc/include/asm/pgtable.h b/arch/parisc/include/asm/pgtable.h index a27d2e200fb2..01c15035e783 100644 --- a/arch/parisc/include/asm/pgtable.h +++ b/arch/parisc/include/asm/pgtable.h | |||
@@ -410,7 +410,7 @@ extern void paging_init (void); | |||
410 | 410 | ||
411 | #define PG_dcache_dirty PG_arch_1 | 411 | #define PG_dcache_dirty PG_arch_1 |
412 | 412 | ||
413 | extern void update_mmu_cache(struct vm_area_struct *, unsigned long, pte_t); | 413 | extern void update_mmu_cache(struct vm_area_struct *, unsigned long, pte_t *); |
414 | 414 | ||
415 | /* Encode and de-code a swap entry */ | 415 | /* Encode and de-code a swap entry */ |
416 | 416 | ||
diff --git a/arch/parisc/include/asm/ptrace.h b/arch/parisc/include/asm/ptrace.h index aead40b16dd8..7f09533da771 100644 --- a/arch/parisc/include/asm/ptrace.h +++ b/arch/parisc/include/asm/ptrace.h | |||
@@ -47,13 +47,8 @@ struct pt_regs { | |||
47 | 47 | ||
48 | #define task_regs(task) ((struct pt_regs *) ((char *)(task) + TASK_REGS)) | 48 | #define task_regs(task) ((struct pt_regs *) ((char *)(task) + TASK_REGS)) |
49 | 49 | ||
50 | struct task_struct; | ||
51 | #define arch_has_single_step() 1 | 50 | #define arch_has_single_step() 1 |
52 | void user_disable_single_step(struct task_struct *task); | ||
53 | void user_enable_single_step(struct task_struct *task); | ||
54 | |||
55 | #define arch_has_block_step() 1 | 51 | #define arch_has_block_step() 1 |
56 | void user_enable_block_step(struct task_struct *task); | ||
57 | 52 | ||
58 | /* XXX should we use iaoq[1] or iaoq[0] ? */ | 53 | /* XXX should we use iaoq[1] or iaoq[0] ? */ |
59 | #define user_mode(regs) (((regs)->iaoq[0] & 3) ? 1 : 0) | 54 | #define user_mode(regs) (((regs)->iaoq[0] & 3) ? 1 : 0) |
diff --git a/arch/parisc/include/asm/system.h b/arch/parisc/include/asm/system.h index d91357bca5b4..4653c77bf9d1 100644 --- a/arch/parisc/include/asm/system.h +++ b/arch/parisc/include/asm/system.h | |||
@@ -160,7 +160,7 @@ static inline void set_eiem(unsigned long val) | |||
160 | ldcd). */ | 160 | ldcd). */ |
161 | 161 | ||
162 | #define __PA_LDCW_ALIGNMENT 4 | 162 | #define __PA_LDCW_ALIGNMENT 4 |
163 | #define __ldcw_align(a) ((volatile unsigned int *)a) | 163 | #define __ldcw_align(a) (&(a)->slock) |
164 | #define __LDCW "ldcw,co" | 164 | #define __LDCW "ldcw,co" |
165 | 165 | ||
166 | #endif /*!CONFIG_PA20*/ | 166 | #endif /*!CONFIG_PA20*/ |
diff --git a/arch/parisc/include/asm/uaccess.h b/arch/parisc/include/asm/uaccess.h index 7cf799d70b4c..ff4cf9dab8d2 100644 --- a/arch/parisc/include/asm/uaccess.h +++ b/arch/parisc/include/asm/uaccess.h | |||
@@ -7,6 +7,7 @@ | |||
7 | #include <asm/page.h> | 7 | #include <asm/page.h> |
8 | #include <asm/system.h> | 8 | #include <asm/system.h> |
9 | #include <asm/cache.h> | 9 | #include <asm/cache.h> |
10 | #include <asm/errno.h> | ||
10 | #include <asm-generic/uaccess-unaligned.h> | 11 | #include <asm-generic/uaccess-unaligned.h> |
11 | 12 | ||
12 | #define VERIFY_READ 0 | 13 | #define VERIFY_READ 0 |
@@ -234,13 +235,35 @@ extern long lstrnlen_user(const char __user *,long); | |||
234 | 235 | ||
235 | unsigned long copy_to_user(void __user *dst, const void *src, unsigned long len); | 236 | unsigned long copy_to_user(void __user *dst, const void *src, unsigned long len); |
236 | #define __copy_to_user copy_to_user | 237 | #define __copy_to_user copy_to_user |
237 | unsigned long copy_from_user(void *dst, const void __user *src, unsigned long len); | 238 | unsigned long __copy_from_user(void *dst, const void __user *src, unsigned long len); |
238 | #define __copy_from_user copy_from_user | ||
239 | unsigned long copy_in_user(void __user *dst, const void __user *src, unsigned long len); | 239 | unsigned long copy_in_user(void __user *dst, const void __user *src, unsigned long len); |
240 | #define __copy_in_user copy_in_user | 240 | #define __copy_in_user copy_in_user |
241 | #define __copy_to_user_inatomic __copy_to_user | 241 | #define __copy_to_user_inatomic __copy_to_user |
242 | #define __copy_from_user_inatomic __copy_from_user | 242 | #define __copy_from_user_inatomic __copy_from_user |
243 | 243 | ||
244 | extern void copy_from_user_overflow(void) | ||
245 | #ifdef CONFIG_DEBUG_STRICT_USER_COPY_CHECKS | ||
246 | __compiletime_error("copy_from_user() buffer size is not provably correct") | ||
247 | #else | ||
248 | __compiletime_warning("copy_from_user() buffer size is not provably correct") | ||
249 | #endif | ||
250 | ; | ||
251 | |||
252 | static inline unsigned long __must_check copy_from_user(void *to, | ||
253 | const void __user *from, | ||
254 | unsigned long n) | ||
255 | { | ||
256 | int sz = __compiletime_object_size(to); | ||
257 | int ret = -EFAULT; | ||
258 | |||
259 | if (likely(sz == -1 || !__builtin_constant_p(n) || sz >= n)) | ||
260 | ret = __copy_from_user(to, from, n); | ||
261 | else | ||
262 | copy_from_user_overflow(); | ||
263 | |||
264 | return ret; | ||
265 | } | ||
266 | |||
244 | struct pt_regs; | 267 | struct pt_regs; |
245 | int fixup_exception(struct pt_regs *regs); | 268 | int fixup_exception(struct pt_regs *regs); |
246 | 269 | ||
diff --git a/arch/parisc/include/asm/unistd.h b/arch/parisc/include/asm/unistd.h index cda158318c62..1ce7d2851d90 100644 --- a/arch/parisc/include/asm/unistd.h +++ b/arch/parisc/include/asm/unistd.h | |||
@@ -811,8 +811,10 @@ | |||
811 | #define __NR_pwritev (__NR_Linux + 316) | 811 | #define __NR_pwritev (__NR_Linux + 316) |
812 | #define __NR_rt_tgsigqueueinfo (__NR_Linux + 317) | 812 | #define __NR_rt_tgsigqueueinfo (__NR_Linux + 317) |
813 | #define __NR_perf_event_open (__NR_Linux + 318) | 813 | #define __NR_perf_event_open (__NR_Linux + 318) |
814 | #define __NR_recvmmsg (__NR_Linux + 319) | ||
815 | #define __NR_accept4 (__NR_Linux + 320) | ||
814 | 816 | ||
815 | #define __NR_Linux_syscalls (__NR_perf_event_open + 1) | 817 | #define __NR_Linux_syscalls (__NR_accept4 + 1) |
816 | 818 | ||
817 | 819 | ||
818 | #define __IGNORE_select /* newselect */ | 820 | #define __IGNORE_select /* newselect */ |