diff options
author | Atsushi Nemoto <anemo@mba.ocn.ne.jp> | 2007-05-17 11:46:13 -0400 |
---|---|---|
committer | Ralf Baechle <ralf@linux-mips.org> | 2007-06-06 14:34:32 -0400 |
commit | 8676d2e0244cbef294c7d9ad6e50048f9dfba9e0 (patch) | |
tree | 83cfb1392fc17f58494d9ef9f46d0e4f1f7d45ad | |
parent | fbd5604d56c4543457aeae6dda69c9b8a1405474 (diff) |
[MIPS] Fix some system calls with long long arguments
* O32 fadvise64() pass long long arguments by register pairs. Add
sys32 version for 64 bit kernel.
* N32 readahead() can pass a long long argument by one register. No
need to use sys32_readahead.
Signed-off-by: Atsushi Nemoto <anemo@mba.ocn.ne.jp>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
-rw-r--r-- | arch/mips/kernel/linux32.c | 10 | ||||
-rw-r--r-- | arch/mips/kernel/scall64-n32.S | 2 | ||||
-rw-r--r-- | arch/mips/kernel/scall64-o32.S | 2 |
3 files changed, 12 insertions, 2 deletions
diff --git a/arch/mips/kernel/linux32.c b/arch/mips/kernel/linux32.c index 37849edd0645..06e04da211d5 100644 --- a/arch/mips/kernel/linux32.c +++ b/arch/mips/kernel/linux32.c | |||
@@ -556,6 +556,16 @@ asmlinkage long sys32_sync_file_range(int fd, int __pad, | |||
556 | flags); | 556 | flags); |
557 | } | 557 | } |
558 | 558 | ||
559 | asmlinkage long sys32_fadvise64_64(int fd, int __pad, | ||
560 | unsigned long a2, unsigned long a3, | ||
561 | unsigned long a4, unsigned long a5, | ||
562 | int flags) | ||
563 | { | ||
564 | return sys_fadvise64_64(fd, | ||
565 | merge_64(a2, a3), merge_64(a4, a5), | ||
566 | flags); | ||
567 | } | ||
568 | |||
559 | save_static_function(sys32_clone); | 569 | save_static_function(sys32_clone); |
560 | __attribute_used__ noinline static int | 570 | __attribute_used__ noinline static int |
561 | _sys32_clone(nabi_no_regargs struct pt_regs regs) | 571 | _sys32_clone(nabi_no_regargs struct pt_regs regs) |
diff --git a/arch/mips/kernel/scall64-n32.S b/arch/mips/kernel/scall64-n32.S index 6eac28337423..1631035ffc24 100644 --- a/arch/mips/kernel/scall64-n32.S +++ b/arch/mips/kernel/scall64-n32.S | |||
@@ -299,7 +299,7 @@ EXPORT(sysn32_call_table) | |||
299 | PTR sys_ni_syscall /* res. for afs_syscall */ | 299 | PTR sys_ni_syscall /* res. for afs_syscall */ |
300 | PTR sys_ni_syscall /* res. for security */ | 300 | PTR sys_ni_syscall /* res. for security */ |
301 | PTR sys_gettid | 301 | PTR sys_gettid |
302 | PTR sys32_readahead | 302 | PTR sys_readahead |
303 | PTR sys_setxattr /* 6180 */ | 303 | PTR sys_setxattr /* 6180 */ |
304 | PTR sys_lsetxattr | 304 | PTR sys_lsetxattr |
305 | PTR sys_fsetxattr | 305 | PTR sys_fsetxattr |
diff --git a/arch/mips/kernel/scall64-o32.S b/arch/mips/kernel/scall64-o32.S index 7e74b412a782..2aa99426ac1c 100644 --- a/arch/mips/kernel/scall64-o32.S +++ b/arch/mips/kernel/scall64-o32.S | |||
@@ -459,7 +459,7 @@ sys_call_table: | |||
459 | PTR sys_remap_file_pages | 459 | PTR sys_remap_file_pages |
460 | PTR sys_set_tid_address | 460 | PTR sys_set_tid_address |
461 | PTR sys_restart_syscall | 461 | PTR sys_restart_syscall |
462 | PTR sys_fadvise64_64 | 462 | PTR sys32_fadvise64_64 |
463 | PTR compat_sys_statfs64 /* 4255 */ | 463 | PTR compat_sys_statfs64 /* 4255 */ |
464 | PTR compat_sys_fstatfs64 | 464 | PTR compat_sys_fstatfs64 |
465 | PTR compat_sys_timer_create | 465 | PTR compat_sys_timer_create |