]> pilppa.com Git - linux-2.6-omap-h63xx.git/commitdiff
[MIPS] Wire up the fallocate syscall.
authorRalf Baechle <ralf@linux-mips.org>
Thu, 26 Jul 2007 02:38:24 +0000 (03:38 +0100)
committerRalf Baechle <ralf@linux-mips.org>
Tue, 31 Jul 2007 20:35:22 +0000 (21:35 +0100)
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
arch/mips/kernel/linux32.c
arch/mips/kernel/scall32-o32.S
arch/mips/kernel/scall64-64.S
arch/mips/kernel/scall64-n32.S
arch/mips/kernel/scall64-o32.S
include/asm-mips/unistd.h

index c37568d6fb55d7133550dfc1e53a577288808933..135d9a5fe337c9f232eb39704ac6cef4c104ccb1 100644 (file)
@@ -566,6 +566,13 @@ asmlinkage long sys32_fadvise64_64(int fd, int __pad,
                        flags);
 }
 
+asmlinkage long sys32_fallocate(int fd, int mode, unsigned offset_a2,
+       unsigned offset_a3, unsigned len_a4, unsigned len_a5)
+{
+       return sys_fallocate(fd, mode, merge_64(offset_a2, offset_a3),
+                            merge_64(len_a4, len_a5));
+}
+
 save_static_function(sys32_clone);
 static int noinline __used
 _sys32_clone(nabi_no_regargs struct pt_regs regs)
index ae985d1fcca12cb6722fc371f681ff3bce9000a1..82480a1717d892eb6b07db692055c643851c0e44 100644 (file)
@@ -662,6 +662,7 @@ einval:     li      v0, -EINVAL
        sys     sys_signalfd            3
        sys     sys_timerfd             4
        sys     sys_eventfd             1
+       sys     sys_fallocate           6       /* 4320 */
        .endm
 
        /* We pre-compute the number of _instruction_ bytes needed to
index 7bcd5a1a85f593ad818abe3e763b08ab1f705db3..c2c10876da2e2a85d4ad9299111bddf004fb58f6 100644 (file)
@@ -477,4 +477,5 @@ sys_call_table:
        PTR     sys_signalfd
        PTR     sys_timerfd
        PTR     sys_eventfd
+       PTR     sys_fallocate
        .size   sys_call_table,.-sys_call_table
index 532a2f3b42fc53c1498abfae16ca6289649b3eee..53d7a977193c6172d581cab48e43f4551ec8e5af 100644 (file)
@@ -403,4 +403,5 @@ EXPORT(sysn32_call_table)
        PTR     compat_sys_signalfd             /* 5280 */
        PTR     compat_sys_timerfd
        PTR     sys_eventfd
+       PTR     sys_fallocate
        .size   sysn32_call_table,.-sysn32_call_table
index 6bbe0f4ed8ba757dc6c3c897c6ab5618a6ec3aac..b3ed731a24c6ad41c293101826f56958a8d4d7ca 100644 (file)
@@ -525,4 +525,5 @@ sys_call_table:
        PTR     compat_sys_signalfd
        PTR     compat_sys_timerfd
        PTR     sys_eventfd
+       PTR     sys_fallocate                   /* 4320 */
        .size   sys_call_table,.-sys_call_table
index ed16de0a6398b92e7a1912f2db813a6e43fbbc97..fa9a587b3bf18e4b8bef3a1e610116fa3c4dd4e9 100644 (file)
 #define __NR_signalfd                  (__NR_Linux + 317)
 #define __NR_timerfd                   (__NR_Linux + 318)
 #define __NR_eventfd                   (__NR_Linux + 319)
+#define __NR_fallocate                 (__NR_Linux + 320)
 
 /*
  * Offset of the last Linux o32 flavoured syscall
  */
-#define __NR_Linux_syscalls            319
+#define __NR_Linux_syscalls            320
 
 #endif /* _MIPS_SIM == _MIPS_SIM_ABI32 */
 
 #define __NR_O32_Linux                 4000
-#define __NR_O32_Linux_syscalls                319
+#define __NR_O32_Linux_syscalls                320
 
 #if _MIPS_SIM == _MIPS_SIM_ABI64
 
 #define __NR_signalfd                  (__NR_Linux + 276)
 #define __NR_timerfd                   (__NR_Linux + 277)
 #define __NR_eventfd                   (__NR_Linux + 278)
+#define __NR_fallocate                 (__NR_Linux + 279)
 
 /*
  * Offset of the last Linux 64-bit flavoured syscall
  */
-#define __NR_Linux_syscalls            278
+#define __NR_Linux_syscalls            279
 
 #endif /* _MIPS_SIM == _MIPS_SIM_ABI64 */
 
 #define __NR_64_Linux                  5000
-#define __NR_64_Linux_syscalls         278
+#define __NR_64_Linux_syscalls         279
 
 #if _MIPS_SIM == _MIPS_SIM_NABI32
 
 #define __NR_signalfd                  (__NR_Linux + 280)
 #define __NR_timerfd                   (__NR_Linux + 281)
 #define __NR_eventfd                   (__NR_Linux + 282)
+#define __NR_fallocate                 (__NR_Linux + 283)
 
 /*
  * Offset of the last N32 flavoured syscall
  */
-#define __NR_Linux_syscalls            282
+#define __NR_Linux_syscalls            283
 
 #endif /* _MIPS_SIM == _MIPS_SIM_NABI32 */
 
 #define __NR_N32_Linux                 6000
-#define __NR_N32_Linux_syscalls                282
+#define __NR_N32_Linux_syscalls                283
 
 #ifdef __KERNEL__