syscalls.master revision 59288
1248590Smm $FreeBSD: head/sys/kern/syscalls.master 59288 2000-04-16 18:53:38Z jlemon $
2248590Smm;	from: @(#)syscalls.master	8.2 (Berkeley) 1/13/94
3248590Smm;
4248590Smm; System call name/number master file.
5248590Smm; Processed to created init_sysent.c, syscalls.c and syscall.h.
6248590Smm
7248590Smm; Columns: number [MPSAFE] type nargs namespc name alt{name,tag,rtyp}/comments
8248590Smm;	number	system call number, must be in order
9248590Smm;   MPSAFE	optional field, specifies that syscall does not want the
10248590Smm;		BGL grabbed automatically (it is SMP safe).
11248590Smm;	type	one of STD, OBSOL, UNIMPL, COMPAT, CPT_NOA, LIBCOMPAT,
12248590Smm;		NODEF, NOARGS, NOPROTO, NOIMPL
13248590Smm;	namespc one of POSIX, BSD, NOHIDE
14248590Smm;	name	psuedo-prototype of syscall routine
15248590Smm;		If one of the following alts is different, then all appear:
16248590Smm;	altname	name of system call if different
17248590Smm;	alttag	name of args struct tag if different from [o]`name'"_args"
18248590Smm;	altrtyp	return type if not int (bogus - syscalls always return int)
19248590Smm;		for UNIMPL/OBSOL, name continues with comments
20248590Smm
21248590Smm; types:
22248590Smm;	STD	always included
23248590Smm;	COMPAT	included on COMPAT #ifdef
24248590Smm;	LIBCOMPAT included on COMPAT #ifdef, and placed in syscall.h
25248590Smm;	OBSOL	obsolete, not included in system, only specifies name
26248590Smm;	UNIMPL	not implemented, placeholder only
27248590Smm
28248590Smm; #ifdef's, etc. may be included, and are copied to the output files.
29248590Smm
30248590Smm#include <sys/param.h>
31248590Smm#include <sys/sysent.h>
32248590Smm#include <sys/sysproto.h>
33248590Smm
34248590Smm; Reserved/unimplemented system calls in the range 0-150 inclusive
35248590Smm; are reserved for use in future Berkeley releases.
36248590Smm; Additional system calls implemented in vendor and other
37248590Smm; redistributions should be placed in the reserved range at the end
38248590Smm; of the current calls.
39248590Smm
40248590Smm0	STD	NOHIDE	{ int nosys(void); } syscall nosys_args int
41248590Smm1	STD	NOHIDE	{ void exit(int rval); } exit rexit_args void
42248590Smm2	STD	POSIX	{ int fork(void); }
43248590Smm3	STD	POSIX	{ ssize_t read(int fd, void *buf, size_t nbyte); }
44248590Smm4	STD	POSIX	{ ssize_t write(int fd, const void *buf, size_t nbyte); }
45248590Smm5	STD	POSIX	{ int open(char *path, int flags, int mode); }
46248590Smm; XXX should be		{ int open(const char *path, int flags, ...); }
47248590Smm; but we're not ready for `const' or varargs.
48248590Smm; XXX man page says `mode_t mode'.
49248590Smm6	STD	POSIX	{ int close(int fd); }
50248590Smm7	STD	BSD	{ int wait4(int pid, int *status, int options, \
51248590Smm			    struct rusage *rusage); } wait4 wait_args int
52248590Smm8	COMPAT	BSD	{ int creat(char *path, int mode); }
53248590Smm9	STD	POSIX	{ int link(char *path, char *link); }
54248590Smm10	STD	POSIX	{ int unlink(char *path); }
55248590Smm11	OBSOL	NOHIDE	execv
56248590Smm12	STD	POSIX	{ int chdir(char *path); }
57248590Smm13	STD	BSD	{ int fchdir(int fd); }
58248590Smm14	STD	POSIX	{ int mknod(char *path, int mode, int dev); }
59248590Smm15	STD	POSIX	{ int chmod(char *path, int mode); }
60248590Smm16	STD	POSIX	{ int chown(char *path, int uid, int gid); }
61248590Smm17	STD	BSD	{ int obreak(char *nsize); } break obreak_args int
62248590Smm18	STD	BSD	{ int getfsstat(struct statfs *buf, long bufsize, \
63248590Smm			    int flags); }
64248590Smm19	COMPAT	POSIX	{ long lseek(int fd, long offset, int whence); }
65248590Smm20	STD	POSIX	{ pid_t getpid(void); }
66248590Smm21	STD	BSD	{ int mount(char *type, char *path, int flags, \
67248590Smm			    caddr_t data); }
68248590Smm; XXX 4.4lite2 uses `char *type' but we're not ready for that.
69248590Smm; XXX `path' should have type `const char *' but we're not ready for that.
70248590Smm22	STD	BSD	{ int unmount(char *path, int flags); }
71248590Smm23	STD	POSIX	{ int setuid(uid_t uid); }
72248590Smm24	MPSAFE	STD	POSIX	{ uid_t getuid(void); }
73248590Smm25	MPSAFE	STD	POSIX	{ uid_t geteuid(void); }
74248590Smm26	STD	BSD	{ int ptrace(int req, pid_t pid, caddr_t addr, \
75248590Smm			    int data); }
76248590Smm27	STD	BSD	{ int recvmsg(int s, struct msghdr *msg, int flags); }
77248590Smm28	STD	BSD	{ int sendmsg(int s, caddr_t msg, int flags); }
78248590Smm29	STD	BSD	{ int recvfrom(int s, caddr_t buf, size_t len, \
79248590Smm			    int flags, caddr_t from, int *fromlenaddr); }
80248590Smm30	STD	BSD	{ int accept(int s, caddr_t name, int *anamelen); }
81248590Smm31	STD	BSD	{ int getpeername(int fdes, caddr_t asa, int *alen); }
82248590Smm32	STD	BSD	{ int getsockname(int fdes, caddr_t asa, int *alen); }
83248590Smm33	STD	POSIX	{ int access(char *path, int flags); }
84248590Smm34	STD	BSD	{ int chflags(char *path, int flags); }
85248590Smm35	STD	BSD	{ int fchflags(int fd, int flags); }
86248590Smm36	STD	BSD	{ int sync(void); }
87248590Smm37	STD	POSIX	{ int kill(int pid, int signum); }
88248590Smm38	COMPAT	POSIX	{ int stat(char *path, struct ostat *ub); }
89248590Smm39	STD	POSIX	{ pid_t getppid(void); }
90248590Smm40	COMPAT	POSIX	{ int lstat(char *path, struct ostat *ub); }
91248590Smm41	STD	POSIX	{ int dup(u_int fd); }
92248590Smm42	STD	POSIX	{ int pipe(void); }
93248590Smm43	STD	POSIX	{ gid_t getegid(void); }
94248590Smm44	STD	BSD	{ int profil(caddr_t samples, size_t size, \
95248590Smm			    size_t offset, u_int scale); }
96248590Smm45	STD	BSD	{ int ktrace(const char *fname, int ops, int facs, \
97248590Smm			    int pid); }
98248590Smm46	COMPAT	POSIX	{ int sigaction(int signum, struct osigaction *nsa, \
99248590Smm			    struct osigaction *osa); }
100248590Smm47	MPSAFE	STD	POSIX	{ gid_t getgid(void); }
101248590Smm48	MPSAFE	COMPAT	POSIX	{ int sigprocmask(int how, osigset_t mask); }
102248590Smm; XXX note nonstandard (bogus) calling convention - the libc stub passes
103248590Smm; us the mask, not a pointer to it, and we return the old mask as the
104248590Smm; (int) return value.
105248590Smm49	STD	BSD	{ int getlogin(char *namebuf, u_int namelen); }
106248590Smm50	STD	BSD	{ int setlogin(char *namebuf); }
107248590Smm51	STD	BSD	{ int acct(char *path); }
108248590Smm52	COMPAT	POSIX	{ int sigpending(void); }
109248590Smm53	STD	BSD	{ int sigaltstack(stack_t *ss, stack_t *oss); }
110248590Smm54	STD	POSIX	{ int ioctl(int fd, u_long com, caddr_t data); }
111248590Smm55	STD	BSD	{ int reboot(int opt); }
112248590Smm56	STD	POSIX	{ int revoke(char *path); }
113248590Smm57	STD	POSIX	{ int symlink(char *path, char *link); }
114248590Smm58	STD	POSIX	{ int readlink(char *path, char *buf, int count); }
115248590Smm59	STD	POSIX	{ int execve(char *fname, char **argv, char **envv); }
116248590Smm60	MPSAFE	STD	POSIX	{ int umask(int newmask); } umask umask_args int
117248590Smm61	STD	BSD	{ int chroot(char *path); }
118248590Smm62	COMPAT	POSIX	{ int fstat(int fd, struct ostat *sb); }
119248590Smm63	COMPAT	BSD	{ int getkerninfo(int op, char *where, size_t *size, \
120248590Smm			    int arg); } getkerninfo getkerninfo_args int
121248590Smm64	COMPAT	BSD	{ int getpagesize(void); } \
122248590Smm			    getpagesize getpagesize_args int
123248590Smm65	STD	BSD	{ int msync(void *addr, size_t len, int flags); }
124248590Smm66	STD	BSD	{ int vfork(void); }
125248590Smm67	OBSOL	NOHIDE	vread
126248590Smm68	OBSOL	NOHIDE	vwrite
127248590Smm69	STD	BSD	{ int sbrk(int incr); }
128248590Smm70	STD	BSD	{ int sstk(int incr); }
129248590Smm71	COMPAT	BSD	{ int mmap(void *addr, int len, int prot, \
130248590Smm			    int flags, int fd, long pos); }
131248590Smm72	STD	BSD	{ int ovadvise(int anom); } vadvise ovadvise_args int
132248590Smm73	STD	BSD	{ int munmap(void *addr, size_t len); }
133248590Smm74	STD	BSD	{ int mprotect(const void *addr, size_t len, int prot); }
134248590Smm75	STD	BSD	{ int madvise(void *addr, size_t len, int behav); }
135248590Smm76	OBSOL	NOHIDE	vhangup
136248590Smm77	OBSOL	NOHIDE	vlimit
137248590Smm78	STD	BSD	{ int mincore(const void *addr, size_t len, \
138248590Smm			    char *vec); }
139248590Smm79	STD	POSIX	{ int getgroups(u_int gidsetsize, gid_t *gidset); }
140248590Smm80	STD	POSIX	{ int setgroups(u_int gidsetsize, gid_t *gidset); }
141248590Smm81	MPSAFE	STD	POSIX	{ int getpgrp(void); }
142248590Smm82	STD	POSIX	{ int setpgid(int pid, int pgid); }
143248590Smm83	STD	BSD	{ int setitimer(u_int which, struct itimerval *itv, \
144248590Smm			    struct itimerval *oitv); }
145248590Smm84	COMPAT	BSD	{ int wait(void); }
146248590Smm85	STD	BSD	{ int swapon(char *name); }
147248590Smm86	STD	BSD	{ int getitimer(u_int which, struct itimerval *itv); }
148248590Smm87	COMPAT	BSD	{ int gethostname(char *hostname, u_int len); } \
149248590Smm			    gethostname gethostname_args int
150248590Smm88	COMPAT	BSD	{ int sethostname(char *hostname, u_int len); } \
151248590Smm			    sethostname sethostname_args int
152248590Smm89	STD	BSD	{ int getdtablesize(void); }
153248590Smm90	STD	POSIX	{ int dup2(u_int from, u_int to); }
154248590Smm91	UNIMPL	BSD	getdopt
155248590Smm92	STD	POSIX	{ int fcntl(int fd, int cmd, long arg); }
156248590Smm; XXX should be		{ int fcntl(int fd, int cmd, ...); }
157248590Smm; but we're not ready for varargs.
158248590Smm; XXX man page says `int arg' too.
159248590Smm93	STD	BSD	{ int select(int nd, fd_set *in, fd_set *ou, \
160248590Smm			    fd_set *ex, struct timeval *tv); }
161248590Smm94	UNIMPL	BSD	setdopt
162248590Smm95	STD	POSIX	{ int fsync(int fd); }
163248590Smm96	STD	BSD	{ int setpriority(int which, int who, int prio); }
164248590Smm97	STD	BSD	{ int socket(int domain, int type, int protocol); }
165248590Smm98	STD	BSD	{ int connect(int s, caddr_t name, int namelen); }
166248590Smm99	CPT_NOA	BSD	{ int accept(int s, caddr_t name, int *anamelen); } \
167248590Smm			    accept accept_args int
168248590Smm100	STD	BSD	{ int getpriority(int which, int who); }
169248590Smm101	COMPAT	BSD	{ int send(int s, caddr_t buf, int len, int flags); }
170248590Smm102	COMPAT	BSD	{ int recv(int s, caddr_t buf, int len, int flags); }
171248590Smm103	COMPAT	BSD	{ int sigreturn(struct osigcontext *sigcntxp); }
172248590Smm104	STD	BSD	{ int bind(int s, caddr_t name, int namelen); }
173248590Smm105	STD	BSD	{ int setsockopt(int s, int level, int name, \
174248590Smm			    caddr_t val, int valsize); }
175248590Smm106	STD	BSD	{ int listen(int s, int backlog); }
176248590Smm107	OBSOL	NOHIDE	vtimes
177248590Smm108	COMPAT	BSD	{ int sigvec(int signum, struct sigvec *nsv, \
178248590Smm			    struct sigvec *osv); }
179248590Smm109	COMPAT	BSD	{ int sigblock(int mask); }
180248590Smm110	COMPAT	BSD	{ int sigsetmask(int mask); }
181248590Smm111	COMPAT	POSIX	{ int sigsuspend(osigset_t mask); }
182248590Smm; XXX note nonstandard (bogus) calling convention - the libc stub passes
183248590Smm; us the mask, not a pointer to it.
184248590Smm112	COMPAT	BSD	{ int sigstack(struct sigstack *nss, \
185248590Smm			    struct sigstack *oss); }
186248590Smm113	COMPAT	BSD	{ int recvmsg(int s, struct omsghdr *msg, int flags); }
187248590Smm114	COMPAT	BSD	{ int sendmsg(int s, caddr_t msg, int flags); }
188248590Smm115	OBSOL	NOHIDE	vtrace
189248590Smm116	STD	BSD	{ int gettimeofday(struct timeval *tp, \
190248590Smm			    struct timezone *tzp); }
191248590Smm117	STD	BSD	{ int getrusage(int who, struct rusage *rusage); }
192248590Smm118	STD	BSD	{ int getsockopt(int s, int level, int name, \
193248590Smm			    caddr_t val, int *avalsize); }
194248590Smm119	UNIMPL	NOHIDE	resuba (BSD/OS 2.x)
195248590Smm120	STD	BSD	{ int readv(int fd, struct iovec *iovp, u_int iovcnt); }
196248590Smm121	STD	BSD	{ int writev(int fd, struct iovec *iovp, \
197248590Smm			    u_int iovcnt); }
198248590Smm122	STD	BSD	{ int settimeofday(struct timeval *tv, \
199248590Smm			    struct timezone *tzp); }
200248590Smm123	STD	BSD	{ int fchown(int fd, int uid, int gid); }
201248590Smm124	STD	BSD	{ int fchmod(int fd, int mode); }
202248590Smm125	CPT_NOA	BSD	{ int recvfrom(int s, caddr_t buf, size_t len, \
203248590Smm			    int flags, caddr_t from, int *fromlenaddr); } \
204248590Smm			    recvfrom recvfrom_args int
205248590Smm126	STD	BSD	{ int setreuid(int ruid, int euid); }
206248590Smm127	STD	BSD	{ int setregid(int rgid, int egid); }
207248590Smm128	STD	POSIX	{ int rename(char *from, char *to); }
208248590Smm129	COMPAT	BSD	{ int truncate(char *path, long length); }
209248590Smm130	COMPAT	BSD	{ int ftruncate(int fd, long length); }
210248590Smm131	STD	BSD	{ int flock(int fd, int how); }
211248590Smm132	STD	POSIX	{ int mkfifo(char *path, int mode); }
212248590Smm133	STD	BSD	{ int sendto(int s, caddr_t buf, size_t len, \
213248590Smm			    int flags, caddr_t to, int tolen); }
214248590Smm134	STD	BSD	{ int shutdown(int s, int how); }
215248590Smm135	STD	BSD	{ int socketpair(int domain, int type, int protocol, \
216248590Smm			    int *rsv); }
217248590Smm136	STD	POSIX	{ int mkdir(char *path, int mode); }
218248590Smm137	STD	POSIX	{ int rmdir(char *path); }
219248590Smm138	STD	BSD	{ int utimes(char *path, struct timeval *tptr); }
220248590Smm139	OBSOL	NOHIDE	4.2 sigreturn
221248590Smm140	STD	BSD	{ int adjtime(struct timeval *delta, \
222248590Smm			    struct timeval *olddelta); }
223248590Smm141	COMPAT	BSD	{ int getpeername(int fdes, caddr_t asa, int *alen); }
224248590Smm142	COMPAT	BSD	{ long gethostid(void); }
225248590Smm143	COMPAT	BSD	{ int sethostid(long hostid); }
226248590Smm144	COMPAT	BSD	{ int getrlimit(u_int which, struct ogetrlimit *rlp); }
227248590Smm145	COMPAT	BSD	{ int setrlimit(u_int which, struct ogetrlimit *rlp); }
228248590Smm146	COMPAT	BSD	{ int killpg(int pgid, int signum); }
229248590Smm147	STD	POSIX	{ int setsid(void); }
230248590Smm148	STD	BSD	{ int quotactl(char *path, int cmd, int uid, \
231248590Smm			    caddr_t arg); }
232248590Smm149	COMPAT	BSD	{ int quota(void); }
233248590Smm150	CPT_NOA	BSD	{ int getsockname(int fdec, caddr_t asa, int *alen); }\
234248590Smm			    getsockname getsockname_args int
235248590Smm
236248590Smm; Syscalls 151-180 inclusive are reserved for vendor-specific
237248590Smm; system calls.  (This includes various calls added for compatibity
238248590Smm; with other Unix variants.)
239248590Smm; Some of these calls are now supported by BSD...
240248590Smm151	UNIMPL	NOHIDE	sem_lock (BSD/OS 2.x)
241248590Smm152	UNIMPL	NOHIDE	sem_wakeup (BSD/OS 2.x)
242248590Smm153	UNIMPL	NOHIDE	asyncdaemon (BSD/OS 2.x)
243248590Smm154	UNIMPL	NOHIDE	nosys
244248590Smm; 155 is initialized by the NFS code, if present.
245248590Smm155	NOIMPL	BSD	{ int nfssvc(int flag, caddr_t argp); }
246248590Smm156	COMPAT	BSD	{ int getdirentries(int fd, char *buf, u_int count, \
247248590Smm			    long *basep); }
248248590Smm157	STD	BSD	{ int statfs(char *path, struct statfs *buf); }
249248590Smm158	STD	BSD	{ int fstatfs(int fd, struct statfs *buf); }
250248590Smm159	UNIMPL	NOHIDE	nosys
251248590Smm160	UNIMPL	NOHIDE	nosys
252248590Smm; 161 is initialized by the NFS code, if present.
253248590Smm161	STD	BSD	{ int getfh(char *fname, struct fhandle *fhp); }
254248590Smm162	STD	BSD	{ int getdomainname(char *domainname, int len); }
255248590Smm163	STD	BSD	{ int setdomainname(char *domainname, int len); }
256248590Smm164	STD	BSD	{ int uname(struct utsname *name); }
257248590Smm165	STD	BSD	{ int sysarch(int op, char *parms); }
258248590Smm166	STD	BSD	{ int rtprio(int function, pid_t pid, \
259248590Smm			    struct rtprio *rtp); }
260248590Smm167	UNIMPL	NOHIDE	nosys
261248590Smm168	UNIMPL	NOHIDE	nosys
262248590Smm169	STD	BSD	{ int semsys(int which, int a2, int a3, int a4, \
263248590Smm			    int a5); }
264248590Smm; XXX should be		{ int semsys(int which, ...); }
265248590Smm170	STD	BSD	{ int msgsys(int which, int a2, int a3, int a4, \
266248590Smm			    int a5, int a6); }
267248590Smm; XXX should be		{ int msgsys(int which, ...); }
268248590Smm171	STD	BSD	{ int shmsys(int which, int a2, int a3, int a4); }
269248590Smm; XXX should be		{ int shmsys(int which, ...); }
270248590Smm172	UNIMPL	NOHIDE	nosys
271248590Smm173	STD	POSIX	{ ssize_t pread(int fd, void *buf, size_t nbyte, \
272248590Smm			    int pad, off_t offset); }
273248590Smm174	STD	POSIX	{ ssize_t pwrite(int fd, const void *buf, \
274248590Smm			    size_t nbyte, int pad, off_t offset); }
275248590Smm175	UNIMPL	NOHIDE	nosys
276248590Smm176	STD	BSD	{ int ntp_adjtime(struct timex *tp); }
277248590Smm177	UNIMPL	NOHIDE	sfork (BSD/OS 2.x)
278248590Smm178	UNIMPL	NOHIDE	getdescriptor (BSD/OS 2.x)
279248590Smm179	UNIMPL	NOHIDE	setdescriptor (BSD/OS 2.x)
280248590Smm180	UNIMPL	NOHIDE	nosys
281248590Smm
282248590Smm; Syscalls 181-199 are used by/reserved for BSD
283248590Smm181	STD	POSIX	{ int setgid(gid_t gid); }
284248590Smm182	STD	BSD	{ int setegid(gid_t egid); }
285248590Smm183	STD	BSD	{ int seteuid(uid_t euid); }
286248590Smm184	UNIMPL	BSD	lfs_bmapv
287248590Smm185	UNIMPL	BSD	lfs_markv
288248590Smm186	UNIMPL	BSD	lfs_segclean
289248590Smm187	UNIMPL	BSD	lfs_segwait
290248590Smm188	STD	POSIX	{ int stat(char *path, struct stat *ub); }
291248590Smm189	STD	POSIX	{ int fstat(int fd, struct stat *sb); }
292248590Smm190	STD	POSIX	{ int lstat(char *path, struct stat *ub); }
293248590Smm191	STD	POSIX	{ int pathconf(char *path, int name); }
294248590Smm192	STD	POSIX	{ int fpathconf(int fd, int name); }
295248590Smm193	UNIMPL	NOHIDE	nosys
296248590Smm194	STD	BSD	{ int getrlimit(u_int which, \
297248590Smm			    struct orlimit *rlp); } \
298248590Smm			    getrlimit __getrlimit_args int
299248590Smm195	STD	BSD	{ int setrlimit(u_int which, \
300248590Smm			    struct orlimit *rlp); } \
301248590Smm			    setrlimit __setrlimit_args int
302248590Smm196	STD	BSD	{ int getdirentries(int fd, char *buf, u_int count, \
303248590Smm			    long *basep); }
304248590Smm197	STD	BSD	{ caddr_t mmap(caddr_t addr, size_t len, int prot, \
305248590Smm			    int flags, int fd, long pad, off_t pos); }
306248590Smm198	STD	NOHIDE	{ int nosys(void); } __syscall __syscall_args int
307248590Smm199	STD	POSIX	{ off_t lseek(int fd, int pad, off_t offset, \
308248590Smm			    int whence); }
309248590Smm200	STD	BSD	{ int truncate(char *path, int pad, off_t length); }
310248590Smm201	STD	BSD	{ int ftruncate(int fd, int pad, off_t length); }
311248590Smm202	STD	BSD	{ int __sysctl(int *name, u_int namelen, void *old, \
312248590Smm			    size_t *oldlenp, void *new, size_t newlen); } \
313248590Smm			    __sysctl sysctl_args int
314248590Smm; properly, __sysctl should be a NOHIDE, but making an exception
315248590Smm; here allows to avoid one in libc/sys/Makefile.inc.
316248590Smm203	STD	BSD	{ int mlock(const void *addr, size_t len); }
317248590Smm204	STD	BSD	{ int munlock(const void *addr, size_t len); }
318248590Smm205	STD	BSD	{ int undelete(char *path); }
319248590Smm206	STD	BSD	{ int futimes(int fd, struct timeval *tptr); }
320248590Smm207	STD	BSD	{ int getpgid(pid_t pid); }
321248590Smm208	UNIMPL	NOHIDE	newreboot (NetBSD)
322248590Smm209	STD	BSD	{ int poll(struct pollfd *fds, u_int nfds, \
323248590Smm			    int timeout); }
324248590Smm
325248590Smm;
326248590Smm; The following are reserved for loadable syscalls
327248590Smm;
328248590Smm210	NODEF	NOHIDE	lkmnosys lkmnosys nosys_args int
329248590Smm211	NODEF	NOHIDE	lkmnosys lkmnosys nosys_args int
330248590Smm212	NODEF	NOHIDE	lkmnosys lkmnosys nosys_args int
331248590Smm213	NODEF	NOHIDE	lkmnosys lkmnosys nosys_args int
332248590Smm214	NODEF	NOHIDE	lkmnosys lkmnosys nosys_args int
333248590Smm215	NODEF	NOHIDE	lkmnosys lkmnosys nosys_args int
334248590Smm216	NODEF	NOHIDE	lkmnosys lkmnosys nosys_args int
335248590Smm217	NODEF	NOHIDE	lkmnosys lkmnosys nosys_args int
336248590Smm218	NODEF	NOHIDE	lkmnosys lkmnosys nosys_args int
337248590Smm219	NODEF	NOHIDE	lkmnosys lkmnosys nosys_args int
338248590Smm
339248590Smm;
340248590Smm; The following were introduced with NetBSD/4.4Lite-2
341248590Smm;
342248590Smm220	STD	BSD	{ int __semctl(int semid, int semnum, int cmd, \
343248590Smm			    union semun *arg); }
344248590Smm221	STD	BSD	{ int semget(key_t key, int nsems, int semflg); }
345248590Smm222	STD	BSD	{ int semop(int semid, struct sembuf *sops, \
346248590Smm			    u_int nsops); }
347248590Smm223	STD	BSD	{ int semconfig(int flag); }
348248590Smm224	STD	BSD	{ int msgctl(int msqid, int cmd, \
349248590Smm			    struct msqid_ds *buf); }
350248590Smm225	STD	BSD	{ int msgget(key_t key, int msgflg); }
351248590Smm226	STD	BSD	{ int msgsnd(int msqid, void *msgp, size_t msgsz, \
352248590Smm			    int msgflg); }
353248590Smm227	STD	BSD	{ int msgrcv(int msqid, void *msgp, size_t msgsz, \
354248590Smm			    long msgtyp, int msgflg); }
355248590Smm228	STD	BSD	{ int shmat(int shmid, void *shmaddr, int shmflg); }
356248590Smm229	STD	BSD	{ int shmctl(int shmid, int cmd, \
357248590Smm			    struct shmid_ds *buf); }
358248590Smm230	STD	BSD	{ int shmdt(void *shmaddr); }
359248590Smm231	STD	BSD	{ int shmget(key_t key, int size, int shmflg); }
360248590Smm;
361248590Smm232	STD	POSIX	{ int clock_gettime(clockid_t clock_id, \
362248590Smm			    struct timespec *tp); }
363248590Smm233	STD	POSIX	{ int clock_settime(clockid_t clock_id, \
364248590Smm			    const struct timespec *tp); }
365248590Smm234	STD	POSIX	{ int clock_getres(clockid_t clock_id, \
366248590Smm			    struct timespec *tp); }
367248590Smm235	UNIMPL	NOHIDE	timer_create
368248590Smm236	UNIMPL	NOHIDE	timer_delete
369248590Smm237	UNIMPL	NOHIDE	timer_settime
370248590Smm238	UNIMPL	NOHIDE	timer_gettime
371248590Smm239	UNIMPL	NOHIDE	timer_getoverrun
372248590Smm240	STD	POSIX	{ int nanosleep(const struct timespec *rqtp, \
373248590Smm			    struct timespec *rmtp); }
374248590Smm241	UNIMPL	NOHIDE	nosys
375248590Smm242	UNIMPL	NOHIDE	nosys
376248590Smm243	UNIMPL	NOHIDE	nosys
377248590Smm244	UNIMPL	NOHIDE	nosys
378248590Smm245	UNIMPL	NOHIDE	nosys
379248590Smm246	UNIMPL	NOHIDE	nosys
380248590Smm247	UNIMPL	NOHIDE	nosys
381248590Smm248	UNIMPL	NOHIDE	nosys
382248590Smm249	UNIMPL	NOHIDE	nosys
383248590Smm; syscall numbers initially used in OpenBSD
384248590Smm250	STD	BSD	{ int minherit(void *addr, size_t len, int inherit); }
385248590Smm251	STD	BSD	{ int rfork(int flags); }
386248590Smm252	STD	BSD	{ int openbsd_poll(struct pollfd *fds, u_int nfds, \
387248590Smm			    int timeout); }
388248590Smm253	STD	BSD	{ int issetugid(void); }
389248590Smm254	STD	BSD	{ int lchown(char *path, int uid, int gid); }
390248590Smm255	UNIMPL	NOHIDE	nosys
391248590Smm256	UNIMPL	NOHIDE	nosys
392248590Smm257	UNIMPL	NOHIDE	nosys
393248590Smm258	UNIMPL	NOHIDE	nosys
394248590Smm259	UNIMPL	NOHIDE	nosys
395248590Smm260	UNIMPL	NOHIDE	nosys
396248590Smm261	UNIMPL	NOHIDE	nosys
397248590Smm262	UNIMPL	NOHIDE	nosys
398248590Smm263	UNIMPL	NOHIDE	nosys
399248590Smm264	UNIMPL	NOHIDE	nosys
400248590Smm265	UNIMPL	NOHIDE	nosys
401248590Smm266	UNIMPL	NOHIDE	nosys
402248590Smm267	UNIMPL	NOHIDE	nosys
403248590Smm268	UNIMPL	NOHIDE	nosys
404248590Smm269	UNIMPL	NOHIDE	nosys
405248590Smm270	UNIMPL	NOHIDE	nosys
406248590Smm271	UNIMPL	NOHIDE	nosys
407248590Smm272	STD	BSD	{ int getdents(int fd, char *buf, size_t count); }
408248590Smm273	UNIMPL	NOHIDE	nosys
409248590Smm274	STD	BSD	{ int lchmod(char *path, mode_t mode); }
410248590Smm275	NOPROTO BSD	{ int lchown(char *path, uid_t uid, gid_t gid); } netbsd_lchown netbsd_lchown int
411248590Smm276	STD	BSD	{ int lutimes(char *path, struct timeval *tptr); }
412248590Smm277	NOPROTO	BSD	{ int msync(void *addr, size_t len, int flags); } netbsd_msync netbsd_msync int
413248590Smm278	STD	BSD	{ int nstat(char *path, struct nstat *ub); }
414248590Smm279	STD	BSD	{ int nfstat(int fd, struct nstat *sb); }
415248590Smm280	STD	BSD	{ int nlstat(char *path, struct nstat *ub); }
416248590Smm281	UNIMPL	NOHIDE	nosys
417248590Smm282	UNIMPL	NOHIDE	nosys
418248590Smm283	UNIMPL	NOHIDE	nosys
419248590Smm284	UNIMPL	NOHIDE	nosys
420248590Smm285	UNIMPL	NOHIDE	nosys
421248590Smm286	UNIMPL	NOHIDE	nosys
422248590Smm287	UNIMPL	NOHIDE	nosys
423248590Smm288	UNIMPL	NOHIDE	nosys
424248590Smm289	UNIMPL	NOHIDE	nosys
425248590Smm290	UNIMPL	NOHIDE	nosys
426248590Smm291	UNIMPL	NOHIDE	nosys
427248590Smm292	UNIMPL	NOHIDE	nosys
428248590Smm293	UNIMPL	NOHIDE	nosys
429248590Smm294	UNIMPL	NOHIDE	nosys
430248590Smm295	UNIMPL	NOHIDE	nosys
431248590Smm296	UNIMPL	NOHIDE	nosys
432248590Smm; XXX 297 is 300 in NetBSD 
433248590Smm297	STD	BSD	{ int fhstatfs(const struct fhandle *u_fhp, struct statfs *buf); }
434248590Smm298	STD	BSD	{ int fhopen(const struct fhandle *u_fhp, int flags); }
435248590Smm299	STD	BSD 	{ int fhstat(const struct fhandle *u_fhp, struct stat *sb); }
436248590Smm; syscall numbers for FreeBSD
437248590Smm300	STD	BSD	{ int modnext(int modid); }
438248590Smm301	STD	BSD	{ int modstat(int modid, struct module_stat* stat); }
439248590Smm302	STD	BSD	{ int modfnext(int modid); }
440248590Smm303	STD	BSD	{ int modfind(const char *name); }
441248590Smm304	STD	BSD	{ int kldload(const char *file); }
442248590Smm305	STD	BSD	{ int kldunload(int fileid); }
443248590Smm306	STD	BSD	{ int kldfind(const char *file); }
444248590Smm307	STD	BSD	{ int kldnext(int fileid); }
445248590Smm308	STD	BSD	{ int kldstat(int fileid, struct kld_file_stat* stat); }
446248590Smm309	STD	BSD	{ int kldfirstmod(int fileid); }
447248590Smm310	STD	BSD	{ int getsid(pid_t pid); }
448248590Smm311	STD	BSD	{ int setresuid(uid_t ruid, uid_t euid, uid_t suid); }
449248590Smm312	STD	BSD	{ int setresgid(gid_t rgid, gid_t egid, gid_t sgid); }
450248590Smm313	OBSOL	NOHIDE	signanosleep
451248590Smm314     STD     BSD     { int aio_return(struct aiocb *aiocbp); }
452248590Smm315     STD     BSD     { int aio_suspend(struct aiocb * const * aiocbp, int nent, const struct timespec *timeout); }
453248590Smm316     STD     BSD     { int aio_cancel(int fd, struct aiocb *aiocbp); }
454248590Smm317     STD     BSD     { int aio_error(struct aiocb *aiocbp); }
455248590Smm318     STD     BSD     { int aio_read(struct aiocb *aiocbp); }
456248590Smm319     STD     BSD     { int aio_write(struct aiocb *aiocbp); }
457248590Smm320     STD     BSD     { int lio_listio(int mode, struct aiocb * const *acb_list, int nent, struct sigevent *sig); }
458248590Smm321     STD     BSD     { int yield(void); }
459248590Smm322     STD     BSD     { int thr_sleep(const struct timespec *timeout); }
460248590Smm323     STD     BSD     { int thr_wakeup(pid_t pid); }
461248590Smm324     STD     BSD     { int mlockall(int how); }
462248590Smm325     STD     BSD     { int munlockall(void); }
463248590Smm326     STD     BSD     { int __getcwd(u_char *buf, u_int buflen); }
464248590Smm
465248590Smm327     STD     POSIX   { int sched_setparam (pid_t pid, const struct sched_param *param); }
466248590Smm328     STD     POSIX   { int sched_getparam (pid_t pid, struct sched_param *param); }
467248590Smm
468248590Smm329     STD     POSIX   { int sched_setscheduler (pid_t pid, int policy, const struct sched_param *param); }
469248590Smm330     STD     POSIX   { int sched_getscheduler (pid_t pid); }
470248590Smm
471248590Smm331     STD     POSIX   { int sched_yield (void); }
472248590Smm332     STD     POSIX   { int sched_get_priority_max (int policy); }
473248590Smm333     STD     POSIX   { int sched_get_priority_min (int policy); }
474248590Smm334     STD     POSIX   { int sched_rr_get_interval (pid_t pid, struct timespec *interval); }
475248590Smm335	STD	BSD	{ int utrace(const void *addr, size_t len); }
476248590Smm336	STD	BSD	{ int sendfile(int fd, int s, off_t offset, size_t nbytes, \
477248590Smm				struct sf_hdtr *hdtr, off_t *sbytes, int flags); }
478248590Smm337	STD	BSD	{ int kldsym(int fileid, int cmd, void *data); }
479248590Smm338	STD	BSD	{ int jail(struct jail *jail); }
480248590Smm339	UNIMPL	BSD	pioctl
481248590Smm340	MPSAFE	STD	POSIX	{ int sigprocmask(int how, const sigset_t *set, \
482248590Smm			    sigset_t *oset); }
483248590Smm341	STD	POSIX	{ int sigsuspend(const sigset_t *sigmask); }
484248590Smm342	STD	POSIX	{ int sigaction(int sig, const struct sigaction *act, \
485248590Smm			    struct sigaction *oact); }
486248590Smm343	STD	POSIX	{ int sigpending(sigset_t *set); }
487248590Smm344	STD	BSD	{ int sigreturn(ucontext_t *sigcntxp); }
488248590Smm345	UNIMPL	NOHIDE	sigtimedwait
489248590Smm346	UNIMPL	NOHIDE	sigwaitinfo
490248590Smm347	STD	BSD	{ int __acl_get_file(const char *path, \
491248590Smm			    acl_type_t type, struct acl *aclp); }
492248590Smm348	STD	BSD	{ int __acl_set_file(const char *path, \
493248590Smm			    acl_type_t type, struct acl *aclp); }
494248590Smm349	STD	BSD	{ int __acl_get_fd(int filedes, acl_type_t type, \
495248590Smm			    struct acl *aclp); }
496248590Smm350	STD	BSD	{ int __acl_set_fd(int filedes, acl_type_t type, \
497248590Smm			    struct acl *aclp); }
498248590Smm351	STD	BSD	{ int __acl_delete_file(const char *path, \
499248590Smm			    acl_type_t type); }
500248590Smm352	STD	BSD	{ int __acl_delete_fd(int filedes, acl_type_t type); }
501248590Smm353	STD	BSD	{ int __acl_aclcheck_file(const char *path, \
502248590Smm			    acl_type_t type, struct acl *aclp); }
503248590Smm354	STD	BSD	{ int __acl_aclcheck_fd(int filedes, acl_type_t type, \
504248590Smm			    struct acl *aclp); }
505248590Smm355	STD	BSD	{ int extattrctl(const char *path, int cmd, \
506248590Smm			    const char *attrname, char *arg); }
507248590Smm356	STD	BSD	{ int extattr_set_file(const char *path, \
508248590Smm			    const char *attrname, struct iovec *iovp, \
509248590Smm			    unsigned iovcnt); }
510248590Smm357	STD	BSD	{ int extattr_get_file(const char *path, \
511248590Smm			    const char *attrname, struct iovec *iovp, \
512248590Smm			    unsigned iovcnt); }
513248590Smm358	STD	BSD	{ int extattr_delete_file(const char *path, \
514248590Smm			    const char *attrname); }
515248590Smm359	STD	BSD	{ int aio_waitcomplete(struct aiocb **aiocbp, struct timespec *timeout); }
516248590Smm360	STD	BSD	{ int getresuid(uid_t *ruid, uid_t *euid, uid_t *suid); }
517248590Smm361	STD	BSD	{ int getresgid(gid_t *rgid, gid_t *egid, gid_t *sgid); }
518248590Smm362	STD	BSD	{ int kqueue(void); }
519248590Smm363	STD	BSD	{ int kevent(int fd, \
520248590Smm			    int nchanges, struct kevent **changelist, \
521248590Smm			    int nevents, struct kevent *eventlist, \
522248590Smm			    struct timespec *timeout); }
523248590Smm