summaryrefslogtreecommitdiff
path: root/arch/i386
diff options
context:
space:
mode:
authorDanny Holman <dholman@gymli.org>2023-11-26 18:33:53 -0600
committerDanny Holman <dholman@gymli.org>2023-11-26 18:33:53 -0600
commit36df25cf639c44018f51775abe5a8c229a4e2f74 (patch)
tree0e43c6c2adb674c97360e5eeb599f2e9cf040f31 /arch/i386
parentec2aafe64ade291a2a77d7f3771f784ff9cee722 (diff)
arch: i386: syscall.h: define some example system calls
Define a few standard Unix system calls. These may change based on future needs. Signed-off-by: Danny Holman <dholman@gymli.org>
Diffstat (limited to 'arch/i386')
-rw-r--r--arch/i386/include/kernel/syscall.h27
1 files changed, 22 insertions, 5 deletions
diff --git a/arch/i386/include/kernel/syscall.h b/arch/i386/include/kernel/syscall.h
index 4f74c1f..fdd6520 100644
--- a/arch/i386/include/kernel/syscall.h
+++ b/arch/i386/include/kernel/syscall.h
@@ -3,12 +3,29 @@
#include <kernel/isr.h>
-void halt_catch_fire(struct isr_frame *frame);
-void syscall_dispatch(struct isr_frame *frame);
-void register_syscall(void *handler(struct isr_frame*), int num);
-void sys_stop(struct isr_frame *frame);
-void sys_status(struct isr_frame *frame);
+// Unix standard calls
+#define SYS_FORK 1
+#define SYS_EXIT 2
+#define SYS_WAIT 3
+#define SYS_PIPE 4
+#define SYS_READ 5
+#define SYS_WRITE 6
+#define SYS_KILL 7
+#define SYS_FSTAT 8
+#define SYS_CHDIR 9
+#define SYS_DUP 10
+#define SYS_GETPID 11
+#define SYS_SLEEP 12
+#define SYS_OPEN 13
+#define SYS_MKNOD 14
+#define SYS_UNLINK 15
+#define SYS_LINK 16
+#define SYS_MKDIR 17
+#define SYS_CLOSE 18
+#define SYS_REBOOT 88
+
+int handle_syscall(struct isr_frame *frame);
void dump_reg(struct isr_frame *frame);
#endif