summaryrefslogtreecommitdiff
path: root/userspace/newcalls.h
diff options
context:
space:
mode:
authorMiguel <m.i@gmx.at>2018-09-21 01:43:25 +0200
committerMiguel <m.i@gmx.at>2018-09-21 01:43:25 +0200
commitace0646608c393d8952b14536090c302bed2ee85 (patch)
tree5d96e0d0a66c27818b677af3a84ef52af0260be1 /userspace/newcalls.h
parentaeefdb37d1fc1c0eb7953b9c196cab09460bc167 (diff)
piperei working finally :)
Diffstat (limited to 'userspace/newcalls.h')
-rw-r--r--userspace/newcalls.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/userspace/newcalls.h b/userspace/newcalls.h
index 9bc55a5..4568711 100644
--- a/userspace/newcalls.h
+++ b/userspace/newcalls.h
@@ -3,6 +3,7 @@
// this syscall will be moved to newlib later!
#define SYSCALL_CLONE 83
#define SYSCALL_PIPE 84
+#define SYSCALL_DUP2 86
int _clone(void)
{
@@ -12,4 +13,8 @@ int _pipe(uint32_t fds[2])
{
return syscall(SYSCALL_PIPE,fds,0,0);
}
+int _dup2(uint32_t oldfd,uint32_t newfd)
+{
+ return syscall(SYSCALL_DUP2,oldfd,newfd,0);
+}
//