[USER] Exit and wait syscalls

This commit is contained in:
thomas committed 2017-03-27 23:09:09 +02:00
1 parent 5e4946e8e4
commit e3e661e7e5
6 files changed
+75 -8

No files matched your search

+2
View File
@@ -3,4 +3,6 @@
#define SYS_WRITE 0x001
#define SYS_BRK 0x002
#define SYS_FORK 0x003
#define SYS_EXIT 0x004
#define SYS_WAIT 0x005
#define SYS_DEBUG 0x3FF
+12
View File
@@ -42,3 +42,15 @@ SYSCALL_DEF(gettid)
SYSCALL_INIT();
return 0;
}
SYSCALL_DEF(exit_group)
{
SYSCALL_INIT(int, result);
return kernel_syscall(SYS_EXIT, result);
}
SYSCALL_DEF(wait4)
{
SYSCALL_INIT(int, pid, int *, result, int, options, void *, rusage);
return kernel_syscall(SYS_WAIT, result);
}