Home | History | Annotate | Line # | Download | only in i386
syscalls.master revision 1.8
      1 	$NetBSD: syscalls.master,v 1.8 1995/08/14 01:27:56 mycroft Exp $
      2 
      3 ;	@(#)syscalls.master	8.1 (Berkeley) 7/19/93
      4 
      5 ; NetBSD COMPAT_LINUX system call name/number "master" file.
      6 ; (See syscalls.conf to see what it is processed into.)
      7 ;
      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.
     12 ;
     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
     19 ;
     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).
     24 ;
     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]
     30 ;
     31 ; #ifdef's, etc. may be included, and are copied to the output files.
     32 ; #include's are copied to the syscall switch definition file only.
     33 
     34 #include <sys/param.h>
     35 #include <sys/systm.h>
     36 #include <sys/signal.h>
     37 #include <sys/mount.h>
     38 #include <sys/syscallargs.h>
     39 #include <compat/linux/linux_types.h>
     40 #include <compat/linux/linux_signal.h>
     41 #include <compat/linux/linux_syscallargs.h>
     42 #include <machine/linux_machdep.h>
     43 
     44 0	NOARGS		{ int nosys(void); } syscall
     45 1	NOARGS		{ int exit(int rval); }
     46 2	STD		{ int linux_fork(void); }
     47 3	NOARGS		{ int read(int fd, char *buf, u_int nbyte); }
     48 4	NOARGS		{ int write(int fd, char *buf, u_int nbyte); }
     49 5	STD		{ int linux_open(char *path, int flags, int mode); }
     50 6	NOARGS		{ int close(int fd); }
     51 7	STD		{ int linux_waitpid(int pid, int *status, int options);}
     52 8	STD		{ int linux_creat(char *path, int mode); }
     53 9	NOARGS		{ int link(char *path, char *link); }
     54 10	STD		{ int linux_unlink(char *path); }
     55 11	STD		{ int linux_execve(char *path, char **argp, char **envp); }
     56 12	STD		{ int linux_chdir(char *path); }
     57 13	STD		{ int linux_time(linux_time_t *t); }
     58 14	STD		{ int linux_mknod(char *path, int mode, int dev); }
     59 15	STD		{ int linux_chmod(char *path, int mode); }
     60 16	STD		{ int linux_chown(char *path, int uid, int gid); }
     61 17	STD		{ int linux_break(char *nsize); }
     62 18	OBSOL		linux_ostat
     63 19	NOARGS		{ long compat_43_lseek(int fd, long offset, int whence); }
     64 20	NOARGS		{ pid_t getpid(void); }
     65 21	UNIMPL		linux_mount
     66 22	UNIMPL		linux_umount
     67 23	NOARGS		{ int setuid(uid_t uid); }
     68 24	NOARGS		{ uid_t getuid(void); }
     69 25	UNIMPL		linux_stime
     70 26	UNIMPL		linux_ptrace
     71 27	STD		{ int linux_alarm(unsigned int secs); }
     72 28	OBSOL		linux_ofstat
     73 29	STD		{ int linux_pause(void); }
     74 30	STD		{ int linux_utime(char *path, struct linux_utimbuf *times); }
     75 31	UNIMPL		linux_stty
     76 32	UNIMPL		linux_gtty
     77 33	STD		{ int linux_access(char *path, int flags); }
     78 34	UNIMPL		linux_nice
     79 35	UNIMPL		linux_ftime
     80 36	NOARGS		{ int sync(void); }
     81 37	STD		{ int linux_kill(int pid, int signum); }
     82 38	STD		{ int linux_rename(char *from, char *to); }
     83 39	STD		{ int linux_mkdir(char *path, int mode); }
     84 40	STD		{ int linux_rmdir(char *path); }
     85 41	NOARGS		{ int dup(u_int fd); }
     86 42	STD		{ int linux_pipe(int *pfds); }
     87 43	STD		{ int linux_times(struct times *tms); }
     88 44	UNIMPL		linux_prof
     89 45	STD		{ int linux_brk(char *nsize); }
     90 46	NOARGS		{ int setgid(uid_t gid); }
     91 47	NOARGS		{ gid_t getgid(void); }
     92 48	STD		{ int linux_signal(int sig, linux_handler_t handler); }
     93 49	NOARGS		{ uid_t geteuid(void); }
     94 50	NOARGS		{ gid_t getegid(void); }
     95 51	NOARGS		{ int acct(char *path); }
     96 52	UNIMPL		linux_phys
     97 53	UNIMPL		linux_lock
     98 54	STD		{ int linux_ioctl(int fd, u_long com, caddr_t data); }
     99 55	STD		{ int linux_fcntl(int fd, int cmd, void *arg); }
    100 56	UNIMPL		linux_mpx
    101 57	NOARGS		{ int setpgid(int pid, int pgid); }
    102 58	UNIMPL		linux_ulimit
    103 59	UNIMPL		linux_oldolduname
    104 60	NOARGS		{ int umask(int newmask); }
    105 61	NOARGS		{ int chroot(char *path); }
    106 62	UNIMPL		linux_ustat
    107 63	NOARGS		{ int dup2(u_int from, u_int to); }
    108 64	NOARGS		{ pid_t getppid(void); }
    109 65	NOARGS		{ int getpgrp(void); }
    110 66	NOARGS		{ int setsid(void); }
    111 67	STD		{ int linux_sigaction(int signum, \
    112 				struct linux_sigaction *nsa,\
    113 				struct linux_sigaction *osa); }
    114 68	STD		{ int linux_siggetmask(void); }
    115 69	STD		{ int linux_sigsetmask(linux_sigset_t mask); }
    116 70	NOARGS		{ int compat_43_setreuid(int ruid, int euid); }
    117 71	NOARGS		{ int compat_43_setregid(int rgid, int egid); }
    118 72	STD		{ int linux_sigsuspend(caddr_t restart, int oldmask, \
    119 				int mask); }
    120 73	STD		{ int linux_sigpending(linux_sigset_t *mask); }
    121 74	NOARGS		{ int compat_43_sethostname(char *hostname, u_int len);}
    122 75	NOARGS		{ int compat_43_setrlimit(u_int which, \
    123 				struct ogetrlimit *rlp); }
    124 76	NOARGS		{ int compat_43_getrlimit(u_int which, \
    125 				struct ogetrlimit *rlp); }
    126 77	NOARGS		{ int getrusage(int who, struct rusage *rusage); }
    127 78	NOARGS		{ int gettimeofday(struct timeval *tp, \
    128 				struct timezone *tzp); }
    129 79	NOARGS		{ int settimeofday(struct timeval *tp, \
    130 				struct timezone *tzp); }
    131 80	NOARGS		{ int getgroups(u_int gidsetsize, gid_t *gidset); }
    132 81	NOARGS		{ int setgroups(u_int gidsetsize, gid_t *gidset); }
    133 82	STD		{ int linux_select(struct linux_select *lsp); }
    134 83	STD		{ int linux_symlink(char *path, char *to); }
    135 84	NOARGS		{ int compat_43_lstat(char *path, struct ostat *up); }
    136 85	STD		{ int linux_readlink(char *name, char *buf, int count); }
    137 86	STD		{ int linux_uselib(char *path); }
    138 87	NOARGS		{ int swapon(char *name); }
    139 88	NOARGS		{ int reboot(int opt); }
    140 89	STD		{ int linux_readdir(int fd, struct linux_dirent *dent, \
    141 			    unsigned int count); }
    142 90	STD		{ int linux_mmap(struct linux_mmap *lmp); }
    143 91	NOARGS		{ int munmap(caddr_t addr, int len); }
    144 92	STD		{ int linux_truncate(char *path, long length); }
    145 93	NOARGS		{ int compat_43_ftruncate(int fd, long length); }
    146 94	NOARGS		{ int fchmod(int fd, int mode); }
    147 95	NOARGS		{ int fchown(int fd, int uid, int gid); }
    148 96	NOARGS		{ int getpriority(int which, int who); }
    149 97	NOARGS		{ int setpriority(int which, int who, int prio); }
    150 98	NOARGS		{ int profil(caddr_t samples, u_int size, \
    151 				u_int offset, u_int scale); }
    152 99	STD		{ int linux_statfs(char *path, struct linux_statfs *sp); }
    153 100	STD		{ int linux_fstatfs(int fd, struct linux_statfs *sp); }
    154 101	UNIMPL		linux_ioperm
    155 102	STD		{ int linux_socketcall(int what, void *args); }
    156 103	UNIMPL		linux_klog
    157 104	NOARGS		{ int setitimer(u_int which, struct itimerval *itv, \
    158 			    struct itimerval *oitv); }
    159 105	NOARGS		{ int getitimer(u_int which, struct itimerval *itv); }
    160 106	STD		{ int linux_stat(char *path, struct linux_stat *sp); }
    161 107	STD		{ int linux_lstat(char *path, struct linux_stat *sp); }
    162 108	STD		{ int linux_fstat(int fd, struct linux_stat *sp); }
    163 109	UNIMPL		linux_olduname
    164 110	UNIMPL		linux_iopl
    165 111	UNIMPL		linux_vhangup
    166 112	UNIMPL		linux_idle
    167 113	UNIMPL		linux_vm86
    168 114	STD		{ int linux_wait4(int pid, int *status, int options, \
    169 				struct rusage *rusage); }
    170 115	UNIMPL		linux_swapoff
    171 116	UNIMPL		linux_sysinfo
    172 117	STD		{ int linux_ipc(int what, int a1, int a2, int a3, \
    173 				caddr_t ptr); }
    174 118	NOARGS		{ int fsync(int fd); }
    175 119	STD		{ int linux_sigreturn(struct linux_sigcontext *scp); }
    176 120	UNIMPL		linux_clone
    177 121	NOARGS		{ int compat_09_setdomainname(char *name, int len); }
    178 122	STD		{ int linux_uname(struct linux_utsname *up); }
    179 #ifdef __i386__
    180 123	STD		{ int linux_modify_ldt(int func, void *ptr, \
    181 				size_t bytecount); }
    182 #else
    183 123	UNIMPL		linux_modify_ldt
    184 #endif
    185 124	UNIMPL		linux_adjtimex
    186 125	NOARGS		{ int mprotect(caddr_t addr, int len, int prot); }
    187 126	STD		{ int linux_sigprocmask(int how, linux_sigset_t *set, \
    188 				linux_sigset_t *oset); }
    189 127	UNIMPL		linux_create_module
    190 128	UNIMPL		linux_init_module
    191 129	UNIMPL		linux_delete_module
    192 130	UNIMPL		linux_get_kernel_syms
    193 131	UNIMPL		linux_quotactl
    194 132	STD		{ int linux_getpgid(int pid); }
    195 133	NOARGS		{ int fchdir(int fd); }
    196 134	UNIMPL		linux_bdflush
    197 135	UNIMPL		linux_sysfs
    198 136	STD		{ int linux_personality(int per); }
    199 137	UNIMPL		linux_afs_syscall
    200 138	UNIMPL		linux_setfsuid
    201 139	UNIMPL		linux_getfsuid
    202 140	STD		{ int linux_llseek(int fd, u_int32_t ohigh, \
    203 				u_int32_t olow, caddr_t res, int whence); }
    204