aboutsummaryrefslogtreecommitdiffstats
path: root/arch/parisc
diff options
context:
space:
mode:
Diffstat (limited to 'arch/parisc')
-rw-r--r--arch/parisc/Kconfig5
-rw-r--r--arch/parisc/include/asm/a.out.h20
-rw-r--r--arch/parisc/include/asm/elf.h2
-rw-r--r--arch/parisc/include/asm/ide.h4
-rw-r--r--arch/parisc/include/asm/siginfo.h5
-rw-r--r--arch/parisc/include/asm/statfs.h55
-rw-r--r--arch/parisc/include/asm/thread_info.h2
-rw-r--r--arch/parisc/kernel/binfmt_elf32.c2
-rw-r--r--arch/parisc/kernel/sys_parisc32.c105
-rw-r--r--arch/parisc/kernel/syscall_table.S4
10 files changed, 10 insertions, 194 deletions
diff --git a/arch/parisc/Kconfig b/arch/parisc/Kconfig
index 0a8ac703dbec..644a70b1b04e 100644
--- a/arch/parisc/Kconfig
+++ b/arch/parisc/Kconfig
@@ -78,9 +78,6 @@ config IRQ_PER_CPU
78 bool 78 bool
79 default y 79 default y
80 80
81config ARCH_SUPPORTS_AOUT
82 def_bool y
83
84# unless you want to implement ACPI on PA-RISC ... ;-) 81# unless you want to implement ACPI on PA-RISC ... ;-)
85config PM 82config PM
86 bool 83 bool
@@ -95,6 +92,8 @@ config ARCH_MAY_HAVE_PC_FDC
95 92
96source "init/Kconfig" 93source "init/Kconfig"
97 94
95source "kernel/Kconfig.freezer"
96
98 97
99menu "Processor type and features" 98menu "Processor type and features"
100 99
diff --git a/arch/parisc/include/asm/a.out.h b/arch/parisc/include/asm/a.out.h
deleted file mode 100644
index eb04e34c5bb1..000000000000
--- a/arch/parisc/include/asm/a.out.h
+++ /dev/null
@@ -1,20 +0,0 @@
1#ifndef __PARISC_A_OUT_H__
2#define __PARISC_A_OUT_H__
3
4struct exec
5{
6 unsigned int a_info; /* Use macros N_MAGIC, etc for access */
7 unsigned a_text; /* length of text, in bytes */
8 unsigned a_data; /* length of data, in bytes */
9 unsigned a_bss; /* length of uninitialized data area for file, in bytes */
10 unsigned a_syms; /* length of symbol table data in file, in bytes */
11 unsigned a_entry; /* start address */
12 unsigned a_trsize; /* length of relocation info for text, in bytes */
13 unsigned a_drsize; /* length of relocation info for data, in bytes */
14};
15
16#define N_TRSIZE(a) ((a).a_trsize)
17#define N_DRSIZE(a) ((a).a_drsize)
18#define N_SYMSIZE(a) ((a).a_syms)
19
20#endif /* __A_OUT_GNU_H__ */
diff --git a/arch/parisc/include/asm/elf.h b/arch/parisc/include/asm/elf.h
index d0a4a8262818..7fa675799e6d 100644
--- a/arch/parisc/include/asm/elf.h
+++ b/arch/parisc/include/asm/elf.h
@@ -236,7 +236,7 @@ typedef unsigned long elf_greg_t;
236 236
237#define ELF_PLATFORM ("PARISC\0") 237#define ELF_PLATFORM ("PARISC\0")
238 238
239#define SET_PERSONALITY(ex, ibcs2) \ 239#define SET_PERSONALITY(ex) \
240 current->personality = PER_LINUX; \ 240 current->personality = PER_LINUX; \
241 current->thread.map_base = DEFAULT_MAP_BASE; \ 241 current->thread.map_base = DEFAULT_MAP_BASE; \
242 current->thread.task_size = DEFAULT_TASK_SIZE \ 242 current->thread.task_size = DEFAULT_TASK_SIZE \
diff --git a/arch/parisc/include/asm/ide.h b/arch/parisc/include/asm/ide.h
index c246ef75017d..81700a2321cf 100644
--- a/arch/parisc/include/asm/ide.h
+++ b/arch/parisc/include/asm/ide.h
@@ -13,10 +13,6 @@
13 13
14#ifdef __KERNEL__ 14#ifdef __KERNEL__
15 15
16#define ide_request_irq(irq,hand,flg,dev,id) request_irq((irq),(hand),(flg),(dev),(id))
17#define ide_free_irq(irq,dev_id) free_irq((irq), (dev_id))
18#define ide_request_region(from,extent,name) request_region((from), (extent), (name))
19#define ide_release_region(from,extent) release_region((from), (extent))
20/* Generic I/O and MEMIO string operations. */ 16/* Generic I/O and MEMIO string operations. */
21 17
22#define __ide_insw insw 18#define __ide_insw insw
diff --git a/arch/parisc/include/asm/siginfo.h b/arch/parisc/include/asm/siginfo.h
index d4909f55fe35..d7034728f377 100644
--- a/arch/parisc/include/asm/siginfo.h
+++ b/arch/parisc/include/asm/siginfo.h
@@ -3,11 +3,6 @@
3 3
4#include <asm-generic/siginfo.h> 4#include <asm-generic/siginfo.h>
5 5
6/*
7 * SIGTRAP si_codes
8 */
9#define TRAP_BRANCH (__SI_FAULT|3) /* process taken branch trap */
10#define TRAP_HWBKPT (__SI_FAULT|4) /* hardware breakpoint or watchpoint */
11#undef NSIGTRAP 6#undef NSIGTRAP
12#define NSIGTRAP 4 7#define NSIGTRAP 4
13 8
diff --git a/arch/parisc/include/asm/statfs.h b/arch/parisc/include/asm/statfs.h
index 1d2b8130b23d..324bea905dc6 100644
--- a/arch/parisc/include/asm/statfs.h
+++ b/arch/parisc/include/asm/statfs.h
@@ -1,58 +1,7 @@
1#ifndef _PARISC_STATFS_H 1#ifndef _PARISC_STATFS_H
2#define _PARISC_STATFS_H 2#define _PARISC_STATFS_H
3 3
4#ifndef __KERNEL_STRICT_NAMES 4#define __statfs_word long
5 5#include <asm-generic/statfs.h>
6#include <linux/types.h>
7
8typedef __kernel_fsid_t fsid_t;
9
10#endif
11
12/*
13 * It appears that PARISC could be 64 _or_ 32 bit.
14 * 64-bit fields must be explicitly 64-bit in statfs64.
15 */
16struct statfs {
17 long f_type;
18 long f_bsize;
19 long f_blocks;
20 long f_bfree;
21 long f_bavail;
22 long f_files;
23 long f_ffree;
24 __kernel_fsid_t f_fsid;
25 long f_namelen;
26 long f_frsize;
27 long f_spare[5];
28};
29
30struct statfs64 {
31 long f_type;
32 long f_bsize;
33 __u64 f_blocks;
34 __u64 f_bfree;
35 __u64 f_bavail;
36 __u64 f_files;
37 __u64 f_ffree;
38 __kernel_fsid_t f_fsid;
39 long f_namelen;
40 long f_frsize;
41 long f_spare[5];
42};
43
44struct compat_statfs64 {
45 __u32 f_type;
46 __u32 f_bsize;
47 __u64 f_blocks;
48 __u64 f_bfree;
49 __u64 f_bavail;
50 __u64 f_files;
51 __u64 f_ffree;
52 __kernel_fsid_t f_fsid;
53 __u32 f_namelen;
54 __u32 f_frsize;
55 __u32 f_spare[5];
56};
57 6
58#endif 7#endif
diff --git a/arch/parisc/include/asm/thread_info.h b/arch/parisc/include/asm/thread_info.h
index 9f812741c355..0407959da489 100644
--- a/arch/parisc/include/asm/thread_info.h
+++ b/arch/parisc/include/asm/thread_info.h
@@ -58,6 +58,7 @@ struct thread_info {
58#define TIF_32BIT 4 /* 32 bit binary */ 58#define TIF_32BIT 4 /* 32 bit binary */
59#define TIF_MEMDIE 5 59#define TIF_MEMDIE 5
60#define TIF_RESTORE_SIGMASK 6 /* restore saved signal mask */ 60#define TIF_RESTORE_SIGMASK 6 /* restore saved signal mask */
61#define TIF_FREEZE 7 /* is freezing for suspend */
61 62
62#define _TIF_SYSCALL_TRACE (1 << TIF_SYSCALL_TRACE) 63#define _TIF_SYSCALL_TRACE (1 << TIF_SYSCALL_TRACE)
63#define _TIF_SIGPENDING (1 << TIF_SIGPENDING) 64#define _TIF_SIGPENDING (1 << TIF_SIGPENDING)
@@ -65,6 +66,7 @@ struct thread_info {
65#define _TIF_POLLING_NRFLAG (1 << TIF_POLLING_NRFLAG) 66#define _TIF_POLLING_NRFLAG (1 << TIF_POLLING_NRFLAG)
66#define _TIF_32BIT (1 << TIF_32BIT) 67#define _TIF_32BIT (1 << TIF_32BIT)
67#define _TIF_RESTORE_SIGMASK (1 << TIF_RESTORE_SIGMASK) 68#define _TIF_RESTORE_SIGMASK (1 << TIF_RESTORE_SIGMASK)
69#define _TIF_FREEZE (1 << TIF_FREEZE)
68 70
69#define _TIF_USER_WORK_MASK (_TIF_SIGPENDING | \ 71#define _TIF_USER_WORK_MASK (_TIF_SIGPENDING | \
70 _TIF_NEED_RESCHED | _TIF_RESTORE_SIGMASK) 72 _TIF_NEED_RESCHED | _TIF_RESTORE_SIGMASK)
diff --git a/arch/parisc/kernel/binfmt_elf32.c b/arch/parisc/kernel/binfmt_elf32.c
index ecb10a4f63c6..f61692d2b557 100644
--- a/arch/parisc/kernel/binfmt_elf32.c
+++ b/arch/parisc/kernel/binfmt_elf32.c
@@ -85,7 +85,7 @@ struct elf_prpsinfo32
85 * could set a processor dependent flag in the thread_struct. 85 * could set a processor dependent flag in the thread_struct.
86 */ 86 */
87 87
88#define SET_PERSONALITY(ex, ibcs2) \ 88#define SET_PERSONALITY(ex) \
89 set_thread_flag(TIF_32BIT); \ 89 set_thread_flag(TIF_32BIT); \
90 current->thread.map_base = DEFAULT_MAP_BASE32; \ 90 current->thread.map_base = DEFAULT_MAP_BASE32; \
91 current->thread.task_size = DEFAULT_TASK_SIZE32 \ 91 current->thread.task_size = DEFAULT_TASK_SIZE32 \
diff --git a/arch/parisc/kernel/sys_parisc32.c b/arch/parisc/kernel/sys_parisc32.c
index 71efd6a28e2a..0838155b7a88 100644
--- a/arch/parisc/kernel/sys_parisc32.c
+++ b/arch/parisc/kernel/sys_parisc32.c
@@ -179,111 +179,6 @@ asmlinkage long sys32_sched_rr_get_interval(pid_t pid,
179 return ret; 179 return ret;
180} 180}
181 181
182static int
183put_compat_timeval(struct compat_timeval __user *u, struct timeval *t)
184{
185 struct compat_timeval t32;
186 t32.tv_sec = t->tv_sec;
187 t32.tv_usec = t->tv_usec;
188 return copy_to_user(u, &t32, sizeof t32);
189}
190
191static inline long get_ts32(struct timespec *o, struct compat_timeval __user *i)
192{
193 long usec;
194
195 if (__get_user(o->tv_sec, &i->tv_sec))
196 return -EFAULT;
197 if (__get_user(usec, &i->tv_usec))
198 return -EFAULT;
199 o->tv_nsec = usec * 1000;
200 return 0;
201}
202
203asmlinkage int
204sys32_gettimeofday(struct compat_timeval __user *tv, struct timezone __user *tz)
205{
206 extern void do_gettimeofday(struct timeval *tv);
207
208 if (tv) {
209 struct timeval ktv;
210 do_gettimeofday(&ktv);
211 if (put_compat_timeval(tv, &ktv))
212 return -EFAULT;
213 }
214 if (tz) {
215 extern struct timezone sys_tz;
216 if (copy_to_user(tz, &sys_tz, sizeof(sys_tz)))
217 return -EFAULT;
218 }
219 return 0;
220}
221
222asmlinkage
223int sys32_settimeofday(struct compat_timeval __user *tv, struct timezone __user *tz)
224{
225 struct timespec kts;
226 struct timezone ktz;
227
228 if (tv) {
229 if (get_ts32(&kts, tv))
230 return -EFAULT;
231 }
232 if (tz) {
233 if (copy_from_user(&ktz, tz, sizeof(ktz)))
234 return -EFAULT;
235 }
236
237 return do_sys_settimeofday(tv ? &kts : NULL, tz ? &ktz : NULL);
238}
239
240int cp_compat_stat(struct kstat *stat, struct compat_stat __user *statbuf)
241{
242 compat_ino_t ino;
243 int err;
244
245 if (stat->size > MAX_NON_LFS || !new_valid_dev(stat->dev) ||
246 !new_valid_dev(stat->rdev))
247 return -EOVERFLOW;
248
249 ino = stat->ino;
250 if (sizeof(ino) < sizeof(stat->ino) && ino != stat->ino)
251 return -EOVERFLOW;
252
253 err = put_user(new_encode_dev(stat->dev), &statbuf->st_dev);
254 err |= put_user(ino, &statbuf->st_ino);
255 err |= put_user(stat->mode, &statbuf->st_mode);
256 err |= put_user(stat->nlink, &statbuf->st_nlink);
257 err |= put_user(0, &statbuf->st_reserved1);
258 err |= put_user(0, &statbuf->st_reserved2);
259 err |= put_user(new_encode_dev(stat->rdev), &statbuf->st_rdev);
260 err |= put_user(stat->size, &statbuf->st_size);
261 err |= put_user(stat->atime.tv_sec, &statbuf->st_atime);
262 err |= put_user(stat->atime.tv_nsec, &statbuf->st_atime_nsec);
263 err |= put_user(stat->mtime.tv_sec, &statbuf->st_mtime);
264 err |= put_user(stat->mtime.tv_nsec, &statbuf->st_mtime_nsec);
265 err |= put_user(stat->ctime.tv_sec, &statbuf->st_ctime);
266 err |= put_user(stat->ctime.tv_nsec, &statbuf->st_ctime_nsec);
267 err |= put_user(stat->blksize, &statbuf->st_blksize);
268 err |= put_user(stat->blocks, &statbuf->st_blocks);
269 err |= put_user(0, &statbuf->__unused1);
270 err |= put_user(0, &statbuf->__unused2);
271 err |= put_user(0, &statbuf->__unused3);
272 err |= put_user(0, &statbuf->__unused4);
273 err |= put_user(0, &statbuf->__unused5);
274 err |= put_user(0, &statbuf->st_fstype); /* not avail */
275 err |= put_user(0, &statbuf->st_realdev); /* not avail */
276 err |= put_user(0, &statbuf->st_basemode); /* not avail */
277 err |= put_user(0, &statbuf->st_spareshort);
278 err |= put_user(stat->uid, &statbuf->st_uid);
279 err |= put_user(stat->gid, &statbuf->st_gid);
280 err |= put_user(0, &statbuf->st_spare4[0]);
281 err |= put_user(0, &statbuf->st_spare4[1]);
282 err |= put_user(0, &statbuf->st_spare4[2]);
283
284 return err;
285}
286
287/*** copied from mips64 ***/ 182/*** copied from mips64 ***/
288/* 183/*
289 * Ooo, nasty. We need here to frob 32-bit unsigned longs to 184 * Ooo, nasty. We need here to frob 32-bit unsigned longs to
diff --git a/arch/parisc/kernel/syscall_table.S b/arch/parisc/kernel/syscall_table.S
index 4ed01f2d655d..303d2b647e41 100644
--- a/arch/parisc/kernel/syscall_table.S
+++ b/arch/parisc/kernel/syscall_table.S
@@ -149,8 +149,8 @@
149 ENTRY_COMP(getrlimit) 149 ENTRY_COMP(getrlimit)
150 ENTRY_COMP(getrusage) 150 ENTRY_COMP(getrusage)
151 /* struct timeval and timezone are maybe?? consistent wide and narrow */ 151 /* struct timeval and timezone are maybe?? consistent wide and narrow */
152 ENTRY_DIFF(gettimeofday) 152 ENTRY_COMP(gettimeofday)
153 ENTRY_DIFF(settimeofday) 153 ENTRY_COMP(settimeofday)
154 ENTRY_SAME(getgroups) /* 80 */ 154 ENTRY_SAME(getgroups) /* 80 */
155 ENTRY_SAME(setgroups) 155 ENTRY_SAME(setgroups)
156 /* struct socketaddr... */ 156 /* struct socketaddr... */