kernel/libc: Remove sigstack() remains.
[dragonfly.git] / sys / kern / syscalls.master
1 ; @(#)syscalls.master   8.2 (Berkeley) 1/13/94
2 ; $FreeBSD: src/sys/kern/syscalls.master,v 1.72.2.10 2002/07/12 08:22:46 alfred Exp $
3 ;
4 ; System call name/number master file.
5 ; Processed to create kern/init_sysent.c, kern/syscalls.c, sys/syscall.h,
6 ;                     sys/syscall.mk, sys/sysproto.h and sys/sysunion.h
7
8 ; Columns: number type nargs namespc name alt{name,tag,rtyp}/comments
9 ;       number  system call number, must be in order
10 ;       type    one of STD, OBSOL, UNIMPL, COMPAT, CPT_NOA, LIBCOMPAT,
11 ;               NODEF, NOARGS, NOPROTO, NOIMPL
12 ;       name    pseudo-prototype of syscall routine
13 ;               If one of the following alts is different, then all appear:
14 ;       altname name of system call if different
15 ;       alttag  name of args struct tag if different from [o]`name'"_args"
16 ;       altrtyp return type if not int (bogus - syscalls always return int)
17 ;               for UNIMPL/OBSOL, name continues with comments
18 ;
19 ;       NOTE: All system calls are now called without the MP lock.  Those
20 ;             that need the MP lock will acquire it.
21
22 ; types:
23 ;       STD     always included
24 ;       COMPAT  included on COMPAT #ifdef
25 ;       LIBCOMPAT included on COMPAT #ifdef, and placed in syscall.h
26 ;       OBSOL   obsolete, not included in system, only specifies name
27 ;       UNIMPL  not implemented, placeholder only
28
29 ; #ifdef's, etc. may be included, and are copied to the output files.
30
31 #include <sys/param.h>
32 #include <sys/sysent.h>
33 #include <sys/sysproto.h>
34 #include <sys/statvfs.h>
35 #include <machine/cpumask.h>
36
37 ; Reserved/unimplemented system calls in the range 0-150 inclusive
38 ; are reserved for use in future Berkeley releases.
39 ; Additional system calls implemented in vendor and other
40 ; redistributions should be placed in the reserved range at the end
41 ; of the current calls.
42
43 0       STD     { int nosys(void); } syscall nosys_args int
44 1       STD     { void exit(int rval); }
45 2       STD     { int fork(void); }
46 3       STD     { ssize_t read(int fd, void *buf, size_t nbyte); }
47 4       STD     { ssize_t write(int fd, const void *buf, size_t nbyte); }
48 5       STD     { int open(char *path, int flags, int mode); }
49 ; XXX should be         { int open(const char *path, int flags, ...); }
50 ; but we're not ready for `const' or varargs.
51 ; XXX man page says `mode_t mode'.
52 6       STD     { int close(int fd); }
53 7       STD     { int wait4(int pid, int *status, int options, \
54                             struct rusage *rusage); } wait4 wait_args int
55 8       OBSOL   4.3 creat
56 9       STD     { int link(char *path, char *link); }
57 10      STD     { int unlink(char *path); }
58 11      OBSOL   execv
59 12      STD     { int chdir(char *path); }
60 13      STD     { int fchdir(int fd); }
61 14      STD     { int mknod(char *path, int mode, int dev); }
62 15      STD     { int chmod(char *path, int mode); }
63 16      STD     { int chown(char *path, int uid, int gid); }
64 17      STD     { int obreak(char *nsize); } break obreak_args int
65 18      STD     { int getfsstat(struct statfs *buf, long bufsize, \
66                             int flags); }
67 19      COMPAT  { long lseek(int fd, long offset, int whence); }
68 20      STD     { pid_t getpid(void); }
69 21      STD     { int mount(char *type, char *path, int flags, \
70                             caddr_t data); }
71 ; XXX `path' should have type `const char *' but we're not ready for that.
72 22      STD     { int unmount(char *path, int flags); }
73 23      STD     { int setuid(uid_t uid); }
74 24      STD     { uid_t getuid(void); }
75 25      STD     { uid_t geteuid(void); }
76 26      STD     { int ptrace(int req, pid_t pid, caddr_t addr, \
77                             int data); }
78 27      STD     { int recvmsg(int s, struct msghdr *msg, int flags); }
79 28      STD     { int sendmsg(int s, caddr_t msg, int flags); }
80 29      STD     { int recvfrom(int s, caddr_t buf, size_t len, \
81                             int flags, caddr_t from, int *fromlenaddr); }
82 30      STD     { int accept(int s, caddr_t name, int *anamelen); }
83 31      STD     { int getpeername(int fdes, caddr_t asa, int *alen); }
84 32      STD     { int getsockname(int fdes, caddr_t asa, int *alen); }
85 33      STD     { int access(char *path, int flags); }
86 34      STD     { int chflags(char *path, int flags); }
87 35      STD     { int fchflags(int fd, int flags); }
88 36      STD     { int sync(void); }
89 37      STD     { int kill(int pid, int signum); }
90 38      COMPAT  { int stat(char *path, struct ostat *ub); }
91 39      STD     { pid_t getppid(void); }
92 40      COMPAT  { int lstat(char *path, struct ostat *ub); }
93 41      STD     { int dup(int fd); }
94 42      STD     { int pipe(void); }
95 43      STD     { gid_t getegid(void); }
96 44      STD     { int profil(caddr_t samples, size_t size, \
97                             size_t offset, u_int scale); }
98 45      STD     { int ktrace(const char *fname, int ops, int facs, \
99                             int pid); }
100 46      OBSOL   freebsd3_sigaction
101 47      STD     { gid_t getgid(void); }
102 48      OBSOL   freebsd3_sigprocmask
103 ; XXX note nonstandard (bogus) calling convention - the libc stub passes
104 ; us the mask, not a pointer to it, and we return the old mask as the
105 ; (int) return value.
106 49      STD     { int getlogin(char *namebuf, u_int namelen); }
107 50      STD     { int setlogin(char *namebuf); }
108 51      STD     { int acct(char *path); }
109 52      OBSOL   freebsd3_sigpending
110 53      STD     { int sigaltstack(stack_t *ss, stack_t *oss); }
111 54      STD     { int ioctl(int fd, u_long com, caddr_t data); }
112 55      STD     { int reboot(int opt); }
113 56      STD     { int revoke(char *path); }
114 57      STD     { int symlink(char *path, char *link); }
115 58      STD     { int readlink(char *path, char *buf, int count); }
116 59      STD     { int execve(char *fname, char **argv, char **envv); }
117 60      STD     { int umask(int newmask); } umask umask_args int
118 61      STD     { int chroot(char *path); }
119 62      COMPAT  { int fstat(int fd, struct ostat *sb); }
120 63      COMPAT  { int getkerninfo(int op, char *where, size_t *size, \
121                             int arg); } getkerninfo getkerninfo_args int
122 64      COMPAT  { int getpagesize(void); } \
123                             getpagesize getpagesize_args int
124 65      STD     { int msync(void *addr, size_t len, int flags); }
125 66      STD     { pid_t vfork(void); }
126 67      OBSOL   vread
127 68      OBSOL   vwrite
128 69      STD     { int sbrk(int incr); }
129 70      STD     { int sstk(int incr); }
130 71      COMPAT  { int mmap(void *addr, int len, int prot, \
131                             int flags, int fd, long pos); }
132 72      COMPAT  { int vadvise(int anom); } vadvise ovadvise_args int
133 73      STD     { int munmap(void *addr, size_t len); }
134 74      STD     { int mprotect(void *addr, size_t len, int prot); }
135 75      STD     { int madvise(void *addr, size_t len, int behav); }
136 76      OBSOL   vhangup
137 77      OBSOL   vlimit
138 78      STD     { int mincore(const void *addr, size_t len, \
139                             char *vec); }
140 79      STD     { int getgroups(u_int gidsetsize, gid_t *gidset); }
141 80      STD     { int setgroups(u_int gidsetsize, gid_t *gidset); }
142 81      STD     { int getpgrp(void); }
143 82      STD     { int setpgid(int pid, int pgid); }
144 83      STD     { int setitimer(u_int which, struct itimerval *itv, \
145                             struct itimerval *oitv); }
146 84      COMPAT  { int wait(void); }
147 85      STD     { int swapon(char *name); }
148 86      STD     { int getitimer(u_int which, struct itimerval *itv); }
149 87      COMPAT  { int gethostname(char *hostname, u_int len); } \
150                             gethostname gethostname_args int
151 88      COMPAT  { int sethostname(char *hostname, u_int len); } \
152                             sethostname sethostname_args int
153 89      STD     { int getdtablesize(void); }
154 90      STD     { int dup2(int from, int to); }
155 91      UNIMPL  getdopt
156 92      STD     { int fcntl(int fd, int cmd, long arg); }
157 ; XXX should be         { int fcntl(int fd, int cmd, ...); }
158 ; but we're not ready for varargs.
159 ; XXX man page says `int arg' too.
160 93      STD     { int select(int nd, fd_set *in, fd_set *ou, \
161                             fd_set *ex, struct timeval *tv); }
162 94      UNIMPL  setdopt
163 95      STD     { int fsync(int fd); }
164 96      STD     { int setpriority(int which, int who, int prio); }
165 97      STD     { int socket(int domain, int type, int protocol); }
166 98      STD     { int connect(int s, caddr_t name, int namelen); }
167 99      CPT_NOA { int accept(int s, caddr_t name, int *anamelen); } \
168                             accept accept_args int
169 100     STD     { int getpriority(int which, int who); }
170 101     COMPAT  { int send(int s, caddr_t buf, int len, int flags); }
171 102     COMPAT  { int recv(int s, caddr_t buf, int len, int flags); }
172 103     OBSOL   freebsd3_sigreturn
173 104     STD     { int bind(int s, caddr_t name, int namelen); }
174 105     STD     { int setsockopt(int s, int level, int name, \
175                             caddr_t val, int valsize); }
176 106     STD     { int listen(int s, int backlog); }
177 107     OBSOL   vtimes
178 108     OBSOL   4.3 sigvec
179 109     OBSOL   4.3 sigblock
180 110     OBSOL   4.3 sigsetmask
181 111     OBSOL   freebsd3_sigsuspend
182 ; XXX note nonstandard (bogus) calling convention - the libc stub passes
183 ; us the mask, not a pointer to it.
184 112     OBSOL   sigstack;
185 113     COMPAT  { int recvmsg(int s, struct omsghdr *msg, int flags); }
186 114     COMPAT  { int sendmsg(int s, caddr_t msg, int flags); }
187 115     OBSOL   vtrace
188 116     STD     { int gettimeofday(struct timeval *tp, \
189                             struct timezone *tzp); }
190 117     STD     { int getrusage(int who, struct rusage *rusage); }
191 118     STD     { int getsockopt(int s, int level, int name, \
192                             caddr_t val, int *avalsize); }
193 119     UNIMPL  resuba (BSD/OS 2.x)
194 120     STD     { int readv(int fd, struct iovec *iovp, u_int iovcnt); }
195 121     STD     { int writev(int fd, struct iovec *iovp, \
196                             u_int iovcnt); }
197 122     STD     { int settimeofday(struct timeval *tv, \
198                             struct timezone *tzp); }
199 123     STD     { int fchown(int fd, int uid, int gid); }
200 124     STD     { int fchmod(int fd, int mode); }
201 125     CPT_NOA { int recvfrom(int s, caddr_t buf, size_t len, \
202                             int flags, caddr_t from, int *fromlenaddr); } \
203                             recvfrom recvfrom_args int
204 126     STD     { int setreuid(int ruid, int euid); }
205 127     STD     { int setregid(int rgid, int egid); }
206 128     STD     { int rename(char *from, char *to); }
207 129     COMPAT  { int truncate(char *path, long length); }
208 130     COMPAT  { int ftruncate(int fd, long length); }
209 131     STD     { int flock(int fd, int how); }
210 132     STD     { int mkfifo(char *path, int mode); }
211 133     STD     { int sendto(int s, caddr_t buf, size_t len, \
212                             int flags, caddr_t to, int tolen); }
213 134     STD     { int shutdown(int s, int how); }
214 135     STD     { int socketpair(int domain, int type, int protocol, \
215                             int *rsv); }
216 136     STD     { int mkdir(char *path, int mode); }
217 137     STD     { int rmdir(char *path); }
218 138     STD     { int utimes(char *path, struct timeval *tptr); }
219 139     OBSOL   4.2 sigreturn
220 140     STD     { int adjtime(struct timeval *delta, \
221                             struct timeval *olddelta); }
222 141     COMPAT  { int getpeername(int fdes, caddr_t asa, int *alen); }
223 142     OBSOL   4.3 gethostid
224 143     OBSOL   4.3 sethostid
225 144     COMPAT  { int getrlimit(u_int which, struct orlimit *rlp); }
226 145     COMPAT  { int setrlimit(u_int which, struct orlimit *rlp); }
227 146     OBSOL   4.3 killpg
228 147     STD     { int setsid(void); }
229 148     STD     { int quotactl(char *path, int cmd, int uid, \
230                             caddr_t arg); }
231 149     COMPAT  { int quota(void); }
232 150     CPT_NOA { int getsockname(int fdec, caddr_t asa, int *alen); }\
233                             getsockname getsockname_args int
234
235 ; Syscalls 151-180 inclusive are reserved for vendor-specific
236 ; system calls.  (This includes various calls added for compatibity
237 ; with other Unix variants.)
238 ; Some of these calls are now supported by BSD...
239 151     UNIMPL  sem_lock (BSD/OS 2.x)
240 152     UNIMPL  sem_wakeup (BSD/OS 2.x)
241 153     UNIMPL  asyncdaemon (BSD/OS 2.x)
242 154     UNIMPL  nosys
243 ; 155 is initialized by the NFS code, if present.
244 155     NOIMPL  { int nfssvc(int flag, caddr_t argp); }
245 156     COMPAT  { int getdirentries(int fd, char *buf, u_int count, \
246                             long *basep); }
247 157     STD     { int statfs(char *path, struct statfs *buf); }
248 158     STD     { int fstatfs(int fd, struct statfs *buf); }
249 159     UNIMPL  nosys
250 160     UNIMPL  nosys
251 ; 161 is initialized by the NFS code, if present.
252 161     STD     { int getfh(char *fname, struct fhandle *fhp); }
253 162     STD     { int getdomainname(char *domainname, int len); }
254 163     STD     { int setdomainname(char *domainname, int len); }
255 164     STD     { int uname(struct utsname *name); }
256 165     STD     { int sysarch(int op, char *parms); }
257 166     STD     { int rtprio(int function, pid_t pid, \
258                             struct rtprio *rtp); }
259 167     UNIMPL  nosys
260 168     UNIMPL  nosys
261 169     OBSOL   semsys
262 170     OBSOL   msgsys
263 171     OBSOL   shmsys
264 172     UNIMPL  nosys
265 173     STD     { ssize_t extpread(int fd, void *buf, \
266                             size_t nbyte, int flags, off_t offset); }
267 174     STD     { ssize_t extpwrite(int fd, const void *buf, \
268                             size_t nbyte, int flags, off_t offset); }
269 175     UNIMPL  nosys
270 176     STD     { int ntp_adjtime(struct timex *tp); }
271 177     UNIMPL  sfork (BSD/OS 2.x)
272 178     UNIMPL  getdescriptor (BSD/OS 2.x)
273 179     UNIMPL  setdescriptor (BSD/OS 2.x)
274 180     UNIMPL  nosys
275
276 ; Syscalls 181-199 are used by/reserved for BSD
277 181     STD     { int setgid(gid_t gid); }
278 182     STD     { int setegid(gid_t egid); }
279 183     STD     { int seteuid(uid_t euid); }
280 184     UNIMPL  lfs_bmapv
281 185     UNIMPL  lfs_markv
282 186     UNIMPL  lfs_segclean
283 187     UNIMPL  lfs_segwait
284 188     UNIMPL  nosys
285 189     UNIMPL  nosys
286 190     UNIMPL  nosys
287 191     STD     { int pathconf(char *path, int name); }
288 192     STD     { int fpathconf(int fd, int name); }
289 193     UNIMPL  nosys
290 194     STD     { int getrlimit(u_int which, \
291                             struct rlimit *rlp); } \
292                             getrlimit __getrlimit_args int
293 195     STD     { int setrlimit(u_int which, \
294                             struct rlimit *rlp); } \
295                             setrlimit __setrlimit_args int
296 196     UNIMPL  nosys
297 197     STD     { caddr_t mmap(caddr_t addr, size_t len, int prot, \
298                             int flags, int fd, int pad, off_t pos); }
299 198     STD     { int nosys(void); } __syscall __syscall_args int
300 199     STD     { off_t lseek(int fd, int pad, off_t offset, \
301                             int whence); }
302 200     STD     { int truncate(char *path, int pad, off_t length); }
303 201     STD     { int ftruncate(int fd, int pad, off_t length); }
304 202     STD     { int __sysctl(int *name, u_int namelen, void *old, \
305                             size_t *oldlenp, void *new, size_t newlen); } \
306                             __sysctl sysctl_args int
307 203     STD     { int mlock(const void *addr, size_t len); }
308 204     STD     { int munlock(const void *addr, size_t len); }
309 205     STD     { int undelete(char *path); }
310 206     STD     { int futimes(int fd, struct timeval *tptr); }
311 207     STD     { int getpgid(pid_t pid); }
312 208     UNIMPL  newreboot (NetBSD)
313 209     STD     { int poll(struct pollfd *fds, u_int nfds, \
314                             int timeout); }
315
316 ;
317 ; The following are reserved for loadable syscalls
318 ;
319 ; 210 is used by the Checkpoint Module
320 210     NODEF   lkmnosys lkmnosys nosys_args int
321 211     NODEF   lkmnosys lkmnosys nosys_args int
322 212     NODEF   lkmnosys lkmnosys nosys_args int
323 213     NODEF   lkmnosys lkmnosys nosys_args int
324 214     NODEF   lkmnosys lkmnosys nosys_args int
325 215     NODEF   lkmnosys lkmnosys nosys_args int
326 216     NODEF   lkmnosys lkmnosys nosys_args int
327 217     NODEF   lkmnosys lkmnosys nosys_args int
328 218     NODEF   lkmnosys lkmnosys nosys_args int
329 219     NODEF   lkmnosys lkmnosys nosys_args int
330
331 ;
332 ; The following were introduced with NetBSD/4.4Lite-2
333 ;
334 220     STD     { int __semctl(int semid, int semnum, int cmd, \
335                             union semun *arg); }
336 221     STD     { int semget(key_t key, int nsems, int semflg); }
337 222     STD     { int semop(int semid, struct sembuf *sops, \
338                             u_int nsops); }
339 223     UNIMPL  semconfig
340 224     STD     { int msgctl(int msqid, int cmd, \
341                             struct msqid_ds *buf); }
342 225     STD     { int msgget(key_t key, int msgflg); }
343 226     STD     { int msgsnd(int msqid, const void *msgp, size_t msgsz, \
344                             int msgflg); }
345 227     STD     { int msgrcv(int msqid, void *msgp, size_t msgsz, \
346                             long msgtyp, int msgflg); }
347 228     STD     { caddr_t shmat(int shmid, const void *shmaddr, \
348                             int shmflg); }
349 229     STD     { int shmctl(int shmid, int cmd, \
350                             struct shmid_ds *buf); }
351 230     STD     { int shmdt(const void *shmaddr); }
352 231     STD     { int shmget(key_t key, size_t size, int shmflg); }
353 ;
354 232     STD     { int clock_gettime(clockid_t clock_id, \
355                             struct timespec *tp); }
356 233     STD     { int clock_settime(clockid_t clock_id, \
357                             const struct timespec *tp); }
358 234     STD     { int clock_getres(clockid_t clock_id, \
359                             struct timespec *tp); }
360 235     UNIMPL  timer_create
361 236     UNIMPL  timer_delete
362 237     UNIMPL  timer_settime
363 238     UNIMPL  timer_gettime
364 239     UNIMPL  timer_getoverrun
365 240     STD     { int nanosleep(const struct timespec *rqtp, \
366                             struct timespec *rmtp); }
367 241     UNIMPL  nosys
368 242     UNIMPL  nosys
369 243     UNIMPL  nosys
370 244     UNIMPL  nosys
371 245     UNIMPL  nosys
372 246     UNIMPL  nosys
373 247     UNIMPL  nosys
374 248     UNIMPL  nosys
375 249     UNIMPL  nosys
376 ; syscall numbers initially used in OpenBSD
377 250     STD     { int minherit(void *addr, size_t len, int inherit); }
378 251     STD     { int rfork(int flags); }
379 252     STD     { int openbsd_poll(struct pollfd *fds, u_int nfds, \
380                             int timeout); }
381 253     STD     { int issetugid(void); }
382 254     STD     { int lchown(char *path, int uid, int gid); }
383 255     UNIMPL  nosys
384 256     UNIMPL  nosys
385 257     UNIMPL  nosys
386 258     UNIMPL  nosys
387 259     UNIMPL  nosys
388 260     UNIMPL  nosys
389 261     UNIMPL  nosys
390 262     UNIMPL  nosys
391 263     UNIMPL  nosys
392 264     UNIMPL  nosys
393 265     UNIMPL  nosys
394 266     UNIMPL  nosys
395 267     UNIMPL  nosys
396 268     UNIMPL  nosys
397 269     UNIMPL  nosys
398 270     UNIMPL  nosys
399 271     UNIMPL  nosys
400 272     UNIMPL  nosys
401 273     UNIMPL  nosys
402 274     STD     { int lchmod(char *path, mode_t mode); }
403 275     NOPROTO { int lchown(char *path, uid_t uid, gid_t gid); } netbsd_lchown lchown_args int
404 276     STD     { int lutimes(char *path, struct timeval *tptr); }
405 277     NOPROTO { int msync(void *addr, size_t len, int flags); } netbsd_msync msync_args int
406 278     OBSOL   nstat
407 279     OBSOL   nfstat
408 280     OBSOL   nlstat
409 281     UNIMPL  nosys
410 282     UNIMPL  nosys
411 283     UNIMPL  nosys
412 284     UNIMPL  nosys
413 285     UNIMPL  nosys
414 286     UNIMPL  nosys
415 287     UNIMPL  nosys
416 288     UNIMPL  nosys
417 ; 289 and 290 from NetBSD (OpenBSD: 267 and 268)
418 289     STD     { ssize_t extpreadv(int fd, const struct iovec *iovp, \
419                                   int iovcnt, int flags, off_t offset); }
420 290     STD     { ssize_t extpwritev(int fd, const struct iovec *iovp, \
421                                   int iovcnt, int flags, off_t offset); }
422 291     UNIMPL  nosys
423 292     UNIMPL  nosys
424 293     UNIMPL  nosys
425 294     UNIMPL  nosys
426 295     UNIMPL  nosys
427 296     UNIMPL  nosys
428 ; XXX 297 is 300 in NetBSD 
429 297     STD     { int fhstatfs(const struct fhandle *u_fhp, struct statfs *buf); }
430 298     STD     { int fhopen(const struct fhandle *u_fhp, int flags); }
431 299     UNIMPL  nosys
432 ; syscall numbers for FreeBSD
433 300     STD     { int modnext(int modid); }
434 301     STD     { int modstat(int modid, struct module_stat* stat); }
435 302     STD     { int modfnext(int modid); }
436 303     STD     { int modfind(const char *name); }
437 304     STD     { int kldload(const char *file); }
438 305     STD     { int kldunload(int fileid); }
439 306     STD     { int kldfind(const char *file); }
440 307     STD     { int kldnext(int fileid); }
441 308     STD     { int kldstat(int fileid, struct kld_file_stat* stat); }
442 309     STD     { int kldfirstmod(int fileid); }
443 310     STD     { int getsid(pid_t pid); }
444 311     STD     { int setresuid(uid_t ruid, uid_t euid, uid_t suid); }
445 312     STD     { int setresgid(gid_t rgid, gid_t egid, gid_t sgid); }
446 313     OBSOL   signanosleep
447 314     STD     { int aio_return(struct aiocb *aiocbp); }
448 315     STD     { int aio_suspend(struct aiocb * const * aiocbp, int nent, const struct timespec *timeout); }
449 316     STD     { int aio_cancel(int fd, struct aiocb *aiocbp); }
450 317     STD     { int aio_error(struct aiocb *aiocbp); }
451 318     STD     { int aio_read(struct aiocb *aiocbp); }
452 319     STD     { int aio_write(struct aiocb *aiocbp); }
453 320     STD     { int lio_listio(int mode, struct aiocb * const *acb_list, int nent, struct sigevent *sig); }
454 321     STD     { int yield(void); }
455 322     UNIMPL  thr_sleep
456 323     UNIMPL  thr_wakeup
457 324     STD     { int mlockall(int how); }
458 325     STD     { int munlockall(void); }
459 326     STD     { int __getcwd(u_char *buf, u_int buflen); }
460
461 327     STD     { int sched_setparam (pid_t pid, const struct sched_param *param); }
462 328     STD     { int sched_getparam (pid_t pid, struct sched_param *param); }
463
464 329     STD     { int sched_setscheduler (pid_t pid, int policy, const struct sched_param *param); }
465 330     STD     { int sched_getscheduler (pid_t pid); }
466
467 331     STD     { int sched_yield (void); }
468 332     STD     { int sched_get_priority_max (int policy); }
469 333     STD     { int sched_get_priority_min (int policy); }
470 334     STD     { int sched_rr_get_interval (pid_t pid, struct timespec *interval); }
471 335     STD     { int utrace(const void *addr, size_t len); }
472 336     OBSOL   freebsd4_sendfile
473 337     STD     { int kldsym(int fileid, int cmd, void *data); }
474 338     STD     { int jail(struct jail *jail); }
475 339     UNIMPL  pioctl
476 340     STD     { int sigprocmask(int how, const sigset_t *set, \
477                             sigset_t *oset); }
478 341     STD     { int sigsuspend(const sigset_t *sigmask); }
479 342     STD     { int sigaction(int sig, const struct sigaction *act, \
480                             struct sigaction *oact); }
481 343     STD     { int sigpending(sigset_t *set); }
482 344     STD     { int sigreturn(ucontext_t *sigcntxp); }
483 345     STD     { int sigtimedwait(const sigset_t *set,\
484                              siginfo_t *info, const struct timespec *timeout); }
485 346     STD     { int sigwaitinfo(const sigset_t *set,\
486                              siginfo_t *info); }
487 347     STD     { int __acl_get_file(const char *path, \
488                             acl_type_t type, struct acl *aclp); }
489 348     STD     { int __acl_set_file(const char *path, \
490                             acl_type_t type, struct acl *aclp); }
491 349     STD     { int __acl_get_fd(int filedes, acl_type_t type, \
492                             struct acl *aclp); }
493 350     STD     { int __acl_set_fd(int filedes, acl_type_t type, \
494                             struct acl *aclp); }
495 351     STD     { int __acl_delete_file(const char *path, \
496                             acl_type_t type); }
497 352     STD     { int __acl_delete_fd(int filedes, acl_type_t type); }
498 353     STD     { int __acl_aclcheck_file(const char *path, \
499                             acl_type_t type, struct acl *aclp); }
500 354     STD     { int __acl_aclcheck_fd(int filedes, acl_type_t type, \
501                             struct acl *aclp); }
502 355     STD     { int extattrctl(const char *path, int cmd, \
503                             const char *filename, int attrnamespace, \
504                             const char *attrname); }
505 356     STD     { int extattr_set_file(const char *path, \
506                             int attrnamespace, const char *attrname, \
507                             void *data, size_t nbytes); }
508 357     STD     { int extattr_get_file(const char *path, \
509                             int attrnamespace, const char *attrname, \
510                             void *data, size_t nbytes); }
511 358     STD     { int extattr_delete_file(const char *path, \
512                             int attrnamespace, const char *attrname); }
513 359     STD     { int aio_waitcomplete(struct aiocb **aiocbp, struct timespec *timeout); }
514 360     STD     { int getresuid(uid_t *ruid, uid_t *euid, uid_t *suid); }
515 361     STD     { int getresgid(gid_t *rgid, gid_t *egid, gid_t *sgid); }
516 362     STD     { int kqueue(void); }
517 363     STD     { int kevent(int fd, \
518                             const struct kevent *changelist, int nchanges, \
519                             struct kevent *eventlist, int nevents, \
520                             const struct timespec *timeout); }
521 364     UNIMPL  sctp_peeloff
522 ; 365-392 used by FreeBSD-current
523 365     UNIMPL  nosys
524 366     UNIMPL  nosys
525 367     UNIMPL  nosys
526 368     UNIMPL  nosys
527 369     UNIMPL  nosys
528 370     UNIMPL  nosys
529 371     UNIMPL  nosys
530 372     UNIMPL  nosys
531 373     UNIMPL  nosys
532 374     UNIMPL  nosys
533 375     UNIMPL  nosys
534 376     UNIMPL  nosys
535 377     UNIMPL  nosys
536 378     UNIMPL  nosys
537 379     UNIMPL  nosys
538 380     UNIMPL  nosys
539 381     UNIMPL  nosys
540 382     UNIMPL  nosys
541 383     UNIMPL  nosys
542 384     UNIMPL  nosys
543 385     UNIMPL  nosys
544 386     UNIMPL  nosys
545 387     UNIMPL  nosys
546 388     UNIMPL  nosys
547 389     UNIMPL  nosys
548 390     STD     { int kenv(int what, const char *name, char *value, int len); }
549 391     STD     { int lchflags(char *path, int flags); }
550 392     STD     { int uuidgen(struct uuid *store, int count); }
551 393     STD     { int sendfile(int fd, int s, off_t offset, size_t nbytes, \
552                                 struct sf_hdtr *hdtr, off_t *sbytes, int flags); }
553 ; 394-439 used by FreeBSD-current
554 394     UNIMPL  nosys
555 395     UNIMPL  nosys
556 396     UNIMPL  nosys
557 397     UNIMPL  nosys
558 398     UNIMPL  nosys
559 399     UNIMPL  nosys
560 400     UNIMPL  nosys
561 401     UNIMPL  nosys
562 402     UNIMPL  nosys
563 403     UNIMPL  nosys
564 404     UNIMPL  nosys
565 405     UNIMPL  nosys
566 406     UNIMPL  nosys
567 407     UNIMPL  nosys
568 408     UNIMPL  nosys
569 409     UNIMPL  nosys
570 410     UNIMPL  nosys
571 411     UNIMPL  nosys
572 412     UNIMPL  nosys
573 413     UNIMPL  nosys
574 414     UNIMPL  nosys
575 415     UNIMPL  nosys
576 416     UNIMPL  nosys
577 417     UNIMPL  nosys
578 418     UNIMPL  nosys
579 419     UNIMPL  nosys
580 420     UNIMPL  nosys
581 421     UNIMPL  nosys
582 422     UNIMPL  nosys
583 423     UNIMPL  nosys
584 424     UNIMPL  nosys
585 425     UNIMPL  nosys
586 426     UNIMPL  nosys
587 427     UNIMPL  nosys
588 428     UNIMPL  nosys
589 429     UNIMPL  nosys
590 430     UNIMPL  nosys
591 431     UNIMPL  nosys
592 432     UNIMPL  nosys
593 433     UNIMPL  nosys
594 434     UNIMPL  nosys
595 435     UNIMPL  nosys
596 436     UNIMPL  nosys
597 437     UNIMPL  nosys
598 438     UNIMPL  nosys
599 439     UNIMPL  nosys
600 ; 440-449 reserved for FreeBSD-5.x growth
601 440     UNIMPL  nosys
602 441     UNIMPL  nosys
603 442     UNIMPL  nosys
604 443     UNIMPL  nosys
605 444     UNIMPL  nosys
606 445     UNIMPL  nosys
607 446     UNIMPL  nosys
608 447     UNIMPL  nosys
609 448     UNIMPL  nosys
610 449     UNIMPL  nosys
611 ; 450 DragonFly system calls
612 450     STD     { int varsym_set(int level, const char *name, const char *data); }
613 451     STD     { int varsym_get(int mask, const char *wild, char *buf, int bufsize); }
614 452     STD     { int varsym_list(int level, char *buf, int maxsize, int *marker); }
615 453     OBSOL   upc_register
616 454     OBSOL   upc_control
617 455     OBSOL   caps_sys_service
618 456     OBSOL   caps_sys_client
619 457     OBSOL   caps_sys_close
620 458     OBSOL   caps_sys_put
621 459     OBSOL   caps_sys_reply
622 460     OBSOL   caps_sys_get
623 461     OBSOL   caps_sys_wait
624 462     OBSOL   caps_sys_abort
625 463     OBSOL   caps_sys_getgen
626 464     OBSOL   caps_sys_setgen
627 465     STD     { int exec_sys_register(void *entry); }
628 466     STD     { int exec_sys_unregister(int id); }
629 467     STD     { int sys_checkpoint(int type, int fd, pid_t pid, int retval); }
630 468     STD     { int mountctl(const char *path, int op, int fd, const void *ctl, int ctllen, void *buf, int buflen); }
631 469     STD     { int umtx_sleep(volatile const int *ptr, int value, int timeout); }
632 470     STD     { int umtx_wakeup(volatile const int *ptr, int count); }
633 471     STD     { int jail_attach(int jid); }
634 472     STD     { int set_tls_area(int which, struct tls_info *info, size_t infosize); }
635 473     STD     { int get_tls_area(int which, struct tls_info *info, size_t infosize); }
636 474     STD     { int closefrom(int fd); }
637 475     STD     { int stat(const char *path, struct stat *ub); }
638 476     STD     { int fstat(int fd, struct stat *sb); }
639 477     STD     { int lstat(const char *path, struct stat *ub); }
640 478     STD     { int fhstat(const struct fhandle *u_fhp, struct stat *sb); }
641 479     STD     { int getdirentries(int fd, char *buf, u_int count, \
642                             long *basep); }
643 480     STD     { int getdents(int fd, char *buf, size_t count); }
644 481     STD     { int usched_set(pid_t pid, int cmd, void *data, \
645                                 int bytes); }
646 482     STD     { int extaccept(int s, int flags, caddr_t name, int *anamelen); }
647 483     STD     { int extconnect(int s, int flags, caddr_t name, int namelen); }
648 484     OBSOL   syslink
649 485     STD     { int mcontrol(void *addr, size_t len, int behav, off_t value); }
650 486     STD     { int vmspace_create(void *id, int type, void *data); } 
651 487     STD     { int vmspace_destroy(void *id); }
652 488     STD     { int vmspace_ctl(void *id, int cmd,            \
653                                           struct trapframe *tframe,     \
654                                           struct vextframe *vframe); }
655 489     STD     { int vmspace_mmap(void *id, void *addr, size_t len, \
656                                           int prot, int flags, int fd, \
657                                           off_t offset); }
658 490     STD     { int vmspace_munmap(void *id, void *addr,      \
659                                           size_t len); }
660 491     STD     { int vmspace_mcontrol(void *id, void *addr,    \
661                                           size_t len, int behav, off_t value); } 
662 492     STD     { ssize_t vmspace_pread(void *id, void *buf, \
663                             size_t nbyte, int flags, off_t offset); }
664 493     STD     { ssize_t vmspace_pwrite(void *id, const void *buf, \
665                             size_t nbyte, int flags, off_t offset); }
666 494     STD     { void extexit(int how, int status, void *addr); }
667 495     STD     { int lwp_create(struct lwp_params *params); }
668 496     STD     { lwpid_t lwp_gettid(void); }
669 497     STD     { int lwp_kill(pid_t pid, lwpid_t tid, int signum); }
670 498     STD     { int lwp_rtprio(int function, pid_t pid, lwpid_t tid, struct rtprio *rtp); }
671 499     STD     { int pselect(int nd, fd_set *in, fd_set *ou, \
672                             fd_set *ex, const struct timespec *ts,    \
673                             const sigset_t *sigmask); }
674 500     STD     { int statvfs(const char *path, struct statvfs *buf); }
675 501     STD     { int fstatvfs(int fd, struct statvfs *buf); }
676 502     STD     { int fhstatvfs(const struct fhandle *u_fhp, struct statvfs *buf); }
677 503     STD     { int getvfsstat(struct statfs *buf,          \
678                             struct statvfs *vbuf, long vbufsize, int flags); }
679 504     STD     { int openat(int fd, char *path, int flags, int mode); }
680 ; XXX should be         { int openat(int fd, const char *path, int flags, ...);}
681 ; but we're not ready for `const' or varargs.
682 ; XXX man page says `mode_t mode'.
683 505     STD     { int fstatat(int fd, char *path,       \
684                                         struct stat *sb, int flags); }
685 506     STD     { int fchmodat(int fd, char *path, int mode, \
686                                         int flags); }
687 507     STD     { int fchownat(int fd, char *path, int uid, int gid, \
688                                         int flags); }
689 508     STD     { int unlinkat(int fd, char *path, int flags); }
690 509     STD     { int faccessat(int fd, char *path, int amode, \
691                                         int flags); }
692
693 ; POSIX message queues system calls
694 510     STD     { mqd_t mq_open(const char * name, int oflag, \
695                                   mode_t mode, struct mq_attr *attr); }
696 511     STD     { int mq_close(mqd_t mqdes); }
697 512     STD     { int mq_unlink(const char *name); }
698 513     STD     { int mq_getattr(mqd_t mqdes, \
699                                   struct mq_attr *mqstat); }
700 514     STD     { int mq_setattr(mqd_t mqdes, \
701                                   const struct mq_attr *mqstat, \
702                                   struct mq_attr *omqstat); }
703 515     STD     { int mq_notify(mqd_t mqdes, \
704                                   const struct sigevent *notification); }
705 516     STD     { int mq_send(mqd_t mqdes, const char *msg_ptr, \
706                                   size_t msg_len, unsigned msg_prio); }
707 517     STD     { ssize_t mq_receive(mqd_t mqdes, char *msg_ptr, \
708                                   size_t msg_len, unsigned *msg_prio); }
709 518     STD     { int mq_timedsend(mqd_t mqdes, \
710                                   const char *msg_ptr, size_t msg_len, \
711                                   unsigned msg_prio, \
712                                   const struct timespec *abs_timeout); }
713 519     STD     { ssize_t mq_timedreceive(mqd_t mqdes, \
714                                   char *msg_ptr, size_t msg_len, unsigned *msg_prio, \
715                                   const struct timespec *abs_timeout); }
716 520     STD     { int ioprio_set(int which, int who, int prio); }
717 521     STD     { int ioprio_get(int which, int who); }
718 522     STD     { int chroot_kernel(char *path); }
719 523     STD     { int renameat(int oldfd, char *old, int newfd, \
720                                   char *new); }
721 524     STD     { int mkdirat(int fd, char *path, mode_t mode); }
722 525     STD     { int mkfifoat(int fd, char *path, mode_t mode); }
723 526     STD     { int mknodat(int fd, char *path, mode_t mode, \
724                                   dev_t dev); }
725 527     STD     { int readlinkat(int fd, char *path, char *buf, \
726                                   size_t bufsize); }
727 528     STD     { int symlinkat(char *path1, int fd, char *path2); }
728 529     STD     { int swapoff(char *name); }
729 530     STD     { int vquotactl(const char *path, \
730                             struct plistref *pref); }
731 531     STD     { int linkat(int fd1, char *path1, int fd2, \
732                                 char *path2, int flags); }
733 532     STD     { int eaccess(char *path, int flags); }
734 533     STD     { int lpathconf(char *path, int name); }
735 534     STD     { int vmm_guest_ctl(int op, struct vmm_guest_options *options); }
736 535     STD     { int vmm_guest_sync_addr(long *dstaddr, long *srcaddr); }
737 536     STD     { int procctl(idtype_t idtype, id_t id, int cmd, void *data); }
738 537     STD     { int chflagsat(int fd, const char *path, int flags, int atflags);}
739 538     STD     { int pipe2(int *fildes, int flags); }
740 539     STD     { int utimensat(int fd, const char *path, const struct timespec *ts, int flags); }
741 540     STD     { int futimens(int fd, const struct timespec *ts); }
742 541     STD     { int accept4(int s, caddr_t name, int *anamelen, int flags); }
743 542     STD     { int lwp_setname(lwpid_t tid, const char *name); }
744 543     STD     { int ppoll(struct pollfd *fds, u_int nfds, \
745                         const struct timespec *ts, const sigset_t *sigmask); }
746 544     STD     { int lwp_setaffinity(pid_t pid, lwpid_t tid, const cpumask_t *mask); }
747 545     STD     { int lwp_getaffinity(pid_t pid, lwpid_t tid, cpumask_t *mask); }
748 546     STD     { int lwp_create2(struct lwp_params *params, const cpumask_t *mask); }
749 547     STD     { int getcpuclockid(pid_t pid, lwpid_t lwp_id, clockid_t *clock_id); }
750 548     STD     { int wait6(idtype_t idtype, id_t id, int *status, int options, \
751                                 struct __wrusage *wrusage, siginfo_t *info); }