summaryrefslogtreecommitdiffstats
path: root/arch/mips64/kernel
diff options
context:
space:
mode:
authorRalf Baechle <ralf@linux-mips.org>2000-08-28 22:00:09 +0000
committerRalf Baechle <ralf@linux-mips.org>2000-08-28 22:00:09 +0000
commit1a1d77dd589de5a567fa95e36aa6999c704ceca4 (patch)
tree141e31f89f18b9fe0831f31852e0435ceaccafc5 /arch/mips64/kernel
parentfb9c690a18b3d66925a65b17441c37fa14d4370b (diff)
Merge with 2.4.0-test7.
Diffstat (limited to 'arch/mips64/kernel')
-rw-r--r--arch/mips64/kernel/linux32.c25
-rw-r--r--arch/mips64/kernel/scall_64.S3
-rw-r--r--arch/mips64/kernel/scall_o32.S4
3 files changed, 26 insertions, 6 deletions
diff --git a/arch/mips64/kernel/linux32.c b/arch/mips64/kernel/linux32.c
index 4b85a104b..e40837c3b 100644
--- a/arch/mips64/kernel/linux32.c
+++ b/arch/mips64/kernel/linux32.c
@@ -1327,9 +1327,11 @@ static inline int put_flock(struct flock *kfl, struct flock32 *ufl)
return err;
}
-extern asmlinkage long sys_fcntl(unsigned int fd, unsigned int cmd, unsigned long arg);
+extern asmlinkage long
+sys_fcntl(unsigned int fd, unsigned int cmd, unsigned long arg);
-asmlinkage long sys32_fcntl(unsigned int fd, unsigned int cmd, unsigned long arg)
+asmlinkage long
+sys32_fcntl(unsigned int fd, unsigned int cmd, unsigned long arg)
{
switch (cmd) {
case F_GETLK:
@@ -1340,12 +1342,12 @@ asmlinkage long sys32_fcntl(unsigned int fd, unsigned int cmd, unsigned long arg
mm_segment_t old_fs;
long ret;
- if(get_flock(&f, (struct flock32 *)arg))
+ if (get_flock(&f, (struct flock32 *)arg))
return -EFAULT;
old_fs = get_fs(); set_fs (KERNEL_DS);
ret = sys_fcntl(fd, cmd, (unsigned long)&f);
set_fs (old_fs);
- if(put_flock(&f, (struct flock32 *)arg))
+ if (put_flock(&f, (struct flock32 *)arg))
return -EFAULT;
return ret;
}
@@ -1354,6 +1356,21 @@ asmlinkage long sys32_fcntl(unsigned int fd, unsigned int cmd, unsigned long arg
}
}
+asmlinkage long
+sys32_fcntl64(unsigned int fd, unsigned int cmd, unsigned long arg)
+{
+ switch (cmd) {
+ case F_GETLK64:
+ return sys_fcntl(fd, F_GETLK, arg);
+ case F_SETLK64:
+ return sys_fcntl(fd, F_SETLK, arg);
+ case F_SETLKW64:
+ return sys_fcntl(fd, F_SETLKW, arg);
+ }
+
+ return sys32_fcntl(fd, cmd, arg);
+}
+
struct msgbuf32 { s32 mtype; char mtext[1]; };
struct ipc_perm32
diff --git a/arch/mips64/kernel/scall_64.S b/arch/mips64/kernel/scall_64.S
index 2e65e1732..637e63aac 100644
--- a/arch/mips64/kernel/scall_64.S
+++ b/arch/mips64/kernel/scall_64.S
@@ -220,7 +220,7 @@ sys_call_table:
PTR sys_uselib
PTR sys_swapon
PTR sys_reboot
- PTR old_readdir
+ PTR sys_ni_syscall /* old_readdir */
PTR sys_mmap /* 4090 */
PTR sys_munmap
PTR sys_truncate
@@ -344,3 +344,4 @@ sys_call_table:
PTR sys_pivot_root /* 4210 */
PTR sys_mincore
PTR sys_madvise
+ PTR sys_getdents64
diff --git a/arch/mips64/kernel/scall_o32.S b/arch/mips64/kernel/scall_o32.S
index a43fef7bd..5e668a43b 100644
--- a/arch/mips64/kernel/scall_o32.S
+++ b/arch/mips64/kernel/scall_o32.S
@@ -416,10 +416,12 @@ illegal_syscall:
sys sys_ftruncate64 2
sys sys_newstat 3
sys sys_newlstat 3
- sys sys_newfstat 3 /* 4210 */
+ sys sys_newfstat 3 /* 4215 */
sys sys_pivot_root 2
sys sys_mincore 3
sys sys_madvise 3
+ sys sys_getdents64 3
+ sys sys32_fcntl64 3 /* 4220 */
.endm
.macro sys function, nargs