sys_ni.c 6.3 KB
Newer Older
L
Linus Torvalds 已提交
1 2 3 4 5 6

#include <linux/linkage.h>
#include <linux/errno.h>

#include <asm/unistd.h>

7 8 9 10
/*  we can't #include <linux/syscalls.h> here,
    but tell gcc to not warn with -Wmissing-prototypes  */
asmlinkage long sys_ni_syscall(void);

L
Linus Torvalds 已提交
11 12 13 14 15 16 17 18 19
/*
 * Non-implemented system calls get redirected here.
 */
asmlinkage long sys_ni_syscall(void)
{
	return -ENOSYS;
}

cond_syscall(sys_quotactl);
20
cond_syscall(sys32_quotactl);
L
Linus Torvalds 已提交
21 22
cond_syscall(sys_acct);
cond_syscall(sys_lookup_dcookie);
A
Al Viro 已提交
23
cond_syscall(compat_sys_lookup_dcookie);
L
Linus Torvalds 已提交
24 25
cond_syscall(sys_swapon);
cond_syscall(sys_swapoff);
26 27
cond_syscall(sys_kexec_load);
cond_syscall(compat_sys_kexec_load);
28
cond_syscall(sys_kexec_file_load);
L
Linus Torvalds 已提交
29
cond_syscall(sys_init_module);
30
cond_syscall(sys_finit_module);
L
Linus Torvalds 已提交
31 32 33 34 35
cond_syscall(sys_delete_module);
cond_syscall(sys_socketpair);
cond_syscall(sys_bind);
cond_syscall(sys_listen);
cond_syscall(sys_accept);
U
Ulrich Drepper 已提交
36
cond_syscall(sys_accept4);
L
Linus Torvalds 已提交
37 38 39 40 41 42 43 44 45
cond_syscall(sys_connect);
cond_syscall(sys_getsockname);
cond_syscall(sys_getpeername);
cond_syscall(sys_sendto);
cond_syscall(sys_send);
cond_syscall(sys_recvfrom);
cond_syscall(sys_recv);
cond_syscall(sys_socket);
cond_syscall(sys_setsockopt);
46
cond_syscall(compat_sys_setsockopt);
L
Linus Torvalds 已提交
47
cond_syscall(sys_getsockopt);
48
cond_syscall(compat_sys_getsockopt);
L
Linus Torvalds 已提交
49 50
cond_syscall(sys_shutdown);
cond_syscall(sys_sendmsg);
51
cond_syscall(sys_sendmmsg);
52
cond_syscall(compat_sys_sendmsg);
53
cond_syscall(compat_sys_sendmmsg);
L
Linus Torvalds 已提交
54
cond_syscall(sys_recvmsg);
55
cond_syscall(sys_recvmmsg);
56
cond_syscall(compat_sys_recvmsg);
57
cond_syscall(compat_sys_recv);
58
cond_syscall(compat_sys_recvfrom);
59
cond_syscall(compat_sys_recvmmsg);
L
Linus Torvalds 已提交
60 61 62
cond_syscall(sys_socketcall);
cond_syscall(sys_futex);
cond_syscall(compat_sys_futex);
63 64 65 66
cond_syscall(sys_set_robust_list);
cond_syscall(compat_sys_set_robust_list);
cond_syscall(sys_get_robust_list);
cond_syscall(compat_sys_get_robust_list);
L
Linus Torvalds 已提交
67
cond_syscall(sys_epoll_create);
68
cond_syscall(sys_epoll_create1);
L
Linus Torvalds 已提交
69 70
cond_syscall(sys_epoll_ctl);
cond_syscall(sys_epoll_wait);
71
cond_syscall(sys_epoll_pwait);
72
cond_syscall(compat_sys_epoll_pwait);
L
Linus Torvalds 已提交
73 74 75
cond_syscall(sys_semget);
cond_syscall(sys_semop);
cond_syscall(sys_semtimedop);
76
cond_syscall(compat_sys_semtimedop);
L
Linus Torvalds 已提交
77
cond_syscall(sys_semctl);
78
cond_syscall(compat_sys_semctl);
L
Linus Torvalds 已提交
79 80
cond_syscall(sys_msgget);
cond_syscall(sys_msgsnd);
81
cond_syscall(compat_sys_msgsnd);
L
Linus Torvalds 已提交
82
cond_syscall(sys_msgrcv);
83
cond_syscall(compat_sys_msgrcv);
L
Linus Torvalds 已提交
84
cond_syscall(sys_msgctl);
85
cond_syscall(compat_sys_msgctl);
L
Linus Torvalds 已提交
86
cond_syscall(sys_shmget);
S
Stephen Rothwell 已提交
87
cond_syscall(sys_shmat);
88
cond_syscall(compat_sys_shmat);
L
Linus Torvalds 已提交
89 90
cond_syscall(sys_shmdt);
cond_syscall(sys_shmctl);
91
cond_syscall(compat_sys_shmctl);
L
Linus Torvalds 已提交
92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113
cond_syscall(sys_mq_open);
cond_syscall(sys_mq_unlink);
cond_syscall(sys_mq_timedsend);
cond_syscall(sys_mq_timedreceive);
cond_syscall(sys_mq_notify);
cond_syscall(sys_mq_getsetattr);
cond_syscall(compat_sys_mq_open);
cond_syscall(compat_sys_mq_timedsend);
cond_syscall(compat_sys_mq_timedreceive);
cond_syscall(compat_sys_mq_notify);
cond_syscall(compat_sys_mq_getsetattr);
cond_syscall(sys_mbind);
cond_syscall(sys_get_mempolicy);
cond_syscall(sys_set_mempolicy);
cond_syscall(compat_sys_mbind);
cond_syscall(compat_sys_get_mempolicy);
cond_syscall(compat_sys_set_mempolicy);
cond_syscall(sys_add_key);
cond_syscall(sys_request_key);
cond_syscall(sys_keyctl);
cond_syscall(compat_sys_keyctl);
cond_syscall(compat_sys_socketcall);
R
Robert Love 已提交
114
cond_syscall(sys_inotify_init);
U
Ulrich Drepper 已提交
115
cond_syscall(sys_inotify_init1);
R
Robert Love 已提交
116 117
cond_syscall(sys_inotify_add_watch);
cond_syscall(sys_inotify_rm_watch);
118
cond_syscall(sys_migrate_pages);
119
cond_syscall(sys_move_pages);
120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138
cond_syscall(sys_chown16);
cond_syscall(sys_fchown16);
cond_syscall(sys_getegid16);
cond_syscall(sys_geteuid16);
cond_syscall(sys_getgid16);
cond_syscall(sys_getgroups16);
cond_syscall(sys_getresgid16);
cond_syscall(sys_getresuid16);
cond_syscall(sys_getuid16);
cond_syscall(sys_lchown16);
cond_syscall(sys_setfsgid16);
cond_syscall(sys_setfsuid16);
cond_syscall(sys_setgid16);
cond_syscall(sys_setgroups16);
cond_syscall(sys_setregid16);
cond_syscall(sys_setresgid16);
cond_syscall(sys_setresuid16);
cond_syscall(sys_setreuid16);
cond_syscall(sys_setuid16);
139 140
cond_syscall(sys_sgetmask);
cond_syscall(sys_ssetmask);
141 142
cond_syscall(sys_vm86old);
cond_syscall(sys_vm86);
C
Christoph Hellwig 已提交
143
cond_syscall(sys_ipc);
144 145
cond_syscall(compat_sys_ipc);
cond_syscall(compat_sys_sysctl);
146
cond_syscall(sys_flock);
T
Thomas Petazzoni 已提交
147 148 149 150 151
cond_syscall(sys_io_setup);
cond_syscall(sys_io_destroy);
cond_syscall(sys_io_submit);
cond_syscall(sys_io_cancel);
cond_syscall(sys_io_getevents);
152
cond_syscall(sys_sysfs);
153
cond_syscall(sys_syslog);
C
Christopher Yeoh 已提交
154 155 156 157
cond_syscall(sys_process_vm_readv);
cond_syscall(sys_process_vm_writev);
cond_syscall(compat_sys_process_vm_readv);
cond_syscall(compat_sys_process_vm_writev);
158
cond_syscall(sys_uselib);
159 160 161
cond_syscall(sys_fadvise64);
cond_syscall(sys_fadvise64_64);
cond_syscall(sys_madvise);
L
Linus Torvalds 已提交
162 163 164 165 166

/* arch-specific weak syscall entries */
cond_syscall(sys_pciconfig_read);
cond_syscall(sys_pciconfig_write);
cond_syscall(sys_pciconfig_iobase);
A
Al Viro 已提交
167
cond_syscall(compat_sys_s390_ipc);
L
Linus Torvalds 已提交
168
cond_syscall(ppc_rtas);
169 170
cond_syscall(sys_spu_run);
cond_syscall(sys_spu_create);
171
cond_syscall(sys_subpage_prot);
172 173 174 175 176 177 178 179 180 181 182 183

/* mmu depending weak syscall entries */
cond_syscall(sys_mprotect);
cond_syscall(sys_msync);
cond_syscall(sys_mlock);
cond_syscall(sys_munlock);
cond_syscall(sys_mlockall);
cond_syscall(sys_munlockall);
cond_syscall(sys_mincore);
cond_syscall(sys_madvise);
cond_syscall(sys_mremap);
cond_syscall(sys_remap_file_pages);
184
cond_syscall(compat_sys_move_pages);
185
cond_syscall(compat_sys_migrate_pages);
186 187 188 189 190

/* block-layer dependent */
cond_syscall(sys_bdflush);
cond_syscall(sys_ioprio_set);
cond_syscall(sys_ioprio_get);
191 192 193

/* New file descriptors */
cond_syscall(sys_signalfd);
U
Ulrich Drepper 已提交
194
cond_syscall(sys_signalfd4);
195
cond_syscall(compat_sys_signalfd);
196
cond_syscall(compat_sys_signalfd4);
D
Davide Libenzi 已提交
197 198 199 200 201
cond_syscall(sys_timerfd_create);
cond_syscall(sys_timerfd_settime);
cond_syscall(sys_timerfd_gettime);
cond_syscall(compat_sys_timerfd_settime);
cond_syscall(compat_sys_timerfd_gettime);
202
cond_syscall(sys_eventfd);
U
Ulrich Drepper 已提交
203
cond_syscall(sys_eventfd2);
D
David Herrmann 已提交
204
cond_syscall(sys_memfd_create);
T
Thomas Gleixner 已提交
205 206

/* performance counters: */
207
cond_syscall(sys_perf_event_open);
208 209 210

/* fanotify! */
cond_syscall(sys_fanotify_init);
211
cond_syscall(sys_fanotify_mark);
212
cond_syscall(compat_sys_fanotify_mark);
213 214 215

/* open by handle */
cond_syscall(sys_name_to_handle_at);
216 217
cond_syscall(sys_open_by_handle_at);
cond_syscall(compat_sys_open_by_handle_at);
218 219 220

/* compare kernel pointers */
cond_syscall(sys_kcmp);
K
Kees Cook 已提交
221 222 223

/* operate on Secure Computing state */
cond_syscall(sys_seccomp);
224 225 226

/* access BPF programs and maps */
cond_syscall(sys_bpf);