-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathsyscall.h
25 lines (25 loc) · 841 Bytes
/
syscall.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
// System call numbers -- Portland State University version
#define SYS_fork 1
#define SYS_exit SYS_fork+1
#define SYS_wait SYS_exit+1
#define SYS_pipe SYS_wait+1
#define SYS_read SYS_pipe+1
#define SYS_kill SYS_read+1
#define SYS_exec SYS_kill+1
#define SYS_fstat SYS_exec+1
#define SYS_chdir SYS_fstat+1
#define SYS_dup SYS_chdir+1
#define SYS_getpid SYS_dup+1
#define SYS_sbrk SYS_getpid+1
#define SYS_sleep SYS_sbrk+1
#define SYS_uptime SYS_sleep+1
#define SYS_open SYS_uptime+1
#define SYS_write SYS_open+1
#define SYS_mknod SYS_write+1
#define SYS_unlink SYS_mknod+1
#define SYS_link SYS_unlink+1
#define SYS_mkdir SYS_link+1
#define SYS_close SYS_mkdir+1
#define SYS_halt SYS_close+1
// student system calls begin here. Follow the existing pattern.
#define SYS_date SYS_halt+1