MIPS: 64-bit: Fix o32 lookup_dcookie syscall
authorWu Zhangjin <wuzhangjin@gmail.com>
Sat, 10 Oct 2009 11:19:49 +0000 (19:19 +0800)
committerRalf Baechle <ralf@linux-mips.org>
Mon, 2 Nov 2009 11:00:02 +0000 (12:00 +0100)
An o32 aplication passes a 64-bit value in a pair of registers; a 64-bit
kernel expects a 64-bit argument in a single register.

Signed-off-by: Chen Jie <chenj@lemote.com>
Signed-off-by: Hu Hongbing <huhb@lemote.com>
Signed-off-by: Wu Zhangjin <wuzhangjin@gmail.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
arch/mips/kernel/linux32.c
arch/mips/kernel/scall64-o32.S

index 6242bc68add720f86d66698fe544af7f08a23c1b..b77fefaff9da2c5ab49f12da5ee069b754b5db5d 100644 (file)
@@ -428,3 +428,9 @@ _sys32_clone(nabi_no_regargs struct pt_regs regs)
        return do_fork(clone_flags, newsp, &regs, 0,
                       parent_tidptr, child_tidptr);
 }
+
+asmlinkage long sys32_lookup_dcookie(u32 a0, u32 a1, char __user *buf,
+       size_t len)
+{
+       return sys_lookup_dcookie(merge_64(a0, a1), buf, len);
+}
index 9bbf9775e0bdade7b45a1cf227506cadb7e33b22..ba0dde6465a56648bfb76bfada00ea880077f6f0 100644 (file)
@@ -450,7 +450,7 @@ sys_call_table:
        PTR     sys_io_submit
        PTR     sys_io_cancel                   /* 4245 */
        PTR     sys_exit_group
-       PTR     sys_lookup_dcookie
+       PTR     sys32_lookup_dcookie
        PTR     sys_epoll_create
        PTR     sys_epoll_ctl
        PTR     sys_epoll_wait                  /* 4250 */