about summary refs log tree commit diff
path: root/src/linux
diff options
context:
space:
mode:
authorRich Felker <dalias@aerifal.cx>2012-09-08 00:41:11 -0400
committerRich Felker <dalias@aerifal.cx>2012-09-08 00:41:11 -0400
commitb72db3d1ed561d31d059acc7e9a5aacb8c5ee9ac (patch)
tree07660b118a24aa461f385da8a2c59a055c8abb46 /src/linux
parent90f770523f54b2e63a6ad46cba0149c9dc01ddd4 (diff)
downloadmusl-b72db3d1ed561d31d059acc7e9a5aacb8c5ee9ac.tar.gz
musl-b72db3d1ed561d31d059acc7e9a5aacb8c5ee9ac.tar.xz
musl-b72db3d1ed561d31d059acc7e9a5aacb8c5ee9ac.zip
move fallocate syscall wrapper to linux-specific syscalls dir
Diffstat (limited to 'src/linux')
-rw-r--r--src/linux/fallocate.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/linux/fallocate.c b/src/linux/fallocate.c
new file mode 100644
index 00000000..9146350e
--- /dev/null
+++ b/src/linux/fallocate.c
@@ -0,0 +1,9 @@
+#define _GNU_SOURCE
+#include <fcntl.h>
+#include "syscall.h"
+
+int fallocate(int fd, int mode, off_t base, off_t len)
+{
+	return syscall(SYS_fallocate, fd, mode, __SYSCALL_LL_E(base),
+		__SYSCALL_LL_E(len));
+}