Sync usage with man page.
[netbsd-mini2440.git] / sys / compat / svr4 / syscalls.master
blob85e43a38f89fea16810504293e770d8409d9474d
1         $NetBSD: syscalls.master,v 1.60 2009/01/13 22:08:30 pooka Exp $
3 ;       @(#)syscalls.master     8.1 (Berkeley) 7/19/93
5 ; NetBSD COMPAT_SVR4 system call name/number "master" file.
6 ; (See syscalls.conf to see what it is processed into.)
8 ; Fields: number type [type-dependent ...]
9 ;       number  system call number, must be in order
10 ;       type    one of STD, OBSOL, UNIMPL, NODEF, NOARGS, or one of
11 ;               the compatibility options defined in syscalls.conf.
13 ; types:
14 ;       STD     always included
15 ;       OBSOL   obsolete, not included in system
16 ;       UNIMPL  unimplemented, not included in system
17 ;       NODEF   included, but don't define the syscall number
18 ;       NOARGS  included, but don't define the syscall args structure
20 ; The compat options are defined in the syscalls.conf file, and the
21 ; compat option name is prefixed to the syscall name.  Other than
22 ; that, they're like NODEF (for 'compat' options), or STD (for
23 ; 'libcompat' options).
25 ; The type-dependent arguments are as follows:
26 ; For STD, NODEF, NOARGS, and compat syscalls:
27 ;       { pseudo-proto } [alias]
28 ; For other syscalls:
29 ;       [comment]
31 ; #ifdef's, etc. may be included, and are copied to the output files.
32 ; #include's are copied to the syscall names and switch definition files only.
34 #if defined(_KERNEL_OPT)
35 #include "opt_ntp.h"
36 #include "opt_sysv.h"
37 #endif
39 #include <sys/param.h>
40 #include <sys/systm.h>
41 #include <sys/signal.h>
42 #include <sys/mount.h>
43 #include <sys/poll.h>
44 #include <sys/sched.h>
45 #include <sys/syscallargs.h>
47 #include <compat/svr4/svr4_types.h>
48 #include <compat/svr4/svr4_time.h>
49 #include <compat/svr4/svr4_signal.h>
50 #include <compat/svr4/svr4_ucontext.h>
51 #include <compat/svr4/svr4_lwp.h>
52 #include <compat/svr4/svr4_syscallargs.h>
53 #include <compat/svr4/svr4_statvfs.h>
54 #include <compat/svr4/svr4_resource.h>
55 #include <compat/svr4/svr4_acl.h>
56 #include <compat/svr4/svr4_schedctl.h>
59 0       NOARGS          { int|sys||nosys(void); } syscall
60 1       NOARGS          { int|sys||exit(int rval); }
61 2       NOARGS          { int|sys||fork(void); }
62 3       NOARGS          { int|sys||read(int fd, char *buf, u_int nbyte); }
63 4       NOARGS          { int|sys||write(int fd, char *buf, u_int nbyte); }
64 5       STD             { int|svr4_sys||open(const char *path, int flags, \
65                             int mode); }
66 6       NOARGS          { int|sys||close(int fd); }
67 7       STD             { int|svr4_sys||wait(int *status); }
68 8       STD             { int|svr4_sys||creat(const char *path, int mode); }
69 9       NOARGS          { int|sys||link(char *path, char *link); }
70 10      NOARGS          { int|sys||unlink(char *path); }
71 11      STD             { int|svr4_sys||execv(const char *path, char **argp); }
72 12      NOARGS          { int|sys||chdir(char *path); }
73 13      STD             { int|svr4_sys||time(svr4_time_t *t); }
74 14      STD             { int|svr4_sys||mknod(const char* path, int mode, \
75                             int dev); }
76 15      NOARGS          { int|sys||chmod(char *path, int mode); }
77 16      NOARGS          { int|sys||__posix_chown(char *path, int uid, \
78                             int gid); } chown
79 17      STD             { int|svr4_sys||break(void *nsize); }
80 18      STD             { int|svr4_sys||stat(const char* path, \
81                             struct svr4_stat* ub); }
82 19      NOARGS          { long|compat_43_sys||lseek(int fd, long offset, \
83                             int whence); }
84 20      NOARGS          { pid_t|sys||getpid(void); }
85 21      UNIMPL          old_mount
86 22      UNIMPL          System V umount
87 23      NOARGS          { int|sys||setuid(uid_t uid); }
88 24      NOARGS          { uid_t|sys||getuid_with_euid(void); }
89 25      UNIMPL          stime
90 26      UNIMPL          ptrace
91 27      STD             { int|svr4_sys||alarm(unsigned sec); }
92 28      STD             { int|svr4_sys||fstat(int fd, struct svr4_stat *sb); }
93 29      STD             { int|svr4_sys||pause(void); }
94 30      STD             { int|svr4_sys||utime(const char *path, \
95                              struct svr4_utimbuf *ubuf); }
96 31      UNIMPL          was stty
97 32      UNIMPL          was gtty
98 33      STD             { int|svr4_sys||access(const char *path, int flags); }
99 34      STD             { int|svr4_sys||nice(int prio); }
100 35      UNIMPL          statfs
101 36      NOARGS          { int|sys||sync(void); }
102 37      STD             { int|svr4_sys||kill(int pid, int signum); }
103 38      UNIMPL          fstatfs
104 39      STD             { int|svr4_sys||pgrpsys(int cmd, int pid, int pgid); }
105 40      UNIMPL          xenix
106 41      NOARGS          { int|sys||dup(u_int fd); }
107 42      NOARGS          { int|sys||pipe(void); }
108 43      STD             { int|svr4_sys||times(struct tms *tp); }
109 44      UNIMPL          profil
110 45      UNIMPL          plock
111 46      NOARGS          { int|sys||setgid(gid_t gid); }
112 47      NOARGS          { gid_t|sys||getgid_with_egid(void); }
113 48      STD             { int|svr4_sys||signal(int signum, svr4_sig_t handler); }
114 #ifdef SYSVMSG
115 49      STD             { int|svr4_sys||msgsys(int what, int a2, int a3, \
116                                               int a4, int a5); }
117 #else
118 49      UNIMPL          msgsys
119 #endif
120 50      STD             { int|svr4_sys||sysarch(int op, void *a1); }
121 51      UNIMPL          acct
122 #ifdef SYSVSHM
123 52      STD             { int|svr4_sys||shmsys(int what, int a2, int a3, \
124                                               int a4); }
125 #else
126 52      UNIMPL          shmsys
127 #endif
128 #ifdef SYSVSEM
129 53      STD             { int|svr4_sys||semsys(int what, int a2, int a3, \
130                                               int a4, int a5); }
131 #else
132 53      UNIMPL          semsys
133 #endif
134 54      STD             { int|svr4_sys||ioctl(int fd, u_long com, \
135                             void *data); }
136 55      UNIMPL          uadmin
137 56      UNIMPL          exch
138 57      STD             { int|svr4_sys||utssys(void *a1, void *a2, int sel, \
139                             void *a3); }
140 58      NOARGS          { int|sys||fsync(int fd); }
141 59      STD             { int|svr4_sys||execve(const char *path, char **argp, \
142                             char **envp); }
143 60      NOARGS          { int|sys||umask(int newmask); }
144 61      NOARGS          { int|sys||chroot(char *path); }
145 62      STD             { int|svr4_sys||fcntl(int fd, int cmd, char *arg); }
146 63      STD             { long|svr4_sys||ulimit(int cmd, long newlimit); }
147 64      UNIMPL          reserved for unix/pc
148 65      UNIMPL          reserved for unix/pc
149 66      UNIMPL          reserved for unix/pc
150 67      UNIMPL          reserved for unix/pc
151 68      UNIMPL          reserved for unix/pc
152 69      UNIMPL          reserved for unix/pc
153 70      OBSOL           advfs
154 71      OBSOL           unadvfs
155 72      OBSOL           rmount
156 73      OBSOL           rumount
157 74      OBSOL           rfstart
158 75      OBSOL           sigret
159 76      OBSOL           rdebug
160 77      OBSOL           rfstop
161 78      UNIMPL          rfsys
162 79      NOARGS          { int|sys||rmdir(char *path); }
163 80      NOARGS          { int|sys||mkdir(char *path, int mode); }
164 81      STD             { int|svr4_sys||getdents(int fd, char *buf, \
165                             int nbytes); }
166 82      OBSOL           libattach
167 83      OBSOL           libdetach
168 84      UNIMPL          sysfs
169 85      STD             { int|svr4_sys||getmsg(int fd, struct svr4_strbuf *ctl, \
170                             struct svr4_strbuf *dat, int *flags); }
171 86      STD             { int|svr4_sys||putmsg(int fd, struct svr4_strbuf *ctl, \
172                             struct svr4_strbuf *dat, int flags); }
173 87      NOARGS          { int|sys||poll(struct pollfd *fds, u_int nfds, \
174                             int timeout); }
175 88      STD             { int|svr4_sys||lstat(const char *path, \
176                             struct svr4_stat *ub); }
177 89      NOARGS          { int|sys||symlink(char *path, char *link); }
178 90      NOARGS          { int|sys||readlink(char *path, char *buf, int count); }
179 91      NOARGS          { int|sys||getgroups(u_int gidsetsize, gid_t *gidset); }
180 92      NOARGS          { int|sys||setgroups(u_int gidsetsize, gid_t *gidset); }
181 93      NOARGS          { int|sys||fchmod(int fd, int mode); }
182 94      NOARGS          { int|sys||__posix_fchown(int fd, int uid, int gid); } \
183                             fchown
184 95      STD             { int|svr4_sys||sigprocmask(int how, \
185                             const svr4_sigset_t *set, \
186                             svr4_sigset_t *oset); }
187 96      STD             { int|svr4_sys||sigsuspend( \
188                             const svr4_sigset_t *set); }
189 97      STD             { int|svr4_sys||sigaltstack( \
190                             const struct svr4_sigaltstack *nss, \
191                             struct svr4_sigaltstack *oss); }
192 98      STD             { int|svr4_sys||sigaction(int signum, \
193                             const struct svr4_sigaction *nsa, \
194                             struct svr4_sigaction *osa); }
195 99      STD             { int|svr4_sys||sigpending(int what, \
196                             svr4_sigset_t *set); }
197 100     STD             { int|svr4_sys||context(int func, \
198                             struct svr4_ucontext *uc); }
199 101     UNIMPL          evsys
200 102     UNIMPL          evtrapret
201 103     STD             { int|svr4_sys||statvfs(const char *path, \
202                             struct svr4_statvfs *fs); }
203 104     STD             { int|svr4_sys||fstatvfs(int fd, \
204                             struct svr4_statvfs *fs); }
205 105     UNIMPL
206 106     UNIMPL          nfssvc
207 107     STD             { int|svr4_sys||waitsys(int grp, int id, \
208                             union svr4_siginfo *info, int options); }
209 108     UNIMPL          sigsendsys
210 109     STD             { int|svr4_sys||hrtsys(int cmd, int fun, int sub, \
211                             void *rv1, void *rv2); }
212 110     UNIMPL          acancel
213 111     UNIMPL          async
214 112     UNIMPL          priocntlsys
215 113     STD             { int|svr4_sys||pathconf(const char *path, int name); }
216 114     UNIMPL          mincore
217 115     STD             { void *|svr4_sys||mmap(void *addr, \
218                             svr4_size_t len, int prot, int flags, int fd, \
219                             svr4_off_t pos); }
220 116     NOARGS          { int|sys||mprotect(void *addr, int len, int prot); }
221 117     NOARGS          { int|sys||munmap(void *addr, int len); }
222 118     STD             { int|svr4_sys||fpathconf(int fd, int name); }
223 119     NOARGS          { int|sys||vfork(void); }
224 120     NOARGS          { int|sys||fchdir(int fd); }
225 121     NOARGS          { int|sys||readv(int fd, struct iovec *iovp, \
226                             u_int iovcnt); }
227 122     NOARGS          { int|sys||writev(int fd, struct iovec *iovp, \
228                             u_int iovcnt); }
229 123     STD             { int|svr4_sys||xstat(int two, const char *path, \
230                             struct svr4_xstat *ub); }
231 124     STD             { int|svr4_sys||lxstat(int two, const char *path, \
232                             struct svr4_xstat *ub); }
233 125     STD             { int|svr4_sys||fxstat(int two, int fd, \
234                             struct svr4_xstat *sb); }
235 126     STD             { int|svr4_sys||xmknod(int two, char *path, \
236                             svr4_mode_t mode, svr4_dev_t dev); }
237 127     UNIMPL          clocal
238 128     STD             { int|svr4_sys||setrlimit(int which, \
239                             const struct svr4_rlimit *rlp); }
240 129     STD             { int|svr4_sys||getrlimit(int which, \
241                             struct svr4_rlimit *rlp); }
242 130     NOARGS          { int|sys||__posix_lchown(char *path, int uid, \
243                             int gid); } lchown
244 131     STD             { int|svr4_sys||memcntl(void *addr, \
245                             svr4_size_t len, int cmd, void *arg, \
246                             int attr, int mask); }
247 132     UNIMPL          getpmsg
248 133     UNIMPL          putpmsg
249 134     NOARGS          { int|sys||__posix_rename(char *from, char *to); } \
250                             rename
251 135     STD             { int|svr4_sys||uname(struct svr4_utsname* name, \
252                             int dummy); }
253 136     NOARGS          { int|sys||setegid(gid_t egid); }
254 137     STD             { int|svr4_sys||sysconfig(int name); }
255 138     NOARGS          { int|compat_50_sys||adjtime(struct timeval50 *delta, \
256                             struct timeval50 *olddelta); }
257 139     STD             { long|svr4_sys||systeminfo(int what, char *buf, \
258                             long len); }
259 140     UNIMPL
260 141     NOARGS          { int|sys||seteuid(uid_t euid); }
261 142     UNIMPL          vtrace
262 143     NOARGS          { int|sys||fork(void); } fork1
263 144     UNIMPL          sigtimedwait
264 145     STD             { int|svr4_sys||_lwp_info(struct svr4_lwpinfo *lwpinfo);}
265 146     UNIMPL          yield
266 147     UNIMPL          lwp_sema_wait
267 148     UNIMPL          lwp_sema_post
268 149     UNIMPL          lwp_sema_trywait
269 150     UNIMPL
270 151     UNIMPL
271 152     UNIMPL          modctl
272 153     NOARGS          { int|sys||fchroot(int fd); }
273 154     STD             { int|svr4_sys||utimes(const char *path, \
274                             struct timeval50 *tptr); }
275 155     STD             { int|svr4_sys||vhangup(void); }
276 156     STD             { int|svr4_sys||gettimeofday(struct timeval50 *tp); }
277 157     NOARGS          { int|compat_50_sys||getitimer(u_int which, \
278                             struct itimerval50 *itv); }
279 158     NOARGS          { int|compat_50_sys||setitimer(u_int which, \
280                             struct itimerval50 *itv, struct itimerval50 *oitv); }
281 159     STD             { int|svr4_sys||_lwp_create(svr4_ucontext_t *uc, \
282                             unsigned long flags, svr4_lwpid_t *lwpid); }
283 160     STD             { int|svr4_sys||_lwp_exit(void); }
284 161     STD             { int|svr4_sys||_lwp_suspend(svr4_lwpid_t lwpid); }
285 162     STD             { int|svr4_sys||_lwp_continue(svr4_lwpid_t lwpid); }
286 163     STD             { int|svr4_sys||_lwp_kill(svr4_lwpid_t lwpid, \
287                             int signum); }
288 164     STD             { svr4_lwpid_t|svr4_sys||_lwp_self(void); }
289 165     STD             { void *|svr4_sys||_lwp_getprivate(void); }
290 166     STD             { int|svr4_sys||_lwp_setprivate(void *buffer); }
291 167     STD             { int|svr4_sys||_lwp_wait(svr4_lwpid_t wait_for, \
292                             svr4_lwpid_t *departed_lwp); }
293 168     UNIMPL          lwp_mutex_unlock
294 169     UNIMPL          lwp_mutex_lock
295 170     UNIMPL          lwp_cond_wait
296 171     UNIMPL          lwp_cond_signal
297 172     UNIMPL          lwp_cond_broadcast
298 173     STD             { ssize_t|svr4_sys||pread(int fd, void *buf, \
299                             size_t nbyte, svr4_off_t off); }
300 174     STD             { ssize_t|svr4_sys||pwrite(int fd, const void *buf, \
301                             size_t nbyte, svr4_off_t off); }
302 175     STD             { svr4_off64_t|svr4_sys||llseek(int fd, \
303                             long offset1, long offset2, int whence); }
304 176     UNIMPL          inst_sync
305 177     UNIMPL
306 178     UNIMPL          kaio
307 179     UNIMPL
308 180     UNIMPL
309 181     UNIMPL
310 182     UNIMPL
311 183     UNIMPL
312 184     UNIMPL          tsolsys
313 185     STD             { int|svr4_sys||acl(char *path, int cmd, int num, \
314                             struct svr4_aclent *buf); }
315 186     STD             { int|svr4_sys||auditsys(int code, int a1, int a2, \
316                             int a3, int a4, int a5); }
317 187     UNIMPL          processor_bind
318 188     UNIMPL          processor_info
319 189     UNIMPL          p_online
320 190     UNIMPL          sigqueue
321 191     UNIMPL          clock_gettime
322 192     UNIMPL          clock_settime
323 193     UNIMPL          clock_getres
324 194     UNIMPL          timer_create
325 195     UNIMPL          timer_delete
326 196     UNIMPL          timer_settime
327 197     UNIMPL          timer_gettime
328 198     UNIMPL          timer_getoverrun
329 199     NOARGS          { int|compat_50_sys||nanosleep( \
330                             const struct timespec50 *rqtp, \
331                             struct timespec50 *rmtp); }
332 200     STD             { int|svr4_sys||facl(int fd, int cmd, int num, \
333                             struct svr4_aclent *buf); }
334 201     UNIMPL          door
335 202     NOARGS          { int|sys||setreuid(int ruid, int euid); }
336 203     NOARGS          { int|sys||setregid(int rgid, int egid); }
337 204     UNIMPL          install_utrap
338 205     UNIMPL          signotify
339 206     STD             { int|svr4_sys||schedctl(unsigned int x, int y, void **z); }
340 207     UNIMPL          pset
341 208     UNIMPL
342 209     STD             { int|svr4_sys||resolvepath(const char *path, \
343                             char *buf, size_t bufsiz); }
344 210     UNIMPL          signotifywait
345 211     UNIMPL          lwp_sigredirect
346 212     UNIMPL          lwp_alarm
347 213     STD             { int|svr4_sys||getdents64(int fd, \
348                             struct svr4_dirent64 *dp, \
349                             int nbytes); }
350 214     STD             { void *|svr4_sys||mmap64(void *addr, \
351                             svr4_size_t len, int prot, int flags, int fd, \
352                             svr4_off64_t pos); }
353 215     STD             { int|svr4_sys||stat64(const char* path, \
354                             struct svr4_stat64 *sb); }
355 216     STD             { int|svr4_sys||lstat64(const char* path, \
356                             struct svr4_stat64 *sb); }
357 217     STD             { int|svr4_sys||fstat64(int fd, \
358                             struct svr4_stat64 *sb); }
359 218     STD             { int|svr4_sys||statvfs64(const char *path, \
360                             struct svr4_statvfs64 *fs); }
361 219     STD             { int|svr4_sys||fstatvfs64(int fd, \
362                             struct svr4_statvfs64 *fs); }
363 220     STD             { int|svr4_sys||setrlimit64(int which, \
364                             const struct svr4_rlimit64 *rlp); }
365 221     STD             { int|svr4_sys||getrlimit64(int which, \
366                             struct svr4_rlimit64 *rlp); }
367 222     STD             { ssize_t|svr4_sys||pread64(int fd, void *buf, \
368                             size_t nbyte, svr4_off64_t off); }
369 223     STD             { ssize_t|svr4_sys||pwrite64(int fd, \
370                             const void *buf, size_t nbyte, svr4_off64_t off); }
371 224     STD             { int|svr4_sys||creat64(char *path, int mode); }
372 225     STD             { int|svr4_sys||open64(char *path, int flags, \
373                             int mode); }
374 226     UNIMPL          rpcsys
375 227     UNIMPL
376 228     UNIMPL
377 229     UNIMPL
378 230     STD             { int|svr4_sys||socket(int domain, int type, \
379                             int protocol); }
380 231     NOARGS          { int|sys||socketpair(int domain, int type, \
381                             int protocol, int *rsv); }
382 232     NOARGS          { int|sys||bind(int s, const struct sockaddr *name, \
383                             int namelen); }
384 233     NOARGS          { int|sys||listen(int s, int backlog); }
385 234     NOARGS          { int|compat_43_sys||accept(int s, \
386                             struct sockaddr *name, int *anamelen); }
387 235     NOARGS          { int|sys||connect(int s, const struct sockaddr *name, \
388                             int namelen); }
389 236     NOARGS          { int|sys||shutdown(int s, int how); }
390 237     NOARGS          { int|compat_43_sys||recv(int s, void *buf, int len, \
391                             int flags); }
392 238     NOARGS          { ssize_t|compat_43_sys||recvfrom(int s, void *buf, \
393                             size_t len, int flags, struct sockaddr *from, \
394                             int *fromlenaddr); }
395 239     NOARGS          { ssize_t|compat_43_sys||recvmsg(int s, \
396                             struct msghdr *msg, int flags); }
397 240     NOARGS          { int|compat_43_sys||send(int s, void *buf, int len, \
398                             int flags); }
399 241     NOARGS          { ssize_t|compat_43_sys||sendmsg(int s, \
400                             const struct msghdr *msg, int flags); }
401 242     NOARGS          { ssize_t|sys||sendto(int s, const void *buf, \
402                             size_t len, int flags, const struct sockaddr *to, \
403                             int tolen); }
404 243     NOARGS          { int|compat_43_sys||getpeername(int fdes, \
405                             struct sockaddr *asa, int *alen); }
406 244     NOARGS          { int|compat_43_sys||getsockname(int fdes, \
407                             struct sockaddr *asa, int *alen); }
408 245     NOARGS          { int|sys||getsockopt(int s, int level, int name, \
409                             void *val, int *avalsize); }
410 246     NOARGS          { int|sys||setsockopt(int s, int level, int name, \
411                             const void *val, int valsize); }
412 247     UNIMPL          sockconfig
413 248     UNIMPL          sys_ntp_gettime
414 #if defined(NTP) || !defined(_KERNEL)
415 249     NOARGS          { int|sys||ntp_adjtime(struct timex *tp); }
416 #else
417 249     EXCL            ntp_adjtime
418 #endif
419 250     UNIMPL          lwp_mutex_unlock
420 251     UNIMPL          lwp_mutex_trylock
421 252     UNIMPL          lwp_mutex_init
422 253     UNIMPL          cladm
423 254     UNIMPL          lwp_sigtimedwait
424 255     UNIMPL          umount2