System call table

First draft was written based on Linux 2.6.7 and new system calls are added based on Linux 2.6.11 and Linux 2.6.15.6. Many system call tables found in the Internet were outdated, so I decide to make this table myself. I just gathered some information from the source code and comments. I'm still working on this list and please help me to complete this list.
This document would help. http://webster.cs.ucr.edu/Page_Linux/LinuxSysCalls.pdf

Min Lee

Last updated : 16 June 2006

blank : not implemented syscall (sys_ni_syscall)


Number Name Description

Note

Source

Prototype

 

sys_ni_syscall

 not implemented syscall

 

"kernel/sys.c"

asmlinkage long sys_ni_syscall(void)
{
        return -ENOSYS;
}

0

sys_restart_syscall

 

old "setup()" system call, used for restarting

"kernel/signal.c"

asmlinkage long sys_restart_syscall(void)
{
        struct restart_block *restart = &current_thread_info()->restart_block;
        return restart->fn(restart);
}

1

sys_exit

 

 

"kernel/exit.c"

asmlinkage long sys_exit(int error_code)
{
        do_exit((error_code&0xff)<<8);
}

2

sys_fork

 

 

"arch/i386/kernel/process.c"

asmlinkage int sys_fork(struct pt_regs regs)
{
        return do_fork(SIGCHLD, regs.esp, &regs, 0, NULL, NULL);
}

3

sys_read

 

 

"fs/read_write.c"

asmlinkage ssize_t sys_read(unsigned int fd, char __user * buf, size_t count)

4

sys_write

 

 

"fs/read_write.c"

asmlinkage ssize_t sys_write(unsigned int fd, const char __user * buf, size_t count)

5

sys_open

 

 

"fs/open.c"

asmlinkage long sys_open(const char __user * filename, int flags, int mode)

6

sys_close

 

 

"fs/open.c"

asmlinkage long sys_close(unsigned int fd)

7

sys_waitpid

 

 

"kernel/exit.c"

asmlinkage long sys_waitpid(pid_t pid, unsigned __user *stat_addr, int options)
{
        return sys_wait4(pid, stat_addr, options, NULL);
}

8

sys_creat

 

 

"fs/open.c"

asmlinkage long sys_creat(const char __user * pathname, int mode)
{
        return sys_open(pathname, O_CREAT | O_WRONLY | O_TRUNC, mode);
}

9

sys_link

 

 

"fs/namei.c"

asmlinkage long sys_link(const char __user * oldname, const char __user * newname)

10

sys_unlink

 

 

"fs/namei.c"

asmlinkage long sys_unlink(const char __user * pathname)

11

sys_execve

 

 

"arch/i386/kernel/process.c"

asmlinkage int sys_execve(struct pt_regs regs)

12

sys_chdir

 

 

"fs/open.c"

asmlinkage long sys_chdir(const char __user * filename)

13

sys_time

 

 

"kernel/time.c"

asmlinkage long sys_time(int __user * tloc)

14

sys_mknod

 

 

"fs/namei.c"

asmlinkage long sys_mknod(const char __user * filename, int mode, unsigned dev)

15

sys_chmod

 

 

"fs/open.c"

asmlinkage long sys_chmod(const char __user * filename, mode_t mode)

16

sys_lchown16

 

 

"kernel/uid16.c"

asmlinkage long sys_lchown16(const char __user * filename, old_uid_t user, old_gid_t group)
{
        return sys_lchown(filename, low2highuid(user), low2highgid(group));
}

17

 

 

old break syscall holder

 

 

18

sys_stat

 

 

"fs/stat.c"

asmlinkage long sys_stat(char __user * filename, struct __old_kernel_stat __user * statbuf)
{
        struct kstat stat;
        int error = vfs_stat(filename, &stat);

        if (!error)
                error = cp_old_stat(&stat, statbuf);

        return error;
}

19

sys_lseek

 

 

"fs/read_write.c"

asmlinkage off_t sys_lseek(unsigned int fd, off_t offset, unsigned int origin)

20

sys_getpid

 

 

"kernel/timer.c"

asmlinkage long sys_getpid(void)
{
        return current->tgid;
}

21

sys_mount

 

 

"fs/namespace.c"

asmlinkage long sys_mount(char __user * dev_name, char __user * dir_name,
                          char __user * type, unsigned long flags,
                          void __user * data)

22

sys_oldumount

 

 

"fs/namespace.c"

asmlinkage long sys_oldumount(char __user * name)
{
        return sys_umount(name,0);
}

23

sys_setuid16

 

 

"kernel/uid16.c"

asmlinkage long sys_setuid16(old_uid_t uid)
{
        return sys_setuid((uid_t)uid);
}

24

sys_getuid16

 

 

"kernel/uid16.c"

asmlinkage long sys_getuid16(void)
{
        return high2lowuid(current->uid);
}

25

sys_stime

 

 

"kernel/time.c"

asmlinkage long sys_stime(time_t __user *tptr)
{
        struct timespec tv;

        if (!capable(CAP_SYS_TIME))
                return -EPERM;
        if (get_user(tv.tv_sec, tptr))
                return -EFAULT;
 
        tv.tv_nsec = 0;
        do_settimeofday(&tv);
        return 0;
}

26

sys_ptrace

 

 

"arch/i386/kernel/ptrace.c"

asmlinkage int sys_ptrace(long request, long pid, long addr, long data)

27

sys_alarm

 

 

"kernel/timer.c"

asmlinkage unsigned long sys_alarm(unsigned int seconds)

28

sys_fstat

 

 

"fs/stat.c"

asmlinkage long sys_fstat(unsigned int fd, struct __old_kernel_stat __user * statbuf)
{
        struct kstat stat;
        int error = vfs_fstat(fd, &stat);

        if (!error)
                error = cp_old_stat(&stat, statbuf);

        return error;
}

29

sys_pause

 

 

"kernel/signal.c"

asmlinkage long sys_pause(void)

30

sys_utime

 

 

"fs/open.c"

asmlinkage long sys_utime(char __user * filename, struct utimbuf __user * times)

31

 

 

old stty syscall holder

 

 

32

 

 

old gtty syscall holder

 

 

33

sys_access

 

 

"fs/open.c"

asmlinkage long sys_access(const char __user * filename, int mode)

34

sys_nice

 

 

"kernel/sched.c"

asmlinkage long sys_nice(int increment)

35

 

 

old ftime syscall holder

 

 

36

sys_sync

 

 

"fs/buffer.c"

asmlinkage long sys_sync(void)
{
        do_sync(1);
        return 0;
}

37

sys_kill

 

 

"kernel/signal.c"

asmlinkage long sys_kill(int pid, int sig)

38

sys_rename

 

 

"fs/namei.c"

asmlinkage long sys_rename(const char __user * oldname, const char __user * newname)

39

sys_mkdir

 

 

"fs/namei.c"

asmlinkage long sys_mkdir(const char __user * pathname, int mode)

40

sys_rmdir

 

 

"fs/namei.c"

asmlinkage long sys_rmdir(const char __user * pathname)

41

sys_dup

 

 

"fs/fcntl.c"

asmlinkage long sys_dup(unsigned int fildes)
{
        int ret = -EBADF;
        struct file * file = fget(fildes);

        if (file)
                ret = dupfd(file, 0);
        return ret;
}

42

sys_pipe

 

 

"arch/i386/kernel/sys_i386.c"

asmlinkage int sys_pipe(unsigned long __user * fildes)
{
        int fd[2];
        int error;

        error = do_pipe(fd);
        if (!error) {
                if (copy_to_user(fildes, fd, 2*sizeof(int)))
                        error = -EFAULT;
        }
        return error;
}

43

sys_times

 

 

"kernel/sys.c"

asmlinkage long sys_times(struct tms __user * tbuf)

44

 

 

old prof syscall holder

 

 

45

sys_brk

 

 

"mm/mmap.c"

asmlinkage unsigned long sys_brk(unsigned long brk)

46

sys_setgid16

 

 

"kernel/uid16.c"

asmlinkage long sys_setgid16(old_gid_t gid)
{
        return sys_setgid((gid_t)gid);
}

47

sys_getgid16

 

 

"kernel/uid16.c"

asmlinkage long sys_getgid16(void)
{
        return high2lowgid(current->gid);
}

48

sys_signal

 

For backwards compatibility.  Functionality superseded by sigaction.

"kernel/signal.c"

asmlinkage unsigned long
sys_signal(int sig, __sighandler_t handler)
{
        struct k_sigaction new_sa, old_sa;
        int ret;
 
        new_sa.sa.sa_handler = handler;
        new_sa.sa.sa_flags = SA_ONESHOT | SA_NOMASK;

        ret = do_sigaction(sig, &new_sa, &old_sa);

        return ret ? ret : (unsigned long)old_sa.sa.sa_handler;
}

49

sys_geteuid16

 

 

"kernel/uid16.c"

asmlinkage long sys_geteuid16(void)
{
        return high2lowuid(current->euid);
}

50

sys_getegid16

 

 

"kernel/uid16.c"

asmlinkage long sys_getegid16(void)
{
        return high2lowgid(current->egid);
}

51

sys_acct

 the only system call needed to implement process accounting. It takes the name of the file where accounting records should be written. If the filename is NULL, accounting will be shutdown.

 

"kernel/acct.c"

asmlinkage long sys_acct(const char __user *name)

52

sys_umount

 

recycled never used phys()

"fs/namespace.c"

asmlinkage long sys_umount(char __user * name, int flags)

53

 

 

old lock syscall holder

 

 

54

sys_ioctl

 

 

"fs/ioctl.c"

asmlinkage long sys_ioctl(unsigned int fd, unsigned int cmd, unsigned long arg)

55

sys_fcntl

 

 

"fs/fcntl.c"

asmlinkage long sys_fcntl(int fd, unsigned int cmd, unsigned long arg)

56

 

 

old mpx syscall holder

 

 

57

sys_setpgid

 

 

"kernel/sys.c"

asmlinkage long sys_setpgid(pid_t pid, pid_t pgid)

58

 

 

old ulimit syscall holder

 

 

59

sys_olduname

 

 

"arch/i386/kernel/sys_i386.c"

asmlinkage int sys_olduname(struct oldold_utsname __user * name)

60

sys_umask

 

 

"kernel/sys.c"

asmlinkage long sys_umask(int mask)
{
        mask = xchg(&current->fs->umask, mask & S_IRWXUGO);
        return mask;
}

61

sys_chroot

 

 

"fs/open.c"

asmlinkage long sys_chroot(const char __user * filename)

62

sys_ustat

 

 

"fs/super.c"

asmlinkage long sys_ustat(unsigned dev, struct ustat __user * ubuf)

63

sys_dup2

 

 

"fs/fcntl.c"

asmlinkage long sys_dup2(unsigned int oldfd, unsigned int newfd)

64

sys_getppid

 

 

"kernel/timer.c"

asmlinkage long sys_getppid(void)

65

sys_getpgrp

 

 

"kernel/sys.c"

asmlinkage long sys_getpgrp(void)
{
        /* SMP - assuming writes are word atomic this is fine */
        return process_group(current);
}

66

sys_setsid

 

 

"kernel/sys.c"

asmlinkage long sys_setsid(void)

67

sys_sigaction

 

 

"arch/i386/kernel/signal.c"

asmlinkage int sys_sigaction(int sig, const struct old_sigaction __user *act,
              struct old_sigaction __user *oact)

68

sys_sgetmask

 

 For backwards compatibility.  Functionality superseded by sigprocmask.

"kernel/signal.c"

asmlinkage long sys_sgetmask(void)
{
        /* SMP safe */
        return current->blocked.sig[0];
}

69

sys_ssetmask

 

 

"kernel/signal.c"

asmlinkage long sys_ssetmask(int newmask)

70

sys_setreuid16

 

 

"kernel/uid16.c"

asmlinkage long sys_setreuid16(old_uid_t ruid, old_uid_t euid)
{
        return sys_setreuid(low2highuid(ruid), low2highuid(euid));
}

71

sys_setregid16

 

 

"kernel/uid16.c"

asmlinkage long sys_setregid16(old_gid_t rgid, old_gid_t egid)
{
        return sys_setregid(low2highgid(rgid), low2highgid(egid));
}

72

sys_sigsuspend

 

 

"arch/i386/kernel/signal.c"

asmlinkage int sys_sigsuspend(int history0, int history1, old_sigset_t mask)

73

sys_sigpending

 

 

"kernel/signal.c"

asmlinkage long sys_sigpending(old_sigset_t __user *set)
{
        return do_sigpending(set, sizeof(*set));
}

74

sys_sethostname

 

 

"kernel/sys.c"

asmlinkage long sys_sethostname(char __user *name, int len)

75

sys_setrlimit

 

 

"kernel/sys.c"

asmlinkage long sys_setrlimit(unsigned int resource, struct rlimit __user *rlim)

76

sys_old_getrlimit

 

Back compatible 2Gig limited rlimit

"kernel/sys.c"

asmlinkage long sys_old_getrlimit(unsigned int resource, struct rlimit __user *rlim)

77

sys_getrusage

 

 

"kernel/sys.c"

asmlinkage long sys_getrusage(int who, struct rusage __user *ru)
{
        if (who != RUSAGE_SELF && who != RUSAGE_CHILDREN)
                return -EINVAL;
        return getrusage(current, who, ru);
}

78

sys_gettimeofday

 

 

"kernel/time.c"

asmlinkage long sys_gettimeofday(struct timeval __user *tv, struct timezone __user *tz)

79

sys_settimeofday

 

 

"kernel/time.c"

asmlinkage long sys_settimeofday(struct timeval __user *tv,
                                struct timezone __user *tz)

80

sys_getgroups16

 

 

"kernel/uid16.c"

asmlinkage long sys_getgroups16(int gidsetsize, old_gid_t __user *grouplist)

81

sys_setgroups16

 

 

"kernel/uid16.c"

asmlinkage long sys_setgroups16(int gidsetsize, old_gid_t __user *grouplist)

82

old_select

 

 

"arch/i386/kernel/sys_i386.c"

asmlinkage int old_select(struct sel_arg_struct __user *arg)
{
        struct sel_arg_struct a;
 
        if (copy_from_user(&a, arg, sizeof(a)))
                return -EFAULT;
        /* sys_select() does the appropriate kernel locking */
        return sys_select(a.n, a.inp, a.outp, a.exp, a.tvp);
}

83

sys_symlink

 

 

"fs/namei.c"

asmlinkage long sys_symlink(const char __user * oldname, const char __user * newname)

84

sys_lstat

 

 

"fs/stat.c"

asmlinkage long sys_lstat(char __user * filename, struct __old_kernel_stat __user * statbuf)
{
        struct kstat stat;
        int error = vfs_lstat(filename, &stat);
 
        if (!error)
                error = cp_old_stat(&stat, statbuf);
 
        return error;
}

85

sys_readlink

 

 

"fs/stat.c"

asmlinkage long sys_readlink(const char __user * path, char __user * buf, int bufsiz)

86

sys_uselib

 

 

"fs/exec.c"

asmlinkage long sys_uselib(const char __user * library)

87

sys_swapon

 

 

"mm/swapfile.c"

asmlinkage long sys_swapon(const char __user * specialfile, int swap_flags)

88

sys_reboot

 

 

"kernel/sys.c"

asmlinkage long sys_reboot(int magic1, int magic2, unsigned int cmd, void __user * arg)

89

old_readdir

 

 

"fs/readdir.c"

asmlinkage long old_readdir(unsigned int fd, struct old_linux_dirent __user * dirent, unsigned int count)

90

old_mmap

 

 

"arch/i386/kernel/sys_i386.c"

asmlinkage int old_mmap(struct mmap_arg_struct __user *arg)

91

sys_munmap

 

 

"mm/mmap.c"

asmlinkage long sys_munmap(unsigned long addr, size_t len)

92

sys_truncate

 

 

"fs/open.c"

asmlinkage long sys_truncate(const char __user * path, unsigned long length)
{
        /* on 32-bit boxen it will cut the range 2^31--2^32-1 off */
        return do_sys_truncate(path, (long)length);
}

93

sys_ftruncate

 

 

"fs/open.c"

asmlinkage long sys_ftruncate(unsigned int fd, unsigned long length)
{
        return do_sys_ftruncate(fd, length, 1);
}

94

sys_fchmod

 

 

"fs/open.c"

asmlinkage long sys_fchmod(unsigned int fd, mode_t mode)

95

sys_fchown16

 

 

"kernel/uid16.c"

asmlinkage long sys_fchown16(unsigned int fd, old_uid_t user, old_gid_t group)
{
        return sys_fchown(fd, low2highuid(user), low2highgid(group));
}

96

sys_getpriority

 

 

"kernel/sys.c"

asmlinkage long sys_getpriority(int which, int who)

97

sys_setpriority

 

 

"kernel/sys.c"

asmlinkage long sys_setpriority(int which, int who, int niceval)

98

 

 

old profil syscall holder

 

 

99

sys_statfs

 

 

"fs/open.c"

asmlinkage long sys_statfs(const char __user * path, struct statfs __user * buf)

100

sys_fstatfs

 

 

"fs/open.c"

asmlinkage long sys_fstatfs(unsigned int fd, struct statfs __user * buf)

101

sys_ioperm

 

 

"arch/i386/kernel/ioport.c"

asmlinkage long sys_ioperm(unsigned long from, unsigned long num, int turn_on)

102

sys_socketcall

 

 

"net/socket.c"

asmlinkage long sys_socketcall(int call, unsigned long __user *args)

103

sys_syslog

 

 

"kernel/printk.c"

asmlinkage long sys_syslog(int type, char __user * buf, int len)
{
        return do_syslog(type, buf, len);
}

104

sys_setitimer

 

 

"kernel/itimer.c"

asmlinkage long sys_setitimer(int which,
                              struct itimerval __user *value,
                              struct itimerval __user *ovalue)

105

sys_getitimer

 

 

"kernel/itimer.c"

asmlinkage long sys_getitimer(int which, struct itimerval __user *value)

106

sys_newstat

 

 

"fs/stat.c"

asmlinkage long sys_newstat(char __user * filename, struct stat __user * statbuf)
{
        struct kstat stat;
        int error = vfs_stat(filename, &stat);
 
        if (!error)
                error = cp_new_stat(&stat, statbuf);
 
        return error;
}

107

sys_newlstat

 

 

"fs/stat.c"

asmlinkage long sys_newlstat(char __user * filename, struct stat __user * statbuf)
{
        struct kstat stat;
        int error = vfs_lstat(filename, &stat);
 
        if (!error)
                error = cp_new_stat(&stat, statbuf);

        return error;
}

108

sys_newfstat

 

 

"fs/stat.c"

asmlinkage long sys_newfstat(unsigned int fd, struct stat __user * statbuf)
{
        struct kstat stat;
        int error = vfs_fstat(fd, &stat);
 
        if (!error)
                error = cp_new_stat(&stat, statbuf);
 
        return error;
}

109

sys_uname

 

 

"arch/i386/kernel/sys_i386.c"

smlinkage int sys_uname(struct old_utsname __user * name)
{
        int err;

        if (!name)
                return -EFAULT;
        down_read(&uts_sem);
        err=copy_to_user(name, &system_utsname, sizeof (*name));
        up_read(&uts_sem);
        return err?-EFAULT:0;
}

110

sys_iopl

 

 

"arch/i386/kernel/ioport.c"

asmlinkage long sys_iopl(unsigned long unused)

111

sys_vhangup

 

 

"fs/open.c"

asmlinkage long sys_vhangup(void)
{
        if (capable(CAP_SYS_TTY_CONFIG)) {
                tty_vhangup(current->signal->tty);
                return 0;
        }
        return -EPERM;
}

112

 

 

old "idle" syscall

 

 

113

sys_vm86old

 

 

"arch/i386/kernel/vm86.c"

asmlinkage int sys_vm86old(struct vm86_struct __user * v86)

114

sys_wait4

 

 

"kernel/exit.c"

asmlinkage long sys_wait4(pid_t pid,unsigned int __user *stat_addr, int options, struct rusage __user *ru)

115

sys_swapoff

 

 

"mm/swapfile.c"

asmlinkage long sys_swapoff(const char __user * specialfile)

116

sys_sysinfo

 

 

"kernel/timer.c"

asmlinkage long sys_sysinfo(struct sysinfo __user *info)

117

sys_ipc

 

 

"arch/i386/kernel/sys_i386.c"

asmlinkage int sys_ipc (uint call, int first, int second,
                        int third, void __user *ptr, long fifth)

118

sys_fsync

 

 

"fs/buffer.c"

asmlinkage long sys_fsync(unsigned int fd)

119

sys_sigreturn

 

 

"arch/i386/kernel/signal.c"

asmlinkage int sys_sigreturn(unsigned long __unused)

120

sys_clone

 

 

"arch/i386/kernel/process.c"

asmlinkage int sys_clone(struct pt_regs regs)

121

sys_setdomainname

 

 

"kernel/sys.c"

asmlinkage long sys_setdomainname(char __user *name, int len)

122

sys_newuname

 

 

"kernel/sys.c"

asmlinkage long sys_newuname(struct new_utsname __user * name)
{
        int errno = 0;
 
        down_read(&uts_sem);
        if (copy_to_user(name,&system_utsname,sizeof *name))
                errno = -EFAULT;
        up_read(&uts_sem);
        return errno;
}

123

sys_modify_ldt

 

 

"arch/i386/kernel/ldt.c"

asmlinkage int sys_modify_ldt(int func, void __user *ptr, unsigned long bytecount)

124

sys_adjtimex

 

 

"kernel/time.c"

asmlinkage long sys_adjtimex(struct timex __user *txc_p)

125

sys_mprotect

 

 

"mm/mprotect.c"

asmlinkage long sys_mprotect(unsigned long start, size_t len, unsigned long prot)

126

sys_sigprocmask

 

 

"kernel/signal.c"

asmlinkage long sys_sigprocmask(int how, old_sigset_t __user *set, old_sigset_t __user *oset)

127

 

 

old "create_module"

 

 

128

sys_init_module

 

 

"kernel/module.c"

asmlinkage long sys_init_module(void __user *umod,
                unsigned long len,
                const char __user *uargs)

129

sys_delete_module

 

 

"kernel/module.c"

asmlinkage long sys_delete_module(const char __user *name_user, unsigned int flags)

130

 

 

old "get_kernel_syms"

 

 

131

sys_quotactl

 

 

"fs/quota.c"

asmlinkage long sys_quotactl(unsigned int cmd, const char *special, qid_t id, caddr_t addr)

132

sys_getpgid

 

 

"kernel/sys.c"

asmlinkage long sys_getpgid(pid_t pid)

133

sys_fchdir

 

 

"fs/open.c"

asmlinkage long sys_fchdir(unsigned int fd)

134

sys_bdflush

 

 

"fs/buffer.c"

asmlinkage long sys_bdflush(int func, long data)

135

sys_sysfs

 

 

"fs/filesystems.c"

asmlinkage long sys_sysfs(int option, unsigned long arg1, unsigned long arg2)

136

sys_personality

 

 

"kernel/exec_domain.c"

asmlinkage long sys_personality(u_long personality)
{
        u_long old = current->personality;
 
        if (personality != 0xffffffff) {
                set_personality(personality);
                if (current->personality != personality)
                        return -EINVAL;
        }
 
        return (long)old;

137

 

 

reserved for afs_syscall
syscall for Andrew File System

 

 

138

sys_setfsuid16

 

 

"kernel/uid16.c"

asmlinkage long sys_setfsuid16(old_uid_t uid)
{
        return sys_setfsuid((uid_t)uid);
}

139

sys_setfsgid16

 

 

"kernel/uid16.c"

asmlinkage long sys_setfsgid16(old_gid_t gid)
{
        return sys_setfsgid((gid_t)gid);
}

140

sys_llseek

 

 

"fs/read_write.c"

asmlinkage long sys_llseek(unsigned int fd, unsigned long offset_high,
                           unsigned long offset_low, loff_t __user * result,
                           unsigned int origin)

141

sys_getdents

 

 

"fs/readdir.c"

asmlinkage long sys_getdents(unsigned int fd, struct linux_dirent __user * dirent, unsigned int count)

142

sys_select

 

 

"fs/select.c"

asmlinkage long sys_select(int n, fd_set __user *inp, fd_set __user *outp, fd_set __user *exp, struct timeval __user *tvp)

143

sys_flock

      @fd: the file descriptor to lock.
     @cmd: the type of lock to apply.


 Apply a %FL_FLOCK style lock to an open file descriptor.

     The @cmd can be one of
     %LOCK_SH -- a shared lock.
     %LOCK_EX -- an exclusive lock.
     %LOCK_UN -- remove an existing lock.
     %LOCK_MAND -- a `mandatory' flock.

This exists to emulate Windows Share Modes.

     %LOCK_MAND can be combined with %LOCK_READ or %LOCK_WRITE to allow other  processes read and write access respectively.

 

"fs/locks.c"

asmlinkage long sys_flock(unsigned int fd, unsigned int cmd)

144

sys_msync

 

 

"mm/msync.c"

asmlinkage long sys_msync(unsigned long start, size_t len, int flags)

145

sys_readv

 

 

"fs/read_write.c"

asmlinkage ssize_t sys_readv(unsigned long fd, const struct iovec __user *vec, unsigned long vlen)

146

sys_writev

 

 

"fs/read_write.c"

asmlinkage ssize_t sys_writev(unsigned long fd, const struct iovec __user *vec, unsigned long vlen)

147

sys_getsid

 

 

"kernel/sys.c"

asmlinkage long sys_getsid(pid_t pid)

148

sys_fdatasync

 

 

"fs/buffer.c"

asmlinkage long sys_fdatasync(unsigned int fd)

149

sys_sysctl

 

 

"kernel/sysctl.c"

asmlinkage long sys_sysctl(struct __sysctl_args __user *args)

150

sys_mlock

 

 

"mm/mlock.c"

asmlinkage long sys_mlock(unsigned long start, size_t len)

151

sys_munlock

 

 

"mm/mlock.c"

asmlinkage long sys_munlock(unsigned long start, size_t len)

152

sys_mlockall

 

 

"mm/mlock.c"

asmlinkage long sys_mlockall(int flags)

153

sys_munlockall

 

 

"mm/mlock.c"

asmlinkage long sys_munlockall(void)

154

sys_sched_setparam

 set/change the RT priority of a thread

 

"kernel/sched.c"

asmlinkage long sys_sched_setparam(pid_t pid, struct sched_param __user *param)
{
        return setscheduler(pid, -1, param);
}

155

sys_sched_getparam

 get the RT priority of a thread

 

"kernel/sched.c"

asmlinkage long sys_sched_getparam(pid_t pid, struct sched_param __user *param)

156

sys_sched_setscheduler

 set/change the scheduler policy and RT priority

 

"kernel/sched.c"

asmlinkage long sys_sched_setscheduler(pid_t pid, int policy,
                                       struct sched_param __user *param)
{
        return setscheduler(pid, policy, param);
}

157

sys_sched_getscheduler

 get the policy (scheduling class) of a thread

 

"kernel/sched.c"

asmlinkage long sys_sched_getscheduler(pid_t pid)

158

sys_sched_yield

 yield the current processor to other threads.

 

"kernel/sched.c"

asmlinkage long sys_sched_yield(void)

159

sys_sched_get_priority_max

 return maximum RT priority

 

"kernel/sched.c"

asmlinkage long sys_sched_get_priority_max(int policy)

160

sys_sched_get_priority_min

 return minimum RT priority.

 

"kernel/sched.c"

asmlinkage long sys_sched_get_priority_min(int policy)

161

sys_sched_rr_get_interval

 return the default timeslice of a process.

 

"kernel/sched.c"

asmlinkage long sys_sched_rr_get_interval(pid_t pid, struct timespec __user *interval)

162

sys_nanosleep

 

 

"kernel/timer.c"

asmlinkage long sys_nanosleep(struct timespec __user *rqtp, struct timespec __user *rmtp)

163

sys_mremap

 

 

"mm/mremap.c"

asmlinkage unsigned long sys_mremap(unsigned long addr,
        unsigned long old_len, unsigned long new_len,
        unsigned long flags, unsigned long new_addr)

164

sys_setresuid16

 

 

"kernel/uid16.c"

asmlinkage long sys_setresuid16(old_uid_t ruid, old_uid_t euid, old_uid_t suid)
{
        return sys_setresuid(low2highuid(ruid), low2highuid(euid),
                low2highuid(suid));
}

165

sys_getresuid16

 

 

"kernel/uid16.c"

asmlinkage long sys_getresuid16(old_uid_t __user *ruid, old_uid_t __user *euid, old_uid_t __user *suid)

166

sys_vm86

 

 

"arch/i386/kernel/vm86.c"

asmlinkage int sys_vm86(unsigned long subfunction, struct vm86plus_struct __user * v86)

167

 

 

old sys_query_module

 

 

168

sys_poll

 

 

"fs/select.c"

asmlinkage long sys_poll(struct pollfd __user * ufds, unsigned int nfds, long timeout)

169

sys_nfsservctl

 

 

"fs/nfsctl.c"

long asmlinkage sys_nfsservctl(int cmd, struct nfsctl_arg __user *arg, void __user *res)

170

sys_setresgid16

 

 

"kernel/uid16.c"

asmlinkage long sys_setresgid16(old_gid_t rgid, old_gid_t egid, old_gid_t sgid)
{
        return sys_setresgid(low2highgid(rgid), low2highgid(egid),
                low2highgid(sgid));
}

171

sys_getresgid16

 

 

"kernel/uid16.c"

asmlinkage long sys_getresgid16(old_gid_t __user *rgid, old_gid_t __user *egid, old_gid_t __user *sgid)

172

sys_prctl

 

 

"kernel/sys.c"

asmlinkage long sys_prctl(int option, unsigned long arg2, unsigned long arg3,
                          unsigned long arg4, unsigned long arg5)

173

sys_rt_sigreturn

 

 

"arch/i386/kernel/signal.c"

asmlinkage int sys_rt_sigreturn(unsigned long __unused)

174

sys_rt_sigaction

 

 

"kernel/signal.c"

asmlinkage long sys_rt_sigaction(int sig,
                 const struct sigaction __user *act,
                 struct sigaction __user *oact,
                 size_t sigsetsize)

175

sys_rt_sigprocmask

 

 

"kernel/signal.c"

asmlinkage long sys_rt_sigprocmask(int how, sigset_t __user *set, sigset_t __user *oset, size_t sigsetsize)

176

sys_rt_sigpending

 

 

"kernel/signal.c"

asmlinkage long sys_rt_sigpending(sigset_t __user *set, size_t sigsetsize)
{
        return do_sigpending(set, sigsetsize);
}

177

sys_rt_sigtimedwait

 

 

"kernel/signal.c"

asmlinkage long sys_rt_sigtimedwait(const sigset_t __user *uthese,
                    siginfo_t __user *uinfo,
                    const struct timespec __user *uts,
                    size_t sigsetsize)

178

sys_rt_sigqueueinfo

 

 

"kernel/signal.c"

asmlinkage long sys_rt_sigqueueinfo(int pid, int sig, siginfo_t __user *uinfo)

179

sys_rt_sigsuspend

 

 

"arch/i386/kernel/signal.c"

asmlinkage int sys_rt_sigsuspend(sigset_t __user *unewset, size_t sigsetsize)

180

sys_pread64

 

 

"fs/read_write.c"

asmlinkage ssize_t sys_pread64(unsigned int fd, char __user *buf,
                             size_t count, loff_t pos)

181

sys_pwrite64

 

 

"fs/read_write.c"

asmlinkage ssize_t sys_pwrite64(unsigned int fd, const char __user *buf,
                              size_t count, loff_t pos)

182

sys_chown16

 

 

"kernel/uid16.c"

asmlinkage long sys_chown16(const char __user * filename, old_uid_t user, old_gid_t group)
{
        return sys_chown(filename, low2highuid(user), low2highgid(group));
}

183

sys_getcwd

 

 

"fs/dcache.c"

asmlinkage long sys_getcwd(char __user *buf, unsigned long size)

184

sys_capget

 get the capabilities of a given process.

 

"kernel/capability.c"

asmlinkage long sys_capget(cap_user_header_t header, cap_user_data_t dataptr)

185

sys_capset

 set capabilities for a given process, all processes, or all processes in a given process group.[pid is for the 'target' task.  'current' is the calling task.]

 

"kernel/capability.c"

asmlinkage long sys_capset(cap_user_header_t header, const cap_user_data_t data)

186

sys_sigaltstack

 

 

"arch/i386/kernel/signal.c"

asmlinkage int sys_sigaltstack(const stack_t __user *uss, stack_t __user *uoss)
{
        struct pt_regs *regs = (struct pt_regs *) &uss;
        return do_sigaltstack(uss, uoss, regs->esp);
}

187

sys_sendfile

 

 

"fs/read_write.c"

asmlinkage ssize_t sys_sendfile(int out_fd, int in_fd, off_t __user *offset, size_t count)

188

 

 

reserved for streams1
( getpmsg )

 

 

189

 

 

reserved for streams2
( putpmsg )

 

 

190

sys_vfork

 

 

"arch/i386/kernel/process.c"

asmlinkage int sys_vfork(struct pt_regs regs)
{
        return do_fork(CLONE_VFORK | CLONE_VM | SIGCHLD, regs.esp, &regs, 0, NULL, NULL);
}

191

sys_getrlimit

 

 

"kernel/sys.c"

asmlinkage long sys_getrlimit(unsigned int resource, struct rlimit __user *rlim)
{
        if (resource >= RLIM_NLIMITS)
                return -EINVAL;
        else
                return copy_to_user(rlim, current->rlim + resource, sizeof(*rlim))
                        ? -EFAULT : 0;
}

192

sys_mmap2

 

 

"arch/i386/kernel/sys_i386.c"

asmlinkage long sys_mmap2(unsigned long addr, unsigned long len,
        unsigned long prot, unsigned long flags,
        unsigned long fd, unsigned long pgoff)
{
        return do_mmap2(addr, len, prot, flags, fd, pgoff);
}

193

sys_truncate64

 

 

"fs/open.c"

asmlinkage long sys_truncate64(const char __user * path, loff_t length)
{
        return do_sys_truncate(path, length);
}

194

sys_ftruncate64

 

 

"fs/open.c"

asmlinkage long sys_ftruncate64(unsigned int fd, loff_t length)
{
        return do_sys_ftruncate(fd, length, 0);
}

195

sys_stat64

 

 

"fs/stat.c"

asmlinkage long sys_stat64(char __user * filename, struct stat64 __user * statbuf)
{
        struct kstat stat;
        int error = vfs_stat(filename, &stat);
 
        if (!error)
                error = cp_new_stat64(&stat, statbuf);
 
        return error;
}

196

sys_lstat64

 

 

"fs/stat.c"

asmlinkage long sys_lstat64(char __user * filename, struct stat64 __user * statbuf)
{
        struct kstat stat;
        int error = vfs_lstat(filename, &stat);
 
        if (!error)
                error = cp_new_stat64(&stat, statbuf);
 
        return error;
}

197

sys_fstat64

 

 

"fs/stat.c"

asmlinkage long sys_fstat64(unsigned long fd, struct stat64 __user * statbuf)
{
        struct kstat stat;
        int error = vfs_fstat(fd, &stat);
 
        if (!error)
                error = cp_new_stat64(&stat, statbuf);
 
        return error;
}

198

sys_lchown

 

 

"fs/open.c"

asmlinkage long sys_lchown(const char __user * filename, uid_t user, gid_t group)
{
        struct nameidata nd;
        int error;
 
        error = user_path_walk_link(filename, &nd);
        if (!error) {
                error = chown_common(nd.dentry, user, group);
                path_release(&nd);
        }
        return error;
}

199

sys_getuid

 

 

"kernel/timer.c"

asmlinkage long sys_getuid(void)
{
        /* Only we change this so SMP safe */
        return current->uid;
}

200

sys_getgid

 

 

"kernel/timer.c"

asmlinkage long sys_getgid(void)
{
        /* Only we change this so SMP safe */
        return current->gid;
}

201

sys_geteuid

 

 

"kernel/timer.c"

asmlinkage long sys_geteuid(void)
{
        /* Only we change this so SMP safe */
        return current->euid;
}

202

sys_getegid

 

 

"kernel/timer.c"

smlinkage long sys_getegid(void)
{
        /* Only we change this so SMP safe */
        return  current->egid;
}

203

sys_setreuid

 

 

"kernel/sys.c"

asmlinkage long sys_setreuid(uid_t ruid, uid_t euid)

204

sys_setregid

 

 

"kernel/sys.c"

asmlinkage long sys_setregid(gid_t rgid, gid_t egid)

205

sys_getgroups

 

 

"kernel/sys.c"

asmlinkage long sys_getgroups(int gidsetsize, gid_t __user *grouplist)

206

sys_setgroups

 

 

"kernel/sys.c"

asmlinkage long sys_setgroups(int gidsetsize, gid_t __user *grouplist)

207

sys_fchown

 

 

"fs/open.c"

asmlinkage long sys_fchown(unsigned int fd, uid_t user, gid_t group)
{
        struct file * file;
        int error = -EBADF;
 
        file = fget(fd);
        if (file) {
                error = chown_common(file->f_dentry, user, group);
                fput(file);
        }
        return error;
}

208

sys_setresuid

 

 

"kernel/sys.c"

asmlinkage long sys_setresuid(uid_t ruid, uid_t euid, uid_t suid)

209

sys_getresuid

 

 

"kernel/sys.c"

asmlinkage long sys_getresuid(uid_t __user *ruid, uid_t __user *euid, uid_t __user *suid)

210

sys_setresgid

 

 

"kernel/sys.c"

asmlinkage long sys_setresgid(gid_t rgid, gid_t egid, gid_t sgid)

211

sys_getresgid

 

 

"kernel/sys.c"

asmlinkage long sys_getresgid(gid_t __user *rgid, gid_t __user *egid, gid_t __user *sgid)

212

sys_chown

 

 

"fs/open.c"

asmlinkage long sys_chown(const char __user * filename, uid_t user, gid_t group)

213

sys_setuid

 

 

"kernel/sys.c"

asmlinkage long sys_setuid(uid_t uid)

214

sys_setgid

 

 

"kernel/sys.c"

asmlinkage long sys_setgid(gid_t gid)

215

sys_setfsuid

 

 

"kernel/sys.c"

asmlinkage long sys_setfsuid(uid_t uid)

216

sys_setfsgid

 

 

"kernel/sys.c"

asmlinkage long sys_setfsgid(gid_t gid)

217

sys_pivot_root

 

 

"fs/namespace.c"

asmlinkage long sys_pivot_root(const char __user *new_root, const char __user *put_old)

218

sys_mincore

 eturns the memory residency status of the pages in thecurrent process's address space specified by [addr, addr + len).The status is returned in a vector of bytes.  The least significant bit of each byte is 1 if the referenced page is in memory, otherwise it is zero. Because the status of a page can change after mincore() checks it but before it returns to the application, the returned vector may ontain stale information.  Only locked pages are guaranteed to remain in memory.

 

"mm/mincore.c"

asmlinkage long sys_mincore(unsigned long start, size_t len,
        unsigned char __user * vec) 

219

sys_madvise

 Applications can use madvise() to advise the kernel how it should handle paging I/O in this VM area.  The idea is to help the kernel use appropriate read-ahead and caching techniques.  The information provided is advisory only, and can be safely disregarded by the kernel without affecting the correct operation of the application.

 

"mm/madvise.c"

asmlinkage long sys_madvise(unsigned long start, size_t len_in, int behavior)

220

sys_getdents64

 

 

"fs/readdir.c"

asmlinkage long sys_getdents64(unsigned int fd, struct linux_dirent64 __user * dirent, unsigned int count)

221

sys_fcntl64

 

 

"fs/fcntl.c"

asmlinkage long sys_fcntl64(unsigned int fd, unsigned int cmd, unsigned long arg)

222

 

 

reserved for TUX

 

 

223

 

 

 

 

 

224

sys_gettid

 return the thread ID - the internal kernel "pid"

 

"kernel/timer.c"

asmlinkage long sys_gettid(void)
{
        return current->pid;
}

225

sys_readahead

 

 

"mm/filemap.c"

asmlinkage ssize_t sys_readahead(int fd, loff_t offset, size_t count)

226

sys_setxattr

 

 

"fs/xattr.c"

asmlinkage long sys_setxattr(char __user *path, char __user *name, void __user *value, size_t size, int flags)

227

sys_lsetxattr

 

 

"fs/xattr.c"

asmlinkage long sys_lsetxattr(char __user *path, char __user *name, void __user *value, size_t size, int flags)

228

sys_fsetxattr

 

 

"fs/xattr.c"

asmlinkage long sys_fsetxattr(int fd, char __user *name, void __user *value, size_t size, int flags)

229

sys_getxattr

 

 

"fs/xattr.c"

asmlinkage ssize_t sys_getxattr(char __user *path, char __user *name, void __user *value, size_t size)

230

sys_lgetxattr

 

 

"fs/xattr.c"

asmlinkage ssize_t sys_lgetxattr(char __user *path, char __user *name, void __user *value, size_t size)

231

sys_fgetxattr

 

 

"fs/xattr.c"

asmlinkage ssize_t sys_fgetxattr(int fd, char __user *name, void __user *value, size_t size)

232

sys_listxattr

 

 

"fs/xattr.c"

asmlinkage ssize_t sys_listxattr(char __user *path, char __user *list, size_t size)

233

sys_llistxattr

 

 

"fs/xattr.c"

asmlinkage ssize_t sys_llistxattr(char __user *path, char __user *list, size_t size)

234

sys_flistxattr

 

 

"fs/xattr.c"

asmlinkage ssize_t sys_flistxattr(int fd, char __user *list, size_t size)

235

sys_removexattr

 

 

"fs/xattr.c"

asmlinkage long sys_removexattr(char __user *path, char __user *name)

236

sys_lremovexattr

 

 

"fs/xattr.c"

asmlinkage long sys_lremovexattr(char __user *path, char __user *name)

237

sys_fremovexattr

 

 

"fs/xattr.c"

asmlinkage long sys_fremovexattr(int fd, char __user *name)

238

sys_tkill

 Send a signal to only one task, even if it's a CLONE_THREAD task.

 

"kernel/signal.c"

asmlinkage long sys_tkill(int pid, int sig)

239

sys_sendfile64

 

 

"fs/read_write.c"

asmlinkage ssize_t sys_sendfile64(int out_fd, int in_fd, loff_t __user *offset, size_t count)

240

sys_futex

 

 

"kernel/futex.c"

asmlinkage long sys_futex(u32 __user *uaddr, int op, int val,
                          struct timespec __user *utime, u32 __user *uaddr2,
                          int val3)

241

sys_sched_setaffinity

 set the cpu affinity of a process

 

"kernel/sched.c"

asmlinkage long sys_sched_setaffinity(pid_t pid, unsigned int len,
                                      unsigned long __user *user_mask_ptr)

242

sys_sched_getaffinity

 get the cpu affinity of a process

 

"kernel/sched.c"

asmlinkage long sys_sched_getaffinity(pid_t pid, unsigned int len,
                                      unsigned long __user *user_mask_ptr)

243

sys_set_thread_area

 Set a given TLS descriptor

 

"arch/i386/kernel/process.c"

asmlinkage int sys_set_thread_area(struct user_desc __user *u_info)

244

sys_get_thread_area

 

 

"arch/i386/kernel/process.c"

asmlinkage int sys_get_thread_area(struct user_desc __user *u_info)

245

sys_io_setup

 Create an aio_context capable of receiving at least nr_events. ctxp must not point to an aio_context that already exists, and must be initialized to 0 prior to the call.  On successful creation of the aio_context, *ctxp is filled in with the resulting handle.  May fail with -EINVAL if *ctxp is not initialized, if the specified nr_events exceeds internal limits.  May fail with -EAGAIN if the specified nr_events exceeds the user's limit of available events.  May fail with -ENOMEM if insufficient kernel resources are available.  May fail with -EFAULT if an invalid pointer is passed for ctxp.  Will fail with -ENOSYS if not implemented.

 

"fs/aio.c"

asmlinkage long sys_io_setup(unsigned nr_events, aio_context_t __user *ctxp)

246

sys_io_destroy

 Destroy the aio_context specified.  May cancel any outstanding AIOs and block on completion.  Will fail with -ENOSYS if not implemented.  May fail with -EFAULT if the context pointed to is invalid.

 

"fs/aio.c"

asmlinkage long sys_io_destroy(aio_context_t ctx)

247

sys_io_getevents

 Attempts to read at least min_nr events and up to nr events from the completion queue for the aio_context specified by ctx_id.  May fail with -EINVAL if ctx_id is invalid, if min_nr is out of range, if nr is out of range, if when is out of range.  May fail with -EFAULT if any of the memory specified to is invalid.  May return 0 or < min_nr if no events are available and the timeout specified by when has elapsed, where when == NULL specifies an infinite timeout.  Note that the timeout pointed to by when is relative and will be updated if not NULL and the operation blocks.  Will fail with -ENOSYS if not implemented.

 

"fs/aio.c"

asmlinkage long sys_io_getevents(aio_context_t ctx_id,
                                 long min_nr,
                                 long nr,
                                 struct io_event __user *events,
                                 struct timespec __user *timeout)

248

sys_io_submit

 Queue the nr iocbs pointed to by iocbpp for processing.  Returns the number of iocbs queued.  May return -EINVAL if the aio_context specified by ctx_id is invalid, if nr is < 0, if the iocb at *iocbpp[0] is not properly initialized, if the operation specified is invalid for the file descriptor in the iocb.  May fail with -EFAULT if any of the data structures point to invalid data.  May fail with -EBADF if the file descriptor specified in the first iocb is invalid.  May fail with -EAGAIN if insufficient resources are available to queue any iocbs.  Will return 0 if nr is 0.  Will fail with -ENOSYS if not implemented.

 

"fs/aio.c"

asmlinkage long sys_io_submit(aio_context_t ctx_id, long nr,
                              struct iocb __user * __user *iocbpp)

249

sys_io_cancel

 Attempts to cancel an iocb previously passed to io_submit.  If the operation is successfully cancelled, the resulting event is copied into the memory pointed to by result without being placed into the completion queue and 0 is returned.  May fail with -EFAULT if any of the data structures pointed to are invalid. May fail with -EINVAL if aio_context specified by ctx_id is invalid.  May fail with -EAGAIN if the iocb specified was not cancelled.  Will fail with -ENOSYS if not implemented.

 

"fs/aio.c"

smlinkage long sys_io_cancel(aio_context_t ctx_id, struct iocb __user *iocb,
                              struct io_event __user *result)

250

sys_fadvise64

 

 

"mm/fadvise.c"

asmlinkage long sys_fadvise64(int fd, loff_t offset, size_t len, int advice)
{
        return sys_fadvise64_64(fd, offset, len, advice);
}

251

 

 

 

 

 

252

sys_exit_group

this kills every thread in the thread group. Note that any externally wait4()-ing process will get the correct exit code - even if this thread is not the thread group leader.

 

"kernel/exit.c"

asmlinkage void sys_exit_group(int error_code)
{
        do_group_exit((error_code & 0xff) << 8);
}

253

sys_lookup_dcookie

 

 

"fs/dcookies.c"

asmlinkage long sys_lookup_dcookie(u64 cookie64, char __user * buf, size_t len)

254

sys_epoll_create

 It opens an eventpoll file descriptor by suggesting a storage of "size" file descriptors. The size parameter is just an hint about how to size data structures. It won't prevent the user to store more than "size" file descriptors inside the epoll interface. It is the kernel part of the userspace epoll_create(2).

 

"fs/eventpoll.c"

asmlinkage long sys_epoll_create(int size)

255

sys_epoll_ctl

 The following function implements the controller interface for the eventpoll file that enables the insertion/removal/change of file descriptors inside the interest set.  It represents the kernel part of the user space epoll_ctl(2).

 

"fs/eventpoll.c"

asmlinkage long sys_epoll_ctl(int epfd, int op, int fd, struct epoll_event __user *event)

256

sys_epoll_wait

Implement the event wait interface for the eventpoll file. It is the kernel part of the user space epoll_wait(2).

 

"fs/eventpoll.c"

asmlinkage long sys_epoll_wait(int epfd, struct epoll_event __user *events,
                               int maxevents, int timeout)

257

sys_remap_file_pages

 sys_remap_file_pages - remap arbitrary pages of a shared backing store file within an existing vma.

 

 

asmlinkage long sys_remap_file_pages(unsigned long start, unsigned long size,
        unsigned long __prot, unsigned long pgoff, unsigned long flags)

258

sys_set_tid_address

 

 

"kernel/fork.c"

asmlinkage long sys_set_tid_address(int __user *tidptr)
{
        current->clear_child_tid = tidptr;
 
        return current->pid;
}

259

sys_timer_create

 Create a POSIX.1b interval timer

 

"kernel/posix-timers.c"

asmlinkage long sys_timer_create(clockid_t which_clock,
                 struct sigevent __user *timer_event_spec,
                 timer_t __user * created_timer_id)

260

sys_timer_settime

 Set a POSIX.1b interval timer

 

"kernel/posix-timers.c"

asmlinkage long sys_timer_settime(timer_t timer_id, int flags,
                  const struct itimerspec __user *new_setting,
                  struct itimerspec __user *old_setting)

261

sys_timer_gettime

 Get the time remaining on a POSIX.1b interval timer.

 

"kernel/posix-timers.c"

asmlinkage long sys_timer_gettime(timer_t timer_id, struct itimerspec __user *setting)

262

sys_timer_getoverrun

 Get the number of overruns of a POSIX.1b interval timer.  This is to be the overrun of the timer last delivered.  At the same time we are accumulating overruns on the next timer.  The overrun is frozen when the signal is delivered, either at the notify time (if the info block is not queued) or at the actual delivery time (as we are informed by the call back to do_schedule_next_timer().  So all we need to do is to pick up the frozen overrun.

 

"kernel/posix-timers.c"

asmlinkage long sys_timer_getoverrun(timer_t timer_id)

263

sys_timer_delete

 Delete a POSIX.1b interval timer.

 

"kernel/posix-timers.c"

sys_timer_delete(timer_t timer_id)

264

sys_clock_settime

 

 

"kernel/posix-timers.c"

asmlinkage long sys_clock_settime(clockid_t which_clock, const struct timespec __user *tp)

265

sys_clock_gettime

 

 

"kernel/posix-timers.c"

asmlinkage long sys_clock_gettime(clockid_t which_clock, struct timespec __user *tp)

266

sys_clock_getres

 

 

"kernel/posix-timers.c"

asmlinkage long sys_clock_getres(clockid_t which_clock, struct timespec __user *tp)

267

sys_clock_nanosleep

 

 

"kernel/posix-timers.c"

asmlinkage long sys_clock_nanosleep(clockid_t which_clock, int flags,
                    const struct timespec __user *rqtp,
                    struct timespec __user *rmtp)

268

sys_statfs64

 

 

"fs/open.c"

asmlinkage long sys_statfs64(const char __user *path, size_t sz, struct statfs64 __user *buf)

269

sys_fstatfs64

 

 

"fs/open.c"

asmlinkage long sys_fstatfs64(unsigned int fd, size_t sz, struct statfs64 __user *buf)

270

sys_tgkill

 sys_tgkill - send signal to one specific thread

 

"kernel/signal.c"

asmlinkage long sys_tgkill(int tgid, int pid, int sig)

271

sys_utimes

 

 

"fs/open.c"

smlinkage long sys_utimes(char __user * filename, struct timeval __user * utimes)
{
        struct timeval times[2];
 
        if (utimes && copy_from_user(&times, utimes, sizeof(times)))
                return -EFAULT;
        return do_utimes(filename, utimes ? times : NULL);
}

272

sys_fadvise64_64

 

 

"mm/fadvise.c"

asmlinkage long sys_fadvise64_64(int fd, loff_t offset, loff_t len, int advice)

273

 

 

sys_vserver

 

 

274

sys_mbind

 Change policy for a memory range

 

"mm/mempolicy.c"

asmlinkage long sys_mbind(unsigned long start, unsigned long len,
                          unsigned long mode,
                          unsigned long __user *nmask, unsigned long maxnode,
                          unsigned flags)

275

sys_get_mempolicy

 Retrieve NUMA policy

 

"mm/mempolicy.c"

asmlinkage long sys_get_mempolicy(int __user *policy,
                                  unsigned long __user *nmask,
                                  unsigned long maxnode,
                                  unsigned long addr, unsigned long flags)

276

sys_set_mempolicy

 Set the process memory policy

 

"mm/mempolicy.c"

asmlinkage long sys_set_mempolicy(int mode, unsigned long __user *nmask,
                                   unsigned long maxnode)

277

sys_mq_open

 

 

"ipc/mqueue.c"

asmlinkage long sys_mq_open(const char __user *u_name, int oflag, mode_t mode,
                                struct mq_attr __user *u_attr)

278

sys_mq_unlink

 

 

"ipc/mqueue.c"

asmlinkage long sys_mq_unlink(const char __user *u_name)

279

sys_mq_timedsend

 

 

"ipc/mqueue.c"

asmlinkage long sys_mq_timedsend(mqd_t mqdes, const char __user *u_msg_ptr,
        size_t msg_len, unsigned int msg_prio,
        const struct timespec __user *u_abs_timeout)

280

sys_mq_timedreceive

 

 

"ipc/mqueue.c"

asmlinkage ssize_t sys_mq_timedreceive(mqd_t mqdes, char __user *u_msg_ptr,
        size_t msg_len, unsigned int __user *u_msg_prio,
        const struct timespec __user *u_abs_timeout)

281

sys_mq_notify

 

 

"ipc/mqueue.c"

asmlinkage long sys_mq_notify(mqd_t mqdes,
                                const struct sigevent __user *u_notification)

282

sys_mq_getsetattr

 

 

"ipc/mqueue.c"

asmlinkage long sys_mq_getsetattr(mqd_t mqdes,
                        const struct mq_attr __user *u_mqstat,
                        struct mq_attr __user *u_omqstat)

283

 

 

reserved for kexec

 

 

284

sys_waitid

 

 

"kernel/exit.c"

asmlinkage long sys_waitid(int which, pid_t pid,
                           struct siginfo __user *infop, int options,
                           struct rusage __user *ru)

285

 

 

available?

 

 

286

sys_add_key

extract the description of a new key from userspace and either add it as a new key to the specified keyring or update a matching key in that keyring

- the keyring must be writable
- returns the new key's serial number
- implements add_key()

 

"security/keys/keyctl.c"

asmlinkage long sys_add_key(const char __user *_type,
                            const char __user *_description,
                            const void __user *_payload,
                            size_t plen,
                            key_serial_t ringid)

287

sys_request_key

search the process keyrings for a matching key

- nested keyrings may also be searched if they have Search permission
- if a key is found, it will be attached to the destination keyring if there's one specified
- /sbin/request-key will be invoked if _callout_info is non-NULL
- the _callout_info string will be passed to /sbin/request-key
- if the _callout_info string is empty, it will be rendered as "-"
- implements request_key()

 

"security/keys/keyctl.c"

asmlinkage long sys_request_key(const char __user *_type,
                                const char __user *_description,
                                const char __user *_callout_info,
                                key_serial_t destringid)

288

sys_keyctl

the key control system call

 

"security/keys/keyctl.c"

asmlinkage long sys_keyctl(int option, unsigned long arg2, unsigned long arg3,
                           unsigned long arg4, unsigned long arg5)

289

sys_ioprio_set

 

 

"fs/ioprio.c"

asmlinkage long sys_ioprio_set(int which, int who, int ioprio)

290

sys_ioprio_get

 

 

"fs/ioprio.c"

asmlinkage long sys_ioprio_get(int which, int who)

291

sys_inotify_init

 

 

"fs/inotify.c"

asmlinkage long sys_inotify_init(void)

292

sys_inotify_add_watch

 

 

"fs/inotify.c"

asmlinkage long sys_inotify_add_watch(int fd, const char __user *path, u32 mask)

293

sys_inotify_rm_watch

 

 

"fs/inotify.c"

asmlinkage long sys_inotify_rm_watch(int fd, u32 wd)

 

 

 

References

 

http://world.std.com/~slanning/asm/syscall_list.html

http://www.linuxassembly.org/

http://www.bigfoot.com/~jialong_he

 

From Linux 2.6.11 source code

include/asm-i386/unistd.h
arch/i386/kernel/entry.S

 

From Linux 2.6.15.6

arch/i386/kernel/syscall_table.S