The Pedigree Project  0.1
posixSyscallNumbers.h
1 /*
2  * Copyright (c) 2008-2014, Pedigree Developers
3  *
4  * Please see the CONTRIB file in the root of the source tree for a full
5  * list of contributors.
6  *
7  * Permission to use, copy, modify, and distribute this software for any
8  * purpose with or without fee is hereby granted, provided that the above
9  * copyright notice and this permission notice appear in all copies.
10  *
11  * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
12  * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
13  * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
14  * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
15  * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
16  * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
17  * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
18  */
19 
20 #ifndef SYSCALL_NUMBERS_H
21 #define SYSCALL_NUMBERS_H
22 
23 #define POSIX_OPEN 1
24 #define POSIX_WRITE 2
25 #define POSIX_READ 3
26 #define POSIX_CLOSE 4
27 #define POSIX_SBRK 5
28 #define POSIX_FORK 6
29 #define POSIX_EXECVE 7
30 #define POSIX_WAITPID 8
31 #define POSIX_EXIT 9
32 #define POSIX_OPENDIR 10
33 #define POSIX_READDIR 11
34 #define POSIX_REWINDDIR 12
35 #define POSIX_CLOSEDIR 13
36 #define POSIX_TCGETATTR 14
37 #define POSIX_TCSETATTR 15
38 #define POSIX_IOCTL 16
39 #define POSIX_STAT 17
40 #define POSIX_FSTAT 18
41 #define POSIX_GETPID 19
42 #define POSIX_CHDIR 20
43 #define POSIX_SELECT 21
44 #define POSIX_LSEEK 22
45 
46 #define POSIX_SOCKET 23
47 #define POSIX_CONNECT 24
48 #define POSIX_SEND 25
49 #define POSIX_RECV 26
50 #define POSIX_BIND 27
51 #define POSIX_LISTEN 28
52 #define POSIX_ACCEPT 29
53 #define POSIX_RECVFROM 30
54 #define POSIX_SENDTO 31
55 
56 #define POSIX_GETTIMEOFDAY 32
57 #define POSIX_DUP 33
58 #define POSIX_DUP2 34
59 #define POSIX_LSTAT 35
60 #define POSIX_UNLINK 36
61 #define POSIX_SYMLINK 1000
62 
63 #define POSIX_FCNTL 39
64 #define POSIX_PIPE 40
65 
66 #define POSIX_MKDIR 41
67 #define POSIX_GETPWENT 42
68 #define POSIX_GETPWNAM 43
69 #define POSIX_GETUID 44
70 #define POSIX_GETGID 45
71 
72 #define POSIX_SIGACTION 46
73 #define POSIX_SIGNAL 47
74 #define POSIX_RAISE 48
75 #define POSIX_KILL 49
76 #define POSIX_SIGPROCMASK 50
77 
78 #define POSIX_ALARM 51
79 #define POSIX_SLEEP 52
80 
81 #define POSIX_POLL 56
82 
83 #define POSIX_RENAME 57
84 
85 #define POSIX_GETCWD 58
86 
87 #define POSIX_READLINK 59
88 #define POSIX_LINK 60
89 
90 #define POSIX_ISATTY 61
91 
92 #define POSIX_MMAP 62
93 #define POSIX_MUNMAP 63
94 
95 #define POSIX_SHUTDOWN 64
96 
97 #define POSIX_ACCESS 65
98 
99 #define POSIX_SETSID 66
100 #define POSIX_SETPGID 67
101 #define POSIX_GETPGRP 68
102 
103 #define POSIX_SIGALTSTACK 69
104 
105 #define POSIX_SEM_CLOSE 70
106 #define POSIX_SEM_DESTROY 71
107 #define POSIX_SEM_GETVALUE 72
108 #define POSIX_SEM_INIT 73
109 #define POSIX_SEM_OPEN 74
110 #define POSIX_SEM_POST 75
111 #define POSIX_SEM_TIMEWAIT 76
112 #define POSIX_SEM_TRYWAIT 77
113 #define POSIX_SEM_UNLINK 78
114 #define POSIX_SEM_WAIT 79
115 
116 #define POSIX_PTHREAD_RETURN 80
117 #define POSIX_PTHREAD_ENTER 81
118 #define POSIX_PTHREAD_CREATE 82
119 #define POSIX_PTHREAD_JOIN 83
120 #define POSIX_PTHREAD_DETACH 84
121 #define POSIX_PTHREAD_SELF 85
122 #define POSIX_PTHREAD_KILL 86
123 #define POSIX_PTHREAD_SIGMASK 87
124 
125 #define POSIX_PTHREAD_MUTEX_INIT 88
126 #define POSIX_PTHREAD_MUTEX_DESTROY 89
127 #define POSIX_PTHREAD_MUTEX_LOCK 90
128 #define POSIX_PTHREAD_MUTEX_TRYLOCK 91
129 #define POSIX_PTHREAD_MUTEX_UNLOCK 92
130 
131 #define POSIX_PTHREAD_KEY_CREATE 93
132 #define POSIX_PTHREAD_KEY_DELETE 94
133 #define POSIX_PTHREAD_SETSPECIFIC 95
134 #define POSIX_PTHREAD_GETSPECIFIC 96
135 #define POSIX_PTHREAD_KEY_DESTRUCTOR 97
136 
137 #define POSIX_SYSLOG 98
138 
139 #define POSIX_FTRUNCATE 99
140 
141 #define POSIX_STUBBED 100
142 
143 #define PEDIGREE_SIGRET 101
144 #define PEDIGREE_INIT_SIGRET 102
145 
146 #define POSIX_SCHED_YIELD 103
147 
148 #define POSIX_PEDIGREE_THRWAKEUP 104
149 #define POSIX_PEDIGREE_THRSLEEP 105
150 
151 #define POSIX_NANOSLEEP 106
152 #define POSIX_CLOCK_GETTIME 107
153 
154 #define POSIX_GETEUID 108
155 #define POSIX_GETEGID 109
156 #define POSIX_SETEUID 110
157 #define POSIX_SETEGID 111
158 
159 #define POSIX_SETUID 112
160 #define POSIX_SETGID 113
161 
162 #define POSIX_CHOWN 114
163 #define POSIX_CHMOD 115
164 #define POSIX_FCHOWN 116
165 #define POSIX_FCHMOD 117
166 #define POSIX_FCHDIR 118
167 
168 #define POSIX_STATVFS 119
169 #define POSIX_FSTATVFS 120
170 
171 #define PEDIGREE_UNWIND_SIGNAL 121
172 
173 #define POSIX_MSYNC 122
174 
175 #define POSIX_GETPEERNAME 123
176 
177 #define POSIX_FSYNC 124
178 
179 #define POSIX_MPROTECT 125
180 
181 #define POSIX_REALPATH 126
182 
183 #define POSIX_TIMES 127
184 #define POSIX_GETRUSAGE 128
185 
186 #define POSIX_GETSOCKOPT 129
187 #define POSIX_GETPPID 130
188 #define POSIX_UTIME 131
189 #define POSIX_UTIMES 132
190 #define POSIX_CHROOT 133
191 
192 #define POSIX_RMDIR 134
193 #define POSIX_GETGRNAM 135
194 #define POSIX_GETGRGID 136
195 #define POSIX_UMASK 137
196 #define POSIX_GETSOCKNAME 138
197 #define POSIX_WRITEV 139
198 #define POSIX_READV 140
199 #define POSIX_GETDENTS 141
200 #define POSIX_GETTID 142
201 #define POSIX_BRK 143
202 
203 #define POSIX_PTSNAME 200
204 #define POSIX_TTYNAME 201
205 #define POSIX_TCSETPGRP 202
206 #define POSIX_TCGETPGRP 203
207 
208 #define POSIX_USLEEP 204
209 
210 #define POSIX_PEDIGREE_CREATE_WAITER 205
211 #define POSIX_PEDIGREE_DESTROY_WAITER 206
212 #define POSIX_PEDIGREE_THREAD_WAIT_FOR 207
213 #define POSIX_PEDIGREE_THREAD_TRIGGER 209
214 
215 #define POSIX_PEDIGREE_GET_INFO_BLOCK 210
216 
217 // For pthreads
218 #define POSIX_SET_TLS_AREA 211
219 
220 #define POSIX_FUTEX 212
221 #define POSIX_UNAME 213
222 #define POSIX_ARCH_PRCTL 214
223 #define POSIX_CLONE 215
224 #define POSIX_PAUSE 216
225 #define POSIX_GETDENTS64 217
226 #define POSIX_L_SYSLOG 218
227 #define POSIX_FLOCK 219
228 
229 #define POSIX_OPENAT 220
230 #define POSIX_MKDIRAT 221
231 #define POSIX_FCHOWNAT 222
232 #define POSIX_FUTIMESAT 223
233 #define POSIX_UNLINKAT 224
234 #define POSIX_RENAMEAT 225
235 #define POSIX_LINKAT 226
236 #define POSIX_SYMLINKAT 227
237 #define POSIX_READLINKAT 228
238 #define POSIX_FCHMODAT 229
239 #define POSIX_FACCESSAT 230
240 #define POSIX_FSTATAT 231
241 #define POSIX_SETGROUPS 232
242 #define POSIX_EXIT_GROUP 233
243 #define POSIX_GETRLIMIT 234
244 #define POSIX_GETPRIORITY 235
245 #define POSIX_SETPRIORITY 236
246 #define POSIX_GETXATTR 237
247 #define POSIX_LGETXATTR 238
248 #define POSIX_FGETXATTR 239
249 #define POSIX_MKNOD 240
250 #define POSIX_SETREUID 241
251 #define POSIX_SETREGID 242
252 #define POSIX_STATFS 243
253 #define POSIX_FSTATFS 244
254 #define POSIX_SETHOSTNAME 245
255 #define POSIX_CREAT 246
256 #define POSIX_SET_ROBUST_LIST 247
257 #define POSIX_GET_ROBUST_LIST 248
258 #define POSIX_GETGROUPS 249
259 #define POSIX_MOUNT 250
260 #define POSIX_SETTIMEOFDAY 251
261 #define POSIX_SETRLIMIT 252
262 #define POSIX_SETSOCKOPT 253
263 #define POSIX_GETPGID 254
264 
265 #define POSIX_SETRESUID 255
266 #define POSIX_SETRESGID 256
267 #define POSIX_GETRESUID 257
268 #define POSIX_GETRESGID 258
269 
270 #define POSIX_IOPERM 259
271 #define POSIX_IOPL 260
272 
273 #define POSIX_TIME 261
274 #define POSIX_GETITIMER 262
275 #define POSIX_SETITIMER 263
276 #define POSIX_SOCKETPAIR 264
277 #define POSIX_SENDMSG 265
278 #define POSIX_RECVMSG 266
279 #define POSIX_CAPGET 267
280 #define POSIX_CAPSET 268
281 #define POSIX_PRCTL 269
282 
283 #endif